<commit_before>my class Instant { ... }

class IO::Special does IO {
    has Str $.what;

    method new(\what) {
        nqp::p6bindattrinvres(nqp::create(self),self,'$!what',what)
    }
    multi method WHICH(IO::Special:D:) {        "IO::Special$!what"        }
    multi method Str  (IO::Special:D:) {                    $!what         }
    multi method perl (IO::Special:D:) { "{self.^name}.new({$!what.perl})" }

    method IO(IO::Special:D:) { self }

    method e(IO::Special:D: --> True) { }
    method d(IO::Special:D: --> False) { }
    method f(IO::Special:D: --> False) { }
    method s(IO::Special:D:--> 0) { }
    method l(IO::Special:D: --> False) { }
    method r(IO::Special:D:) { $!what eq '<STDIN>' }
    method w(IO::Special:D:) { $!what eq '<STDOUT>' or $!what eq '<STDERR>' }
    method x(IO::Special:D: --> False) { }
    method modified(IO::Special:D: --> Instant) { Instant }<commit_msg>Make IO::Special.WHICH return a ValueObjAt<commit_after>my class Instant { ... }

class IO::Special does IO {
    has Str $.what;

    method new(Str:D \what --> IO::Special:D) {
        nqp::p6bindattrinvres(nqp::create(self),self,'$!what',what)
    }
    multi method WHICH(IO::Special:D: --> ValueObjAt) {
        nqp::box_s(
          nqp::concat(
            nqp::if(
              nqp::eqaddr(self.WHAT,IO::Special),
              'IO::Special|',
              nqp::concat(nqp::unbox_s(self.^name), '|')
            ),
            $!what
          ),
          ValueObjAt
        )
    }
    multi method Str  (IO::Special:D:) {                    $!what         }
    multi method perl (IO::Special:D:) { "{self.^name}.new({$!what.perl})" }

    method IO(IO::Special:D: --> IO::Special:D) { self }

    method e(IO::Special:D: --> True) { }
    method d(IO::Special:D: --> False) { }
    method f(IO::Special:D: --> False) { }
    method s(IO::Special:D:--> 0) { }
    method l(IO::Special:D: --> False) { }
    method r(IO::Special:D: --> Bool:D) {
        $!what eq '<STDIN>'
    }
    method w(IO::Special:D: --> Bool:D) {
        $!what eq '<STDOUT>' or $!what eq '<STDERR>'
    }
    method x(IO::Special:D: --> False) { }
    method modified(IO::Special:D: --> Instant) { Instant }
{'fraction_non_alphanumeric': 0.2100497962879131, 'fraction_numerical': 0.0018107741059302852, 'mean_word_length': 2.3283132530120483, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 28, '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': '7114603', 'n_tokens_mistral': 813, 'n_tokens_neox': 774, 'n_words': 149}