00:10 finanalyst joined 00:14 finanalyst left 00:41 finanalyst joined 00:45 finanalyst left 01:11 finanalyst joined 01:16 finanalyst left 01:26 Voldenet left 01:27 Voldenet joined 01:42 finanalyst joined 01:47 finanalyst left 02:13 finanalyst joined 02:17 finanalyst left 02:44 finanalyst joined 02:48 finanalyst left 03:14 finanalyst joined 03:19 finanalyst left 03:45 finanalyst joined 03:50 finanalyst left 04:16 finanalyst joined 04:20 finanalyst left 04:47 finanalyst joined 04:51 finanalyst left 05:17 finanalyst joined 05:22 finanalyst left 05:40 Pixi left 05:41 Pixi joined 05:48 finanalyst joined 05:52 finanalyst left 06:49 finanalyst joined 06:54 finanalyst left 07:20 finanalyst joined 07:24 finanalyst left 07:51 finanalyst joined 07:56 finanalyst left 08:22 finanalyst joined 08:27 finanalyst left 08:45 ShimmerFairy left, ShimmerFairy joined
Geth rakudo/main: 4b5d0071af | (Elizabeth Mattijsen)++ (committed using GitHub Web editor) | src/core.c/IO/Path.rakumod
Re-imagine IO::Path.resolve (#6906)

Several goals to be achieved here: 1. make it fully functional on Windows as well
This has been attempted by completely agnostically accept both
  / and \ as path separators when parsing paths, and to always allow
... (7 more lines)
08:51
08:52 finanalyst joined 08:57 finanalyst left
Geth rakudo/main: 75698c709a | (Elizabeth Mattijsen)++ (committed using GitHub Web editor) | src/core.c/IO/Path.rakumod
Add IO::Path.resolve-inside method (#6904)

Returns a possibly updated IO::Pathwith the absolute resolved path of the invocant if it is inside the absolute resolved path of the IO::Path given.
my $resolved = $io.resolve-inside($root)
Requires the $root to be a directory (otherwise the invocant could never be "inside" of the root anyway). Based in .resolve(:completely).
09:01
timo lizmat: are you aware that you can make directories on linux that have a backslash in them? 09:02
lizmat yes 09:03
timo then i might have misread the commit message
lizmat no, you haven't I think
you probably also can make directories on WIn systems with forward slashes in them? 09:04
it *is* a minefield
timo c: 4b5d0071af^,4b5d0071af dd IO::Path.new("/tmp/what\\is_this").resolve 09:05
committable6 timo, ¦4b5d0071af^: «IO::Path.new("/tmp/what\\is_this", :SPEC(IO::Spec::Unix), :CWD("/"))␤» ¦4b5d007: «IO::Path.new("/tmp/what/is_this", :SPEC(IO::Spec::Unix), :CWD("/"))␤»
timo that seems bad
lizmat so you're saying we should only accept $!SPEC.dir-sep? 09:06
timo probably
09:23 finanalyst joined
lizmat hmmm.. doing that breaks a spectest 09:24
I'm inclined to keep the current change, and see if it breaks anything in blin 09:26
not ok 15 - IO::Path::Win32 with "../foo"
# Failed test 'IO::Path::Win32 with "../foo"'
# at t/spec/S32-io/io-path.t line 228
# expected: IO::Path::Win32.new("/Users/liz/Github/rakudo\\../bar", :CWD("\\"))
09:28 finanalyst left
timo I think backslash and forward slash are equivalent on windows 09:30
lizmat m: dd IO::Spec::Win32.dir-sep 09:33
camelia "\\"
lizmat that's not what we haz here ?
timo yeah, dir-sep is a Str, not a List or Set, right?
lizmat indeed... now, I could fix .resolve
timo I don't expect blin to show trouble for treating backslashes as forward slashes on linux (or mac) since it'd already be kinda weird to use backslashes in file or folder names in the first place 09:38
a friend tells me there are no APIs in windows that accept forward slashes except for APIs that are for URLs where forward slashes are the correct separater 09:43
separator*
so my assumption that forward and backward slashes are equivalent was actually wrong and it's maybe just some programs or higher-level APIs that allow you to use forward slashes to mean back slashes 09:44
lizmat ok, so if .resolve uses the $!SPEC.dir-sep, we have one spectest fail 09:50
should the test be fixed?
timo I would very much hope someone who gets tortured regularly by windows can chime in 09:51
OK, my friend says UNC paths also use forward slashes and UNC paths can go into many older APIs on newer windows versions 09:53
09:54 finanalyst joined 09:58 finanalyst left
ShimmerFairy On Windows, you can generally use both kinds of slashes on directory separators. On POSIX, only / is a path separator, and \ is a legal filename character (along with everything else, save for / and null). 10:02
As an example of where inspiration may be found, in C++ the std::filesystem::path class understands the concept of a "preferred separator", which may be (and on Windows is) distinct from the "portable" separator. 10:05
timo do we need to do something to support ¥ as path separators? :D 10:10
Geth rakudo/lizmat-115: 5650ae8bfe | (Elizabeth Mattijsen)++ | src/core.c/IO/Path.rakumod
Only support / and \ on IO::Spec::Win32 on IO::Path.resolve

On all other systems, only / is allowed as a directory separator.
  timo++, ShimmerFairy++ for the nudge
10:11
rakudo: lizmat++ created pull request #6909:
Only support / and \ on IO::Spec::Win32 on IO::Path.resolve
lizmat this at least is spectest clean for me
timo thanks for the input ShimmerFairy! 10:14
ShimmerFairy No problem, glad I could help, esp. with something as gnarly as pathname handling. (Another inspiration source which is good to keep in mind, just in case, is that IIRC Rust doesn't handle pathnames as normal Unicode strings, because the OS could allow for any kind of wacky byte sequence there.) 10:21
timo indeed, we do, or at least should, use utf8-c8 for paths and filenames
lizmat yes, we do do that as well 10:22
ShimmerFairy That's good, I don't know the particulars and a very quick glance just saw the presence of Strs in IO::Path.
lizmat well, at least in resolve
github.com/rakudo/rakudo/pull/6909/changes 10:23
timo Str uses synthetic graphemes to represent stuff that wasn't valid utf8, they look a bit funky but when you encode them back with utf8-c8 they turn into what was put in at the beginning 10:25
lizmat the joys of NFG :-)
ShimmerFairy I've had utf8-c8 garbage show up a couple times before where it shouldn't, I think only when typing certain things on the commandline. 10:27
timo if you just "say" it back, it will go through the utf8 encoder and it will put a personal use character and the hex characters 10:30
it doesn't output the round-tripped data because then it could just output invalid utf8 on the output
ShimmerFairy that's what I mean by "garbage"; every once in a while my terminal will fail to send through Unicode properly and I'll suddenly see [box]xFF in the output. 10:31
timo you also don't want to just spit out bytes to the terminal emulator and get it to react to random terminal escape sequences unless you actually want to be sending them 10:32
10:56 finanalyst joined 11:00 finanalyst left 11:26 finanalyst joined 11:31 finanalyst left 11:57 finanalyst joined 12:01 finanalyst left
Geth rakudo/main: a3af6b859a | (Elizabeth Mattijsen)++ (committed by ab5tract) | src/Raku/ast/var-lowering.rakumod
RakuAST: use lowered lexical in hot loops during optimization

The variable lowering optimization logic contains a lot of hot loops going through frames. This commit replaces these accesses from a getattr into a lowered lexical.
Makes optimize stage by about 10% faster (roughly from 5.9 seconds to 5.4 seconds for the core.c setting optimization on my MBP).
12:18
12:28 finanalyst joined
Geth rakudo/main: f571d2fa2c | (Elizabeth Mattijsen)++ (committed using GitHub Web editor) | src/core.c/IO/Path.rakumod
Only support / and \ on IO::Spec::Win32 on IO::Path.resolve (#6909)

On all other systems, only / is allowed as a directory separator.
  timo++, ShimmerFairy++ for the nudge
12:31
12:33 finanalyst left 12:59 finanalyst joined 13:03 finanalyst left 13:29 finanalyst joined 13:34 finanalyst left 14:00 finanalyst joined 14:04 finanalyst left 14:31 finanalyst joined 14:35 finanalyst left
[Coke] one item in the blin run: 14:48
* [ ] [Injector](raku.land/zef:FCO/Injector) – Fail, Bisected: [f20534c](github.com/rakudo/rakudo/commit/f2...b78f9d6c2)
which I think was fixed by github.com/FCO/Injector/pull/7 14:49
lizmat yup, *phew* 14:50
SmokeMachine Oh! I have not released that?! Sorry… I’ll do that after work 14:51
[Coke] oh, it you! 14:53
:)
I can redo the bin run just for that when the new version is out 14:54
15:02 finanalyst joined 15:06 finanalyst left 15:32 finanalyst joined 15:37 finanalyst left 16:03 finanalyst joined 16:08 finanalyst left 16:34 finanalyst joined 16:38 finanalyst left 17:05 finanalyst joined 17:09 finanalyst left 17:35 finanalyst joined 17:40 finanalyst left