pugscode.org/ | nopaste: sial.org/pbot/perl6 | pugs: [~] <m oo se> (or rakudo:, kp6:, elf: etc.) (or perl6: for all) | irclog: irc.pugscode.org/
Set by Tene on 29 July 2008.
00:04 pmurias left 00:24 pcbuetow joined 00:33 KidShenck joined 00:39 pbuetow left 00:54 bsb joined
meppl good night 01:02
01:03 Exodist left 01:04 meppl left 01:06 masak left 01:16 Aisling left, Aisling joined, Aisling left 01:18 pcbuetow left 01:21 kanru left 01:22 KidShenck left, bacek joined
bacek perl6: class Foo {}; my $a = Foo.new; my $b = $a; 01:23
p6eval rakudo 32442: RESULT[Method 'perl' not found for invocant of class 'Foo'␤current instr.: '_block11' pc 25 (EVAL_12:12)␤]
..elf 22847: RESULT[Foo.new(!!!)␤]
..pugs: RESULT[\Foo.new(()]
01:26 Aisling joined 01:41 bacek left 01:47 pedrob left 01:51 bacek joined 01:54 hercynium joined 01:56 alexn_org left 01:58 simcop2387 left 02:24 jauaor left 02:25 wknight8111 left
[particle] rakudo: class Foo {}; my Foo $a .= new; my $b = $a; 02:50
p6eval rakudo 32442: RESULT[Method 'perl' not found for invocant of class 'Foo'␤current instr.: '_block11' pc 25 (EVAL_12:12)␤]
[particle] harumph
bacek perl6: class Foo {}; my Foo $a .= new; my $b = $a; say $b.WHAT 02:57
p6eval pugs, rakudo 32442: OUTPUT[Foo␤]
..elf 22847: OUTPUT[Undef␤]
03:02 jiing joined
bacek perl6: say Bool.pick 03:04
p6eval rakudo 32442: OUTPUT[Bool␤]
..pugs: OUTPUT[*** pick not defined: VType (mkType "Bool")␤ at /tmp/eOLK8UuPHE line 1, column 5 - line 2, column 1␤]
..elf 22847: OUTPUT[Can't locate object method "pick" via package "Bool" at (eval 117) line 3.␤ at ./elf_f line 3861␤]
03:05 simcop2387 joined 03:12 sri_kraih joined 03:20 sri_kraih_ left 03:24 sri_kraih left, sri_kraih joined
rakudo_svn r32443 | chromatic++ | [Rakudo] Fixed a C++ compilation error (Vasily Chekalkin). 03:30
03:45 Psyche^ joined 04:00 Patterner left, Psyche^ is now known as Patterner 04:01 elmex left 04:02 elmex joined 04:10 bacek_ joined 04:13 bacek left 04:25 cpfr left 04:30 Limbic_Region left 04:33 stephenos left 04:40 rindolf joined 04:41 DemoPhreak joined 04:56 DemoFreak left
pugs_svn r22918 | pmichaud++ | [spec]: Clean up some arrayref tests for rakudo. 05:06
05:12 z80ASM joined
pmichaud pugs: my %hash = <a 3>; say %hash.perl; 05:28
p6eval pugs: OUTPUT[\(\("a", "3"),)␤]
pmichaud pugs: my %hash = { a => 3}; say %hash.perl;
p6eval pugs: OUTPUT[\(\("a", 3),)␤]
05:28 tcliou|slept is now known as tcliou
pmichaud my %hash = ( a => 1, b => 2); say %hash.perl; 05:29
pugs: my %hash = ( a => 1, b => 2); say %hash.perl;
p6eval pugs: OUTPUT[\(\("a", 1), \("b", 2))␤]
pmichaud pugs: my %hash = ( a => 1, b => 2); my $x = \%hash; say $x.WHAT; 05:30
p6eval pugs: OUTPUT[Hash␤]
pmichaud pugs: my %hash = ( a => 1, b => 2); my $x = \%hash; say $x.perl;
p6eval pugs: OUTPUT[\\(\("a", 1), \("b", 2))␤]
pmichaud pugs: my $x = \( 1, 2, :foo(3) ); say $x.perl; 05:31
p6eval pugs: OUTPUT[CaptSub {c_feeds = [:MkFeed {f_positionals = [:IFinite 1,IFinite 2:], f_nameds = [(foo,[:IFinite 3:])]}:]}␤]
pmichaud pugs: my %hash = ( a => 1, b => 2); my $x = \( %hash ); say $x.perl; 05:32
p6eval pugs: OUTPUT[CaptSub {c_feeds = [:MkFeed {f_positionals = [:VList [VRef <Pair:0xb7a8465d>,VRef <Pair:0xb7ab769d>]:], f_nameds = []}:]}␤]
05:34 justatheory left 05:46 kanru joined 06:26 nacho_ joined 06:53 tcliou is now known as tcliou|GroundZer, tcliou|GroundZer is now known as tcliou|Ground-0 06:54 tcliou|Ground-0 is now known as tcliou|Away 07:01 just joined 07:12 adc_Penner joined 07:27 azawawi joined
azawawi ping 07:27
lambdabot azawawi: You have 5 new messages. '/msg lambdabot @messages' to read them.
azawawi @messages
lambdabot moritz_ said 3d 10h 32m 57s ago: all required modules are installed on feather1 now (for evalbot)
TimToady said 1d 14h 8s ago: you should find your parsers running somewhat faster now, given that STD now parses itself twice as fast as it did yesterday (given a preloaded cache)
TimToady said 11h 21m 16s ago: S_s_h seems to be calling is_type and is_routine on all sorts of things for which it makes no sense, such as the insides of strings like "True" and the various bits of
longnames like statement_control:PRE
TimToady said 11h 5m 4s ago: the problem is you can't just scan for /identifier/; you need to pick color based on the *last* context you care about, like nibbler or deflongname
TimToady said 10h 56m 58s ago: so in the case of push @basetypenames, "True" the True is currently blue because the push is an identifier, which is bogus, since True is just a nibble
pugs_svn r22919 | particle++ | [t/spec] unmark some passing rakudo tests due to container/value refactor 07:28
azawawi @seen moritz_ 07:31
lambdabot moritz_ is in #perl6. I last heard moritz_ speak 22h 15m 32s ago.
07:31 adc_Penner left
azawawi @tell moritz_ syntax highlighted html snippets are now generated on feather1 (e.g. feather.perl6.nl/~azawawi/html/S05-...ppet.html) 07:31
lambdabot Consider it noted.
pugs_svn r22920 | azawawi++ | [STD_syntax_highlight] ETOOMUCHTIME -> spec_highlight 07:38
r22920 | azawawi++ | [STD_syntax_highlight] removed comments about it being slow, TimToady++
azawawi is irclog.perlgeek.de/perl6/today offline? 07:42
lambdabot Title: IRC log for #perl6, 2008-11-08
azawawi or at least not bringing any results
TimToady people were complaining about it earlier
azawawi hi TimToady
07:42 apeiron left 07:44 apeiron joined
azawawi TimToady: when is lex directory generated? 07:46
TimToady as needed when you start parsing a rule/language that hasn't been parsed before
it's a JIT lexer
azawawi so after 'make', it would not be generated 07:47
TimToady well, a little bit is from the test case
the try5 tries to at least generate terms and infixes 07:48
azawawi is there an option to disable lex dir caching? 07:49
TimToady not really. it does currently suppress it on any package containing /ANON/ 07:50
so anything else could turn it off at the same point 07:51
pugs_svn r22921 | particle++ | [t/spec] unmark some more tests passing for rakudo 07:59
08:03 abra joined
TimToady zzz & 08:08
azawawi TimToady: have a nice zzz ;-) 08:09
08:23 iblechbot joined 08:32 apeiron left 08:36 just left, nacho_ left, pmurias joined 08:37 bacek_ left
pmurias ruoso: hi 08:37
azawawi hi pmurias 08:38
pugs_svn r22922 | azawawi++ | [STD_syntax_highlight] check: working directory should end with src/perl6
pmurias azawawi: hi
08:39 bsb left
azawawi whats new with mildew/smop? 08:39
pmurias i threw out slime yesterday, was mostly offline last week 08:40
azawawi does it parse all of t/spec? 08:41
pmurias STD parses all of t/spec
mildew uses it, but it can only handle very simple things atm 08:42
azawawi i dont know all of mildew/smop... what is it exactly?
pmurias smop is a runtime to run perl6 on, and mildew is the perl6 compiler for it 08:43
mildew/smop is like rakudo/parrot 08:44
azawawi: what's the state of padre STD_syntax_highlighting integration? 08:45
08:50 bacek_ joined
azawawi pmurias: sorry i was away a bit 08:51
pmurias: i dont know about any effort to integrate padre with STD_syntax_highlight
pmurias: with the perlgeek.de irclog being offline... i cant follow up like before 08:52
pmurias i saw in the irc logs that szabgab talked to you about that 08:53
azawawi and that's it... 08:54
08:54 kst left
azawawi i didnt hear from him afterwards 08:54
bacek_ perl6: my %h = {}; exists %h<a>; say %h.perl
p6eval pugs: OUTPUT[*** No compatible multi variant found: "&exists"␤ at /tmp/xQEEtY7TN2 line 1, column 13-25␤]
..rakudo 32444: OUTPUT[No applicable methods.␤␤current instr.: '_block11' pc 66 (EVAL_12:25)␤]
..elf 22847: OUTPUT[Undefined subroutine &GLOBAL::exists called at (eval 119) line 4.␤ at ./elf_f line 3861␤]
azawawi pmurias: im actually working on croning it and then going to work on evalbot to 'highlight:' simple lines to sial.org/pbot 08:55
pmurias azawawi: irc supports color 08:56
bacek_ perl6: my %h = {}; say %h.exists('a'); say %h.perl
p6eval rakudo 32444: OUTPUT[0␤{}␤]
..pugs: OUTPUT[␤\()␤]
..elf 22847: OUTPUT[␤{}␤]
azawawi pmurias: yeah but moritz_ does not colors ;-)
s/color/like color/ 08:57
pmurias 8colored 08:58
azawawi 4i know ;-) 08:59
pmurias azawawi: why doesn't moritz_ like colors in evalbot output
azawawi some irc clients dont support it
pmurias: interesting link -> news.perlfoundation.org/2008/11/200...egrat.html 09:00
lambdabot Title: 2008Q4 Grant Proposal: Integrating Padre with Parrot and Rakudo - The Perl Found ..., tinyurl.com/69gflq
azawawi and this link: szabgab.com/blog/2008/11/1225946474.html 09:01
lambdabot Title: Syntax highlighting nightmare
09:03 ab5tract left 09:08 meppl joined
meppl good morning 09:11
09:21 samlh joined
pugs_svn r22923 | pmurias++ | [smop] mold is used to call DESTROYALL, we still don't have a free this register RI 09:26
r22924 | pmurias++ | [smop] remove the sm0p/ directory 09:27
09:31 pmurias left
pugs_svn r22925 | azawawi++ | [STD_syntax_highlight] refactored error writing routine 09:49
r22925 | azawawi++ | [STD_syntax_highlight] catching CTRL-C is not needed with backticks
09:50 z80ASM left
pugs_svn r22926 | azawawi++ | [STD_syntax_highlight] refactored code into MAIN 09:54
10:10 smg left
pugs_svn r22927 | azawawi++ | [STD_syntax_highlight] added a cron script 10:13
10:19 cpfr joined 10:21 bacek_ left 10:30 schmalbe joined 10:32 |Jedai| joined, bacek_ joined 10:35 pmurias joined 10:42 z80ASM joined 10:43 alexn_org joined 10:44 abra left 10:52 Jedai left
pugs_svn r22928 | jnthn++ | [spectest] Add some tests for generic subs. 10:56
11:02 ZuLuuuuuu joined
rakudo_svn r32446 | jonathan++ | [rakudo] When you use a type in a signature that was captured earlier in the signature, need to fix up the scope. 11:10
11:13 araujo left 11:31 pbuetow joined 11:32 DeadlyTiga joined, DeadlyTiga left
pmurias @tell ruoso we mold doesn't support $r777 = $scope, and i don't know how to cleanly do the previous scheme 11:33
lambdabot Consider it noted.
pmurias @tell ruoso s/cleanly do/cleanly do it without using the/ 11:36
lambdabot Consider it noted.
11:36 ejs joined
pmurias ruoso: ping 11:36
11:40 smg joined
pugs_svn r22929 | pmurias++ | [mildew] reverted 22887 and 22888 as they output broken m0ld, 22888 likely needs to be reapplied once things works again 11:42
11:42 bacek__ joined, pedrob joined
pugs_svn r22930 | pmurias++ | [smop] hello wold works with m0ld --exec again 11:45
r22930 | pmurias++ | it is a problem with BValues
r22930 | pmurias++ | added BValue.DEBUG and smop_describe_object to help debugging
11:46 pedrob_ joined
pmurias walk& 11:47
11:50 pedrob left 11:51 pedrob joined 11:54 bacek_ left 11:56 pedrob__ joined 12:01 pedrob left, pedrob joined 12:03 pjcj left 12:05 pedrob___ joined 12:06 pedrob_ left 12:07 z80ASM left 12:09 rindolf left 12:15 rindolf joined 12:20 samlh left 12:21 pedrob__ left 12:23 pedrob left 12:25 pedrob___ left 12:27 pjcj joined 12:38 abra joined
bacek__ perl6: sub is($a,$b) { $a eq $b }; say is (42,42) 12:38
p6eval rakudo 32447: OUTPUT[too few arguments passed (1) - 2 params expected␤current instr.: 'is' pc 89 (EVAL_13:37)␤]
..pugs: OUTPUT[pugs: Extra space found after &is (...) -- did you mean &is(...) instead?␤]
..elf 22847: OUTPUT[1␤]
12:38 abra left 12:39 bacek__ is now known as bacek 12:59 plash_ joined
pmurias perl6: sub is($a,$b) { $a eq $b }; say is(42,42) 12:59
p6eval elf 22847, pugs, rakudo 32447: OUTPUT[1␤]
bacek pmichaud: I just wonder why extra space is prohibited...
pmurias bacek: it propably passes a list as a single param 13:02
bacek pmichaud: yes, indeed... 13:03
azawawi @tell moritz_ spec_highlight is now scheduled to run every 3 hours on feather1 13:04
lambdabot Consider it noted.
pmurias bacek: i'm pmurias ;)
13:05 rindolf left
bacek pmurias: oh shi.. :) 2 letters isn't enough for tab completion :) 13:05
azawawi how do i nice all bash commands by default?
pmurias nice bash?
bacek azawawi: . /etc/bash_completion
perl6: sub foo($x) { $x/=2 }; my $a=84; foo($a); say $x 13:06
p6eval rakudo 32447: OUTPUT[No handler to delete.␤current instr.: 'parrot;PAST;Compiler;as_post' pc 6052 (src/PAST/Compiler.pir:1651)␤]
..pugs: OUTPUT[*** Can't modify constant item: VRef <Scalar:0xb5edf639>␤ at /tmp/xXdYANXJpC line 1, column 15-21␤]
..elf 22847: OUTPUT[Unknown rule: infix_postfix_meta_operator:=␤It needs to be added to ast_handlers.␤ at ./elf_f line 1918␤]
azawawi cool thx
bacek perl6: sub foo($x) { $x/=2 }; my $a=84; foo($a); say $a
p6eval pugs: OUTPUT[*** Can't modify constant item: VRef <Scalar:0xb5ddf639>␤ at /tmp/KS3nSbHGGK line 1, column 15-21␤]
..rakudo 32447: OUTPUT[42␤]
..elf 22847: OUTPUT[Unknown rule: infix_postfix_meta_operator:=␤It needs to be added to ast_handlers.␤ at ./elf_f line 1918␤]
bacek azawawi: put it into .bash_profile :) 13:07
13:08 abra joined
rakudo_svn r32448 | jonathan++ | [rakudo] Add spectest file for generic subs to spectest_regression. 13:10
pmurias ruoso: we need a way of doing SMOP_DISPATCH in a stackfull way in order for C code to be able to receive an anwser from setr 13:12
13:24 abra left 13:30 pedrob joined, pedrob left 13:41 bacek left 13:54 z80ASM joined 13:56 bacek joined 13:58 masak joined 14:00 lisppaste3 left 14:02 wknight8111 joined 14:13 schmalbe left 14:14 KidShenck joined 14:18 bacek left 14:19 bacek joined, araujo joined 14:25 pedrob joined 14:30 iblechbot left 15:01 Bzek joined 15:02 dbrock joined
dbrock if I wanted to write a parser in Perl 6, how would I go about doing that? 15:02
masak dbrock: so, you want to use the grammars in Perl 6 to parse something?
15:03 z80ASM left
dbrock yeah, I just want to parse it and write out the syntax tree in some structured format 15:03
is that a good idea?
is Perl 6 a good tool for that?
masak dbrock: 1. download Rakudo, 2. write a grammar, 3. write the code that matches on a text and traverses $/
dbrock: Perl 6 is an excellent tool for that
dbrock cool :-)
what's $/?
masak dbrock: if you need working examples, see the November source code.
dbrock okay 15:04
masak dbrock: ok, if you don't know what $/ is, you need to read S05
perlcabal.org/syn/S05.html
lambdabot Title: S05
dbrock thanks!
I'm kind of excited that I'm about to try to actually write something in Perl 6 :-) 15:05
masak dbrock: np. let me know if you have any questions.
dbrock: I know the feeling :)
rakudo: grammar SSN { rule TOP { ^ \d ** 10 $ } }; say ?("8936628302" ~~ SSN::TOP) 15:09
p6eval rakudo 32449: OUTPUT[1␤]
15:15 bacek_ joined 15:16 bacek left 15:25 hercynium left 15:26 meteorjay left 15:32 DemoPhreak left 15:38 alexn_org left 15:45 ZuLuuuuuu left 15:47 bacek joined 15:57 bacek_ left 16:01 apeiron joined 16:06 pedrob left 16:08 justatheory joined 16:11 pedrob joined 16:13 slavik joined 16:17 iblechbot joined 16:20 adc_Penner joined
slavik there should be an extension to grammars called syntax 16:21
16:23 bacek_ joined
masak slavik: what would syntax be that grammar would not? 16:24
16:25 bacek left
slavik masak: it would try to match any "simple" token in case it didn't match something it expected 16:25
masak slavik: not sure I understand. do you have an example?
16:26 samlh joined
slavik masak: basically, it should detect that it was given not something it was expected 16:26
as in an <operator> appeared where <keyword> was expected or something 16:27
masak slavik: sounds wortwhile, yes. couldn't you make a module use grammars in such a way?
slavik masak: probably 16:28
masak: this is like a basic syntax checker made from grammars, since a valid grammar generates what could be seen as a syntax tree
so you define a grammar, which will parse 'code' and then you just need to build something which will evaluate the matcher object (since that is the syntax tree) 16:29
masak aye 16:30
16:30 pedrob_ joined
slavik basically, perl6 comes prebuilt with half of a compiler/interpreter :) 16:30
16:30 pedrob left
masak I'm still hoping that something like the {*} syntax will make it easier to tie actions to rules 16:30
slavik hmm? 16:32
as in do stuff if some rule matches?
masak yes. 16:33
this is how PCT does it, for example, so PGE has support for it. 16:34
but Rakudo currently doesn't.
slavik PCT, PGE???
masak slavik: these are Parrot components. 16:35
slavik ahh
masak the Parrot Compiler Toolkit makes it easier to build high-level languages quickly
16:35 nacho_ joined
slavik gotcha 16:35
masak the Parrot Grammar Engine implements Perl 6 rules and grammars
slavik right 16:36
pmichaud Rakudo supports {*} 16:39
masak pmichaud: is it possible to tie a sub or method to a {*} in Rakudo? 16:40
pmichaud yes.
I'm creating an example now.
masak oh. I missed when that happened.
that is excellent news.
pmichaud it's been there from the beginning. :-)
masak strange. I've complained about it before, and never got this answer. :)
pmichaud 16:45 <nopaste> "pmichaud" at 76.183.97.54 pasted "action methods in Rakudo (for masak)" (21 lines) at nopaste.snit.ch/14512 16:45
masak cool. 16:46
I'll notify the November mailing list immediately.
pmichaud of course, it's not officially part of the Perl 6 spec, but it works. :-) 16:47
I'm hoping something like it makes it into the spec someday.
masak as do I.
slavik NICE!!! 16:54
pmichaud I like this approach because it makes it easy to plug new actions into an existing grammar, or to derive a new Action class that replaces one or more actions and inherits the rest. 16:55
masak ideed. I've been mulling over how to solve that. 16:56
[particle] protoactions ) 16:57
:)
masak and you get the Match objects as a parameter, that's very good. 16:58
pmichaud and if you name the parameter as $/, then the $<...> and $0 syntaxes work as expected. 16:59
slavik in regex, what is the syntax to match an int in a certain range?
masak pmichaud: cool.
slavik as in \d{1,3} where it is in 0-255 ?
masak slavik: use a closure, perhaps?
slavik masak: what would it look like? 17:00
masak slavik: \d{1,3} is written \d ** 1..3 nowadays, I think.
pmichaud from S05:
A leading ?{ or !{ indicates a code assertion:
(\d**1..3) <?{ $0 < 256 }> / / (\d**1..3) <!{ $0 < 256 }> /
oops
silly slashes
/ (\d**1..3) <?{ $0 < 256 }> /
slavik why the <>? 17:01
closure?
pmichaud it's a "code assertion" -- we execute the closure testing it for truth/false
slavik k
pmichaud if done as a pure closure, it would need to be
/ (\d**1..3) { $0 < 256 or fail } / 17:02
slavik !{} I assume would do something more error like than ?{} ???
pmichaud <!{...}> fails the match if the code returns true
<?{...}> fails the match if the code returns false
slavik ahh
got it 17:03
pmichaud or, another way of thinking of it
<?{...}> # assert that ... is true
<!{...}> # assert that ... is false, fail otherwise
dbrock isn't there any way to refer to the last capture?
so you don't have to say $0
pmichaud in general '?' in Perl 6 means "is it true?" and '!' means "is it false?"
slavik pmichaud: gotcha, ty 17:04
pmichaud (last capture) -- if there is, it's likely to be longer than $0 :-) 17:05
I suspect someone could do $[*-1]
but that's also kinda odd.
masak $/.end :) 17:06
slavik hmm, if I have something like: rule blah { \d+\s? }, how can I match against <blah> without the \s being extracted?
masak slavik: put it in a subrule and call it with a colon, I think
or was it a dot? 17:07
yes, a dot, I think
slavik umm, how would it look like?
slavik is still learning perl6 syntax :P
masak slavik: have you read S05? :)
perlcabal.org/syn/S05.html 17:08
lambdabot Title: S05
slavik yes, but I probably missed it
I'll read it again
pmichaud I don't quite understand "without the \s being extracted"
masak I think slavik meant 'without it ending up in $/'
slavik if you do "12312312 1231232" ~~ <blah> it will return "12312312 ", I want "12312312" 17:09
yes
pmichaud first, you probably don't want a rule there. 17:10
slavik token?
[particle] tokens rule!
;)
masak slavik: ah, here: perlcabal.org/syn/S05.html#line_1226
lambdabot Title: S05
slavik heh
dbrock quick and stupid question: how do I run a Perl 6 program? I have installed Parrot; what else do I need?
pmichaud slavik: I suspect you want <( and >) 17:11
masak dbrock: cd languages/perl6; make perl6
pmichaud token blah { <( \d+ )> \s? }
dbrock I installed it via Ubuntu
masak dbrock: ./perl6 -e 'say "OH HAI"'
slavik dbrock: perl6 is in Ubuntu?!
pmichaud I think the Ubuntu package is very old.
dbrock well, parrot is anyway
pmichaud what version of Parrot?
dbrock oh, okay
masak dbrock: oh. I don't know how Ubuntu does it.
slavik oh yeah, it is
dbrock 0.4.13 17:12
pmichaud ancient.
masak dbrock: better download from svn and get the latest, coolest, stuff
dbrock ah
slavik masak: ty :)
dbrock will do
masak slavik: np.
pmichaud token blah { <( \d+ )> \s? }
slavik pmichaud: has the semi-colon required after {} BLOCK been fixed? :P
pmichaud: I see, ty
pmichaud "12312312 12312312" ~~ / <blah> /; # $<blah> matches the space but doesn't include it. 17:13
slavik: which semi-colon required after {} BLOCK? ;)
slavik: example?
masak pmichaud: in grammars.
there's a ticket about it, hold on.
pmichaud oh, in grammars. I think that's a bug in the grammar grammar.
slavik ROFL
pmichaud I just noticed that as well.
masak *lol*
at least it's not a bug bug in the grammar grammar. 17:14
slavik WTF?!
heh
masak WWTTFF??!!
slavik btw, what is the name of the notation used to show syntax for a language?
dbrock BNF?
slavik yes 17:15
basically, grammar == BNF (IMO)
masak rt.perl.org/rt3/Ticket/Display.html?id=57874
lambdabot Title: #57874: Tokens inconsistently require semicolons after them
masak slavik: that's reducing away a lot of cool stuff. 17:16
slavik huh?
masak slavik: grammars are quite powerful in Perl 6.
slavik masak: right
masak: they are BNF that build a parse tree :)
masak slavik: so, at least in Perl6, grammar > BND
s/BND/BNF/ 17:17
pmichaud and that's a BFD. :-P
slavik masak: like I said before, grammars are a half of a compiler :)
masak slavik: it's a bit like saying that a car is basically a bicykle.
slavik well, they both have wheels :P
tires rather
masak slavik: exactly, so you're not 100% wrong.
just 90% or so.
slavik masak: I know, just trying to use existing understanding to base new understanding on it :) 17:18
[particle] my bike has cupholders
masak slavik: yes, that's perfectly ok.
slavik: just saying that a grammar is not _only_ a BNF 17:19
slavik: and that clinging to that view might limit your horizons
slavik right
[particle]: any reason you are not "particle" ??? 17:20
slavik knows "particle"
17:20 justatheory left
slavik heh 17:20
I know 2 particles ... :-\
pmichaud okay, I think I have 57874 fixed -- running make spectest now. 17:23
masak pmichaud++
pmichaud: speaking of tickets, how's the lex branch going? 17:24
pmichaud a little slower this week -- I have to figure out how to handle autoclose semantics
masak ok.
pmichaud now that container semantics are fixed the lexicals are (by far) the highest priority on my plat 17:25
*plate
masak yay!
pmichaud 17:28 <nopaste> "pmichaud" at 76.183.97.54 pasted "token no longer requires semicolon (RT #57874, for masak)" (7 lines) at nopaste.snit.ch/14513 17:28
masak nice.
17:38 alexn_org joined
rakudo_svn r32450 | pmichaud++ | [rakudo]: Closing } in regex/token/rule can terminate statements (RT #57874) 17:40
17:40 pedrob_ left 17:53 spx2_ left, spx2 joined
dbrock how would you write a grammar to match any comma-separated list of words, where the last word may optionally have a star in front of it? 18:02
I currently have this: rule args { <restarg> | [<arg> [',' [<args> | <restarg>]]?]? } 18:04
where <arg> is a word and <restarg> is a star-word
(it works; I'm just wondering if there is a better way) 18:06
18:11 pmurias_ joined, pmurias_ left
[particle] maybe something like { <restarg> || <arg> ** ',' [ ',' <restarg> ] } 18:11
i think you'll need that second comma there because ** ',' won't match a trailing one 18:12
slavik pmichaud: so, now rakudo's grammars are not broken? 18:13
18:15 ejs left, aindilis left 18:16 aindilis joined
dbrock I don't think ** ',' works in rakudo :-( 18:17
18:19 ejs joined
slavik pmichaud: I am building it now :) 18:21
pmichaud: can has fixed bignum naoh plz? 18:22
perl6 has OpenGL bindings??? 18:24
I saw -lGL and -LGLU while making rakudo ... 18:25
18:32 ab5tract joined
masak dbrock: you're correct. that spec feature is newer than PGE. 18:32
18:41 eternaleye joined 19:02 simcop2387 left, simcop2387-vnc joined 19:03 stephang joined, simcop2387-vnc is now known as simcop2387 19:04 Bzek left 19:11 lisppaste3 joined, FurnaceBoy joined 19:14 lisppaste3 left 19:18 ejs left
masak so the type int1 has the two possible values 0 and -1 ? :) 19:18
TimToady: S09: "The unsized types C<int> and C<num> are based on the architecture's normal size for C<int> and C<double> in whatever version of C the run-time system (presumably Parrot) is compiled in." The last "in" is redundant. 19:19
19:19 lisppaste3 joined 19:20 ejs joined
masak rakudo: say Complex ~~ Num 19:29
p6eval rakudo 32450: OUTPUT[0␤]
masak if a Complex isn't a Num, how come sign(1+1i) works in Rakudo?
rakudo: say sign(1+1i) 19:30
p6eval rakudo 32450: OUTPUT[1␤]
masak S29 doesn't say anything about non-Num arguments to &sign
(oh. S09 even mentions the two possible values of int1. TimToady++) 19:35
rakudo: sub foo (@a) { 1.say for @a }; foo(1,2,3) 19:41
p6eval rakudo 32450: OUTPUT[too many arguments passed (3) - 1 params expected␤current instr.: 'foo' pc 74 (EVAL_13:37)␤]
masak do I need to make @a slurpy?
rakudo: sub foo (*@a) { 1.say for @a }; foo(1,2,3)
p6eval rakudo 32450: OUTPUT[1␤]
masak that must be ihrd's bug.
slavik is rakudo going to be "THE Perl6"? 19:42
masak slavik: what do you mean?
slavik seems like nobody does pugs work anymore :(
masak slavik: audreyt++ has said she will resume work on Pugs once GHC gets a few planned features 19:43
slavik I see
masak slavik: and there are also a lot of other implementations showing promise
slavik is not aware of other 19:44
others
I know there is kp6, but that is supposed to be just enough to write perl6 in perl6
masak something called mildew, worked on by pmurias++ and ruoso++
and something called elf
slavik: yes, kp6 is not Perl 6 19:45
slavik: it's considered more or less stable, as I understand it
slavik: it's being used in the actions parts of PCT
slavik hmm, haven't seen though 19:46
those*
bah
masak slavik: you will if you keep hanging around here at #perl6 19:47
slavik masak: I try L(
:)
btw, masak++ 19:48
:)
masak perl6: <OH HAI>.say
p6eval elf 22847, pugs, rakudo 32453: OUTPUT[OHHAI␤]
slavik grr, shouldn't that give you karma?
masak @karma masak
lambdabot You have a karma of 36
masak slavik: it did, silently.
slavik ahh, ok
:)
pmichaud++ 19:49
masak indeed.
19:57 jfredett joined
samlh actually, kp6 [kinda perl6] was an attempt to bootstrap, that ended up too slow to be useful 20:09
while nqp [not quite perl] is the language used for PCT actions
masak samlh: ah, yes. that's right; I misremembered. 20:10
20:15 ejs left
pugs_svn r22931 | masak++ | [S04-statements/for-scope.t] added tests against [perl #60404] 20:17
20:19 ab5tract left 20:22 ab5tract joined 20:30 smg left
ruoso slavik, we're already starting to write the Perl 6 built-in types in Perl 6... you might want to take a look at svn.pugscode.org/pugs/v6/smop/src-s1p/ 20:31
lambdabot ruoso: You have 2 new messages. '/msg lambdabot @messages' to read them.
ruoso pmurias, about stackfull DISPATH, I've thought about using some longjmp hacks to make it work 20:33
20:33 abra joined
ruoso pmurias, about my $id = $otherreg; I think it's easier to solve it in a second pass, like an optimizer that removes all the redundant registers 20:33
pmurias, in fact... I was already wondering how hard would it be to do rewrite the m0ld compiler in p5 using "use SMOP" 20:38
japhb slavik: Parrot has OpenGL bindings (I created them, or at least, the first few versions of them). I have not had a chance to try them from Rakudo itself yet. You can be the first! 20:44
:-)
pmurias ruoso: hi 20:48
ruoso: why are you opposed to the previous way of emitting stuff 20:49
ruoso: re rewrite of the mold compiler the problem ./m0ld --exec works now for some stuff 20:50
20:51 abra left 20:59 fridim_ joined
ruoso pmurias, hi 21:09
pmurias, the previous way you mean using globals? 21:10
21:13 dmq left
ruoso pmurias, I think we can solve the problem by leaving the assignment of an id to the node being emitted 21:14
then it returns a code to initialize the register and the register that contains the info
instead of the current schema of sending the desired register... 21:15
then the node can decide if it's worth creating a new register or not...
then AST::*->m0ld would receive only $self and return ($code, $reg) 21:17
pugs_svn r22932 | ruoso++ | [mildew] the support for SMOP__S1P__Array 21:18
21:22 Jedai joined
ruoso pmurias, nevermind my changes... it's working now... I'll keep it as it is.... 21:23
pmurias ruoso: any idea what causes the test failures in mildew tests now? 21:24
ruoso I think it's the indentation 21:25
pmurias indentation? 21:26
ruoso hmm... no... it's not
it's if.t that is failing in the compilation 21:27
the others are failing somewhere else
I think it's the Code lookup 21:28
pmurias what's the point of interpreter.goto(false)
ruoso pmurias, it forces a release of the current continuation
which will lead to destroying a lot of objects immediatly 21:29
pmurias if the interpreter is destroyed shortly afterwords it's pointless? 21:31
ruoso mostly yes... I usually used it in the tests to be able to test DESTROYALL calls order 21:32
pmurias, but.... beware that without an interpreter some DESTROYALL codes might fail 21:33
so before destroying the interpreter it's sane to make sure it doesn't contain a continuation
pmurias ok 21:34
ruoso: adding stuff to mildew before it passes it's tests is not very sane
as it tends to break it more 21:35
ruoso you mean the AST::If?
pmurias just in general ;) 21:36
and why do we need AST::If instead of using AST::Call? 21:37
ruoso because it generates a different m0ld code?
and how do I pass a test without adding it to mildew/ 21:38
?
21:39 DemoFreak joined
pmurias ruoso: what i meant is that mildew is currently broken 21:39
21:39 fridim_ left
pmurias ruoso: sorry, i meant AST::List 21:40
AST::If is ok
ruoso pmurias, AST::List was in the way of adding proper slice context to captures
pmurias you can do what it does with an AST::Call 21:41
ruoso yeah... ok 21:42
pmurias you can add it to AST::Helpers if using AST::Call is inconvenient 21:43
21:45 jferrero joined
pmurias ruoso: found the bug which break mildew tests 21:48
S1P::IO.print was assuming FETCH does a C return
ruoso hmm
ok
pmurias ruoso: any ideas how i should cleanly fix it 21:50
?
ruoso pmurias, make it a m0ld 21:51
and then call it with the value already fetched
call an internal mehtod
pmurias and add infix:<+> in order to loop through positionals 21:52
?
ruoso infix:<+> ? 21:53
ah... int + int
pmurias in order to increment the positional index
yes
ruoso infix:<+> would probably be a multi, right? 21:54
pmurias yes :(
i'll just have the S1P::IO require a native type for now, and make a perl6 wrapper call FETCH
ruoso maybe we could get an iterator for the capture
and call map with it
22:00 smg joined
pugs_svn r22933 | pmurias++ | [mildew] S1P::IO.print no longer FETCHes it's arguments t/binding.t passes 22:06
pmurias ruoso: mildew seems to semi-work now, so if you want to add features feel free 22:07
ruoso ok
pmurias mildew: $OUT.print("Mildew is back-ish\n"); 22:10
p6eval mildew: No output (you need to produce output to STDOUT)
masak ish. 22:11
22:17 PZt left 22:18 Limbic_Region joined
pmurias ruoso: do we need mildew to 'use SMOP' now? 22:22
ruoso pmurias, not really needing... but I guess I could be more helpful if it did
pmurias is there anything in the haskell part that needs changing? 22:23
22:35 bacek_ left 22:39 justatheory joined 22:40 bacek_ joined
rakudo_svn r32456 | pmichaud++ | [rakudo]: spectest-progress.csv update: 210 files, 4439 passing, 4 failing 22:50
22:59 justatheory left 23:03 silug joined 23:05 bacek__ joined 23:07 bacek_ left, Psyche^ joined 23:11 aindilis left, aindilis joined 23:14 adc_Penner left 23:15 DemoPhreak joined 23:18 Psyche^ is now known as Patterner1 23:19 Patterner left, Patterner1 is now known as Patterner 23:22 pmurias left 23:28 DemoFreak left 23:32 masak left 23:34 bacek__ left
slavik japhb: awesome :D, there are two things missing IMO, SDL and gtk/glade :D then I'm all set 23:36
23:38 samlh left 23:44 bacek__ joined 23:50 apeiron is now known as zpeiron
ewilhelm where are these syntax highlighted spectests that particle mentions? 23:55
"they're linked from spec.pugscode.org" -- use.perl.org/~chromatic/journal/37825
lambdabot Title: Journal of chromatic (983)
ewilhelm but spec.pugscode.org redirects me to perlcabal.org/syn/ 23:56
lambdabot Title: Official Perl 6 Documentation
ewilhelm hmm, which is also the "spec coverage" link from pugscode.org sidebar :-/ 23:57