This file contains hidden or 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
use v6; | |
class Brainfuck { | |
has $!buf; | |
has $!ptr; | |
submethod BUILD(:$buf-size = 1024) { | |
$!buf = Buf.new(0 xx $buf-size); | |
$!ptr = 0; | |
} |
This file contains hidden or 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
require 'formula' | |
class Vim < Formula | |
homepage 'http://www.vim.org/' | |
url 'ftp://ftp.vim.org/pub/vim/unix/vim-7.3.tar.bz2' | |
head 'https://vim.googlecode.com/hg/' | |
sha256 '5c5d5d6e07f1bbc49b6fe3906ff8a7e39b049928b68195b38e3e3d347100221d' | |
version '7.3.682' | |
def features; %w(tiny small normal big huge) end |
This file contains hidden or 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
diff --git a/src/Perl6/Actions.pm b/src/Perl6/Actions.pm | |
index 9e44a7b..fc6e9c1 100644 | |
--- a/src/Perl6/Actions.pm | |
+++ b/src/Perl6/Actions.pm | |
@@ -3541,7 +3541,8 @@ INIT { | |
%not_curried{'WHERE'} := 2; | |
} | |
sub whatever_curry($/, $past, $upto_arity) { | |
- if $past.isa(PAST::Op) && %not_curried{$past.name} != 2 && $past<pasttype> ne 'call' { | |
+ if $past.isa(PAST::Op) && %not_curried{$past.name} != 2 |
This file contains hidden or 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
diff --git a/S02-builtin_data_types/whatever.t b/S02-builtin_data_types/whatever.t | |
index 92b5680..49acb2d 100644 | |
--- a/S02-builtin_data_types/whatever.t | |
+++ b/S02-builtin_data_types/whatever.t | |
@@ -1,7 +1,7 @@ | |
use v6; | |
use Test; | |
-plan 62; | |
+plan 65; |
This file contains hidden or 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
diff --git a/src/Perl6/Compiler/Role.pm b/src/Perl6/Compiler/Role.pm | |
index d88dc0e..b3a7daf 100644 | |
--- a/src/Perl6/Compiler/Role.pm | |
+++ b/src/Perl6/Compiler/Role.pm | |
@@ -148,6 +148,7 @@ method finish($block) { | |
PAST::Op.new( :pasttype('bind'), | |
PAST::Var.new( :name('master_role'), :scope('register'), :isdecl(1) ), | |
PAST::Op.new( :pasttype('call'), :name('!create_master_role'), | |
+ ~$name, | |
~$short_name, |
This file contains hidden or 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
diff --git a/src/Perl6/Actions.pm b/src/Perl6/Actions.pm | |
index 9e44a7b..2828b82 100644 | |
--- a/src/Perl6/Actions.pm | |
+++ b/src/Perl6/Actions.pm | |
@@ -2547,8 +2547,13 @@ method postfixish($/) { | |
if $<postfix_prefix_meta_operator> { | |
my $past := $<OPER>.ast; | |
if $past && $past.isa(PAST::Op) && $past.pasttype() eq 'call' { | |
- $past.unshift($past.name()); | |
- $past.name('!dispatch_dispatcher_parallel'); |
This file contains hidden or 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
diff --git a/src/builtins/Str.pir b/src/builtins/Str.pir | |
index ebee051..4c653cb 100644 | |
--- a/src/builtins/Str.pir | |
+++ b/src/builtins/Str.pir | |
@@ -28,6 +28,14 @@ as the Perl 6 C<Str> class. | |
.tailcall '&infix:<eq>'(topic, self) | |
.end | |
+=item new() | |
+ |
This file contains hidden or 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
use v6; | |
module Foo { | |
my %escape; | |
for 0 .. 255 -> $c { | |
%escape{ chr($c) } = sprintf('%%%02X', $c); | |
} | |
our sub bar (Int $value) { | |
return %escape{ chr($value) }; |
This file contains hidden or 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
diff --git a/src/Perl6/Grammar.pm b/src/Perl6/Grammar.pm | |
index 93b73c0..6a307ef 100644 | |
--- a/src/Perl6/Grammar.pm | |
+++ b/src/Perl6/Grammar.pm | |
@@ -797,7 +797,7 @@ token variable { | |
|| [ | |
| <sigil> <twigil>? <desigilname> | |
| <special_variable> | |
- | <sigil> $<index>=[\d+] [ <?{ $*IN_DECL}> <.panic: "Can't declare a numeric variable">]? | |
+ | <sigil> $<index>=[\d+] [ <?{ $*IN_DECL eq 'variable' }> <.panic: "Can't declare a numeric variable">]? |