Created
November 9, 2014 18:13
-
-
Save peschwa/4b001dec921220da0051 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ git diff nom -- src/Perl6/World.nqp | |
diff --git a/src/Perl6/World.nqp b/src/Perl6/World.nqp | |
index 327fc4e..6d8ab69 100644 | |
--- a/src/Perl6/World.nqp | |
+++ b/src/Perl6/World.nqp | |
@@ -1654,6 +1654,20 @@ class Perl6::World is HLL::World { | |
} | |
return join(' ', @pieces); | |
} | |
+ elsif nqp::istype($ast[0], QAST::Want) && $ast[0].has_compile_time_value { | |
+ return nqp::unbox_s($ast[0].compile_time_value); | |
+ } | |
+ elsif nqp::istype($ast, QAST::Stmts) { | |
+ my $var := $ast; | |
+ while !nqp::istype($var, QAST::Var) { | |
+ $var := $var[0]; | |
+ } | |
+ my $value; | |
+ try { | |
+ $value := self.find_symbol([$var.name]); | |
+ } | |
+ return $value; | |
+ } | |
else { | |
$/.CURSOR.panic($mkerr()); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment