Sender | Message | Time |
---|---|---|
13 Apr 2024 | ||
vylsaz | Well I think one shouldn't run cmd.exe with user input to begin with | 06:31:05 |
loke | In reply to @ecy00:matrix.orgThere is also the locale that is involved. And don't forget about Japanese windows and how it uses a path separator | 06:32:12 |
LoneTech | sort of. the path separator is just an illegal character as far as the fs structures are concerned. lots of those, not to mention special device names. | 06:33:10 |
loke | * There is also the locale that is involved. And don't forget about Japanese windows and how it uses a diffrrent path separator, which leaks into the unicode representation of files | 06:33:20 |
LoneTech | macos also has multiple path separators (classically : or unixly /) | 06:35:11 |
LoneTech | it just happens to leak less because many systems use : for other special uses, but / leaked all the same in classic macos, archival tool ports had to translate | 06:37:27 |
LoneTech | found via a cygwin mailing list discussion highlighting how cygwin and msvcrt disagree on quoting: https://learn.microsoft.com/en-us/archive/blogs/twistylittlepassagesallalike/everyone-quotes-command-line-arguments-the-wrong-way | 06:40:50 |
loke | But when they moved to OSX the API's were all Unix and the UI handled all the conversion. That's the right thing to do, and something Microsoft always takes to do. Like the Program Files directory being localised in the filesystem instead of in the UI. Or early versions of VBA having different reoresentations of translated commands so files were incompatible between different languages. | 06:42:12 |
loke | * But when they moved to OSX the API's were all Unix and the UI handled all the conversion. That's the right thing to do, and something Microsoft always fails to do. Like the Program Files directory being localised in the filesystem instead of in the UI. Or early versions of VBA having different reoresentations of translated commands so files were incompatible between different languages. | 06:42:45 |
LoneTech | Excel did that mess before VBA, I think. And it did it worse; it remapped hotkeys too. | 06:44:15 |
LoneTech | huh. I guess Rust people got the idea that cmd was the special case from that article. meanwhile, batch files were originally executed by command, not cmd, and it had different rules still. | 06:50:28 |
LoneTech | and the command interpreter is another configurable choice | 06:50:50 |
LoneTech | I wonder how many people have it set to powershell? | 06:59:47 |
dzaima | ↰ LoneTech (well, not just rust, but a bunch of languages, i.e. all that want to be sanely usable; but unfortunately windows sucks at allowing for sane things to exist) | 13:01:52 |
dzaima | (and we all know that if multiple language runtimes mess up the conversion (if this case even qualifies as "messing it up"), individual language users will sure as hell mess it up a ton more, you just won't get to assign a single nice CVE for it) | 13:06:03 |
vylsaz | Another bug on windows... weird newlines with redirected output | 18:50:07 |
vylsaz | I think it's caused by •Out mixes replxx_print and standard putchar() | 18:51:50 |
14 Apr 2024 | ||
simpalaxy joined the room. | 08:07:05 | |
brian_e | i want to apply 4 functions where each function is applied to one group, but the ⊔ primitive doesn't always return 4 groups, so i can't just use ¨ . I do have a solution but i don't like it that much
Is there some other way to group with a specific amount of output lists, or maybe not needing the ⍷i ? | 22:24:49 |
dzaima | you can just 4↑𝕨⊔𝕩 | 22:25:29 |
dzaima | that'll always pad with empty arrays | 22:25:37 |
dzaima | ⍷i probably doesn't even do what you want on i←0‿2‿1 , and errors on i←2‿1 | 22:27:38 |
brian_e | oh nice, for some reason i thought 4‿4‿4‿4‿4⊔"abcde" would return ⟨"abcde"⟩ instead of padding the first 4 spots with ⟨⟩ | 22:28:02 |
dzaima | that's what APLs ⌸ is more like | 22:28:23 |
brian_e | and yeah now my solution is very broken | 22:28:25 |
dzaima | but BQNs ⊔ always puts things at the exact indices in 𝕨 | 22:28:39 |
brian_e | that's nice | 22:28:48 |
brian_e | thanks | 22:29:00 |
dzaima | (also, instead of 4↑𝕨⊔𝕩 there's (𝕨∾4)⊔𝕩 depending on how you're feeling) | 22:29:05 |
brian_e | uhhh𝕨∾4 does look disgusting i must say but that's neat i guess? | 22:30:15 |