»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'perl6: say 3;' or rakudo:, niecza:, std:, or /msg p6eval perl6: ... | irclog: irc.perl6.org/ | UTF-8 is our friend! Set by sorear on 4 February 2011. |
|||
00:09
uasi left,
jamtech_ joined,
jamtech left
|
|||
dalek | ast: 53b43a6 | Coke++ | S05-metasyntax/repeat.t: rakudo/nom fudging |
00:12 | |
kudo/nom: 0d73bac | Coke++ | t/spectest.data: run fudged test |
00:13 | ||
00:14
replore_ joined,
Chillance left
00:30
uasi joined
00:33
soh_cah_toa joined,
y3llow left,
y3llow joined
|
|||
[Coke] | rakudo: sub foo { say "bar" }; my $x = 'foo'; ::$x() | 00:39 | |
p6eval | rakudo b10ef5: OUTPUT«===SORRY!===Cannot look up empty name» | ||
diakopter | does it work without the :: | 00:40 | |
oh, of course not | |||
sorear | should be ::($x) anyway | ||
[Coke] | sorear: perhaps you can close out RT#64846 | 00:41 | |
00:46
jamtech_ left
|
|||
sorear | [Coke]: no. | 00:47 | |
00:47
jamtech_ joined
|
|||
sorear | hmm, rakudo needs to become self-aware | 00:48 | |
00:49
buubot_backup left
|
|||
[Coke] | hey, rakudodevs. can we reject #68636 ? | 00:53 | |
rakudo: %*h.push: $*IN.slurp.join.comb.map(-> $k {$k=>1}); say %*h.perl | 00:54 | ||
p6eval | rakudo b10ef5: OUTPUT«Method 'push' not found for invocant of class 'Failure' in <anon> at /tmp/HOfa8x5OBj:1 in <anon> at /tmp/HOfa8x5OBj:1» | ||
sorear | niecza: class B0rk { say $.a } | 00:55 | |
p6eval | niecza v9-32-g380d891: OUTPUT«===SORRY!===Variable $.a used where no 'self' is available at /tmp/QbuhzpkBAZ line 1:------> class B0rk { say ⏏$.a }Unhandled exception: Check failed at /home/p6eval/niecza/boot/lib/CORE.setting line 685 (CORE di… | ||
colomon | woah, slew of bug e-mails from [Coke] | ||
:) | 00:56 | ||
00:57
uasi left
|
|||
[Coke] | perl6: role woowoo {}; multi trait_mod:<is>(Routine $c, woowoo) { $c.wrap: sub { say "Woowoo" } }; sub foo is woowoo { say "foo" }; foo(); | 00:59 | |
p6eval | niecza v9-32-g380d891: OUTPUT«===SORRY!===Cannot extend category:trait_mod with subs at /tmp/BMLhA2C9Nk line 1:------> role woowoo {}; multi trait_mod:<is>⏏(Routine $c, woowoo) { $c.wrap: sub { saUnhandled exception: Unable to resolve method ast… | ||
..pugs: OUTPUT«***  Unexpected ":<is" expecting "::", "handles", "is", bare trait, subroutine parameters, trait or block at /tmp/nyWkzg6sgM line 1, column 32» | |||
..rakudo 0d73ba: OUTPUT«===SORRY!===Method 'wrap' not found for invocant of class 'Sub'» | |||
soh_cah_toa | that reminds me, in other trait_mod definitions (in src/core/traits.pm), i see signatures w/ what look like smiley faces attached to the type. for instance, 'multi trait_mod:<of>(Routine:D $target, Mu:U $type)'. what are the :D and :U for? i don't think i've ever seen those in the spec before | 01:04 | |
[Coke] | t/spec/S02-types/enum.t - any reason this file isn't even in spectest.data ? | 01:06 | |
01:06
uasi joined
01:09
buubot_backup joined
01:14
thou left
|
|||
dalek | ast: 74ac196 | Coke++ | S02-types/enum.t: rakudo nom fudging |
01:18 | |
[Coke] guesses no. | |||
dalek | kudo/nom: cbdd9b0 | Coke++ | t/spectest.data: run fudged test. |
||
[Coke] | rakudo: ({nextsame})() | 01:19 | |
p6eval | rakudo 0d73ba: OUTPUT«No dispatcher in scope in block <anon> at /tmp/eaLBhdn45F:1 in <anon> at /tmp/eaLBhdn45F:1 in <anon> at /tmp/eaLBhdn45F:1» | ||
dalek | ecs: fe723c3 | larry++ | S12-objects.pod: rm "Conjectural" from :D and :U |
01:21 | |
TimToady | soh_cah_toa: see S12:1590 | 01:22 | |
01:22
woosley joined
01:23
wolfman2000 joined
|
|||
soh_cah_toa | ah, i knew it! i guessed d = defined and u = undefined | 01:23 | |
so :T as a type object means an object that can't be instantiated, correct? | 01:24 | ||
01:26
vlixes joined
01:29
arnsholt joined
|
|||
TimToady | well, it means an object *isn't* instantiated at that spot... | 01:35 | |
but you can certainly instantiate one out of a type object using the .new method :D | |||
soh_cah_toa | oh, so 'my Int $a' doesn't actually instantiate it until i say '$a = 42' | 01:37 | |
TimToady | doesn't instantiate it then either, since the 42 is already instantiated | 01:39 | |
nom & | 01:40 | ||
soh_cah_toa | how is 42 instantiated? it's a constant | ||
donri | but still an object right? | 01:41 | |
soh_cah_toa | oh right, you can do stuff like 42.abs() | 01:42 | |
everything is an object now, that's right | 01:43 | ||
so then still, what's the difference between a type object and say a user-defined object? if a type object isn't instantiated when it's declared, when is it instantiated? | 01:45 | ||
donri | does that work, it's commonly a syntax error in many languages | 01:46 | |
rakudo: 42.abs | |||
p6eval | rakudo 0d73ba: ( no output ) | ||
donri | rakudo: say 42.abs | ||
p6eval | rakudo 0d73ba: OUTPUT«42» | ||
donri | rakudo: say 42. | ||
p6eval | rakudo 0d73ba: OUTPUT«===SORRY!===Confused at line 1, near "say 42."» | ||
donri | rakudo: say .5 | ||
p6eval | rakudo 0d73ba: OUTPUT«0.5» | ||
01:50
buubot_backup left
|
|||
[Coke] | rakudo: say one.5 | 01:53 | |
p6eval | rakudo 0d73ba: OUTPUT«===SORRY!===Confused at line 1, near "say one.5"» | ||
donri | this aint ruby ;) | 01:59 | |
02:11
buubot_backup joined
02:18
mykhal left
02:20
donri left
|
|||
TimToady | perl6: say slurp; | 02:22 | |
p6eval | niecza v9-32-g380d891: OUTPUT«Unhandled exception: No value for parameter $path in CORE slurp at /home/p6eval/niecza/lib/CORE.setting line 0 (CORE slurp @ 0)  at /tmp/m4v6NNxa25 line 1 (MAIN mainline @ 1)  at /home/p6eval/niecza/lib/CORE.setting line 2060 (CORE C968_ANON @ 2)  a… | ||
..rakudo cbdd9b: OUTPUT«No applicable candidates found to dispatch to for 'slurp'. Available candidates are::(Any $filename) in sub slurp at src/gen/CORE.setting:4892 in <anon> at /tmp/aDXoSGkc7x:1 in <anon> at /tmp/aDXoSGkc7x:1» | |||
..pugs: OUTPUT«***  Unexpected ";" at /tmp/geUmRzq0SQ line 1, column 10» | |||
diakopter | niecza: say slurp 'Makefile' | 02:23 | |
p6eval | niecza v9-32-g380d891: OUTPUT«Unhandled exception: CORE slurp may not be used in safe mode at /home/p6eval/niecza/lib/CORE.setting line 0 (CORE slurp @ 0)  at /tmp/Ew4ZEILOpb line 1 (MAIN mainline @ 1)  at /home/p6eval/niecza/lib/CORE.setting line 2060 (CORE C968_ANON @ 2)  at /… | ||
TimToady | slurp should default to ARGFILES | ||
dinner really & | |||
02:25
am0c joined
02:35
jamtech_ left
02:36
jamtech_ joined
|
|||
TimToady | perl6: say slurp($*ARGFILES) | 02:44 | |
p6eval | niecza v9-32-g380d891: OUTPUT«Unhandled exception: CORE slurp may not be used in safe mode at /home/p6eval/niecza/lib/CORE.setting line 0 (CORE slurp @ 0)  at /tmp/bYV_c9HJnQ line 1 (MAIN mainline @ 1)  at /home/p6eval/niecza/lib/CORE.setting line 2060 (CORE C968_ANON @ 2)  at /… | ||
..rakudo cbdd9b: OUTPUT«This type cannot unbox to a native string in method open at src/gen/CORE.setting:4761 in sub open at src/gen/CORE.setting:4874 in sub slurp at src/gen/CORE.setting:4894 in <anon> at /tmp/KMqpS6_q5U:1 in <anon> at /tmp/KMqpS6_q5U:1» | |||
..pugs: OUTPUT«*** Unsafe function 'slurp' called under safe mode at /tmp/e04AMhVxhP line 1, column 5 - line 2, column 1» | |||
diakopter | I think slurp and other file reading things should be allowed in safe mode; it's my p6eval box, after all | 02:45 | |
02:46
packetknife joined
02:50
__sri left
02:51
Patterner left,
jfried joined,
Gothmog_ joined,
Psyche^ joined,
Psyche^ is now known as Patterner
|
|||
sorear | diakopter: noted. | 02:51 | |
02:53
_sri joined
|
|||
TimToady | rosettacode.org/wiki/Letter_frequency#Perl_6 | 02:53 | |
02:59
jnthn joined
03:00
vlixes left
03:04
cotto left
03:05
cotto joined
03:13
uasi left
03:18
jamtech__ joined
03:19
jamtech_ left,
envi_|2 joined
03:28
packetknife left
03:31
bluescreen10 left
|
|||
[Coke] | rakudo: say index("uuúuúuùù", "úuù") | 03:31 | |
p6eval | rakudo cbdd9b: OUTPUT«4» | ||
[Coke] | perl6: my $*x = 42; say $*x.WHAT | 03:33 | |
p6eval | pugs: OUTPUT«Scalar» | ||
..rakudo cbdd9b, niecza v9-32-g380d891: OUTPUT«Int()» | |||
[Coke] | rakudo: $*x = 42; say $*x.WHAT | 03:34 | |
p6eval | rakudo cbdd9b: OUTPUT«Cannot assign to a non-container in <anon> at /tmp/meGTbjLflb:1 in <anon> at /tmp/meGTbjLflb:1» | ||
[Coke] | rakudo: my Str %s = {a => 'b'} | 03:35 | |
p6eval | rakudo cbdd9b: ( no output ) | ||
[Coke] | rakudo: my %s of Str; %s<a> = 'b'; | ||
p6eval | rakudo cbdd9b: ( no output ) | ||
[Coke] | rakudo: my Str %s = a => 'b' | 03:36 | |
p6eval | rakudo cbdd9b: ( no output ) | ||
03:38
uasi joined
|
|||
[Coke] | rakudo: enum A::B <a b c>; say b | 03:44 | |
p6eval | rakudo cbdd9b: OUTPUT«A::B::b» | ||
[Coke] | rakudo: $a = (my $a) | 03:49 | |
p6eval | rakudo cbdd9b: ( no output ) | ||
[Coke] | rakudo: my $a = $_ given $a | ||
p6eval | rakudo cbdd9b: ( no output ) | ||
[Coke] | rakudo: my @a = (1,2) Z (3,4); say @a.perl | 03:50 | |
p6eval | rakudo cbdd9b: OUTPUT«Array.new(1, 3, 2, 4)» | ||
[Coke] wonders why "testsneeded" comes last. | 03:53 | ||
rakudo: &infix:(+)(3,4).say | 03:54 | ||
p6eval | rakudo cbdd9b: OUTPUT«===SORRY!===Malformed parameter at line 1, near "+)(3,4).sa"» | ||
[Coke] | rakudo: &infix:("+")(3,4).say | ||
p6eval | rakudo cbdd9b: OUTPUT«===SORRY!===Symbol '&infix:("+")' not predeclared in <anonymous> (/tmp/Sz2DJWxqL6:1)» | ||
[Coke] | rakudo: my $foo="+";&infix:($foo)(3,4).say | ||
p6eval | rakudo cbdd9b: OUTPUT«===SORRY!===Symbol '&infix:($foo)' not predeclared in <anonymous> (/tmp/qTMVLz747s:1)» | ||
[Coke] | rakudo: class A { method f(*%_) { |%_ } }' | 03:55 | |
p6eval | rakudo cbdd9b: OUTPUT«===SORRY!===Confused at line 1, near "class A { "» | ||
[Coke] | rakudo: for 1..5 -> $a, $b { say $a, $b } | 03:56 | |
p6eval | rakudo cbdd9b: OUTPUT«1234Not enough positional parameters passed; got 1 but expected 2 in block <anon> at /tmp/DxYdxC7jfN:1 in method reify at src/gen/CORE.setting:3690 in method reify at src/gen/CORE.setting:3595 in method reify at src/gen/CORE.setting:3595 in method gimme… | ||
[Coke] | rakudo: for 1..5 -> $a, $b { say $a, $b? } | ||
p6eval | rakudo cbdd9b: OUTPUT«===SORRY!===Unable to parse blockoid, couldn't find final '}' at line 1» | ||
[Coke] | rakudo: for 1..5 -> $a, $b? { say $a, $b } | ||
p6eval | rakudo cbdd9b: OUTPUT«12345Mu()» | ||
[Coke] | rakudo: say %("foo" ~~ /foo/).exists("foo") | 03:57 | |
p6eval | rakudo cbdd9b: OUTPUT«Bool::False» | ||
03:59
satyavvd joined
|
|||
[Coke] | rakudo: ok %( 'foo' ~~ /<alpha> oo/ ){ 'alpha' }:exists; say "alive" | 03:59 | |
p6eval | rakudo cbdd9b: OUTPUT«===SORRY!===Confused at line 1, near "ok %( 'foo"» | ||
[Coke] | rakudo: Inf.int.say | 04:00 | |
p6eval | rakudo cbdd9b: OUTPUT«Method 'int' not found for invocant of class 'Num' in <anon> at /tmp/qPsFlg_0FW:1 in <anon> at /tmp/qPsFlg_0FW:1» | ||
[Coke] | rakudo: Inf.Int.say | ||
p6eval | rakudo cbdd9b: OUTPUT«-9223372036854775808» | ||
04:01
birdwindupbird joined
|
|||
[Coke] | sorear: ping. | 04:08 | |
phenny: ask sorear if we can close 75030 - it was originally rejected, and rakudo has autoprint in REPL now. | 04:09 | ||
phenny | [Coke]: I'll pass that on when sorear is around. | ||
[Coke] | rakudo: sub foo() { return 1,2,:c<3> }; say foo().perl | 04:10 | |
p6eval | rakudo cbdd9b: OUTPUT«(1, 2, "c" => Mu)» | ||
[Coke] | rakudo: say '16'{'%x'} | ||
p6eval | rakudo cbdd9b: OUTPUT«Method 'at_key' not found for invocant of class 'Str' in method postcircumfix:<{ }> at src/gen/CORE.setting:1002 in <anon> at /tmp/MHZjKseyZi:1 in <anon> at /tmp/MHZjKseyZi:1» | ||
sorear | [Coke]: you may close 75030. | ||
phenny | sorear: 04:09Z <[Coke]> ask sorear if we can close 75030 - it was originally rejected, and rakudo has autoprint in REPL now. | ||
sorear | [Coke]: I don't know if you can - I know I can't. Who can give out close bits? | 04:11 | |
moritz | sorear: I think pmichaud can | ||
good morning | |||
[Coke] | I can. | 04:12 | |
I am an rt p6 admin from the dark times. | |||
but to give them out, I have to git-bisect parrot until I find the instructions. ;) | |||
enum A <a b c>; enum B <a b c>; say &a.perl | 04:13 | ||
rakudo: enum A <a b c>; enum B <a b c>; say &a.perl | |||
p6eval | rakudo cbdd9b: OUTPUT«===SORRY!===Symbol '&a' not predeclared in <anonymous> (/tmp/4cTc1McdVJ:1)» | ||
[Coke] | rakudo: enum A <a b c>; enum B <a b c d>; say &d.perl | ||
p6eval | rakudo cbdd9b: OUTPUT«===SORRY!===Symbol '&d' not predeclared in <anonymous> (/tmp/vOGTaBd5w0:1)» | ||
[Coke] | rakudo: my ::foo $x; say $x | 04:19 | |
p6eval | rakudo cbdd9b: OUTPUT«Cannot call a method on type variable foo in find_method at src/gen/Metamodel.pm:261 in sub say at src/gen/CORE.setting:4722 in sub say at src/gen/CORE.setting:4729 in <anon> at /tmp/ormgC9k2j3:1 in <anon> at /tmp/ormgC9k2j3:1» | ||
[Coke] | rakudo: my ::foo $x; | ||
p6eval | rakudo cbdd9b: ( no output ) | ||
[Coke] | rakudo: my ::foo $x; say "alive" | ||
p6eval | rakudo cbdd9b: OUTPUT«alive» | ||
04:22
jamtech joined,
jamtech__ left
|
|||
dalek | ecza/serialize: 06f4a53 | sorear++ | / (6 files): Code execution in new model, checkpoint 2 |
04:22 | |
[Coke] | rakudo: rakudo: say (4...^5).perl | 04:23 | |
p6eval | rakudo cbdd9b: OUTPUT«===SORRY!===Confused at line 1, near "rakudo: sa"» | ||
[Coke] | rakudo: say (4 ... 0, 1, 2, 3, 4).perl | ||
p6eval | rakudo cbdd9b: OUTPUT«(4, 3, 2, 1, 0, 1, 2, 3, 4).list» | ||
[Coke] | rakudo: rakudo: say (-5...^5).perl | 04:24 | |
p6eval | rakudo cbdd9b: OUTPUT«===SORRY!===Confused at line 1, near "rakudo: sa"» | ||
[Coke] | rakudo: rakudo: say (4...^5).perl | ||
p6eval | rakudo cbdd9b: OUTPUT«===SORRY!===Confused at line 1, near "rakudo: sa"» | ||
[Coke] | rakudo: rakudo: say (4 ... ^5).perl | ||
p6eval | rakudo cbdd9b: OUTPUT«===SORRY!===Confused at line 1, near "rakudo: sa"» | ||
[Coke] | there's a list branch but I can't see it on github? | 04:26 | |
sorear | it was deleted a while ago | 04:27 | |
git pull doesn't delete locally-saved branches | |||
it only pulls new ones | |||
[Coke] | can I see when it was deleted? | ||
sorear | maybe by running reflog on the server | 04:28 | |
[Coke] | eh. not worth it. Danke. | 04:30 | |
rakudo: die | 04:33 | ||
p6eval | rakudo cbdd9b: OUTPUT« in <anon> at /tmp/FgvcEoz0pL:1 in <anon> at /tmp/FgvcEoz0pL:1» | ||
[Coke] | rakudo: ... | 04:34 | |
p6eval | rakudo cbdd9b: ( no output ) | ||
[Coke] | rakudo: fail | ||
p6eval | rakudo cbdd9b: ( no output ) | ||
[Coke] | rakudo: exit | ||
p6eval | rakudo cbdd9b: ( no output ) | ||
[Coke] | rakudo: .die | ||
p6eval | rakudo cbdd9b: OUTPUT«Method 'die' not found for invocant of class 'Any' in <anon> at /tmp/0jzYTcsKvO:1 in <anon> at /tmp/0jzYTcsKvO:1» | ||
[Coke] | rakudo: class AtestOfSay { ... }; my AtestOfSay $t; say $t; | 04:35 | |
p6eval | rakudo cbdd9b: OUTPUT«===SORRY!===The following packages were stubbed but not defined: AtestOfSay» | ||
[Coke] | rakudo: Seq.new.^methods>>.say | 04:36 | |
p6eval | rakudo cbdd9b: OUTPUT«joinunshiftat_posexistsrindexsaydispatch:<.*>acosdispatch:<::>infinitegrepgistmaxatanhsqrtfmtcossinhmatchBUILDALLcisinfiniteanypairsasechArraytanDUMP-IDtrim-trailingclassifyiteratorNumpostcircumfix:<[ ]>cosechIntvaluescapitalize… | ||
[Coke] | die Exception.new("Test"); | 04:37 | |
04:37
jaldhar left
|
|||
[Coke] | rakudo: die Exception.new("Test"); | 04:37 | |
p6eval | rakudo cbdd9b: OUTPUT«Default constructor only takes named arguments in method new at src/gen/CORE.setting:502 in <anon> at /tmp/Vb7LIiy8VA:1 in <anon> at /tmp/Vb7LIiy8VA:1» | ||
04:38
jaldhar joined
|
|||
[Coke] | rakudo: sub foo() { succeed }; say foo | 04:38 | |
p6eval | rakudo cbdd9b: OUTPUT«Warning0» | ||
[Coke] | rakudo: say <1 2 3>.>>.perl | 04:40 | |
p6eval | rakudo cbdd9b: OUTPUT«===SORRY!===Confused at line 1, near "say <1 2 3"» | ||
04:42
packetknife joined
|
|||
[Coke] | rakudo: say "abcd".index("xyz") == 0 | 04:43 | |
p6eval | rakudo cbdd9b: OUTPUT«Use of uninitialized value in numeric contextBool::True» | ||
[Coke] | rakudo: say Mu.perl | 04:46 | |
p6eval | rakudo cbdd9b: OUTPUT«Mu» | ||
[Coke] | rakudo: class A {}; A.new.perl | ||
p6eval | rakudo cbdd9b: ( no output ) | ||
[Coke] | rakudo: class A {}; A.new.perl.say | ||
p6eval | rakudo cbdd9b: OUTPUT«A<95569160>» | 04:47 | |
[Coke] | rakudo: say (1..10).sort(&rand) | ||
p6eval | rakudo cbdd9b: OUTPUT«Too many positional parameters passed; got 1 but expected 0 in sub rand at src/gen/CORE.setting:2609 in method reify at src/gen/CORE.setting:3690 in method reify at src/gen/CORE.setting:3595 in method gimme at src/gen/CORE.setting:3932 in method eager at … | ||
[Coke] | rakudo: say 357+498+7 | 04:50 | |
p6eval | rakudo cbdd9b: OUTPUT«862» | ||
04:52
packetknife left
04:53
soh_cah_toa left
05:03
mberends left
|
|||
moritz | nom: enum SomeEnum < a b c>; say SomeEnum::.keys | 05:04 | |
p6eval | nom cbdd9b: OUTPUT«0» | ||
moritz | nom: enum SomeEnum < a b c>; say SomeEnum::.enums.keys | ||
p6eval | nom cbdd9b: OUTPUT«a b c» | ||
moritz | (that was RT #70894) | 05:05 | |
05:05
packetknife joined
05:07
jamtech left
|
|||
moritz | [Coke]++ # going wild in RT queue | 05:09 | |
dalek | ast: a4a120d | moritz++ | S0 (3 files): random rakudo unfudges |
05:19 | |
05:26
koban` joined,
koban` left
05:39
daniel-s joined
05:41
cookys joined
06:02
wtw joined,
lestrrat left
06:03
lestrrat joined
06:08
orafu left
06:10
orafu joined
06:11
JimmyZ joined
06:13
wolfman2000 left
|
|||
JimmyZ | rakudo: trait_mod:<is-a>(Routine:D $r, :$rw!) { $r.set_rw(); } # bug ? | 06:14 | |
p6eval | rakudo cbdd9b: OUTPUT«===SORRY!===Unable to parse postcircumfix:sym<( )>, couldn't find final ')' at line 1» | ||
06:14
uasi_ joined
06:15
uasi left,
uasi joined
06:16
kaleem joined
|
|||
sorear | JimmyZ: you need "sub " at the beginning of the line. | 06:18 | |
JimmyZ | LTA error? | ||
sorear | JimmyZ: rakudo is parsing (...) as an argument and getting confused, because argument lists can't have types | ||
It's a technically correct error, and I'm not sure how it can be improved. | 06:19 | ||
06:19
uasi_ left
|
|||
sorear | except maybe by unifying parameter and argument syntax, but for a language like Perl 6 that would waterbed a geyser... it could probably be made to work in C# | 06:20 | |
06:20
Sarten-X left
|
|||
JimmyZ | rakudo: class A { method trait_mod:<is-a>( $r, :$rw!) { $r.set_rw(); } }; # how can I use is-a here? | 06:21 | |
p6eval | rakudo cbdd9b: ( no output ) | ||
sorear | A.trait_mod:<is-a>(@args) | ||
implicit trait syntax only works for subs, not methods | |||
general rule - if you're changing the syntax, it needs to be through something with the my-scope | 06:22 | ||
jnthn | It's just "is", not "is-a" | 06:23 | |
JimmyZ | rakudo: class A { sub trait_mod:<is-a>( $r, :$rw!) { $r.set_rw(); } }; # and this one? | ||
p6eval | rakudo cbdd9b: ( no output ) | ||
jnthn | Unless you're trying to introduce a new one... | ||
mornin', btw | |||
JimmyZ | yes, I'm trying to introduce new one | ||
sorear | JimmyZ: Why do you keep saying class A? | ||
06:23
zby_home_ joined
|
|||
JimmyZ | good morning, jnthn | 06:23 | |
sorear | mornin', jnthn | 06:24 | |
cotto | hi jnthn | ||
JimmyZ | sorear: I'm trying to find bug | ||
jnthn | JimmyZ: Then it needs to be declared multi trait_mod:<blah>(...) { ... }, but Rakudo won't augment the parser for new ones yet. | ||
sorear | JimmyZ: I'm fairly sure that introducing new trait keywords is not supported by any compiler yet | ||
(this will change next month) | 06:25 | ||
06:25
packetknife left
|
|||
JimmyZ | rakudo: class A { sub trait_mod:<is>( $r, :$rw!) { $r.set_rw(); } }; # how can I use is here? | 06:25 | |
p6eval | rakudo cbdd9b: ( no output ) | ||
JimmyZ | I didn't is not supported ,hehe | ||
I didn't know it is not supported ,hehe | |||
jnthn | YOu can declare custom trait mods for sure. | ||
For now you should explicitly mark them multi. | 06:26 | ||
JimmyZ | rakudo: class A { mutil trait_mod:<is>(Class:D $r, :$rw!) { $r.set_rw(); } }; # how can I use is here? | ||
p6eval | rakudo cbdd9b: OUTPUT«===SORRY!===Unable to parse postcircumfix:sym<( )>, couldn't find final ')' at line 1» | ||
jnthn | JimmyZ: See my grammar debugger module for an example of a module that adds, and exports, extra traits. | ||
multi, not mutil :) | |||
YOu use traits by putting them on declarative thins. | 06:27 | ||
06:27
Sarten-X joined
|
|||
JimmyZ | rakudo: class A { multi trait_mod:<is>(Class:D $r, :$rw!) { $r.set_rw(); } }; | 06:28 | |
p6eval | rakudo cbdd9b: OUTPUT«===SORRY!===Invalid typename in parameter declaration at line 1, near " $r, :$rw!"» | ||
jnthn | rakudo: multi trait_mod:<is>(Routine:D $r, :$blah!) { $r does role { method blah { True } } }; sub foo() is blah { }; say &foo.blah | ||
p6eval | rakudo cbdd9b: OUTPUT«===SORRY!===Lexical '$r' not found» | ||
jnthn | uh...huh. | 06:29 | |
rakudo: multi trait_mod:<is>(Routine:D $r, :$blah!) { $r does role { method blah { True } } } | |||
p6eval | rakudo cbdd9b: ( no output ) | ||
jnthn | meh, too little coffee to debug stuff... :) | ||
JimmyZ | rakudo: class A { multi trait_mod:<is>(Routine:D $r, :$rw!) { $r.set_rw(); } }; | 06:30 | |
p6eval | rakudo cbdd9b: ( no output ) | ||
JimmyZ | jnthn: How can I use it when it's defined in a class | ||
jnthn | JimmyZ: By applying it to things in the class. | 06:32 | |
method foo() is rw { ... } # should hit your trait mode | |||
*mod | |||
It may not, however, because I didn't do the tie-breaking on scope depth yet. | 06:33 | ||
JimmyZ | rakudo: class A { multi trait_mod:<is>( $r, :$rwr!) { $r.set_rw(); }; sub b is rwr { }; }; | 06:34 | |
p6eval | rakudo cbdd9b: OUTPUT«===SORRY!===Lexical '$r' not found» | ||
jnthn | JimmyZ: That should work. I'm a bit confused about why it doesn't. | 06:36 | |
rakudo: sub foo($a) { say $a }; BEGIN foo(42) | 06:37 | ||
p6eval | rakudo cbdd9b: OUTPUT«42» | ||
jnthn | rakudo: multi sub foo($a) { say $a }; BEGIN foo(42) | 06:38 | |
p6eval | rakudo cbdd9b: OUTPUT«42» | ||
JimmyZ | rakudo: class A { multi method trait_mod:<is>( :$rwr!) { }; Class b is rwr { }; }; | ||
p6eval | rakudo cbdd9b: OUTPUT«Could not find sub &rwr in <anon> at /tmp/fu78dmR3EG:1 in <anon> at /tmp/fu78dmR3EG:1 in <anon> at /tmp/fu78dmR3EG:1» | ||
jnthn | oh...it's that bug :( | 06:39 | |
moritz | uhm, is it write to declare trait_mod as a methodß | 06:40 | |
s/ß/?/ | |||
jnthn | moritz: no | ||
moritz: I just found why the multi sub case isn't working though. | 06:41 | ||
JimmyZ uses rakudo with a bit violence | |||
how to user multi method trait_mod:<is> ? | |||
use | 06:42 | ||
jnthn | JimmyZ: You're not meant to write it as a method. | ||
JimmyZ: Traits are dispatched to as subs. | |||
JimmyZ | rakudo: class A { multi method trait_mod:<is>( :$rwr!) { }; } | ||
p6eval | rakudo cbdd9b: ( no output ) | ||
JimmyZ | rakudo allows me to write it as a method ;) | 06:43 | |
jnthn | So what? | ||
It's just a name. | |||
If you do class Foo { method m() { ... }; m() } | |||
Then it'll let you write m as a method too. | |||
But the dispatch will fail. | 06:44 | ||
It's not that you can't write a method called trait_mod:<is>. You can - we do it in Actions.pm. It's that trait dispatch is a sub dispatch, not a method one. | |||
moritz | if it were a method, in which class would it look for the trait method? | 06:46 | |
sorear | also, JimmyZ, trait subs should be declared at top level, not in a brace group | 06:47 | |
unless you want to limit the use of the trait to the group | |||
06:47
frhodes joined
06:50
uasi left
|
|||
TimToady | perl6: [{a => 1}, {a => 2}]»<a>.say | 06:52 | |
p6eval | pugs: OUTPUT«decodeUTF8': bad data: '\187'***  Unexpected "\187<" expecting term postfix or operator at /tmp/y0k53zSN_O line 1, column 21» | ||
..rakudo cbdd9b: OUTPUT«Method 'at_key' not found for invocant of class 'Int' in method postcircumfix:<{ }> at src/gen/CORE.setting:1002 in method reify at src/gen/CORE.setting:3690 in method reify at src/gen/CORE.setting:3595 in method reify at src/gen/CORE.setting:3595 in meth… | |||
..niecza v9-32-g380d891: OUTPUT«Unhandled exception: Cannot use hash access on an object of type Int at line 0 (ExitRunloop @ 0)  at /home/p6eval/niecza/lib/CORE.setting line 101 (CORE Any.at_key @ 8)  at line 0 (ExitRunloop @ 0)  at /tmp/8xEerIsAOB line 0 (MAIN C3_ANON @ 0)  … | |||
TimToady | b: [{a => 1}, {a => 2}]»<a>.say | ||
p6eval | b 1b7dd1: OUTPUT«12» | ||
TimToady | only old rakudo manages to do it right | ||
or is there some reason why hyper should be iterating the key and value of the pair separately? | 06:53 | ||
jnthn | TimToady: hypers descend into data structures. | 06:54 | |
TimToady: Here it desends into the inner hashes. | |||
TimToady: I thought that was what it was meant to do, fwiw. | |||
TimToady | it makes little sense to treat the keys the same as the values, since they're likely of different types | 06:55 | |
JimmyZ | if I want to define method trait_mod:<is>, how can I use it? | ||
TimToady | so I think it should not descend into the pairs of a hash | ||
jnthn | TimToady: I don't think it does | ||
JimmyZ dosesn't how Actions.pm uses it | |||
jnthn | TimToady: I think it's calling .<a> on 1 and 2 | 06:56 | |
The values of the hash. | |||
oops, meeting!! & | |||
06:58
uasi joined
|
|||
sorear | JimmyZ: if you want to define a method named trait_mod:<is>, you need to use it as an ordinary method. | 06:58 | |
rakudo: class A { method trait_mod:<is>() { say "hi" } }; A.new.trait_mod:<is>(); | |||
p6eval | rakudo cbdd9b: OUTPUT«hi» | ||
JimmyZ | oh | ||
thanks sorear | 07:00 | ||
07:03
JimmyZ left
07:04
JimmyZ joined
|
|||
TimToady | jnthn: nevermind, I was thinking about it wrong; what I really want is multidimensional subscripting someday... | 07:05 | |
07:06
mj41 joined
|
|||
dalek | ecza/serialize: 37d7895 | sorear++ | lib/ (2 files): Finish initial cases of running code |
07:12 | |
sorear | stefan@stefans:~/rel/niecza$ mono-sgen run/Niecza.exe -L NULL -e 'Q:CgOp { (prog (say (s "Hello world")) {0}) }' | ||
Hello world | |||
sorear sleep | |||
07:13
zby_home_ left
07:17
mberends joined
|
|||
mberends | 'night sorear | 07:18 | |
07:24
JimmyZ left
07:26
mishin_ joined
|
|||
woosley | Hi, #perl6. How is undef defined in Perl6? | 07:33 | |
Does Mu stand for undefined object in perl6? | |||
moritz | woosley: for every class there is a type object. The type object is undefined | 07:34 | |
so Int, Str and Mu are perfectly fine undefined objects | |||
Mu is the "most undefined" object in the sense that it defines the least behavior | 07:36 | ||
woosley | moritz: Can I get a Mu object, by "$x.WHAT.say" ? | ||
moritz | rakudo: my $x = Mu; $x.WHAT.say | 07:38 | |
p6eval | rakudo cbdd9b: OUTPUT«Mu()» | ||
woosley | rakudo: my $x = FO; $x.WHAT.say | 07:39 | |
p6eval | rakudo cbdd9b: OUTPUT«Could not find sub &FO in <anon> at /tmp/VvCCif3zXi:1 in <anon> at /tmp/VvCCif3zXi:1» | ||
woosley | moritz: what is the relationship between Cool, Any, Mu, it there any document about these object type? | 07:41 | |
moritz | S02 I think | 07:42 | |
rakudo: say Cool.^mro | 07:43 | ||
p6eval | rakudo cbdd9b: OUTPUT«Cool() Any() Mu()» | ||
08:02
y3llow left,
y3llow joined
08:17
cougnut joined
08:26
bakedb joined
08:27
y3llow left,
y3llow_ joined,
y3llow_ is now known as y3llow
08:30
dakkar joined,
am0c left
|
|||
jnthn back | 08:30 | ||
08:41
am0c joined
08:42
SHODAN joined
|
|||
moritz | welcome back. | 08:46 | |
tadzik | backtoo | 08:49 | |
mls_ | morning! | 08:51 | |
jnthn: CATCH/CONTROL still have to have their own $/ $! $_, right? | 08:53 | ||
moritz | I'm pretty sure that they have their own $_ at least | 08:54 | |
because that's aliased to $! | |||
mls_ | yes. It's more about the other two, cause jnthn++ patched the way they work yesterday | 08:55 | |
moritz | but we expect do { die 'foo'; CATCH { default { 1 } } }; say $! to access the $! | ||
(because it's the same as try { die 'foo' }; say $! # which we certainly want to continue working) | |||
mls_ | What about CONTROL? I don't think we want to leak $! $/ ? | 08:57 | |
moritz has no idea about CONTROL, because I don't know any use cases for it | |||
mls_ | warn() et al | ||
moritz | that's not exactly a "use case", just a keyword :-) | 08:58 | |
mls_ | I'm talking about the "resume exception" case. I don't think we should change $/ $! in that case. | ||
S04 talks about warnings throwing a control exception | 08:59 | ||
afk for half an hour... dayjob... | 09:00 | ||
09:04
mberends left
|
|||
jnthn | mls_: Well, the other thing is that we're discussing whether $! should be looked up lexically or dynamically. Which also has some bearing on this. | 09:08 | |
I don't have a good feeling for which way that one will go. | |||
It does fix the long-standing .subst closure issue. | |||
09:27
mishin_ left
09:28
daxim joined
09:39
replore_ left
09:51
bakedb left
10:08
bakedb joined
|
|||
mls_ | jnthn: I'd prefer lexical | 10:13 | |
could grep et al do something like local($CALLER::</>) ? | 10:14 | ||
moritz | that was my proposal as well :-) | ||
mls_ | (local being the perl5 local, I don't know if it's the same in perl6) | ||
moritz | called temp() in p6 | ||
erm, probably just temp, it's not a function | 10:15 | ||
10:16
cyfi joined
|
|||
mls_ | regarding setting $! in CATCH: S04's catch lambda contains an explicit set_outer_caller's_bang(@handled) call | 10:21 | |
moritz | ok, so that's not an argument for missing $! in CATCH blocks | 10:22 | |
mls_ | perl6: say do {die; CATCH {"hello"}}; | 10:25 | |
p6eval | rakudo cbdd9b: OUTPUT«Method 'gist' not found for invocant of class 'Exception' in sub say at src/gen/CORE.setting:4729 in <anon> at /tmp/znwlmr7cjz:1 in <anon> at /tmp/znwlmr7cjz:1» | ||
..niecza v9-32-g380d891: OUTPUT«Unhandled exception: Died at /home/p6eval/niecza/lib/CORE.setting line 742 (CORE die @ 2)  at /tmp/RL2zpdsmL6 line 1 (MAIN C1_ANON @ 1)  at /tmp/RL2zpdsmL6 line 1 (MAIN mainline @ 2)  at /home/p6eval/niecza/lib/CORE.setting line 2060 (CORE C968_ANON… | |||
..pugs: OUTPUT«*** Died at /tmp/hSTOj_AHu1 line 1, column 9-12» | |||
cougnut | hello moritz, could you assit me with ilbot? | 10:26 | |
10:26
am0c left
|
|||
moritz | cougnut: I can try, please /msg me | 10:26 | |
mls_ | afk -> lunch | 10:29 | |
10:37
lateau_ joined
10:44
mishin joined
11:00
lateau_ left
11:02
uasi left
|
|||
ingy | phenny: tell pmurias alias TOP to a rule called something else and start on that rule? Realize that I am writing language grammars where I almost always want to parse an entire text. requiring ^$ is not only annoying, it is going to cause problems when people forget it. | 11:03 | |
phenny | ingy: I'll pass that on when pmurias is around. | ||
bbkr | enum.t passing \o/, RT queue will decrease to 850 :) | 11:08 | |
11:23
uasi joined
11:26
nsh joined,
sbp joined
11:34
envi_|2 left
11:35
satyavvd left
11:36
Psyche^ joined
11:39
benabik joined,
Patterner left,
Psyche^ is now known as Patterner
11:48
envi_laptop joined
11:58
mtk left
12:03
mtk joined,
woosley left
|
|||
[Coke] yawns from $DAYJOB | 12:11 | ||
12:12
envi_|2 joined
|
|||
ingy | moritz: gist.github.com/1228947 as promised | 12:13 | |
moritz: basically want to think up operators for these use cases. also more use cases if you think of any. | 12:14 | ||
moritz thinks about it | 12:15 | ||
12:15
envi_laptop left
|
|||
[Coke] wonders why the grants queue is always filled with spam whenever he happens to look at it. | 12:16 | ||
12:19
bluescreen10 joined
12:20
cyfi left
|
|||
[Coke] | rakudo: sub incr1 (*@v is rw) { @v[0]++; @v[1]++; } | 12:21 | |
p6eval | rakudo cbdd9b: ( no output ) | ||
12:23
cougnut left
|
|||
moritz | rakudo: sub incr1 (*@v is rw) { @v[0]++; @v[1]++; }; incr1 my $x; say $x | 12:23 | |
p6eval | rakudo cbdd9b: OUTPUT«Any()» | ||
[Coke] | rakudo: $?:: # known? | 12:24 | |
p6eval | rakudo cbdd9b: OUTPUT«===SORRY!===Non-declarative sigil is missing its name at line 1, near "$?:: # kno"» | ||
moritz | std: $?:: | ||
p6eval | std bb4f150: OUTPUT«===SORRY!===Bogus statement at /tmp/UmSFYMvwJz line 1:------> <BOL>⏏$?::Parse failedFAILED 00:01 120m» | ||
moritz | ingy: somehow I dislike ?**?, but I'm not sure what a better operator for it would be | ||
usually the ? implies that it's ok to have fewer atoms in your string, here it means it's ok have more | 12:25 | ||
[Coke] | rakudo: class A { method foo {} }; say A.can("foo").WHAT | ||
p6eval | rakudo cbdd9b: OUTPUT«Parcel()» | ||
felher | [Coke]++ #35 Tickets. Wow! | ||
[Coke] | 35 tickets... worked on? | 12:26 | |
tadzik | remaining? :P | ||
felher Just checked his mails and thought: 35 Mails tagged with Perl6BugTracker... what the.. has to be spam. | 12:28 | ||
12:29
woosley joined
|
|||
jnthn | moritz: Not sure if "is rw" is really valid in slurpy...does the spec call it either way? | 12:29 | |
[Coke] | who manages rakudo.org, accounts and sthings? | ||
jnthn | [Coke]: pmichaud, I believe. | 12:30 | |
moritz | jnthn: I think the spec is silent on that | ||
aye | |||
jnthn | moritz: Feared so ;) | ||
I'll just hope TimToady++ swings by with a ruling ;) | |||
[Coke] | ... in your favor! | ||
jnthn | [Coke]: could go either way ;) | 12:31 | |
12:32
satyavvd joined,
rhr joined
12:33
wolverian joined
|
|||
moritz | fwiw I just deployed some small but untested changes to the IRC logs -- please notify me if you see something odd (erm, odder than usual :-) | 12:33 | |
12:36
cyfi joined
|
|||
felher just looks at S04-statements/for.t line 47-55 and wonders: where should the '4' in 'is $str, "(1 5)(2 4)(3 6)",' come from? | 12:37 | ||
12:38
cougnut joined
|
|||
moritz | that test looks wrong. | 12:38 | |
felher | *nods* | 12:39 | |
moritz | felher: do you want to fix it, or should I? | ||
felher | guess it should be 1..3 and 4..6, and (1 4), (2 5) and (3 6) | ||
moritz: i'll fix it | |||
Woodi | how i can check general type of param ? eg: sub( $k, $v) { if $v.is_numeriv {} else ... ? | 12:49 | |
12:49
cougnut left
|
|||
jnthn | if $v ~~ Numeric { ... } | 12:49 | |
tadzik | .WHAT | 12:50 | |
jnthn | Don't really need to resort to .WHAT | ||
tadzik | I think I do sotmehing like this in File::Find, hmm | ||
jnthn | Plus it won't give you the general type | ||
Woodi | yes, what gives to many posibilities | ||
tadzik | oh well, if it's about Numeric | ||
jnthn | All numeric types do Numeric. Anything string-like does Stringy. etc. | ||
Woodi: What does? | |||
moritz | .WHAT should not be used for type checking | 12:51 | |
Woodi | WHAT gives: Int, Rat, ... - so many for 'if' | ||
tadzik | github.com/tadzik/perl6-File-Tools...ind.pm#L16 | ||
moritz | Woodi: use if $thing ~~ Numeric { ... } instead | ||
jnthn | Woodi: Yes, that's why I suggested you use Numeric. | 12:52 | |
moritz | Woodi: that will catch them all | ||
tadzik | it's not really WHAT here | ||
jnthn | Doing .WHAT === ... is a very bad idea. | ||
Woodi | k, thank you | ||
jnthn | As you break polymorphism. | ||
moritz | tadzik: that's really just type checking with smart matching | ||
tadzik | yef | ||
moritz | (given/when does smart matching) | ||
tadzik | yep | ||
and no ifs :) | |||
12:54
cougnut joined
|
|||
dalek | ast: 3c9d437 | (Felix Herrmann)++ | S04-statements/for.t: [S04-statements/for.t] fix test: 'for zip(@a; @b) -> $x, $y' |
12:56 | |
12:58
benabik left,
uasi left
13:01
benabik joined
13:04
Holy_Cow joined
13:05
Holy_Cow left
13:11
jimmy1980 joined
|
|||
lucs | lslcom | 13:14 | |
ww, sorry | 13:15 | ||
13:16
uasi joined,
skangas__ left,
skangas joined
13:32
bluescreen10 left
13:46
robins joined
13:47
bluescreen10 joined,
robins is now known as robinsmidsrod
13:48
Juerd joined
|
|||
Juerd | Say, is anyone still using feather3 for anything? | 13:48 | |
Judging by the charts its filesystem has been full for quite a while; it's managed to exhaust its inodes, even! | 13:49 | ||
moritz | I think try.rakudo.org runs on feather3 | ||
erm, tried to run :-) | |||
Juerd: have you cleaned it up again? doesn't look full to me now | 13:50 | ||
Juerd | No; I'm just looking at munin charts | ||
jnthn | try.rakudo.org seems to basically work. | ||
Juerd | It's using 99% of available inodes and it's been topped out a few times | ||
moritz | ah, I was just looking at df -h | 13:51 | |
Juerd | I'll try to find where all those (temporary?) files are | ||
Try df -i | |||
moritz | /dev/vdb 655360 647369 7991 99% / | ||
wee | |||
Juerd | You'd think that 655360 ought to be enough... :D | ||
13:52
skangas left,
skangas joined
|
|||
moritz | no lsof installed :( | 13:52 | |
13:54
dakkar left
|
|||
Juerd | It is now :) | 13:54 | |
moritz | thanks | 13:55 | |
doesn't show me anything interesting though | |||
Woodi | rakudo: my $v = "Hallo World!"; $v ~~ s/(\s)/\\$1/; say $v; | ||
13:55
dakkar joined
|
|||
p6eval | rakudo cbdd9b: OUTPUT«Hallo\World!» | 13:55 | |
Woodi | how to get escaped whites ? | 13:56 | |
rakudo: my $v = "Hallo World!"; $v ~~ s/(\s)/\\$0/; say $v; | |||
p6eval | rakudo cbdd9b: OUTPUT«Hallo\World!» | ||
Woodi | perl6: my $v = "Hallo World!"; $v ~~ s/(\s)/\\$0/; say $v; | 13:57 | |
p6eval | niecza v9-32-g380d891: OUTPUT«Hallo\ World!» | ||
..rakudo cbdd9b: OUTPUT«Hallo\World!» | |||
..pugs: OUTPUT«Error eval perl5: "if (!$INC{'Pugs/Runtime/Match/HsBridge.pm'}) { unshift @INC, '/home/p6eval/.cabal/share/Pugs-6.2.13.16/blib6/pugs/perl5/lib'; eval q[require 'Pugs/Runtime/Match/HsBridge.pm'] or die $@;}'Pugs::Runtime::Match::HsBridge'"*** '<HANDLE>' trapped b… | |||
Woodi | wooo, niecza works | ||
perl6: my $v = "Hallo World!"; $v ~~ s/(\s)/\\$1/; say $v; | |||
p6eval | niecza v9-32-g380d891: OUTPUT«Use of uninitialized value in string context at /home/p6eval/niecza/lib/CORE.setting line 589 (CORE warn @ 2)  at /home/p6eval/niecza/lib/CORE.setting line 21 (CORE Mu.Str @ 12)  at line 0 (ExitRunloop @ 0)  at /home/p6eval/niecza/lib/CORE.setting … | ||
..rakudo cbdd9b: OUTPUT«Hallo\World!» | |||
..pugs: OUTPUT«Error eval perl5: "if (!$INC{'Pugs/Runtime/Match/HsBridge.pm'}) { unshift @INC, '/home/p6eval/.cabal/share/Pugs-6.2.13.16/blib6/pugs/perl5/lib'; eval q[require 'Pugs/Runtime/Match/HsBridge.pm'] or die $@;}'Pugs::Runtime::Match::HsBridge'"*** '<HANDLE>' trapped b… | |||
Juerd | feather3:/home/tene/.ccache# find | wc -l | 13:59 | |
354474 | |||
That is a bit much. | |||
Can anyone write a nice perl or find oneliner to delete old files, say, everything older than a month? | 14:00 | ||
14:00
soh_cah_toa joined
|
|||
Juerd | I'm rm -rf'ing ~tene/.ccache | 14:00 | |
Tene: ping | |||
benabik | find <DIR> -mtime +30 -delete # I suggest running it without -delete at least once to see what it'll delete | 14:02 | |
Juerd: ^^ | 14:03 | ||
Juerd | Thanks :) | ||
benabik | Juerd: Note: untested… | ||
(Which is why I recommend not using -delete at first. ;-) | 14:04 | ||
Juerd | That's okay; we'll find out if it works in a month or so | ||
The rm is still running :) | |||
benabik | Living on the edge. :-D | ||
Juerd | Inode usage has dropped to 95% | 14:05 | |
This isn't going very fast. | |||
benabik | Deleting 354k files takes a while... | ||
Juerd | Apparently :) | ||
14:07
uasi left,
uasi joined
|
|||
mls_ | jnthn: patch that makes Rakudo_cont_store throw an exception if the cont == PMCNULL: gist.github.com/1229149 | 14:07 | |
(guards against perl6_container_store misuse) | 14:08 | ||
jnthn | mls_: oh, good one. | 14:09 | |
mls_: Will apply later today | |||
Juerd | rm: cannot remove `.ccache/3': Directory not empty | ||
But... but... but... that's why I did -r | |||
moritz | Juerd: maybe permission defined for one file? | 14:10 | |
Juerd | moritz: I'm root | ||
moritz | Juerd: or a new file has been created while the others have been deleted? | ||
Juerd | I'm guessing that something is compiling while I'm deleting stuff. The compile will probably fail. | ||
benabik | Juerd: Probably not? ccache is pretty conservative. | 14:11 | |
moritz | htop doesn't show any compilation running | ||
.oO( not anymore ) |
|||
Juerd | moritz: That's exactly what I thought too :) | ||
mls_ | jnthn: store_lex_skip_current doesn not exist, right? | ||
Juerd | 88% and still dropping | 14:12 | |
\o/ | |||
mls_ | (btw, find_lex_skip_current doesn't seem to get used anymore) | ||
Juerd | By the way, it has had this many files for at least half a year. | ||
It's a miracle that it kept working. | |||
PerlJam | Juerd: is this just feather3 you're talking about? | 14:13 | |
Juerd | Yes. | ||
[Coke] | Juerd++ | ||
jnthn | mls_: Maybe not. | 14:14 | |
mls_: Do you need it for something? | |||
If so, can always add it... :) | |||
mls_: Note that we assign $! in Rakudo now, not bind. | |||
mls_: So if it's for that, you should use find and the assign. | |||
(totally taking a wild guess at what you might be working on :)) | 14:15 | ||
mls_ | not sure. seems I have to set $! of the outer ctx in the exception handler somehow | ||
jnthn | Yeah, you'd do find, and then assign to it. | ||
store_lex_skip_current would bind, not assign. | |||
(if it existed) | |||
mls_ | true, we want assign nowadays ;) | 14:16 | |
jnthn | Well, it was only last night that I went through and tried to get us to be consistent on that. :) | ||
14:17
woosley left
|
|||
mls_ | (that's why I tried to use perl6_container_store) | 14:17 | |
(which segfaulted because the find_lex returned PMCNULL) | |||
(cause I also have a ".lex "$!") | 14:18 | ||
(and it doesn't matter that the .lex comes after the find_lex) | |||
jnthn | .lex is declarative, not imperative. So yes, order won't help you. :) | 14:19 | |
mls_ | Yeah, I saw that when I checked the imcc sources... | 14:20 | |
14:21
donri joined
|
|||
mls_ | So I use find_lex_skip_current to get the $! container of the outer? | 14:23 | |
14:23
jimmy1980 left
|
|||
jnthn | Should work, yes. | 14:24 | |
mls_ | ok, thanks! | ||
14:25
wtw left
14:28
thou joined,
kaleem left
14:34
wamba joined
14:37
localhost left
|
|||
moritz | now down to 285K used inodes on feather3 | 14:39 | |
that's still more than on the root partition of my laptop | |||
but not excessive | 14:40 | ||
Juerd | A few code repositories fills it up easily. | ||
That was my first guess. Fortunately I was wrong. | |||
moritz | du -sch /home/*/.cpan/build | ||
127M | 14:41 | ||
Juerd | That's not quite as many files as full git repositories with history. | ||
14:41
kaare_ joined
|
|||
moritz | right | 14:41 | |
Juerd | I wonder which filesystems they use at github | 14:42 | |
moritz | didn't some people invent file systems for nntp servers that were optimized for many small files? | 14:43 | |
mux | I think you're thinking of ifs which has long since been removed from base; and it wasn't really optimized for small files but for applications who don't actually need a namespace | 14:45 | |
that is, applications using ifs needed to be explicitely modified to open files by their inode number instead | 14:46 | ||
14:47
soh_cah_toa left
|
|||
mux | oh damn, wrong channel, what I just said was actually FreeBSD-specific | 14:47 | |
I fail at IRC. | |||
14:48
abercrombie joined
|
|||
TimToady | well, it's freenode at least :) | 14:50 | |
sorear | good * #perl6 | ||
hi mux! | |||
14:52
espadrine joined
|
|||
TimToady | mls_: I'm trying hard to get rid of $! inside of CATCH, since $! should only mean "the exception that was just handled", and the ones in flight inside CATCH are not handled | 14:54 | |
mux | sorear: hi there :) | ||
14:54
lateau_ joined
|
|||
TimToady | and we already have $_ bound to the current in-flight exception (in a loop) | 14:54 | |
I think use of temp to modify a caller's variable is very smelly. | 14:56 | ||
moritz | agreed | ||
TimToady | and we've already mentioned that control functions need to be transparent to $/ and $! as dynvars | 15:00 | |
15:04
im2ee joined
|
|||
im2ee | Hello :) | 15:04 | |
mikemol | Hi | 15:06 | |
15:08
birdwindupbird left
|
|||
moritz | #phasers in 2h20min, right? | 15:10 | |
sorear | more like 26h20min, no? | 15:11 | |
moritz | oh right, Wed, not Tue :-) | 15:12 | |
glad I asked | |||
mls_ | Hi TimToady! | 15:22 | |
TimToady: what are your thoughts on the return value of blocks that caught an exceptions? | 15:24 | ||
dalek | ecs: 58a9ca5 | larry++ | S05-regex.pod: get hybrid ** out of my head and into spec |
||
mls_ | perl6: say do {die; CATCH {"hello"}}; | ||
p6eval | rakudo cbdd9b: OUTPUT«Method 'gist' not found for invocant of class 'Exception' in sub say at src/gen/CORE.setting:4729 in <anon> at /tmp/dLQUlyFNma:1 in <anon> at /tmp/dLQUlyFNma:1» | ||
..pugs: OUTPUT«*** Died at /tmp/Qn9K0lODHD line 1, column 9-12» | |||
..niecza v9-32-g380d891: OUTPUT«Unhandled exception: Died at /home/p6eval/niecza/lib/CORE.setting line 742 (CORE die @ 2)  at /tmp/1ms6CMP83Y line 1 (MAIN C1_ANON @ 1)  at /tmp/1ms6CMP83Y line 1 (MAIN mainline @ 2)  at /home/p6eval/niecza/lib/CORE.setting line 2060 (CORE C968_ANON… | |||
mls_ | should that say hello? | ||
moritz | since the exception is not handled, it should rethrow as niecza does | 15:25 | |
TimToady | I don't think so, offhand | ||
moritz | more interesting: | ||
perl6: say do {die; CATCH { default { "hello" }}}; | |||
p6eval | niecza v9-32-g380d891: OUTPUT«Nil» | ||
..pugs: OUTPUT«*** Died at /tmp/itEC3UwkJm line 1, column 9-12» | |||
..rakudo cbdd9b: OUTPUT«Method 'gist' not found for invocant of class 'Exception' in sub say at src/gen/CORE.setting:4729 in <anon> at /tmp/E18saprxiD:1 in <anon> at /tmp/E18saprxiD:1» | |||
mls_ | moritz: assume that is handled. I'm wondering if there's a nice way for the handler to set the block return value | 15:26 | |
thus an easy way to return an "error" result | |||
TimToady | CATCH is never implicitly going to set the return value, though we might allow explicit return | 15:27 | |
15:27
jaldhar left
|
|||
mls_ | well, return leaves the Routing. We might need OUTER::leave or something | 15:28 | |
TimToady | that is, not implicitly set to the return value of the handler. we should implicitly set it to something undefined, as in p5, I think | ||
dalek | ecs: e639b7d | moritz++ | S05-regex.pod: [S05] fix typo |
||
moritz | TimToady: did you see the suggestion to use ~** for the <a> ** <delimiter> form, and +** for the <a> ** 1..* form? | 15:29 | |
moritz liked that, and it's orthogonal to the last S05 patch | |||
TimToady | it seems a bit crufty | 15:30 | |
15:31
envi_|2 left
|
|||
moritz | less crufty than using the same operator for two different functions | 15:31 | |
15:31
envi_laptop joined
|
|||
TimToady | there's an underlying sense in which it is the same operator with a different test | 15:31 | |
moritz | still the problem remains that a mis-typed range on the is usually valid syntax for a separator, resulting in LTA misbehavior | 15:32 | |
TimToady | trew | 15:34 | |
making it a separate operator still doesn't help with the fact that we have two independent criteria for the same repetition | 15:37 | ||
I've also been playing with ways of combining the two right args | |||
<a> ** [0..* ','] or something | 15:38 | ||
but don't really like that one enough | |||
moritz | well, <a> +** 0..* ~** ',' would help, but it's not pretty at all | 15:39 | |
mux | arg, my eyes | ||
TimToady | as for the typo problem, restricting the syntax of the sep form would help | ||
for instance, if we required brackets: | 15:40 | ||
<a> ** [','] | |||
or something that a person would never use near 0..* | |||
'course, you still have the problem that a malformed 0..* can be taken for normal match material | |||
moritz | requiring brackets would work, yes | 15:41 | |
TimToady | std: / <a> ** 0.. foo / | ||
p6eval | std bb4f150: OUTPUT«===SORRY!===Malformed range at /tmp/rZ7j34PsYE line 1:------> / <a> ** 0..⏏ foo / expecting quantifierParse failedFAILED 00:01 121m» | ||
TimToady | std actually catches some of 'em | ||
I wish the other regex folx hadn't stolen ++ for possesive + | 15:43 | ||
15:43
jaldhar joined
|
|||
TimToady | ah well, can't be undone | 15:44 | |
still need to come up with a way to combine them though | 15:49 | ||
<a> ** {0..*}[','] or something like that | |||
flussence | the first idea that comes to mind for me is [',' xx 0..*]. Is xx already taken in regex? | 15:51 | |
TimToady | well, they'd be taken literally by default | 15:52 | |
but we can claim keywords if we need to | 15:53 | ||
however, your form looks like it's replicating the comma | |||
flussence | I was thinking along the lines of having it look like "$regex ** $list-of-separators"... | 15:54 | |
TimToady | well, but 0 commas still means 1 of the lhs | ||
flussence | oh, good point. | 15:55 | |
TimToady | and I think that varying separators is rare enough that we can dehuffmanize it | ||
and just make people write it out long | 15:56 | ||
15:57
dukeleto left
15:58
dukeleto joined
|
|||
TimToady | there are also approaches where we make the separator a modifier on any quantifier | 15:58 | |
then you could write <a>* via ',' or some such | |||
and for the current <a> ** ',' we'd either force people to write <a>+ via ',' or assume the + | 16:00 | ||
PerlJam | It took me a while to get used to (and even come to like) A ** B, and now you're gonna change it?!? | 16:02 | |
:-) | |||
TimToady | I'd be inclined to require the + in order to reduce accidental recognition of whatever keyword we use | ||
PerlJam | <a>+:sep(',') ? | 16:04 | |
TimToady | it's not a string, it's a regex | ||
PerlJam | sure ... <a>+:sep(<foo>) | ||
TimToady | that form is a normal P6 expression inside () | ||
I wouldn't steal a normal adverbial for that | 16:05 | ||
PerlJam | okay, let's just say the "via" in "<a>+ via ','" doesn't quite work for me :) | ||
just that it's wordy, not the word itself | |||
though, looking at the scroll back, some form that combines range and separator would be nice. | 16:06 | ||
16:07
MayDaniel joined
|
|||
TimToady | prejudiced against romance languages, eh? :P | 16:07 | |
wordy is good when the things around it are symbolic | |||
16:08
mkramer1 joined
|
|||
PerlJam | Except that I have this nice rule in my head that says wordy things are literal in a regex and I kind of like it that way | 16:09 | |
TimToady | and we have, in fact, already reserved all the punctuation | ||
we need something that doesn't look like either side | 16:10 | ||
16:10
satyavvd left
|
|||
TimToady | <a>+ % ',' # modulo! | 16:11 | |
PerlJam notes that #perl6 once again has me staring at my keyboard | 16:12 | ||
slavik1 | TimToady: I think I realized the trouble you have with designing a language ... | 16:13 | |
TimToady | std: / <a> % <b> | ||
p6eval | std bb4f150: OUTPUT«===SORRY!===Unrecognized regex metacharacter % (must be quoted to match literally) at /tmp/DT0IXDt_L3 line 1:------> / <a> %⏏ <b>Unable to parse regex; couldn't find final '/' at /tmp/DT0IXDt_L3 line 1:------> / <a> %[33… | ||
TimToady | std: / <a> % <b> / | ||
p6eval | std bb4f150: OUTPUT«===SORRY!===Unrecognized regex metacharacter % (must be quoted to match literally) at /tmp/idkFhHLC3z line 1:------> / <a> %⏏ <b> /Unable to parse regex; couldn't find final '/' at /tmp/idkFhHLC3z line 1:------> / <a> %[… | ||
TimToady | I think I like it | ||
slavik1 | we don't have enough symbols ... | ||
PerlJam | I like it, but I worry a bit about that + | ||
slavik1 | on the keyboard | ||
TimToady | which way do you worry about it? | 16:14 | |
requiring it, or not requiring it? | |||
PerlJam | Basically just differentiating between aaa,aaaa,aaa and a,a,a,a,a | ||
TimToady | there's always [<a>*] % ',' | 16:15 | |
moritz | % is cute | 16:16 | |
TimToady | and has two parts, like key/value | ||
16:17
uasi left
|
|||
TimToady | and means "constrained by" in colloquial usage of "modulo" | 16:17 | |
in fact, I expect people would pronounce it that way in their heads | |||
arnsholt | I agree with moritz. Definitely cute. The modulo mnemonic complements it nicely | 16:18 | |
PerlJam | and so we'd have / [<a> % ','] ** 3..5 / for combinations | ||
(for instance) | 16:19 | ||
moritz | TimToady: so we keep ** $range? | ||
TimToady | that would be the idea | ||
moritz | +1 | ||
TimToady | PerlJam: no, inside out from that | ||
so % could modify any quantifier | 16:20 | ||
including ** | |||
PerlJam | Aye, I realized the difficulty as soon as I'd hit enter :) | ||
TimToady | <a> ** 3..5 % ',' | ||
PerlJam | so yes ... % is really nice TimToady++ | ||
TimToady | the only remaining question is whether to require a quantifier | 16:21 | |
PerlJam | I vote no | ||
TimToady | well, and where to allow whitespace, and what whitespace means | ||
<a> +% ',' ain't so bad | 16:22 | ||
though looks like a numeric prefix | |||
<a>+ % ',' is probably better from that perspective | 16:23 | ||
16:23
JimmyZ joined
|
|||
TimToady | with ws dependency before and after %, we need to worry just a bit about accidental hashes, as in <a>%foo | 16:24 | |
16:25
bluescreen10 left
|
|||
PerlJam | TimToady: Where would the ? mod go in either rendition? / <a> +%? ',' / or / <a>+? % ',' / | 16:25 | |
16:25
tokuhiro_ joined,
JimmyZ_ joined
|
|||
PerlJam | (or disallowed?) | 16:26 | |
16:26
mj41 left
16:28
JimmyZ left,
JimmyZ_ is now known as JimmyZ
|
|||
TimToady | the latter | 16:28 | |
er, the second | 16:29 | ||
+? % | |||
because of the possibility of a hash, I think we have to require the real quantifier | |||
it's not like people will write the form all that often that we need to huffmanize it down to nothing | 16:30 | ||
and <a>+ indicates we expect some number of them even before we read the % | |||
mls_ | jnthn: your steal_outer hack in perl6lexpad.pmc doesn't seem to work if the outer block doesn't know the lexical | 16:31 | |
TimToady | and we can give a decent error message: "% doesn't modify a quantifier" | ||
jnthn | mls_: It's not really a hack... | ||
mls_: Also, it's only meant to be for $_ these days. | |||
(Since $! and $/ are per routine now.) | 16:32 | ||
mls_ | Ok, so you need to remove thr $! $/ part | ||
jnthn | Makes sense...got a test case? | ||
16:32
cosimo joined
|
|||
jnthn | It'd have been nice if the spectests had reminded me of this ;) | 16:32 | |
PerlJam | TimToady: I don't know ... I think most of my uses of ** are really of the % variety rather than ranges. | 16:33 | |
oh, never mind. My brain is a tad slow right now. | 16:34 | ||
TimToady: in any case, it doesn't chunk right in my head. / <a>+ % ',' / still "looks funny" | 16:35 | ||
TimToady: but that's why you're the languages designer ... :-) | 16:36 | ||
16:36
Chillance joined,
bluescreen10 joined
16:42
tokuhiro_ left
|
|||
im2ee | Can i iterate through 001, 002, 003 and so on using only maths? You know.. something like 001+1 = 002 | 16:44 | |
:) | |||
say 001+1 returns 2. | 16:45 | ||
I want 002. :) | |||
Tene | Juerd: I haven't logged into feather3 in years, iirc, and I've never configured ccache | ||
wolverian | rakudo: "002"+1 | ||
p6eval | rakudo cbdd9b: ( no output ) | ||
mls_ | jnthn: I can't find a simple testcase. I need an uninitialized .lex $/ ... | 16:46 | |
JimmyZ | rakudo: say "001" ... "005" | ||
p6eval | rakudo cbdd9b: OUTPUT«001 002 003 004 005» | ||
Juerd | Tene: Interesting :) | ||
wolverian | I always forget saying it. thanks, JimmyZ. | ||
bbkr | rakudo: say "01" .. "there is a cake in last test chamber" | 16:47 | |
p6eval | rakudo cbdd9b: OUTPUT«"01".."there is a cake in last test chamber"» | ||
JimmyZ | rakudo: say "001.jpg" ... "005.jpg" | ||
p6eval | rakudo cbdd9b: OUTPUT«001.jpg 002.jpg 003.jpg 004.jpg 005.jpg» | ||
Tene | Juerd: at least, I don't remember doing so. It's a bit long ago for me to be certain. You could check my .bash-history. | 16:49 | |
im2ee | Thanks, i will try it. :) | ||
PerlJam | im2ee: you can also just use ++ | ||
16:49
JimmyZ left
|
|||
[Coke] | if you want numbers that are formatted as strings instead of strings that are incremented like numbers, you could do that too. | 16:50 | |
PerlJam | rakudo: my $str = "001"; for 0..5 { say $str++ } | ||
p6eval | rakudo cbdd9b: OUTPUT«001002003004005006» | ||
im2ee | PerlJam, ++ on this channel (for karma) or in perl (for my program)? :) | 16:51 | |
16:53
Chillance left
16:54
espadrine left
16:55
MayDaniel left,
espadrine joined
|
|||
jnthn | mls_: Ah, that's not likely to happen... | 16:58 | |
mls_: But anyway, removing it...it's just cruft now. | |||
16:59
saaki left
|
|||
dalek | kudo/nom: 7552eb9 | jnthn++ | src/pmc/perl6lexpad.pmc: Remove now unrequired calls to steal_outer (mls++). |
17:00 | |
17:03
Chillance joined
17:10
saaki joined
17:11
mberends joined,
mj41 joined
17:16
zby_home_ joined
17:20
sayu joined,
thou left
|
|||
dalek | ecs: a455b11 | larry++ | S05-regex.pod: old <a>**',' is now written <a>+%',' The separator syntax is now required to be a modifier on a quantifier, so the old <a> ** ',' is now written <a>+ % ','. This allows for other quantifiers like * or ** on the left as the basis of the constraint, while disambiguating use of ** to only work as a quantifier without overloading separator matching. The C<%> because it can be pronounced 'modulo' and because it looks like the relationship of two things. And also because it's unlikely to be confused with other regex forms. |
17:23 | |
17:23
espadrine left
|
|||
mls_ | jnthn: current state of exception handler change: gist.github.com/1229726 | 17:24 | |
flussence | % looks vaguely pythonish :) | ||
im2ee | karma larry | ||
aloha | larry has karma of 134. | ||
mls_ | jnthn: gets rid of the extra block, assigns to OUTER::$! | 17:25 | |
I'll do some testing tomorrow | |||
(some more testing, first tests look good) | |||
jnthn | TimToady: Should CATCH blocks declare a $? ? | 17:26 | |
er | |||
a $/ | |||
? | |||
mls_ | (I hope it's ok to modify $handler<past_block>...) | ||
jnthn | $handler<past_block>.unshift($handler_start); | ||
Probably should be | |||
$handler<past_block>[1].unshift($handler_start); | |||
So you change the imperative bit, not the declaritive bit | 17:27 | ||
TimToady | jnthn: probably, since when clauses may be doing pattern matching | ||
jnthn | OK, then mls++ :) | ||
+ PAST::Var.new( :scope('lexical_6model'), :name('$_'), :isdecl(1) ), | |||
PAST::Op.new( :pasttype('bind_6model'), | |||
PAST::Var.new( :scope('lexical_6model'), :name('$_') ), | |||
mls_: ^^ here, why the separate :isdecl? Why not just put :isdecl on the one inside the bind? | 17:28 | ||
dalek | kudo/nom: 7fdc6b4 | jnthn++ | src/binder/container.c: Apply patch from mls++ to harden container storage. |
||
TimToady | should probably declare a $! too, just to keep it empty, and force people to say OUTER::<$!> if they mean it | ||
jnthn | OK | ||
TimToady | but the SIMPLECATCH doesn't set $! | ||
mls_ | isdecl: I just copied that from the old code | 17:29 | |
TimToady | it's not like CATCH has to be all that efficient, if expections are really exceptional | ||
jnthn | mls_: In the case of what TimToady just said, the binding to $! should probably be removed. | ||
s/case/light/ | |||
mls_ | ok, removing... | ||
jnthn | mls_: Ah, OK...feel free to clear up too :) | ||
mls_: Feels like the right direction. | 17:30 | ||
TimToady | CONTROL, on the other hand, should probably be transparent | ||
17:30
Sarten-X left
|
|||
TimToady | and as lightweight as possible | 17:30 | |
since control exceptions are not unusual | 17:31 | ||
17:31
espadrine joined
|
|||
jnthn | *nod8 | 17:31 | |
mls_ | so CONTROL should not mess with the outers $!? | 17:32 | |
$! ? | |||
TimToady | outer shouldn't have a $! either | ||
mls_ | Ok, the Routine's $! | 17:33 | |
17:33
thou joined
|
|||
TimToady | statement_control:<while> should not be declared such that it defines a $! or $/ | 17:33 | |
it should be transparent to the dynvar | |||
if we're going to set the user's $! or $/ dynamically | 17:34 | ||
which it looks like we need to do | |||
17:34
benabik left
|
|||
TimToady | (note that dynvars are still lexically scoped; it's just the lookup that is dynamic) | 17:34 | |
dynvars are temp done right | 17:35 | ||
felher | TimToady++ for '**' in regex. /me searched for that 1 1/2 months ago. :) | ||
TimToady | we could just say that any routine that defines a CONTROL block doesn't get $/ or $! by default | 17:36 | |
17:36
Sarten-X joined
17:37
benabik joined
17:42
dakkar left
|
|||
mls_ | new version of patch: gist.github.com/1229760 | 17:43 | |
17:43
espadrine left
17:45
Chillance left
|
|||
mls_ | afk -> home... | 17:45 | |
jnthn | mls_: Thanks | 17:46 | |
17:50
mishin left
17:52
bakedb left
|
|||
tadzik | perl6lexpad.c: In function ‘Parrot_Perl6LexPad_get_number_keyed_str’: | 17:52 | |
perl6lexpad.c:211:5: warning: passing argument 2 of ‘register_number_for_get’ discards ‘const’ qualifier from pointer target type [enabled by default] | |||
perl6lexpad.c:69:15: note: expected ‘struct Hash *’ but argument is of type ‘const struct Hash *’ | |||
I got plenty of those with the newest patches | |||
flussence | hm | 17:55 | |
those showed up between 2011-09-15 and 2011-09-16 according to my cron output | 17:56 | ||
17:56
Chillance joined
18:00
envi_laptop left
18:06
daniel-s left
18:07
araujo left
|
|||
Woodi | perl6 async { say "my tid is ", +self; }; | 18:07 | |
perl6: async { say "my tid is ", +self; }; | 18:08 | ||
p6eval | rakudo 7fdc6b: OUTPUT«===SORRY!===Symbol 'self' not predeclared in <anonymous> (/tmp/pca6xM4Cyz:1)» | ||
..niecza v9-32-g380d891: OUTPUT«===SORRY!==='self' used where no object is available at /tmp/Xv1BMaOA_H line 1:------> async { say "my tid is ", +self⏏; };Action method statement_prefix:async not yet implemented at /tmp/Xv1BMaOA_H line 1:------> … | |||
..pugs: ( no output ) | |||
18:08
sayu left
|
|||
benabik | tadzik: Do you compile parrot with g++ or gcc? | 18:08 | |
Woodi | perl6: async { say "my tid is ", ~ '1213'; }; | ||
p6eval | rakudo 7fdc6b: OUTPUT«Could not find sub &async in <anon> at /tmp/bOS42Lcful:1 in <anon> at /tmp/bOS42Lcful:1» | ||
..niecza v9-32-g380d891: OUTPUT«===SORRY!===Action method statement_prefix:async not yet implemented at /tmp/NLgVB6SjkH line 1:------> async { say "my tid is ", ~ '1213'; }⏏;Unhandled exception: Unable to resolve method statement_level in class St… | |||
..pugs: OUTPUT«my tid is 1213» | |||
tadzik | benabik: gcc | 18:09 | |
dalek | kudo/nom: 79344e0 | jnthn++ | src/pmc/perl6lexpad.pmc: Try to eliminate a bunch of C compiler warnings tadzik++ is seeing. |
18:10 | |
jnthn | tadzik: Lemme know if ^^ helps. | ||
Woodi | pugs: my $thr = async { say "my tid is ", ~ '1213'; }; $thr.started; | ||
p6eval | pugs: OUTPUT«my tid is 1213*** No such method in class Thread: "&started" at /tmp/e_rxPalyOf line 1, column 50-62» | ||
tadzik | jnthn: will see | ||
18:11
benabik left
|
|||
jnthn | some of the consting was bogus, we were gonna modify the hash... :) | 18:11 | |
tadzik | oh you :) | 18:13 | |
PerlJam | TimToady: I'm still trying to puzzle out the edges of the new % .... A non-sigspace repitition separated by comma would look like this? <a>**2..*%',' Doesn't "*%" run afoul of LTM? Seems like a space between quantifier and % should be mandatory and not contribute to sigspace | 18:16 | |
tadzik | jnthn: yeah, that removed the warning from perl6lexpad | 18:20 | |
18:22
localhost joined
|
|||
jnthn | tadzik: nice :) | 18:24 | |
18:26
frhodes left
18:27
espadrine joined
18:33
espadrine left,
espadrine joined
|
|||
TimToady | PerlJam: there is no *% token available at that point, so I don't know what would try to match it | 18:39 | |
the next thing must be * or a number | |||
and that's a Whatever star, not a quantifier star | 18:40 | ||
so it happilly parses **2..* as a quantifier, then %',' as a quant modifier | |||
well, it's not a quant modifier in the sense that ? or ! is, since you can have <a>+? % ',' | 18:42 | ||
I guess a quant mod in the sense of being a quant modulus :) | 18:43 | ||
PerlJam | :-) | ||
TimToady++ good call on using % :) | 18:47 | ||
18:54
daxim left
18:57
odoacre left
19:01
lateau_ left
19:03
MayDaniel joined
19:05
worr joined
19:09
odoacre joined,
[Coke] left
19:11
[Coke] joined
19:12
espadrine left
|
|||
dalek | kudo/nom: 091c262 | jnthn++ | src/ (2 files): Fix issue with dynamic compilation of multis belonging to a derived dispatcher. Fixes issues with declaring custom traits and using them in the same compilation unit. |
19:15 | |
19:15
frhodes joined
19:21
birdwindupbird joined,
birdwindupbird left
|
|||
dalek | d: c22b2ee | larry++ | STD.pm6: first step to +% transition, deprecate ** sep and also take a whack at parsing the +% form |
19:25 | |
19:29
bbkr1 joined
19:34
espadrine joined
19:41
MayDaniel left
19:44
jaldhar left
19:45
benabik joined
19:50
jaldhar joined
19:56
thou left
20:08
SHODAN left
20:11
araujo joined
|
|||
cognominal | when I do a break from C to Perl, that does not last. But when I do a last in C, everything breaks. :( | 20:25 | |
20:30
soh_cah_toa joined
|
|||
mberends | cognominal: that is almost true in a philosophical sense as well # double entendre curieux :) | 20:32 | |
jnthn | :) | 20:34 | |
Woodi | there is trink in perl5 to generate accessors with closure: for my $field (qw(name first second)) { my $slot = __PACKAGE__."::$field"; ... how to do something like this in v6 ? | 20:42 | |
*trick | |||
PerlJam | Woodi: you're asking how to dynamically create methods? | 20:43 | |
Woodi | yes i think | ||
with nearly same code, different name | 20:44 | ||
PerlJam | Woodi: you use the mop to add methods to a class/object | ||
Woodi | it is documentet somewhere ? | 20:46 | |
bbkr1 | Woodi: you may check github.com/bbkr/jsonrpc/blob/maste.../Client.pm - I install there RPC methods in runtime by composing roles into class | 20:47 | |
Woodi | k | 20:48 | |
PerlJam | Woodi: I don't know if it's documented ... try github.com/jnthn/6model maybe | ||
jnthn | The introspecty bits of the MOP are in S12, but the declarative bits arne't. | 20:49 | |
*aren't | |||
PerlJam | perhaps there needs to be a S12.5 - the MOP :) | 20:50 | |
jnthn | rakudo: class Foo { }; for <bar baz waz> -> $name { Foo.^add_method($name, method () { "method for $name" }); }; Foo.baz | 20:51 | |
p6eval | rakudo 091c26: ( no output ) | ||
jnthn | rakudo: class Foo { }; for <bar baz waz> -> $name { Foo.^add_method($name, method () { "method for $name" }); }; say Foo.baz | ||
p6eval | rakudo 091c26: OUTPUT«method for baz» | ||
jnthn | Woodi: ^^ | ||
Though, that adds them at runtime | 20:52 | ||
Woodi is reading && parsing | |||
jnthn | rakudo: class Foo { BEGIN { for <bar baz waz> -> $name { Foo.^add_method($name, method () { "method for $name" }); } }; say Foo.baz | ||
p6eval | rakudo 091c26: OUTPUT«===SORRY!===Method 'dispatch:<.^>' not found for invocant of class 'Foo'» | ||
jnthn | oh, yes :) | ||
rakudo: class Foo { BEGIN { for <bar baz waz> -> $name { Foo.HOW.add_method(Foo, $name, method () { "method for $name" }); } }; say Foo.baz | |||
p6eval | rakudo 091c26: OUTPUT«===SORRY!===Unable to parse blockoid, couldn't find final '}' at line 1» | ||
jnthn tries to spot his syntax error... | 20:53 | ||
rakudo: class Foo { BEGIN { for <bar baz waz> -> $name { Foo.HOW.add_method(Foo, $name, method () { "method for $name" }); } } }; say Foo.baz | |||
p6eval | rakudo 091c26: OUTPUT«method for baz» | ||
jnthn | That adds them at BEGIN time. | 20:54 | |
Which basically gives the same effect as if the compiler added them. | |||
(So, they're available to participate in role compositon conflict resolution, etc.) | |||
PerlJam | jnthn: when does "dispatch:<.^>" get installed? | ||
jnthn | PerlJam: It's inherited from Mu. | ||
PerlJam: But we don't set a default parent until composition time. | 20:55 | ||
PerlJam | gotcha | ||
Woodi | thanx jnthn++ bbkr1++ PerlJam++ :) | ||
jnthn | PerlJam: We could maybe cheat on it a bit. But there's a chance we should be doing .^ by a syntactic re-write anyway. :) | 20:56 | |
PerlJam | Woodi: why are you creating methods dynamically btw? | ||
bbkr1 bets on "database ORM" answer :) | 20:57 | ||
Woodi | PerlJam: to save place in file in some typing. just do not want to have same methods with different names | ||
PerlJam | Woodi: so ... you're just making aliases? | 20:58 | |
Woodi | bbkr1: s/ORM// :) | ||
PerlJam: i didn't write it yet, so don't know exactly. "alias" sugests identical behaviour | 21:00 | ||
21:00
kaare_ left
|
|||
PerlJam | Woodi: not necessarily. | 21:00 | |
Woodi | do alias means something specyfic in perl6 ? | ||
bbkr1 | Woodi: If you're making aliases just install the same method (it's an object) under many names. my $m = method () {}; Foo.^add_method('name1', $m); Foo.^add_method('name2', $m); | 21:01 | |
PerlJam | Woodi: you could parameterize a method appropriately then create aliases to curried versions of that method | ||
Woodi | my maind isn't curied yet... what is difference to jnthn++ add_method ? | 21:02 | |
arnsholt | Or you could write multis, or use keyword arguments/default values in general | ||
Reassuringly, there's more than one way to do it =) | |||
21:03
zby_home_ left
|
|||
Woodi | i want something like in v5 trick :) | 21:03 | |
PerlJam | It's all TimToady's fault | ||
mberends | (there's only one way to blame it) | 21:04 | |
PerlJam | Woodi: Perl 6 has things like the Perl 5 trick, but better/safer. But the exact nature of those things really depends on what you're trying to achieve. | 21:05 | |
bbkr1 | off topic - do we have any P6 GTK libs under development? | ||
PerlJam | bbkr1: are you volunteering? :) | 21:06 | |
mberends | bbkr1: yes, over here, with Niecza! | ||
im2ee | Good night! | ||
21:06
im2ee left
|
|||
PerlJam | mberends: Shh! I wanted him to replicate it with Rakudo | 21:06 | |
:) | |||
mberends | oops | 21:07 | |
jnthn | Probably need to fix nativecall first... | ||
bbkr1 | PerlJam: no, i plan to spent time on improving Mongo driver after NOM release. | ||
mberends: do you need any GTK dev packages installed? ssh X forwarding is already enabled so you can test them on MacOS | 21:08 | ||
21:08
japhb left
|
|||
PerlJam | what's a nom-based R* release waiting on exactly? pmichaud regex fixes? something else? | 21:09 | |
21:09
japhb joined
|
|||
jnthn | PerlJam: Largely regexes and grammars. | 21:11 | |
There's other bits in nommap, but we're gradually picking away at them. | |||
PerlJam | Is there any LHF wrt grammars and regex on nom? | 21:13 | |
bbkr1 | I miss pack/unpack and Str.encode/decode most. That's huge regression for all streaming and serialization usage. | ||
21:15
wamba left
21:19
masak joined
|
|||
masak | hi sweet #perl6 | 21:19 | |
just wanted to stop by and wave before I go to sleep :) | 21:20 | ||
mberends | masak: \o/ | ||
masak | ingy++ and TimToady++ for the % changes. | ||
I approve of all of it... although I'm not sure I think the negative-numbers stuff was worth the extra complexity. | 21:21 | ||
jnthn | o/ masak | ||
21:21
bluescreen10 left
|
|||
bbkr1 | i flagged 9 RT tickets assigned to me as testneeded, feel free to steal if you want to close them faster, as I won't be able to take care of them as planned during weekend :( | 21:27 | |
21:28
y3llow_ joined,
bbkr1 left
21:29
pothos_ joined
21:30
y3llow left
21:31
pothos left,
y3llow_ is now known as y3llow,
pothos_ left,
bbkr1 joined
21:32
pothos_ joined,
pothos_ is now known as pothos
|
|||
mberends | bbkr1: after some testing, I'll be able answer what Gtk libs are needed, not right now. I look forward to testing it soon. Meantime you could try this mostly working Gtk xclock for Niecza: gist.github.com/1224163 | 21:33 | |
bbkr1 | testing... | 21:41 | |
21:45
dukeleto left
21:46
dukeleto joined,
dukeleto left,
dukeleto joined
|
|||
bbkr1 | tons of dependencies for gtk-sharp, installing | 21:46 | |
21:46
dukeleto left
21:47
dukeleto joined,
dukeleto left,
dukeleto joined,
dukeleto left
|
|||
tadzik | good evening | 21:47 | |
masak | tadzik! \o/ | ||
21:48
dukeleto joined,
dukeleto left
|
|||
jnthn | o/ tadzik | 21:48 | |
tadzik | lol, masak! | ||
masak | lol! | ||
tadzik | and jnthn! lol! | ||
masak | lolnthn! | ||
tadzik | how are you guys doing? | ||
21:48
dukeleto joined,
dukeleto left
|
|||
masak <-- giddy, happy, tired | 21:48 | ||
21:49
dukeleto joined,
dukeleto left
|
|||
jnthn kinda tired too | 21:49 | ||
21:49
dukeleto joined,
dukeleto left
21:50
dukeleto joined,
dukeleto left
|
|||
tadzik well-fed, notmuch tired, quite happy | 21:50 | ||
21:50
dukeleto joined,
dukeleto left
21:51
dukeleto joined,
dukeleto left,
dukeleto joined,
dukeleto left
|
|||
masak | dukeleto: dude, you need an ark of something. | 21:51 | |
or* | 21:52 | ||
21:52
dukeleto joined,
dukeleto left
21:53
dukeleto joined,
dukeleto left,
dukeleto joined,
dukeleto left
21:54
dukeleto joined,
dukeleto left
21:55
dukeleto joined,
dukeleto left,
dukeleto joined
21:56
dukeleto left,
dukeleto joined,
dukeleto left
21:57
dukeleto joined,
dukeleto left,
dukeleto joined,
dukeleto left
21:58
dukeleto joined,
dukeleto left
22:00
dukeleto joined,
dukeleto left,
mberends left,
dukeleto joined,
dukeleto left
22:01
dukeleto joined,
dukeleto left,
tokuhiro_ joined
22:02
dukeleto joined
|
|||
masak | 'night, channel | 22:03 | |
22:03
masak left,
mj41 left
22:04
Juerd left
22:10
mkramer1 left,
tokuhiro_ left,
tokuhiro_ joined
22:11
Ledrug[RCo] joined
22:13
Ledrug[RCo] is now known as Ledrug
22:16
tokuhir__ joined,
tokuhiro_ left
22:18
Sarten-X left
22:24
donri left
22:26
benabik left
22:28
Sarten-X joined
22:36
satyavvd joined
|
|||
Woodi | rakudo: class Foo::Bar { BEGIN { for <bar baz waz> -> $name { Foo::Bar.HOW.add_method( Foo::Bar, $name, method () { "method for $name" }); } } }; say Foo::Bar.baz | 22:40 | |
p6eval | rakudo 091c26: OUTPUT«method for baz» | ||
Woodi | this don't work on debian rakudo, build with parrot 3.6.0 0 | 22:41 | |
means Star 2011.07 ? | 22:42 | ||
tadzik | rakudo: is the development version, not yet released | 22:43 | |
p6eval | rakudo 091c26: OUTPUT«Could not find sub &version in <anon> at /tmp/oBHMhTwiip:1 in <anon> at /tmp/oBHMhTwiip:1» | ||
tadzik | yeah, right | ||
what you have in debian is most probably b: | |||
b: class Foo::Bar { BEGIN { for <bar baz waz> -> $name { Foo::Bar.HOW.add_method( Foo::Bar, $name, method () { "method for $name" }); } } }; say Foo::Bar.baz | |||
p6eval | b 1b7dd1: OUTPUT«Method 'baz' not found for invocant of class '' in main program body at line 22:/tmp/k4hI48T8GD» | ||
Woodi | other error | ||
Unable to parse postcircumfix:sym<( )>, couldn't find final ')' at line 10 | 22:44 | ||
rakudo: class Foo::Bar { BEGIN { for <bar baz waz> -> $name { Foo::Bar.HOW.add_method( Foo::Bar, $name, method { "method for $name" }); } } }; say Foo::Bar.baz | |||
p6eval | rakudo 091c26: OUTPUT«method for baz» | ||
jnthn | Only the current (unreleased) development branch has good BEGIN support. | ||
tadzik | that's just a parse error, I'd bet it's not the same code | ||
jnthn | That's one of the things we've drastically improved in the nom refactors. | ||
Woodi | i spend hour looking on that line | ||
22:45
REPLeffect joined
|
|||
Woodi | it isn't the same :) | 22:45 | |
rakudo: class Foo::Bar { BEGIN { for <bar baz waz> -> $name { Foo::Bar.HOW.add_method( Foo::Bar, $name, method() { "method for $name" }); } } }; say Foo::Bar.baz | 22:57 | ||
p6eval | rakudo 091c26: OUTPUT«===SORRY!===Unable to parse postcircumfix:sym<( )>, couldn't find final ')' at line 1» | ||
Woodi | give me perl5 perl back... | 22:58 | |
stupid space | |||
22:59
d4l3k_ joined,
Maddingu1 joined
23:00
JodaZ_ joined
23:01
kthakore_ joined,
jdv79_ joined,
szabgab_ joined,
tewk_ joined
23:02
daemon_ joined,
apejens_ joined,
TimToady_ joined,
ruz joined
23:03
Tene_ joined,
Tene_ left,
Tene_ joined,
wooden_ joined,
wooden_ left,
wooden_ joined,
yath_ joined
23:07
wooden left,
TimToady left,
Tene left,
dalek left,
tewk left,
daemon left,
jdv79 left,
apejens_ is now known as apejens,
daemon_ is now known as daemon,
d4l3k_ is now known as dalek,
TimToady_ is now known as TimToady,
ChanServ sets mode: +v dalek
23:08
bbkr joined,
phenny joined
23:11
pmichaud joined,
hugme joined,
jrockway_ joined,
zelazny.freenode.net sets mode: +v hugme
23:13
pernatiy joined,
benabik joined
23:14
molaf_ left
|
|||
jnthn | sleep & | 23:16 | |
Woodi | rakudo: my $a = 2; given $a { when 2, 3 { say "2 or 4" } } | 23:19 | |
p6eval | rakudo 091c26: ( no output ) | ||
Woodi | rakudo: my $a = 2; given $a { when 2 { say "2 or 4" } } | ||
p6eval | rakudo 091c26: OUTPUT«2 or 4» | ||
TimToady | Woodi: earlier you were asking about checking the type of a parameter; the easiest way to do that is to just put the type in the signature along with the parameter | 23:21 | |
Woodi | so just use ? :) | 23:23 | |
sjohnson | given technology! | ||
TimToady | sub foo ( $k, Numeric $v ) {...} | 23:24 | |
and if you want to conditionalize on it, that's when you want multi subs | 23:25 | ||
Woodi | now understud | ||
23:26
molaf_ joined
|
|||
Woodi | rakudo: my $a = 2; given $a { when 2|3 { say "2 or 3" } } | 23:28 | |
p6eval | rakudo 091c26: OUTPUT«2 or 3» | ||
23:30
Alias joined
23:32
espadrine left
23:35
dorlamm joined
23:36
pmichaud left,
hugme left,
jrockway_ left
23:39
pmichaud joined,
hugme joined,
jrockway_ joined,
zelazny.freenode.net sets mode: +v hugme
|
|||
TimToady | phenny: tell masak the negative quantification has been there a long time; it just got relocated to stay near the ** text | 23:43 | |
phenny | TimToady: I'll pass that on when masak is around. | ||
Woodi | rakudo: sub a() { 1 }; my $r = a() or die; | 23:48 | |
p6eval | rakudo 091c26: ( no output ) | ||
Woodi | rakudo: sub a() { 0 }; my $r = a() or die; | ||
p6eval | rakudo 091c26: OUTPUT« in <anon> at /tmp/u1Zv8l6sPh:1 in <anon> at /tmp/u1Zv8l6sPh:1» | ||
23:49
dorlamm left
|
|||
TimToady | std: method() {...} | 23:49 | |
p6eval | std c22b2ee: OUTPUT«===SORRY!===Word 'method' interpreted as 'method()' function call; please use whitespace around the parens at /tmp/uHKDkEkCO9 line 1:------> method⏏() {...}Unexpected block in infix position (two terms in a row) at /tmp/uHKDkEk… | ||
TimToady | Woodi: note that rakudo gives a substandard error there | ||
Woodi | rakudo: sub a() { 0 }; my $r = a() or say( 'die' ); | ||
p6eval | rakudo 091c26: OUTPUT«die» | ||
Woodi | yes, i wondered what exactly was that. | 23:50 | |
rakudo: sub a() { 1 }; my $r = a() or say( 'die' ); | |||
p6eval | rakudo 091c26: ( no output ) | ||
Woodi | just translating from v5; | 23:51 | |
TimToady | niecza: method() {...} | ||
p6eval | niecza v9-32-g380d891: OUTPUT«===SORRY!===Word 'method' interpreted as 'method()' function call; please use whitespace around the parens at /tmp/MSktHY09ty line 1:------> method⏏() {...}Unexpected block in infix position (two terms in a row) at /… | ||
TimToady | note that niecza has a more standard parser, so maybe you want to syntax check with niecza, then get it to run under rakudo | 23:52 | |
Woodi | i will | ||
btw. can Perl6 be more user friendly ? :) | 23:53 | ||
TimToady | well, if you can figure out a way to do that, I'm all ears | 23:54 | |
std: say $? | |||
Woodi | 'my' not needed, self!method is harder then . | ||
p6eval | std c22b2ee: OUTPUT«===SORRY!===Unsupported use of $? variable as child error; in Perl 6 please use $! at /tmp/x1zw1pWca0 line 1:------> say $?⏏<EOL>Parse failedFAILED 00:01 119m» | ||
23:54
Ledrug left
|
|||
TimToady | $!method is not much harder than $.method | 23:55 | |
Woodi | thats for readability | ||
23:55
ledrug joined
|
|||
Woodi | yes, but it is much different then c/c++/perl5 | 23:55 | |
TimToady | unfortunately we can't just have !method :) | 23:56 | |
sometimes different is better, eventually :) | |||
Woodi | i talk only about call !method, not declaration | ||
yes | |||
TimToady | you can call it as $!method(args) | ||
supposed to be able to, anyway | 23:57 | ||
23:57
uasi joined
|
|||
Woodi | but why ! ? :) | 23:57 | |
TimToady | ran out of characters :) | 23:58 | |
Woodi | . for calling ? | ||
TimToady | but also it's a mnemonic for negativity, as in "Don't touch!" | ||
Woodi | aha | ||
hard to switch mind to perl6 | |||
so potentially less users... | 23:59 | ||
TimToady | potentially different users | ||
we expect to leave some Perl 5 programmers behind, but gain others |