Skip to content
Browse files

Implement first cut of $*CWD. Patch courtesy of Lyle <webmaster@cosmi…

…cperl.com> along with a tweak from me.
  • Loading branch information...
1 parent 1317e53 commit f484da5e6c20acadabefb5b5e13e81a2dc4a70cb @jnthn jnthn committed
Showing with 7 additions and 0 deletions.
  1. +7 −0 src/builtins/globals.pir
View
7 src/builtins/globals.pir
@@ -53,6 +53,13 @@ src/builtins/globals.pir - initialize miscellaneous global variables
$P0 = info
set_hll_global '$EXECUTABLE_NAME', $P0
+ ## create basic $*CWD
+ .local pmc os
+ os = new ['OS']
+ $S0 = os."cwd"()
+ $P0 = box $S0
+ set_hll_global '$CWD', $P0
+
## create $*IN, $*OUT, $*ERR filehandles
.local pmc pio, perl6io, perl6ioclass
perl6ioclass = get_hll_global "IO"

0 comments on commit f484da5

Please sign in to comment.
Something went wrong with that request. Please try again.