Skip to content

Commit

Permalink
Also include "_" in Str.raku fastpath
Browse files Browse the repository at this point in the history
  • Loading branch information
lizmat committed Jan 8, 2020
1 parent 5d8ef43 commit ccb92df
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/core.c/Str.pm6
Expand Up @@ -338,7 +338,7 @@ my class Str does Stringy { # declared in BOOTSTRAP
multi method raku(Str:D: --> Str:D) {
nqp::chars(self)
?? nqp::findnotcclass(
nqp::const::CCLASS_ALPHANUMERIC,self,0,nqp::chars(self)
nqp::const::CCLASS_WORD,self,0,nqp::chars(self)
) == nqp::chars(self)
?? nqp::concat('"',nqp::concat(self,'"')) # fast path alpha
!! self!rakufy # slow path non-alpha
Expand Down

0 comments on commit ccb92df

Please sign in to comment.