pugscode.org/ | nopaste: sial.org/pbot/perl6 | pugs: [~] <m oo se> (or rakudo:, kp6:, smop: etc.) || We do Haskell, too | > reverse . show $ foldl1 (*) [1..4] | irclog: irc.pugscode.org/
Set by TimToady on 25 January 2008.
00:05 armagad left 00:06 Chillance left 00:32 elmex left
meppl good night 00:36
00:48 meppl left 01:59 c1sung joined 02:17 kanru joined
s1n pugs: 1..^5 02:21
p6eval pugs: RESULT[(1, 2, 3, 4)]
02:25 justatheory left
s1n pugs: 5..1 02:30
p6eval pugs: RESULT[()]
s1n Auzon: what do i do with tests that should work but are currently failing? 02:31
mark them as rakudo skip tests? 02:32
SamB s1n: why would you want to do that? 02:33
s1n SamB: do what, mark them rakudo skip? the test is currently in spectest_regression.dat, so i assumed we didn't want anything in those tests failing 02:34
02:35 jhorwitz left
SamB oh, sure, I guess it doesn't qualify as a regression if it never worked in rakudo... 02:38
s1n SamB: are you suggesting it should be skipped then? 02:39
SamB dunno 02:41
02:43 nipotan is now known as nipotaway
s1n pugs: 'd'..'a' 02:48
p6eval pugs: RESULT[()]
s1n pugs 'a'..'d'
pugs: 'a'..'d'
p6eval pugs: RESULT[("a", "b", "c", "d")]
s1n pugs: 1..1 02:51
p6eval pugs: RESULT[(1,)]
02:57 PZt left, PZt joined
s1n if a spectest is failing but shouldn't be, and it's in the spectest_regression.dat, should it be marked as SKIP? 02:59
03:01 alanhaggai left 03:10 Schwern joined 03:14 virbyte joined, wknight8111 left 03:15 dduncan joined 03:18 dduncan_ joined, dduncan_ left 03:19 dduncan_ joined, pbuetow joined
bacek pugs: say 5..1; 03:22
p6eval pugs: OUTPUT[ā¤]
s1n see
pugs: 'a'..'d'
p6eval pugs: RESULT[("a", "b", "c", "d")]
s1n pugs: 'd'..'a'
p6eval pugs: RESULT[()]
s1n it's a fail, but probably shouldn't be
bacek rakudo: 'a'..'d' 03:23
p6eval rakudo 29575: RESULT["a".."d"]
bacek rakudo: 'd'..'a'
p6eval rakudo 29575: RESULT["d".."a"]
bacek rakudo: ('a'..'d').WHAT
p6eval rakudo 29575: OUTPUT[Null PMC access in get_bool()ā¤current instr.: 'parrot;Range;true' pc 4722 (src/gen_builtins.pir:3203)ā¤]
s1n rakudo: 'd'^..'a'
p6eval rakudo 29575: RESULT["d"^.."a"]
bacek rakudo: say ('a'..'d').WHAT
p6eval rakudo 29575: OUTPUT[Rangeā¤]
s1n hmm, lemme check my tests again 03:24
bacek s1n: rakudo's output looks sane for me
s1n rakudo: 1..1
TimToady pugs doesn't implement Range objects yet
p6eval rakudo 29575: RESULT[1..1]
s1n rakudo (1..1).WHAT 03:25
TimToady: there's some partial work there, i went through the tests yesterday, i think there were 64 passing with a handful being fudged 03:26
rakudo: (1..1).WHAT
p6eval rakudo 29575: OUTPUT[Null PMC access in get_bool()ā¤current instr.: 'parrot;Range;true' pc 4722 (src/gen_builtins.pir:3203)ā¤]
bacek rakudo: say (1..1).WHAT
p6eval rakudo 29575: OUTPUT[Rangeā¤]
bacek rakudo: say ~('a'..'d') 03:27
p6eval rakudo 29575: OUTPUT[a b c dā¤]
bacek rakudo: say ('a'..'d')
p6eval rakudo 29575: OUTPUT[abcdā¤]
s1n rakudo: say ~('d'..'a')
p6eval rakudo 29575: OUTPUT[ā¤]
s1n hmmm
rakudo say ~(5..1)
damnit
bacek s1n: stringified empty list.
s1n rakudo: say ~(5..1)
p6eval rakudo 29575: OUTPUT[ā¤]
s1n bacek: wouldn't an empty list be wrong in this case? 03:28
bacek no. Why?
s1n so you can't create decreasing ranges? 03:29
bacek rakudo: say reverse(1..5)
p6eval rakudo 29575: OUTPUT[54321ā¤]
s1n yeah but if i can do increasing ranges, why can't i do increasing ranges without using reverse?
err decreasing ranges w/o reverse
bacek s1n: just because you can't.
s1n heh
bacek Range is increasing only. 03:30
s1n monotonically increasing ranges only?
is that in the spec?
hmm, i never tried that in perl5 but it does that in perl5, if it's in the spec to keep it as-is, then that's fine 03:31
03:33 dduncan left
bacek s1n: perl5 doesn't have 'decresing ranges'... 03:33
Probably S02 should be clarified about Ranges. 03:35
s1n yeah, i noticed 03:36
how about i mark them as skip and unspecced
i don't really see anything in the spec that clarifies this 03:37
bacek s1n: sounds good for me.
s1n bacek: okay 03:38
03:39 baest joined 03:46 pbuetow_ joined
s1n rakudo: say ~(1..1) 03:48
p6eval rakudo 29575: OUTPUT[1ā¤]
s1n moritz_: should unspecced tests be fudged? i talked it over with Auzon and he said go ahead and unfudge them 03:52
moritz_: i'm adding a few more things that test .perl so if they should be fudged, let me know
moritz_: they pass, but if they're supposed to be fudged, that's fine (i.e. (1..5).perl acually gives '1..5') 03:53
03:54 pbuetow left 03:57 dduncan_ left
bacek rakudo: say (1..5).perl 03:58
p6eval rakudo 29575: OUTPUT[1..5ā¤]
bacek rakudo: say (1..'a').perl
p6eval rakudo 29575: OUTPUT[1.."a"ā¤]
bacek rakudo: say (1..'a')
p6eval rakudo 29575: OUTPUT[ā¤]
bacek pugs: say (1..'a') 03:59
p6eval pugs: OUTPUT[ā¤]
Auzon s1n: If it's a parsefail, mark it as skip. But if it parses and gives the wrong result, 'todo' is the proper one 04:03
Some parsefails might require some more creativity if fudge doesn't remove the correct line. This happens if the parsefail is on the line above the test and fudge doesn't get both lines. 04:04
The solution here is to skip the test and use something like #?rakudo emit #
04:09 s1n left
TimToady sigh, it *is* specced... see S03:2641 04:17
04:23 s1n joined 04:32 Jamtech joined 04:51 pbuetow_ left 05:11 araujo left 05:14 Jamtech left, hcchien left, agentzh left, Khisanth left, virbyte left 05:16 virbyte joined, hcchien joined 05:17 Jamtech joined, agentzh joined, Khisanth joined, kcwu joined, kcwu left, kcwu_ joined, Khisanth left, Jamtech_ joined
ingy hola 05:22
TimToady chirps like crickets 05:25
05:28 Khisanth joined 05:29 Lorn left 05:30 Jamtech left
TimToady heh, STD found a bug in t/spec/S02-whitespace_and_comments/unspace.t 05:34
pugs_svn r21369 | lwall++ | [STD] now handles @foo non-interpolation 05:39
r21369 | lwall++ | [unspace.t] accidentally tried to use #() comments at beginning of line
05:53 Psyche^ joined
bacek pugs: say (1|2|3) < 2; 06:04
p6eval pugs: OUTPUT[any(VBool False,VBool True)ā¤]
bacek pugs: say (1&2&3) < 2; 06:05
p6eval pugs: OUTPUT[all(VBool False,VBool True)ā¤]
bacek hmm..
06:06 Patterner left, Psyche^ is now known as Patterner
bacek pugs: say (1&2&3) < 5; 06:11
p6eval pugs: OUTPUT[all(VBool True)ā¤]
06:12 tuxdna joined 06:13 alanhaggai joined 06:18 ashizawa joined 06:43 Psyche^ joined 06:46 pmurias joined
pmurias wouldn't it be possible to just have the parser skip things it doesn't understand rather than fudging parsefail? 06:47
moritz_ pmurias: bad idea, I think 06:49
I can't see how it could reliably resume after an unknown construct
plus, sometimes the test files are wrong - it's nice to get a syntax error then
06:51 iblechbot joined
pmurias if you add todo markers, adding parse failure markers is similiar i guess 06:52
moritz_ I can't really imagine how that could work 06:53
pmurias skip a line and try again 06:55
and the statement level
moritz_ so you basically want to merge fudge and the grammar 06:56
06:59 Patterner left, Psyche^ is now known as Patterner
pmurias moritz_: i would to it for STD.pm, but it tends to parse things 06:59
s/to/do 07:00
moritz_ well, for the tests you'd have to do a bit more, for example note the number of skipped tests 07:01
so you have to put it into the AST somehow as well
I don't think it's worth the trouble
07:01 barney joined
pmurias moritz_: they would be failed tests really 07:04
moritz_ and how could you skip/todo them?
pmurias with fudge ;) 07:05
moritz_ ;-)
pmurias moritz_: do you know what the general test numbering policy is? 07:10
moritz_ what do you mean?
pmurias should the test numbers in a test suit reflect the order of test creation, the order how they depend on each other or something else? 07:12
moritz_ I generally don't number my tests, except the very basic ones to run first 07:13
smop seems to number in order of creation 07:14
pugs_svn r21370 | lwall++ | [STD] handle \@foo and other fiddly issues
pmurias and how should i do test removal?, leave gaps 07:15
moritz_ I'd leave the gaps, but I wouldn't have numbered them in the first place ;-) 07:16
07:25 kanru left
pugs_svn r21371 | lwall++ | [STD] handle Q forms 07:35
r21371 | lwall++ | [quoting.t] change q:q and q:qq to Q:q and Q:qq
07:37 meppl joined 07:42 jan___ joined
pmurias @tell where should i put the root namespace creation ruoso and destruction, as SMOP_DISPATCH and SMOP_RELEASE take an interpreter as a parameter 07:45
lambdabot Consider it noted.
moritz_ pmurias: wrong target person ;-) 07:47
07:50 jan_ left
rakudo_svn r29576 | moritz++ | [rakudo] added S04-statements/do.t to spectest_regression, Auzon++ 07:59
r29576 | moritz++ | +14 pass, +9 todo/skip tests
08:02 masak joined
pmurias @tell ruoso where should i put the root namespace creation ruoso and destruction, as SMOP_DISPATCH and SMOP_RELEASE take an interpreter as a parameter 08:06
lambdabot Consider it noted.
masak speaking of cascaded subscripts, will we be seeing any compile-time checks for array index that are out of bounds in Perl 6? 08:10
moritz_ I don't think it'll be specced to happen at compile time
masak but theoretically it could, right? 08:11
I mean, some of the checks, constants and stuff
moritz_ partially, yes
masak my @a[10]; say @a[15] # BAM
moritz_ there are so many checks that could actually made at compile time... I think we won't see very much of this in an initial release, but the compiler will improve for quite some time after the release 08:12
like compile-time checking for read-only variables
masak that's fine by me.
just wondering if it was on the table at all
by me, if it can be done at compile time, it should 08:13
but I realize it might not be prio before christmas
moritz_ I agree, "fail early" is important
just like "use strict;"
perl5 doesn't do some checks at compile time because the code might not be reachable 08:15
masak ACK
moritz_ perl5.8.8 -ce ' if (0) { 1/ 0}' 08:16
Illegal division by zero at -e line 1.
perl5.10.0 -ce ' if (0) { 1/ 0}'
-e syntax OK
08:17 rindolf joined
moritz_ I haven't made up my mind yet if that's a good thing or not 08:17
I mean in the case of literal constants it's not a good thing 08:18
but it allows you to write stuff like 'our $debug = 0; ... if ($debug) { my $ratio = 1 / $debug; ... }
pmurias masak: the problem with such checks is that there would be false positives 08:20
with things like eval which can changed everything
08:26 isop joined
pmurias Perl 6 offers much more dynamism by default than healthy/nessesary but a pragma could be used to force it to compile time 08:26
08:27 isop left 08:28 isop joined, isop left, isop joined 08:35 barney left 08:39 elmex joined 08:40 fullermd left 08:54 Jamtech_ left 09:09 Alias__ left 09:12 bacek left 09:14 Nebster joined 09:15 rindolf left 09:20 jfredett_ joined 09:26 jfredett1 joined 09:35 jfredett left 09:38 jfredett_ left 10:07 tuxdna left, tuxdna joined 10:11 pmurias left 10:12 iblechbot left 10:14 [particle] left 10:16 araujo joined 10:17 jfredett1 is now known as jfredett 10:21 hcchien_ joined 10:23 hcchien left 10:33 fullermd joined, ashizawa left 10:42 kanru2 joined 10:53 Nebster left, ashizawa joined 10:55 ruoso joined 11:01 wknight8111 joined, alanhaggai left 11:22 chris2 joined 12:11 iblechbot joined 12:12 pmurias joined
pmurias ruoso: hi 12:12
ruoso: where should namespace creation/destruction live? 12:14
i can't put it in the init/destroy sequence as it needs a interpreter 12:16
pugs_svn r21372 | jnthn++ | [spectest] Tests for anonymous classes. 12:26
rakudo_svn r29580 | jonathan++ | [rakudo] Implement anonymous classes. 12:27
masak TimToady: can there be anon grammars? 12:38
pmurias masak: why not? 12:41
masak pmurias: I also don't see why not, but the spec is silent on that point
same with modules, but in that case my intuition says there shouldn't be anon modules
also, this is not a case where spec-doesn't-say-so-same-as-p5 applies 12:42
pmichaud why shouldn't we have anonymous modules?
masak I don't know... because modules are containers, and if you can't refer to the container by name, it's pretty useless? 12:43
I might be wildly wrong, though
pmurias masak: they would parse at least if it weren't for a bug in STD/gimme5 12:44
masak pmurias: could one imagine a use case for them? 12:45
pmurias masak: for anon grammars?
masak modules
pmurias mixing them in
masak hm 12:46
pmurias mixing them in refered to grammars 12:47
masak: you can use anon modules the same as normal ones
i guess
masak but you cannot refer to them
or can you?
pmurias if you have them in a scalar, why not?
masak ah 12:48
right.
so anon grammars/modules are ok, then
pmurias ruoso: should the root namespace be global or per interpreter? 13:01
13:06 cmarcelo joined 13:13 Arathorn joined
Arathorn hi all - don't suppose anyone knows if anyone's already expressed the RFC822 address syntax as perl6 rules? 13:13
pmurias Arathorn: hi, want to try? 13:18
Arathorn hehe 13:20
guess I could - was more wondering whether there was prior art
ruoso pmurias, we could start a prelude interpreter 13:21
lambdabot ruoso: You have 2 new messages. '/msg lambdabot @messages' to read them.
ruoso pmurias, the global namespace needs to be present as C symbol... for boostrap reasons 13:23
pmurias prelude interpreter - explain please 13:24
ruoso: i can create the global namespace withough a interpreter, but i need one to destroy it 13:25
* withought
ruoso the point is that at some point, we are going to need a interpreter available to continue the boostrap 13:27
and even to start another intepreter, eventually
so starting a interpreter would be part of the prelude, the same way the global namespace would
pmurias so there will be a global interpreter
?
s/global/main 13:28
ruoso not really main in the sense that everything would depend on it...
but that it would be avialable for everyone to use it
I mena...
mean
native types doesn't need an interpreter... 13:29
but initializing Object will require
that's where the "prelude intepreter" comes in... it can be used by anyone that needs some interpreter
but it doesn't mean that it will be the interpreter used for everything.... 13:30
one could switch interpreters and probably no one would notice
but we're probably going to stick with it for now, 13:31
at least untill the bootstrap is finished...
13:31 [particle] joined
ruoso pmurias, does it make sense now? 13:32
pmurias yes 13:35
ruoso the point is... after loading the prelude, the "prelude interpreter" could be used, or some other interpreter could be used instead... 13:36
pmurias wouldn't the "bootstrap interpreter" be a better name? 13:37
ruoso yeah... probably... ;) 13:38
ruoso not really good at naming things...
pmurias in what variable should the stored, and where should it be created? 13:40
ruoso SMOP__GlobalNamespace? 13:49
smop_s1p.h? 13:50
and then it would be created during smop_init()
and destroyed during smop_destr()
13:51 isop left 13:52 jiing left
rakudo_svn r29582 | jonathan++ | [rakudo] role_name goes away, since we want to parse a signature in a role definition, and an expression when it's used with does. This should somewhat simplify things when we implement parametric roles. Note role_name is also gone in STD.pm (though getting to what it has now 13:52
..would take a larger refactor).
pmurias ruoso: i'll implement it 13:57
ruoso pmurias++ cool
ruoso from one workplace to another & 13:59
13:59 ruoso left 14:02 rindolf joined, nothingmuch joined 14:04 ingy left 14:05 pjcj joined 14:09 kane_ left, hcchien_ is now known as hcchien, kane_ joined 14:19 alester joined 14:22 wknight8111 left 14:25 cmarcelo left, cmarcelo joined 14:28 pmurias left
rakudo_svn r29585 | jonathan++ | [rakudo] Implement .^ (call on metaclass) syntax, with passing the invocant in as a first argument to the metaclass method, as specified in S12. 14:31
14:48 eternaleye left 14:55 virbyte left 14:57 hcchien left 14:58 Jamtech joined 14:59 tuxdna left 15:06 ruoso joined 15:08 ashizawa left 15:10 elmex left 15:12 meppl left 15:14 meppl joined 15:23 hercynium joined 15:28 rindolf left 15:30 hcchien joined 15:35 cmarcelo left
masak perl6: my $var = 0; nothing while $var++ < 3; say "et voilĆ !" 15:37
p6eval elf 21372: OUTPUT[Undefined subroutine &GLOBAL::nothing called at (eval 119) line 5.ā¤ at ./elf_f line 3861ā¤]
..pugs: OUTPUT[et voilĆ !ā¤]
..rakudo 29585: OUTPUT[Could not find non-existent sub whileā¤current instr.: '_block11' pc 71 (EVAL_13:26)ā¤]
15:39 ludan joined
TimToady kinda sad that rakudo doesn't tell you the name of the missing sub... 15:39
also kinda sad that pugs doesn't fail :)
masak TimToady: rakudo does tell me the name: 'while' 15:40
only it's not supposed to be a missing sub
15:41 |jedai| left, Exodist joined
rakudo_svn r29586 | jonathan++ | [rakudo] Move WHENCE related things that were in P6Object.pir into the Rakudo source tree (Object.pir). 15:41
masak and I don't think it's sad that Pugs doesn't fail :)
TimToady er, you want non-existent subs to silently just do nothing? 15:44
pmichaud rakudo is thinking that 'while' is an undeclared sub 15:46
and it's trying to evaluate 'while' so that it can pass the result to 'nothing'
(which is also an undeclared sub, but rakudo hasn't figured that out yet.) 15:47
15:48 Gothmog_ left
TimToady nothing should be taken as a listop, but "while" should terminate its list 15:48
masak pmichaud: but 'nothing' is declared, I found it in the rakudo source
TimToady: I just assumed that Pugs eval-ed it correctly 15:49
pmichaud TimToady: I agree that rakudo probably isn't parsing 'while' correctly.
masak: nothing is declared in the rakudo source? where? 15:50
(I don't disagree -- I'm just unaware of it)
masak pmichaud: src/builtins/control.pir
TimToady there's nothing in the spec, and who's on first
masak line 91
TimToady: :) 15:51
use/mention
pmichaud ah, nothing is in S29. It probably needs to be defined as a named 0-ary, perhaps?
TimToady interesting--thanks for nothing... 15:52
masak pmichaud: if you point me to something else that is defined as a named 0-ary, I can try to fix it
TimToady I wonder who put it there
masak ...and send a patch
pmichaud masak: rand
masak TimToady: probably nobody :)
pmichaud: oki, thanks
pmichaud masak: it's in grammar.pg, under "named_0ary"
masak goodie
pmichaud we probably need to revise S29 to use the correct syntax for the named 0-aries 15:53
TimToady and I'm not entirely sure I believe in "nothing" yet 15:54
[particle] consult satre
TimToady he doesn't exist
[particle] perhaps godot will drop by 15:55
TimToady I think it has something to do with free will...
[particle] will is free to leave anytime. heck, sanity has already left. 15:56
pmichaud TimToady: in "listop while 1;" --- what in STD.pm causes 'while' to not be treated as a post-declared listop 15:57
?
TimToady well, if correctly coded, the fact that we have terminator:sym<while> defined 16:00
but it's possible the listop parser isn't checking correctly since we took the terminator check out of expect_term
pmichaud right 16:01
that's what I was just following
I get listop -> arglist -> EXPR -> expect_term -> noun -> term:name (or something like that)
I could be missing a step that takes care of it, though. 16:02
TimToady it needs a <!stdstopper> before parsing arglist I think
pmichaud ah, that would work nicely.
16:02 peeps[work] joined
TimToady well, probably needs to go into arglist 16:03
pmichaud even better.
TimToady after .ws
pugs_svn r21373 | lwall++ | [STD] parse nothing while correctly 16:04
TimToady now to test it :)
rakudo_svn r29588 | jonathan++ | [rakudo] Make multi-methods vaguely work (in as far as subs work, anyway). 16:05
TimToady well, STD still parses itself 16:06
rakudo_svn r29589 | jonathan++ | [rakudo] Fix nothing. Patch courtesy of Carl Masak [email@hidden.address] masak++ 16:12
16:16 justatheory joined 16:17 masak left 16:19 armagad joined 16:28 kanru2 left 16:39 Schwern left 16:43 kanru joined 16:45 GarulfoUnix joined
rakudo_svn r29590 | jonathan++ | [rakudo] [p6object] Make isa and can in the metaclass take the object to test as a first parameter, as specified in recent-ish S12 updates. 16:51
16:51 rindolf joined
pugs_svn r21374 | lwall++ | [STD] restore missing precedence limiter in arglist 16:53
16:55 pmurias joined
pmurias doesn't do {} fill the role of &nothing? 16:56
TimToady sure, so does ()
so does 0, unless you get a "useless use" warning...
[particle] what about *;
TimToady that would work, but kinda implies "do whatever", which is more like anything than nothing 16:57
pmurias so why do we need nothing?
TimToady we don't
pmurias should i remove it then? ;)
TimToady it's good for making much ado about :) 16:58
who put it there in the first place?
[particle] nobody
or was it not me?
TimToady mugwump, it would appear 16:59
17:00 silug joined
[particle] the villain from down under 17:00
pmurias TimToady: based on svn blame? 17:01
svn log -r 3270 Functions.pod
TimToady pmurias: *nod*
pmurias Hand-over version from Rod Adams
TimToady well, I think we probably have lots of ways to indicate a noop without it 17:02
and likely * will turn out to be the canonical way, though maybe not 17:03
* still counts as something outside of a void context
so maybe () is better
particularly in a list context that thinks it's collecting all the iteration results 17:04
pmurias 1 while something(); is the perl5 idiom isn't it?
TimToady which I always though should be 0 while something() instead...
[particle] i really want to see foo while 1 replaced by foo while true in perl 6 code
TimToady but 0 is also something in list context, and () isn't
[particle] (magic numbers)--
is false something in list context? 17:05
TimToady yes, any scalar value will be something in list context
17:06 cmarcelo joined 17:07 cosimo left
TimToady "while true" isn't going to fly 17:07
true is a unary 17:08
rhr is 'foo loop' allowed? 17:09
TimToady no
Exodist I am about to write some tests for subroutines, I want to verify the following syntax:
TimToady rhr: logically it would make sense, but the use cases are rare enough that it would leave lots of people scratching their heads 17:10
Exodist sub hi { say "hi" }
rhr nod
Exodist &hi.wrap({ callsame; say "there" })
rakudo_svn r29591 | jonathan++ | [rakudo] Implement .WHERE.
TimToady perl6: say *.true 17:11
p6eval elf 21374: OUTPUT[Undefined subroutine &GLOBAL::whatever called at (eval 119) line 3.ā¤ at ./elf_f line 3861ā¤]
..pugs: OUTPUT[1ā¤]
..rakudo 29590: OUTPUT[Statement not terminated properly at line 1, near ".true"ā¤current instr.: 'parrot;PGE::Util;die' pc 120 (runtime/parrot/library/PGE/Util.pir:82)ā¤]
TimToady pugs has it right there, I think
so "while *" works 17:12
and indicates similar semantics to 'xx *'
[particle] while * and while () instead of 1 and 0, then 17:13
17:13 eternaleye joined
[particle] it's not any prettier 17:13
TimToady while 0 isn't terribly useful anyway
[particle] it's used in debugging 17:14
TimToady how is it different from if 0
and why not use for ()
[particle] it's not, but if you want to remove a while statement instead of an if statement...
while (0) { #foo < bar) { 17:15
TimToady s/#/#(
[particle] / 17:16
TimToady :P
Exodist perl6: sub hi { say "hi" }; &hi.wrap({ callsame; say "there" }); hi 17:18
p6eval elf 21374: OUTPUT[/home/evalenv/pugs/misc/STD_red/match.rb:141:in `block in to_dump0': undefined method `to_dump0' for true:TrueClass (NoMethodError)ā¤ from /home/evalenv/pugs/misc/STD_red/match.rb:140:in `each'ā¤ from /home/evalenv/pugs/misc/STD_red/match.rb:140:in `map'ā¤ from
../home/evalenv/pugs/mi...
..pugs: OUTPUT[*** No such method in class Sub: "&wrap"ā¤ at /tmp/VM8YvJ7Dbq line 1, column 22-57ā¤]
..rakudo 29591: OUTPUT[Method 'wrap' not found for invocant of class 'Closure'ā¤current instr.: '_block11' pc 27 (EVAL_13:16)ā¤]
Exodist now, my question is did I do it wrong, or is it not yet implimented? 17:19
TimToady looks okay to me 17:20
Exodist ty.
TimToady but what do I know... 17:21
17:24 dylanc joined, dylanc left, dylanc joined
pugs_svn r21375 | lwall++ | [Functions.pod] nothing isn't sacred, just use () which is less than nothing 17:29
17:30 dylanc is now known as hour[10] 17:33 jhorwitz joined
pugs_svn r21376 | lwall++ | [nothing.t] nothing here, move along 17:35
17:40 araujo left 17:48 kanru left 17:54 REPLeffect joined 17:55 ludan left
Exodist perl6: sub hi { "Hi" }; ok try { &hi.wrap({ callsame _ " there" }) }; is( hi, "Hi there" ) 17:58
p6eval elf 21376: OUTPUT[/home/evalenv/pugs/misc/STD_red/match.rb:141:in `block in to_dump0': undefined method `to_dump0' for true:TrueClass (NoMethodError)ā¤ from /home/evalenv/pugs/misc/STD_red/match.rb:140:in `each'ā¤ from /home/evalenv/pugs/misc/STD_red/match.rb:140:in `map'ā¤ from
../home/evalenv/pugs/mi...
..pugs: OUTPUT[*** No such subroutine: "&ok"ā¤ at /tmp/eWgbvaRMXS line 1, column 18-62ā¤]
..rakudo 29591: OUTPUT[Could not find non-existent sub okā¤current instr.: '_block11' pc 40 (EVAL_13:21)ā¤]
17:58 alanhaggai_ joined
Exodist perl6: sub hi { "Hi" }; try { &hi.wrap({ callsame _ " there" }) }; say $@; hi; 17:59
p6eval elf 21376: OUTPUT[Parse error in: /tmp/jRDtK8SSv8ā¤panic at line 1 column 60 (pos 60): Can't understand next input--giving upā¤WHERE: p({ callsame _ " there" }) }; say $@; hi;ā¤WHERE: /\<-- HEREā¤ STD_red/prelude.rb:99:in `panic'ā¤ STD_red/std.rb:76:in
..`scan_unitstopper'ā¤...
..pugs: OUTPUT[*** ā¤ Unexpected "@;"ā¤ expecting "::"ā¤ at /tmp/GbeCDqe8Lf line 1, column 66ā¤]
..rakudo 29591: OUTPUT[Statement not terminated properly at line 1, near "$@; hi;"ā¤current instr.: 'parrot;PGE::Util;die' pc 120 (runtime/parrot/library/PGE/Util.pir:82)ā¤]
Exodist perl6: sub hi { "Hi" }; try { &hi.wrap({ callsame _ " there" }) }; hi;
p6eval elf 21376: OUTPUT[/home/evalenv/pugs/misc/STD_red/match.rb:141:in `block in to_dump0': undefined method `to_dump0' for true:TrueClass (NoMethodError)ā¤ from /home/evalenv/pugs/misc/STD_red/match.rb:140:in `each'ā¤ from /home/evalenv/pugs/misc/STD_red/match.rb:140:in `map'ā¤ from
../home/evalenv/pugs/mi...
..pugs: RESULT["Hi"]
..rakudo 29591: RESULT["Hi"]
18:01 alanhaggai_ is now known as alanhaggai
Exodist perl6: say "hi" ~ " there"; 18:03
p6eval elf 21376: OUTPUT[hi thereā¤]
..pugs: OUTPUT[hi thereā¤]
..rakudo 29591: OUTPUT[hi thereā¤]
Exodist perl6: say "hi" _ " there"; 18:04
p6eval elf 21376: OUTPUT[Parse error in: /tmp/mn9q5hjWhAā¤panic at line 1 column 0 (pos 0): Can't understand next input--giving upā¤WHERE: say "hi" _ " there";ā¤WHERE:/\<-- HEREā¤ STD_red/prelude.rb:99:in `panic'ā¤ STD_red/std.rb:76:in `scan_unitstopper'ā¤ STD_red/std.rb:224:in `comp_unit'ā¤
..STD_red/std.rb:...
..pugs: OUTPUT[*** ā¤ Unexpected "_"ā¤ expecting operator, ":" or ","ā¤ at /tmp/DrqHZnUtPX line 1, column 10ā¤]
..rakudo 29591: OUTPUT[Statement not terminated properly at line 1, near "_ \" there\""ā¤current instr.: 'parrot;PGE::Util;die' pc 120 (runtime/parrot/library/PGE/Util.pir:82)ā¤]
18:04 kanru joined
TimToady wow, ancient history... 18:04
Exodist is there a way to use the eval there w/o flooding the channel?
TimToady maybe with /mst
er, /msg
Exodist TimToady: Yeah, I am just starting on perl 6, today is my first time tryint o write any. 18:05
TimToady cool. do you have a pugs commit bit yet?
Exodist yes, I got it last week.
My company is giving me 4 hours a week to work on perl6.
TimToady sugoi 18:06
Exodist I plan to write tests since my C is probably not up to working on rakudo.
perl is my lang of choice for a few years now.
TimToady how's your Haskell ;)
Exodist nonexistant.
:-/
TimToady Haskell is easy to learn--I've done it several times now 18:07
I just have a personality conflict with its compiler...
18:07 alanhaggai_ joined
Exodist I had a hard time getting the compiler installed, on gentoo (my distro of choice) or ubuntu (work distro) 18:08
TimToady anyway, we certainly need more tests
18:08 alanhaggai left
TimToady I got the cabal version installed on ubuntu this week 18:08
Exodist I spent 2 weeks trying to get pugs going before giving up and making rakudo work in an hour.
*2 weeks off and on.
TimToady I had to make one tweak to get zlib to use the provided version rather than the system version, and then cabal works okay 18:09
Exodist hmm, I may give it another try at some point here. but for now I am trying to figure out how these spec tests work... all my attempts at any kind of eval or try are giving me errors about unterminated lines. 18:10
but others I did not write are giving me the same... is this a rakudo thing?
TimToady that tends to be the default error message
Exodist it seems that it does not finish parsing the line before bailing. 18:11
t/spec/S06-advanced_subroutine_features/wrapping.t....Statement not terminated properly at line 9, near "try({ &hi."
TimToady the way the parser works, if something fails but doesn't give an immediate error, it backs off and then stalls out in the middle of the statement, yielding that error
Exodist 9 try({ &hi.wrap({ callsame ~ " there" }) });
TimToady STD has the same difficulty
Exodist hmm.
18:11 r0bby left
TimToady with STD I look at the log to see what the high-water mark was, but we'll have to get better control of reporting what was expected and not found 18:12
Exodist 'the log'?
TimToady when you parse with STD.pm you can get it to spit out a debugging log, but it's about 10 times slower that way 18:13
Exodist hmm, is this documented somewhere? I could use a good doc on test procedures and such. 18:14
Exodist feels like a newb.
TimToady STD.pm is independent of rakudo
18:14 cjfields joined
TimToady (so far) 18:14
except that rakudo's grammar is converging on STD, more or less
so don't worry about that part, if you're concentrating on parrot 18:15
Exodist ok.
TimToady I'll need to think about how to get better errors in STD, and then that will probably get into rakudo at some point 18:16
Exodist perl6: sub hi { "Hi" }; try{ &hi.wrap({ callsame ~ " there" }) }; 18:18
p6eval elf 21376: OUTPUT[/home/evalenv/pugs/misc/STD_red/match.rb:141:in `block in to_dump0': undefined method `to_dump0' for true:TrueClass (NoMethodError)ā¤ from /home/evalenv/pugs/misc/STD_red/match.rb:140:in `each'ā¤ from /home/evalenv/pugs/misc/STD_red/match.rb:140:in `map'ā¤ from
../home/evalenv/pugs/mi...
..pugs: RESULT[undef]
..rakudo 29591: RESULT[Null PMC access in find_method()ā¤current instr.: '_block11' pc 25 (EVAL_13:12)ā¤]
Exodist perl6: sub hi { "Hi" }; try{ &hi.wrap({ callsame ~ " there" }) }; hi;
p6eval elf 21376: OUTPUT[/home/evalenv/pugs/misc/STD_red/match.rb:141:in `block in to_dump0': undefined method `to_dump0' for true:TrueClass (NoMethodError)ā¤ from /home/evalenv/pugs/misc/STD_red/match.rb:140:in `each'ā¤ from /home/evalenv/pugs/misc/STD_red/match.rb:140:in `map'ā¤ from
../home/evalenv/pugs/mi...
..pugs: RESULT["Hi"]
..rakudo 29591: RESULT["Hi"]
18:19 zostay joined
Exodist hits himself hard... he forgot a semiclon on the previous line... been a long time since I had this much trouble from something that simple. 18:21
it also explains why it worked in here...
pmurias Exodist: re rakudo, C-fu is not really a topmost priority when working on rakudo 18:30
Exodist pmurias: I am listening.
pmurias a high-pir tolerance and an ability to read the synopsis should be enough 18:31
Exodist high-pir?
pmurias a high pir tolerance, sorry ;)
Exodist pir?
pmurias pir is parrot assembler
Exodist pulls up google+wikipedia
ah, ok. 18:32
hmm, I will read this tutorial and see if I can get into Rakudo coding. 18:33
oh, this tutorial: www.perlfoundation.org/parrot/index...al_and_faq 18:34
lambdabot Title: PIR Tutorial and FAQ / Parrot, tinyurl.com/5mhdqv
Exodist unless you have a better reference.
pmurias i'm not a parrot guy
i hate pir ;) 18:35
Exodist so what do you normally work on? 18:36
pmurias smop now
it's a sort of parrot alternative 18:37
Exodist reading this: www.perlfoundation.org/perl6/index.cgi?smop 18:38
lambdabot Title: SMOP / Perl 6
pmurias and did some work on elf previously which is a partialy bootstraped perl6 implementation
Exodist hmm, maybe I should ask this: "I am a perl guy, my other languages have been neglected greatly, and my skillsets in them were probably not all that high to begin with. I want to work on and contribute to perl 6, what is the best place for me?" 18:40
pmurias either rakudo or elf
Exodist have a link for 'elf'? 18:42
pmurias misc/elf in the pugs repo
you could hack on elf only coding in perl5 and perl6, but rakudo has more monumentum 18:44
Exodist is reading the elf README... scary. 18:46
pmurias a bit skimpy 18:47
Exodist: re scary, an questions? 18:48
Exodist no, I just had a hard tiem reading it for some reason, probably long week + no sleep + info overload + full moon. 18:49
Tene Exodist: probably rakudo. 18:51
18:51 chris2 left
Exodist yeah, I am reading the PIR tutorial again, I am probably gonna stick to tests for a bit, but I took an assembly class forever ago, I might be able to dive in again. 18:52
pmurias pir isn't really a traditional assembler, it dosn't have all the memory manipulation 18:53
Exodist thats ok, I never got into assembly enough to have anything in memory to get int he way. 18:55
Tene Exodist: you should be able to pick it up pretty quick by looking at a few examples. It's a pretty simple language. 18:56
pmurias s/simple/silly/ ;)
[particle] it's a low-class language, for sure 18:57
look in examples/tutorial/
pmurias i prefer it to sm0p however 18:58
18:58 alanhaggai_ left, alanhaggai_ joined
pmurias but sm0p is a DSL only 19:02
19:04 alanhaggai_ is now known as alanhaggai
Exodist thanks for all the suggestions guys. 19:07
19:12 wknight8111 joined
pugs_svn r21377 | pmurias++ | [smop] 19:14
r21377 | pmurias++ | root namespace
r21377 | pmurias++ | global interpreter (causes horrible leakage, when i try to destroy it spits out segfaults)
r21377 | pmurias++ | some work on p6opauque
pmurias ruoso: i get a segfault when it RELEASE the global interpreter 19:15
ruoso pmurias, /me checking 19:20
pmurias thanks 19:21
19:22 armagad left
ruoso pmurias, test/12 is still valid? 19:26
pmurias, the same for test/14 19:27
it seems you removed the .sm0p, but kept the test...
pmurias i move tests 12 and 14 to misc 19:28
ruoso alright...
I removed the compiled tests 12 and 14 and have no more segfaults
they were using the old version of p6opaque
(but that was there only by a missing make clean on my part) 19:29
pmurias ruoso: i commented the segfault causing part
in smop.c
sorry
ruoso oh... ok 19:30
pmurias as i considered memory leaks less serious 19:31
19:38 hercynium left 19:39 destiney joined
Exodist using Rakudo perl6, hwo would one run the tests verbosely? liek the -v flag for prove? 19:41
Tene easiest is just parrot perl6.pbc t/the/test.pl 19:43
ruoso pmurias, the main issue is that the global interpreter still holds a reference to the last frame at that time 19:46
pmurias looking 19:47
19:47 wknight8111 left
Exodist Tene: thank you. 19:47
19:47 cjfields is now known as perl6 19:48 perl6 is now known as cjfields
pmurias ruoso: how can we fix it? 19:49
ruoso pmurias, I'm experimenting one thing
there's a shutdown sequence issue
there's something that depends on hash that is being held until after the hash RI is destroyed. 19:52
I think we need to make an extra boot phase 19:53
pmurias loads RIs and then setup objects 19:55
ruoso have an almost working version 19:56
pugs_svn r21378 | ruoso++ | [smop] define yet another boot phase in smop, one that can count on a interpreter... 19:58
ruoso pmurias, take a look now... 19:59
now there's a single s1p hash leaking
pmurias ruoso: looking/fixing 20:01
ruoso pmurias, I've just changed a bit the indentation in root_namespace.c
pugs_svn r21379 | ruoso++ | [smop] a little more indentation in root_namespace.c
ruoso pmurias, you should only RELEASE the object *after* using it... 20:02
you might get your object destroyed before you want to...
pmurias i can't RELEASE a brand new object? 20:03
20:03 r0bby joined
pmurias (if i don't use it) 20:04
ruoso if you don't... yes...
ruoso referring to the RELEASE call on the top of the hash message 20:05
pmurias, btw... you're not using locks
pmurias oops 20:06
ruoso pmurias, is there anyone using the global namespace already? 20:07
pmurias a test 20:08
ruoso hmm
pmurias * a lame test
ruoso then it doesn't make sense for it to be leaking in every test
weid
wird
weird
pmurias ruoso: RELEASE's have to be before the loop?
ruoso gah
20:08 araujo joined
ruoso yes 20:08
pmurias it's released after
ruoso cool 20:09
that's it
pmurias how should the new destruction pass be names
* named
? 20:10
pugs_svn r21380 | ruoso++ | [smop] the interpreter loops through the rest of the continuations before finishing the GlobalInterpreter
ruoso I called it SMOP_BOOTSTRAP_INIT_SEQUENCE
they're defined in smop.c and smop_internal.
h
YAY! no more leaks 20:11
ruoso turning into a good plumber
pmurias ruoso++ 20:14
do you too see [bool] "has_next" is not implemented in bool.? 20:15
ruoso pmurias, yes... 20:17
there are some places setting a bool as the continuation...
we need a "empty continuation"
that simply returns false to "has_next"
it can be constant...
pmurias a continuation isa a Frame currently? 20:22
ruoso continuation isa anything... ;)
"Polymorphic Eval" 20:23
ruoso adding a trick to make goto false as goto nowhere...
pugs_svn r21381 | ruoso++ | [smop] goto(bool) means release the current continuation 20:24
pmurias ruoso: assuming we use our only runloop slime
ruoso pmurias, what do you mean? 20:25
wow... all tests passing, no warnings...
I haven't seen this outcome in "make test" for a long time ;) ;)
20:26 alanhaggai_ joined
ruoso pmurias, how hard you think it would be to bring .^!how back to p6opaque? 20:28
pmurias ruoso: i meant what does SLIME use as it's continuations, Frames
ruoso yes... SLIME uses Frames
pmurias $obj.^!how = $foo;
ruoso but it should not assume the continuations to be frames...
pmurias, yes... 20:29
pmurias the assignment itself would be trivial
ruoso pmurias, so we can take back the metaclass delegation for method dispatch
see misc/p6opaque.sm0p:176 20:30
pugs_svn r21382 | pmurias++ | [smop] p6opaque.how 20:33
r21383 | ruoso++ | [smop] SMOP_REFERENCE how before returning 20:36
ruoso pmurias, have you seen how to use the locking?
it's simple as three functions in the API
20:36 alanhaggai_ left
pmurias reading... 20:36
20:36 alanhaggai left
ruoso smop_lowlevel_rdlock(value), smop_lowlevel_wrlock(value) and smop_lowlevel_unlock(value) 20:36
20:36 alanhaggai_ joined
ruoso it's a simple interface to the pthread rwlock 20:37
pugs_svn r21384 | fglock++ | moved local tests to t/v6-pm/; added t/spec/, etc # 408 tests pass
ruoso knows STM is cooler, but is not that smart...
pmurias STM is more complicated for sure 20:39
20:39 Alias_ joined
pmurias fglock has revived v6.pm? 20:40
ruoso pmurias, you're creating both the metadata and instance for every p6opaque 20:42
you don't need to
you just need to create it as it is needed...
because instance values are not going to have metadata (usually)
as well as protoobjects are not going to have instance data... 20:43
pmurias, I've added a few items that were missing in p6opaque structure 20:44
pugs_svn r21385 | ruoso++ | [smop] completing p6opaque structure definition...
pmurias ruoso: wouldn't just sharing the metadata pointer be better for class based objects? 20:45
ruoso pmurias, maybe, but that's not what Perl 6 spec says... 20:46
pmurias got the precise quote? 20:47
ruoso all the HOW and WHAT thing... 20:48
if we make the metadata as HOW, we make prototype-based OO impossible with p6opaque
HOW is just one of the metadata items p6opaque hs 20:49
pmurias p6opaque is for class oo only
ruoso not really...
that's not up to p6opaque to define
p6opaque should support both 20:50
(and in fact, the current design in smop does)
pmurias re p6opaque is ..., maybe is misrembered it's lateish 20:51
pugs_svn r21386 | exodist++ | * Initial tests for function wrapping. 20:52
ruoso pmurias, actually I'm not sure the spec defines that...
pmurias, but I would be really sad on forcing only class-based OO in p6opaque
Exodist woohoo, my first commit to perl6 :-)
ruoso Exodist++
ruoso home &
ruoso 'll try to log in later... but he certainly need some beers...
pmurias ruoso: instanceof is an Array? 20:53
ruoso pmurias, nope...
it points to a direct protoobject
pmurias you have multiple of those in prototype-oo
otherwise it's just poor man's class based oo
like in javascript 20:54
ruoso pmurias, yes yes... and that's why you have isa and does
you can do it pure prototype
but when it's prototype by delegatoin
20:54 donaldh joined
ruoso you can say that this object delegates entirely to *that* prototype 20:54
pmurias il think about it tommorow 20:55
ruoso have people waiting for him...
pmurias * i'll
ruoso later &
20:55 ruoso left 20:56 pmurias left 20:59 Alias__ joined, Alias_ left 21:02 jhorwitz left 21:10 Jamtech left
rakudo_svn r29594 | chromatic++ | [Rakudo] Fixed a POD error in Object. 21:11
pugs_svn r21387 | exodist++ | * Added temporization test on wrapping. 21:13
r21387 | exodist++ | * Added tests for unwrapping a sandwitched wrapper.
21:13 alester left 21:17 iblechbot left 21:19 rindolf left 21:22 Kattana_ joined, Kattana_ left 21:25 wknight8111 joined 21:52 ingy joined 21:57 GarulfoUnix left
rakudo_svn r29598 | jonathan++ | [rakudo] Implement WHICH in object. We now need to override it in the various value types, and then we can implement ===. 21:59
22:00 destiney left 22:02 eternaleye left 22:04 cjfields left 22:07 Limbic_Region joined 22:12 jferrero joined 22:21 REPLeffect left 22:22 REPLeffect joined 22:23 donaldh left 22:32 eternaleye_ joined
pugs_svn r21388 | fglock++ | [v6.pm] fixed block interpolation in string 22:39
22:40 peeps[work] left 22:44 mncharity joined
pugs_svn r21389 | putter++ | [misc/elfish/rx_on_re] No longer segfaults. 22:44
r21389 | putter++ | The bootstrap grammar for p5 re modifiers uses a (?{helper($^N)}),
r21389 | putter++ | which then called a split(). split() within regexps is a known
r21389 | putter++ | locus of corruption. As now. Thankful kudos to moritz_++ TimToady++.
mncharity I would have thought rx_on_re was (?{}) (??{}) free. Turned out the grammar for p5 regexps used a (?{}) helper sub. Which then lived dangerously with a split(). 22:46
lambdabot mncharity: You have 1 new message. '/msg lambdabot @messages' to read it.
mncharity Thanks all.
22:46 jferrero left 22:47 mncharity left 22:56 ikeda joined 23:03 Exodist left 23:08 smtms left 23:11 eternaleye_ left, eternaleye_ joined 23:17 cmarcelo left 23:21 hour[10] left
s1n moritz_: should I skip and/or not add any tests using .perl, even if they pass? 23:31
Auzon: same question for you
.perl isn't specced, but in many cases it works 23:32
23:32 peeps[work] joined
s1n that is, this will pass: is (1..5).perl, '1..5', ".perl .."; 23:33
23:47 icwiener joined