<commit_before>my class IO::Spec::Win32 is IO::Spec::Unix {

    # Some regexes we use for path splitting
    my $slash	    = regex {  <[\/ \\]> }
    my $notslash    = regex { <-[\/ \\]> }
    my $driveletter = regex { <[A..Z a..z]> ':' }
    my $UNCpath     = regex { [<$slash> ** 2] <$notslash>+  <$slash>  [<$notslash>+ | $] }
    my $volume_rx   = regex { <$driveletter> | <$UNCpath> }

    method canonpath ($path) { $path.chars ?? self!canon-cat($path) !! '' }

    method catdir(*@dirs) {
        return "" unless @dirs;
        return self!canon-cat( "\\", |@dirs ) if @dirs[0] eq "";
        self!canon-cat(|@dirs);
    }
    method splitdir($dir)        { $dir.split($slash)  }
    method catfile(|c)           { self.catdir(|c)     }
    method devnull               { 'nul'               }
    method rootdir               { '\\'                }

    method tmpdir {
        self.canonpath: first( { .defined && .IO.d && .IO.w },<commit_msg>Don't cannonicalize Win32 tmpdir path for now.<commit_after>my class IO::Spec::Win32 is IO::Spec::Unix {

    # Some regexes we use for path splitting
    my $slash	    = regex {  <[\/ \\]> }
    my $notslash    = regex { <-[\/ \\]> }
    my $driveletter = regex { <[A..Z a..z]> ':' }
    my $UNCpath     = regex { [<$slash> ** 2] <$notslash>+  <$slash>  [<$notslash>+ | $] }
    my $volume_rx   = regex { <$driveletter> | <$UNCpath> }

    method canonpath ($path) { $path.chars ?? self!canon-cat($path) !! '' }

    method catdir(*@dirs) {
        return "" unless @dirs;
        return self!canon-cat( "\\", |@dirs ) if @dirs[0] eq "";
        self!canon-cat(|@dirs);
    }
    method splitdir($dir)        { $dir.split($slash)  }
    method catfile(|c)           { self.catdir(|c)     }
    method devnull               { 'nul'               }
    method rootdir               { '\\'                }

    method tmpdir {
        first( { .defined && .IO.d && .IO.w },
{'fraction_non_alphanumeric': 0.19408406850025947, 'fraction_numerical': 0.005189413596263622, 'mean_word_length': 1.8352941176470587, 'pattern_counts': {'":': 0, '<': 21, '<?xml version=': 0, '>': 21, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7189044', 'n_tokens_mistral': 705, 'n_tokens_neox': 675, 'n_words': 147}