»ö« 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:03 MayDaniel left 00:08 MikeFair_ joined
[Coke] nqp: INIT {my %foo := Hash.new()} ; %foo{3} :=4; say %foo.perl; 00:15
p6eval nqp: OUTPUT«(signal SEGV)»
[Coke] BOOYAH
(the my should be outside of the INIT block) 00:16
opened as nqp#57 00:18
00:25 stopbit left 00:34 erkan left 01:13 sftp_ left 01:16 sftp joined 01:30 sftp left, sftp joined 01:35 sftp left 01:36 sftp joined 01:37 ServerSage left, xinming left, odoacre left 01:42 ServerSage joined, xinming joined, odoacre joined 01:46 _jaldhar_ left 01:49 sizz_ joined 01:52 ServerSage left, xinming left, odoacre left 01:58 ServerSage joined, xinming joined, odoacre joined 01:59 _jaldhar_ joined 02:07 xdbr left 02:09 odoacre_ joined, sftp left 02:11 odoacre left, sftp_ joined 02:21 macae joined 02:26 JTAAEIDW joined 02:28 macae left 02:31 macae joined 02:39 am0c joined 02:43 armitage81 joined, macae left 02:46 orafu left, PacoAir left, orafu joined 02:48 PacoAir joined 02:50 armitage81 left 02:52 PacoAir left 02:54 PacoAir joined 02:55 macae joined 02:56 tokuhiro_ joined 02:59 PacoAir left 03:01 macae left 03:41 Tanktalus left 03:48 thou joined 03:53 Tanktalus joined 04:00 popl joined 04:01 rurban left
[Coke] anyone know how I can invoke a sub in nqp when I have the /name/ of the sub in a var? "command"(@args) works, but my $a := 'command'; "$a"(@args) # fails. 04:02
04:04 rurban joined
sorear [Coke]: how is the sub defined? 04:12
maybe some variation on pir::find_lex__PS($a)(@args) 04:13
04:14 telex left
[Coke] in a .pm that is precompiled to pir and then use'd 04:14
(and the sub is exported, so it's visible)
nqp: sub v($a) {say($a)}; pir::find_lex__PS("v")(4); 04:16
p6eval nqp: OUTPUT«(signal SEGV)»
sorear nqp: sub v($a) {say($a)}; pir::find_lex__PS("foo")(4); 04:17
p6eval nqp: OUTPUT«(signal SEGV)»
sorear nqp: sub v($a) {say($a)}; pir::find_lex__PS("&v")(4);
p6eval nqp: OUTPUT«4␤»
[Coke] opens issue#58 for that.
sorear nqp: pir::find_lex__PS("v")(4);
p6eval nqp: OUTPUT«(signal SEGV)»
sorear found a working version and golfed the crash \o/ 04:18
[Coke] me updates.
sorear if you put lines ``` before and after the irc log chunk, github's markdown parser won't eat it 04:19
sorear fixed the issue
[Coke] fixed. 04:20
sorear: the find lex doesn't find it. 04:21
works fine in a single .pm, but not when things are being use'd and exported.
04:22 rurban left
[Coke] trying get_global__PS 04:22
nope. 04:23
(segfaults trying to exec, presumably having found nothing)
sorear [Coke]: the obvious workaround is to make a hash of coderefs 04:25
alternatively, use a class and nqp::findmethod somehow
04:26 telex joined
sorear maybe obvious is not quite the right word. simplest? 04:26
[Coke] (hash of coderefs)... which is what I had in parrot-nqp, s/hash/namespace/ ;)
I'm just getting further and further away from the VM here. 04:28
04:28 gfldex joined
[Coke] -> zzz 04:29
sorear++
04:29 rurban joined 04:49 gfldex left 04:51 gfldex joined 05:08 Tanktalus left 05:22 Tanktalus joined 05:25 gfldex left
moritz good morning 05:25
dalek kudo/nom: 30a13c1 | moritz++ | / (2 files):
implement :60[..] with decimal dot
sorear good morning moritz. 05:26
05:27 gfldex joined 05:56 Chillance left, am0c left 06:15 popl left 06:28 gfldex left 06:30 gfldex joined 07:05 Tanktalus left
jnthn afternoon o/ 07:09
diakopter o/
07:19 Tanktalus joined 07:34 Psyche^ joined 07:38 Patterner left, Psyche^ is now known as Patterner
jnthn So...been segfaulting NQP have we... :) 07:42
sorear o/ jnthn 07:46
yes, [Coke]++ has been continuing his heroic efforts to get tcl running on new-nqp 07:47
TimToady
.oO(All progress depends on the unreasonable man...)
jnthn Think I can see why we get the unreasonable segfaults... 07:51
dalek p: 81e9c47 | jonathan++ | src/pmc/nqplexpad.pmc:
Fix a NULL-o.
07:54
diakopter I'll return you
jnthn Now the segfault is fixed, lemme see about detecting undeclared variables properly :) 07:55
diakopter n: say 1.1.<><> 07:56
p6eval niecza v22-6-g9e5350d: OUTPUT«␤»
diakopter n: say 1.1.<m>
p6eval niecza v22-6-g9e5350d: OUTPUT«Unhandled exception: Cannot use hash access on an object of type Rat␤ at <unknown> line 0 (ExitRunloop @ 0) ␤ at /home/p6eval/niecza/lib/CORE.setting line 352 (Any.at_key @ 9) ␤ at <unknown> line 0 (ExitRunloop @ 0) ␤ at /tmp/W3E0hrvsCd line 1 (mainline…
diakopter rn: say .--, .--, .-- 07:59
p6eval niecza v22-6-g9e5350d: OUTPUT«0-1-2␤»
..rakudo 30a13c: OUTPUT«===SORRY!===␤Method 'unshift' not found for invocant of class 'NQPMu'␤»
jnthn wtf :)
More code is valid Perl 6? :P
diakopter we so valid
TimToady rn: ---...--- 08:00
p6eval niecza v22-6-g9e5350d: OUTPUT«===SORRY!===␤␤"--" and "--" are not associative at /tmp/I4F3j0n6rE line 1:␤------> ---...--⏏-␤␤Unhandled exception: "--" and "--" are not associative at /tmp/I4F3j0n6rE line 1:␤------> ---...--⏏-␤␤ at…
..rakudo 30a13c: OUTPUT«===SORRY!===␤Confused␤at /tmp/2Vp0k488jr:1␤»
sorear r: .--
p6eval rakudo 30a13c: OUTPUT«===SORRY!===␤Method 'unshift' not found for invocant of class 'NQPMu'␤»
TimToady rn: ...---...
p6eval rakudo 30a13c: ( no output )
..niecza v22-6-g9e5350d: OUTPUT«Unhandled exception: >>>Stub code executed␤ at /tmp/dQF2FPJwkL line 1 (mainline @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4198 (ANON @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4199 (module-CORE @ 574) ␤ at /home/p6eval/niecza/lib/CORE…
TimToady rn: say ...---...
p6eval niecza v22-6-g9e5350d: OUTPUT«Unhandled exception: >>>Stub code executed␤ at /tmp/hue1zcpNor line 1 (mainline @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4198 (ANON @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4199 (module-CORE @ 574) ␤ at /home/p6eval/niecza/lib/CORE…
..rakudo 30a13c: ( no output )
diakopter rakudo? no newline? 08:01
sorear no, because ... has the effect of a &return in Rakudo
it's a kind of &fail
diakopter rn: say {}[]() 08:03
p6eval niecza v22-6-g9e5350d: OUTPUT«Unhandled exception: Unable to resolve method postcircumfix:<( )> in type Hash␤ at /tmp/eGPe2svuiN line 1 (mainline @ 9) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4198 (ANON @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4199 (module-CORE @ 574…
..rakudo 30a13c: OUTPUT«No such method 'postcircumfix:<( )>' for invocant of type 'List'␤ in at src/gen/BOOTSTRAP.pm:827␤ in any at src/gen/BOOTSTRAP.pm:811␤ in block at /tmp/OypVFFQGLk:1␤␤»
diakopter Hash vs List
rn: say {}[].WHAT 08:04
p6eval niecza v22-6-g9e5350d: OUTPUT«Hash()␤»
..rakudo 30a13c: OUTPUT«List()␤»
diakopter who so right
jnthn Rakudo I think
You did a zen slice
diakopter rn: say (8, 7)[* * *] 08:06
p6eval niecza v22-6-g9e5350d: OUTPUT«Unhandled exception: No value for parameter 'anon_1' in 'ANON'␤ at /tmp/_QrmS8WAg8 line 0 (ANON @ 1) ␤ at <unknown> line 0 (ExitRunloop @ 0) ␤ at /tmp/_QrmS8WAg8 line 1 (mainline @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4198 (ANON @ 3) ␤ at …
..rakudo 30a13c: OUTPUT«Nil␤»
08:08 GlitchMr joined
sorear rn: [1..10][&say] 08:08
p6eval niecza v22-6-g9e5350d: OUTPUT«10␤»
..rakudo 30a13c: OUTPUT«Cannot coerce Inf to an Int␤ in method Numeric at src/gen/CORE.setting:9927␤ in sub infix:<==> at src/gen/CORE.setting:2602␤ in sub infix:<xx> at src/gen/CORE.setting:5856␤ in method postcircumfix:<[ ]> at src/gen/CORE.setting:1303␤ in block at /tmp/t4kuYEMPr…
sorear what. 08:09
diakopter titters
jnthn heh
r: say &say.arity 08:10
p6eval rakudo 30a13c: OUTPUT«0␤»
jnthn r: say &say.count
p6eval rakudo 30a13c: OUTPUT«Inf␤»
diakopter r: say Confused . 08:12
p6eval rakudo 30a13c: OUTPUT«===SORRY!===␤Confused␤at /tmp/cmFVtqiHTv:1␤»
diakopter XD
n: say (1 !??! !! !1 !! 1).WHAT 08:19
p6eval niecza v22-6-g9e5350d: OUTPUT«Use of uninitialized value in string context␤ at /home/p6eval/niecza/boot/lib/CORE.setting line 1289 (warn @ 5) ␤ at /home/p6eval/niecza/boot/lib/CORE.setting line 266 (Mu.Str @ 15) ␤ at <unknown> line 0 (ExitRunloop @ 0) ␤ at /home/p6eval/niecza/boot/l…
diakopter n: 1 !??! !! !1 !! 1
p6eval niecza v22-6-g9e5350d: OUTPUT«Use of uninitialized value in string context␤ at /home/p6eval/niecza/boot/lib/CORE.setting line 1289 (warn @ 5) ␤ at /home/p6eval/niecza/boot/lib/CORE.setting line 266 (Mu.Str @ 15) ␤ at <unknown> line 0 (ExitRunloop @ 0) ␤ at /home/p6eval/niecza/boot/l…
diakopter sorear: _._ 08:20
08:20 Tanktalus left
diakopter n: say 1 ??! !! !0 !! 1 08:21
p6eval niecza v22-6-g9e5350d: OUTPUT«False␤»
diakopter this confusez me. 08:22
sorear diakopter: ^.^?
diakopter :)
which !! goes with the ?? above
sorear n: say 1 ?? (! !! !0) !! 1
p6eval niecza v22-6-g9e5350d: OUTPUT«False␤» 08:23
sorear std: say ! !! !0
p6eval std 77327a4: OUTPUT«ok 00:00 42m␤»
sorear std: say 1 ??! !! !0 !! 1
p6eval std 77327a4: OUTPUT«ok 00:00 42m␤»
diakopter k
n: say !?!!?!1??1!??!!?!?!?1!!1!!1 08:25
p6eval niecza v22-6-g9e5350d: OUTPUT«Use of uninitialized value in string context␤ at /home/p6eval/niecza/boot/lib/CORE.setting line 1289 (warn @ 5) ␤ at /home/p6eval/niecza/boot/lib/CORE.setting line 266 (Mu.Str @ 15) ␤ at <unknown> line 0 (ExitRunloop @ 0) ␤ at /home/p6eval/niecza/boot/l…
diakopter where is Mu 08:26
n: say 1??1!??1!!1 # golfed 08:29
p6eval niecza v22-6-g9e5350d: OUTPUT«Use of uninitialized value in string context␤ at /home/p6eval/niecza/boot/lib/CORE.setting line 1289 (warn @ 5) ␤ at /home/p6eval/niecza/boot/lib/CORE.setting line 266 (Mu.Str @ 15) ␤ at <unknown> line 0 (ExitRunloop @ 0) ␤ at /home/p6eval/niecza/boot/l…
diakopter std: say 1??1!??1!!1 # golfed 08:30
p6eval std 77327a4: OUTPUT«===SORRY!===␤Cannot negate ?? !! because conditional operators are too fiddly at /tmp/cKY74ZkZyp line 1:␤------> say 1??1!??1!!⏏1 # golfed␤Cannot negate ??1!! because conditional operators are not iffy enough at /tmp/cKY74ZkZyp li…
diakopter rn: say - - -
p6eval niecza v22-6-g9e5350d: OUTPUT«===SORRY!===␤␤Prefix requires an argument at /tmp/mWzDlRpKj4 line 1 (EOF):␤------> say - - -⏏<EOL>␤␤Parse failed␤␤» 08:31
..rakudo 30a13c: OUTPUT«===SORRY!===␤Preceding context expects a term, but found infix - instead␤at /tmp/qoHP4LFvX0:1␤»
diakopter rn: say - - - 1
p6eval rakudo 30a13c, niecza v22-6-g9e5350d: OUTPUT«-1␤»
diakopter rn: say - - - -- - - --- - -- - -- - -- - -- 1
p6eval rakudo 30a13c: OUTPUT«Cannot assign to a non-container␤ in sub prefix:<--> at src/gen/CORE.setting:2869␤ in block at /tmp/RdW4wdgT_p:1␤␤»
..niecza v22-6-g9e5350d: OUTPUT«Unhandled exception: Writing to readonly scalar␤ at /tmp/qYmFSIT49a line 1 (mainline @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4198 (ANON @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4199 (module-CORE @ 574) ␤ at /home/p6eval/niecza/lib…
diakopter rn: say - - - -- - - --- - -- - -- - -- - -- $_
p6eval rakudo 30a13c: OUTPUT«Cannot assign to a non-container␤ in sub prefix:<--> at src/gen/CORE.setting:2869␤ in block at /tmp/4VNeSp0Mqj:1␤␤»
..niecza v22-6-g9e5350d: OUTPUT«Unhandled exception: Writing to readonly scalar␤ at /tmp/BsfCoOwyCx line 1 (mainline @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4198 (ANON @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4199 (module-CORE @ 574) ␤ at /home/p6eval/niecza/lib…
diakopter rn: say $_ - - - -- - - --- - -- - -- - -- - -- $_
p6eval rakudo 30a13c: OUTPUT«Cannot assign to a non-container␤ in sub prefix:<--> at src/gen/CORE.setting:2869␤ in block at /tmp/x7M5wZF6mr:1␤␤» 08:32
..niecza v22-6-g9e5350d: OUTPUT«Unhandled exception: Writing to readonly scalar␤ at /tmp/Yt0Plzwihb line 1 (mainline @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4198 (ANON @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4199 (module-CORE @ 574) ␤ at /home/p6eval/niecza/lib…
diakopter rn: say $_ - - - --$_
p6eval rakudo 30a13c, niecza v22-6-g9e5350d: OUTPUT«0␤»
diakopter rn: say $_ - -- --$_
p6eval niecza v22-6-g9e5350d: OUTPUT«0␤»
..rakudo 30a13c: OUTPUT«Cannot assign to a readonly variable or a value␤ in sub prefix:<--> at src/gen/CORE.setting:2869␤ in block at /tmp/_HXhuoLF2B:1␤␤»
diakopter rn: say -- --$_
p6eval rakudo 30a13c: OUTPUT«Cannot assign to a readonly variable or a value␤ in sub prefix:<--> at src/gen/CORE.setting:2869␤ in block at /tmp/U2tTBDkgkk:1␤␤»
..niecza v22-6-g9e5350d: OUTPUT«-2␤»
diakopter rn: say --$_
p6eval rakudo 30a13c, niecza v22-6-g9e5350d: OUTPUT«-1␤»
diakopter oops 08:33
didn't mean to spam the channel
srry
thought I was in a different window
how embracing
dalek p: a0b4c57 | jonathan++ | src/NQP/Actions.pm:
Catch undeclared variables properly.
diakopter jnthn: see this: 08:34
rn: say --$_
p6eval rakudo 30a13c, niecza v22-6-g9e5350d: OUTPUT«-1␤»
08:34 Tanktalus joined
diakopter rn: say -- --$_ 08:34
p6eval rakudo 30a13c: OUTPUT«Cannot assign to a readonly variable or a value␤ in sub prefix:<--> at src/gen/CORE.setting:2869␤ in block at /tmp/nIC_JBTffj:1␤␤»
..niecza v22-6-g9e5350d: OUTPUT«-2␤»
diakopter I don't know which is right
jnthn diakopter: In Rakudo it returns the value I guess 08:35
diakopter rn: say $_++++ 08:36
p6eval niecza v22-6-g9e5350d: OUTPUT«Unhandled exception: Writing to readonly scalar␤ at /tmp/41t8iE5qKh line 1 (mainline @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4198 (ANON @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4199 (module-CORE @ 574) ␤ at /home/p6eval/niecza/lib…
..rakudo 30a13c: OUTPUT«Cannot assign to a non-container␤ in sub postfix:<++> at src/gen/CORE.setting:2873␤ in block at /tmp/3yPUyjWxAU:1␤␤»
diakopter they both return the value for post
jnthn phenny: tell [Coke] both tickets resolved 08:39
phenny jnthn: I'll pass that on when [Coke] is around.
08:41 tgt joined
diakopter rn: say %$_ 08:41
p6eval niecza v22-6-g9e5350d: OUTPUT«Unhandled exception: Unmatched key in Hash.LISTSTORE␤ at /home/p6eval/niecza/lib/CORE.setting line 388 (Any.hash @ 3) ␤ at <unknown> line 0 (ExitRunloop @ 0) ␤ at /tmp/f2Ue8uLohI line 1 (mainline @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4198 …
..rakudo 30a13c: OUTPUT«Odd number of elements found where hash expected␤ in method STORE at src/gen/CORE.setting:6341␤ in method hash at src/gen/CORE.setting:1147␤ in block at /tmp/VNAXiOjJBV:1␤␤»
08:44 erkan joined, erkan left, erkan joined
diakopter r: say %1 * 3 08:45
p6eval rakudo 30a13c: OUTPUT«use of uninitialized variable $v of type Any in numeric context in block at /tmp/uwX4eggWmn:1␤␤0␤»
diakopter rn: say -1 +& -2 08:46
p6eval niecza v22-6-g9e5350d: OUTPUT«-2␤»
..rakudo 30a13c: OUTPUT«0␤»
diakopter sorear: ^^
rn: say -1 +& -3 08:47
p6eval niecza v22-6-g9e5350d: OUTPUT«-3␤»
..rakudo 30a13c: OUTPUT«-1␤»
diakopter eh
GlitchMr >>> -1 & -2 08:48
-2
That sounds right
diakopter poor rakudo
GlitchMr It's negative integer, so everything gets reversed 08:49
sorear I probably ought to disable my highlight on niecza
I like to know when people are talking about niecza but I don't like to know when diakopter is fuzz testing 08:50
is it possible to tell irssi to not trigger highlights on anything p6eval generates?
diakopter I try not to fuzz on the channel; I just put things to the channel I find interesting
08:51 crab2313 joined
sorear interesting things will be immediately forgotten if they're sent here 08:51
there must be a better way
GlitchMr I mean, on -1 & -2 Python and Ruby say me -2. So it's right
And it makes sense. -1 is ~0.
diakopter GlitchMr: right, so rakudo is different
sorear remember precedence.... 08:52
GlitchMr -1 (with 8-bit integers) is 0xFF, -2 is 0xFE
0xFF & 0xFE == 0xFE 08:53
of course, Perl 6 has infinite length integers
But it still works like that
sorear but niecza does bitops in 32-bit
n: say 2**31 +| 1
p6eval niecza v22-6-g9e5350d: OUTPUT«-2147483647␤»
sorear n: say 2**30 +| 1
p6eval niecza v22-6-g9e5350d: OUTPUT«1073741825␤»
sorear n: say 2**32 +| 1
p6eval niecza v22-6-g9e5350d: OUTPUT«-2147483647␤»
GlitchMr Yeah, that sounds like a bug
Ruby and Python can do bitwise operations on infinite length integers 08:54
But 0 definitely isn't right 08:55
Somehow I have feeling that Rakudo has different number representation or something
diakopter rn: say -1 +& 2**190 08:56
p6eval niecza v22-6-g9e5350d: OUTPUT«-2147483648␤»
..rakudo 30a13c: OUTPUT«1569275433846670190958947355801916604025588861116008628224␤»
GlitchMr Everything looks like Rakudo has separate negative flag 08:57
08:57 flightrecorder joined, FROGGS joined
GlitchMr In C, negative version of i is ~i + 1 08:58
I find infinite integers really confusing when dealing with bitwise operations, especially ~. 08:59
Or when dealing with bitwise operations and negative integers
sorear GlitchMr: niecza represents integers either as two's complement 32-bit if that fits, or else as bigint with separate negative flag. but it tries to hide this; bitops are one place it doesn't 09:01
I haven't touched the bitop code since the old days when niecza had only Num 09:02
diakopter rn: say (2**2**17).chars
p6eval rakudo 30a13c, niecza v22-6-g9e5350d: OUTPUT«39457␤»
sorear and bitops worked Javascript-style
sleep&
GlitchMr But well, bitwise operations on infinite integers make sense...
As long you don't at values
dalek ast: e267414 | jonathan++ | S05-modifier/perl5_2.t:
Re-fudge some m:P5/.../ tests.
09:03
GlitchMr rn: say -1 +> 42 09:05
p6eval niecza v22-6-g9e5350d: OUTPUT«-1␤»
..rakudo 30a13c: OUTPUT«0␤»
GlitchMr It should be -1
Becuase infinity
09:05 Tanktalus left 09:06 thou left
diakopter rn: say +^^^^ -1 09:08
p6eval niecza v22-6-g9e5350d: OUTPUT«===SORRY!===␤␤Expecting a term, but found either infix ^^ or redundant prefix ^␤ (to suppress this message, please use space between ^ ^) at /tmp/WV9CFqxIln line 1:␤------> say +^^^⏏^ -1␤␤Parse failed␤␤»…
..rakudo 30a13c: OUTPUT«-1␤»
diakopter rn: say +^^^ -1
p6eval niecza v22-6-g9e5350d: OUTPUT«===SORRY!===␤␤Expecting a term, but found either infix ^^ or redundant prefix ^␤ (to suppress this message, please use space between ^ ^) at /tmp/fZ0ufLAHKl line 1:␤------> say +^^^⏏ -1␤␤Parse failed␤␤»
..rakudo 30a13c: OUTPUT«-1␤»
diakopter rn: say +^^ -1 09:09
p6eval rakudo 30a13c, niecza v22-6-g9e5350d: OUTPUT«-1␤»
GlitchMr oh... wait... JavaScript says that -1 >> whatever is -1... 09:10
But >>> makes math properly
Interesting
Arithmetic right shift doesn't make sense in languages with infinite length integers, but well, JavaScript isn't one of those 09:11
I meant, logical
>>> sounds like a hack anyways 09:12
diakopter rn: say 8.80000000000000000000000000000000000000000000001-8.8
p6eval rakudo 30a13c: OUTPUT«1.00000000000002e-47␤» 09:13
..niecza v22-6-g9e5350d: OUTPUT«-1.7763568394002505E-15␤»
GlitchMr The floating point world is world without rules. 09:15
diakopter rakudo is closer
GlitchMr Probably bigger precission of something
rn: say 1e-1 + 2e-1 - 3e-1 09:16
p6eval rakudo 30a13c, niecza v22-6-g9e5350d: OUTPUT«0␤»
GlitchMr 0? But isn't it floating point number? 09:17
rn: say 1e-1 + 2e-1 - 3e-1 * 1e20
p6eval rakudo 30a13c: OUTPUT«-3e+19␤»
..niecza v22-6-g9e5350d: OUTPUT«-3.0000000000000004E+19␤»
GlitchMr oops
Precedence
rn: say (1e-1 + 2e-1 - 3e-1) * 1e20
p6eval rakudo 30a13c, niecza v22-6-g9e5350d: OUTPUT«0␤»
09:18 Tanktalus joined, spider-mario joined
moritz r: say :60[1, 2, 3] 09:23
p6eval rakudo 30a13c: OUTPUT«3723␤»
moritz r: say :60[1, 2, 3, '.', 6]
p6eval rakudo 30a13c: OUTPUT«3723.1␤»
TimToady \o/ 09:24
dalek kudo/nom: 3b883b6 | jonathan++ | t/spectest.data:
Run S05-modifier/perl5_2.t.
kudo/nom: 3d31af9 | jonathan++ | tools/build/NQP_REVISION:
Bump NQP revision for m:P5 improvements.
moritz TimToady: we aim to please, occasionally :-) 09:25
and it was a LHF
09:29 cognominal joined 09:31 cognominal_ joined
FROGGS r: say :16[1, 2, 3] 09:33
p6eval rakudo 30a13c: OUTPUT«291␤»
FROGGS thats cool
09:34 cognominal left
FROGGS but I cant remember als these twigils and signs :|^* 09:34
Perl 6 is not turning into a language like brainfuck, no? 09:35
jnthn No; bf is minimal :P 09:36
TimToady you just have to learn them, then it's easy to remember them :P 09:37
FROGGS hehe
I remember the | to flatten args on function calls though
appending ! to an arg to make it a required one seems good, but : doesnt speak for itself when prepending it to something like the example above 09:39
TimToady it's supposed to look like a pair, and the two dots are indicating the pairness of it 09:55
% is also like that, with the two circles
so a hash is a bunch of pairs :) 09:56
FROGGS ohh, never seen it like this 09:57
10:02 cognominal joined 10:03 cognominal_ left
TimToady visual metaphors Я us 10:10
10:11 MayDaniel joined
TimToady looks like the typhoon is just missing us, except for the breeze; nearly all the rain has been to the west of us 10:11
diakopter good thing it didn't become a hurricane 10:13
jnthn That woulda blown 10:18
10:29 cognominal left 10:32 cognominal joined 10:38 cognominal left 10:49 crab2313 left 10:52 cognominal joined 10:58 cognominal left 11:02 bbkr1 joined 11:05 bbkr1 left, Su-Shee_ joined 11:08 Su-Shee left 11:14 replore joined 11:24 am0c joined 11:37 tokuhiro_ left 11:40 benabik joined, mucker joined 11:41 cognominal joined, cognominal left 11:47 jlaire joined 11:55 cognominal joined 11:56 jlaire left
cognominal nqp: my $s := "<toto>&lt;"; $s := nqp::substr($s, 0, 10); say($s); $s := subst($s, '&', / '&amp;' /, :global); say($s); 11:59
p6eval nqp: OUTPUT«<toto>&lt;␤Method 'ACCEPTS' not found for invocant of class 'String'␤current instr.: 'match' pc 855 (src/stage2/gen/NQPCORE.setting.pir:400) (src/stage2/NQPCORE.setting:346)␤»
cognominal What I am doing wrong?
ho 12:00
I am not awake apparently
nqp: my $s := "<toto>&lt;"; $s := nqp::substr($s, 0, 10); say($s); $s := subst($s, / '&' /, '&amp;' , :global); say($s); 12:01
p6eval nqp: OUTPUT«<toto>&lt;␤<toto>&amp;lt;␤»
cognominal everything works fine
12:02 sftp_ left 12:04 jlaire joined
cognominal subst second argument cannot be a string. To get around that, I ended putting the slash in the wrong place. :( 12:05
12:13 sftp_ joined 12:32 cognominal_ joined, cognominal left 12:37 cognominal__ joined 12:38 cognominal_ left 12:42 Su-Shee_ is now known as Su-Shee 12:46 sftp_ left 12:50 sisar joined
sisar hi #perl6 ! 12:50
12:50 benabik left 12:51 benabik joined
sisar r: my $x = Int.new; say $x; $x = 'a'; say $x; 12:52
p6eval rakudo 3d31af: OUTPUT«0␤a␤»
sisar ^ Why is assigning 'a' to $x not an error ? 12:53
jnthn Why would it be?
12:53 sftp joined
jnthn You didn't constrain $x in any way 12:53
r: my Int $x = Int.new; say $x; $x = 'a'; say $x;
p6eval rakudo 3d31af: OUTPUT«0␤Type check failed in assignment to '$x'; expected 'Int' but got 'Str'␤ in block at /tmp/aK_JdshNA1:1␤␤»
jnthn That's how you get constraints. 12:54
sisar jnthn: ok
ah, assigning 'a' replaces the Int object which $x referred to earlier. 12:56
jnthn Yes
sisar silly me :-)
13:02 Tanktalus left 13:04 daniel-s__ joined 13:05 cognominal__ left 13:07 daniel-s left 13:13 cognominal joined 13:16 Tanktalus joined 13:31 preflex left
GlitchMr r: my Real $number = 42; $number = '42'; # sure? 13:32
p6eval rakudo 3d31af: OUTPUT«Type check failed in assignment to '$number'; expected 'Real' but got 'Str'␤ in block at /tmp/DwS_vK0gW9:1␤␤»
GlitchMr r: my Cool $number = 42; $number = [42]; # sure?
p6eval rakudo 3d31af: ( no output )
GlitchMr That worked?
oh ok, Cool is really wide 13:33
r: my Cool $number = 42; $number = \42; # sure? 13:34
p6eval rakudo 3d31af: OUTPUT«Type check failed in assignment to '$number'; expected 'Cool' but got 'Capture'␤ in block at /tmp/08ZJbKYqjj:1␤␤»
13:37 PacoAir joined, PacoAir left, PacoAir joined 13:40 Tanktalus left 13:52 Tanktalus joined 13:56 cognominal_ joined 13:58 cognominal left 14:01 jlaire left 14:08 jlaire joined 14:12 kaare__ joined 14:17 cognominal joined, cognominal_ left 14:21 benabik left, telex left 14:22 telex joined 14:24 cognominal left 14:25 cognominal joined 14:29 xinming left 14:31 xinming joined
tadzik good afternoon, #perl6 14:34
14:38 spider-mario left
cognominal good afternoon, tadzik et al. 14:43
[Coke] jnthn: thanks. 14:47
phenny [Coke]: 08:39Z <jnthn> tell [Coke] both tickets resolved
14:48 ChoHag left
tadzik jnthn: do you plan to look at the threads issue? 14:49
14:51 cognominal left 14:52 birdwindupbird joined 14:53 benabik joined 15:02 cognominal joined 15:14 ChoHag joined 15:16 daniel-s__ left 15:17 daniel-s__ joined 15:19 am0c left 15:20 benabik left 15:22 benabik joined 15:28 tgt left 15:32 cognominal_ joined 15:33 cognominal left, mucker left, tgt joined
GlitchMr yes \ | cat -n | while read a; do expr $a % 2 > /dev/null && echo $a; done 15:39
Those examples on Rosetta Code are interesting...
I wonder how feasible it would be have something like that in Perl 6...
15:39 cognominal_ left
GlitchMr 1 .. * ==> grep * %2 15:40
hmmm... ok
15:40 bbkr_ joined 15:41 bbkr left 15:50 cognominal_ joined 15:51 Ulti joined
Ulti does split in Perl6 give you an iterator? 15:52
or lazy list whichever is the more correct term 15:53
15:53 birdwindupbird left, phenny left 15:56 benabik left 16:00 cognominal_ left, cognominal joined 16:02 isBEKaml joined 16:03 robinsmidsrod left 16:04 robinsmidsrod joined
gfldex i got a problems to build rakudo on cygwin 16:08
Using /home/dex/rakudo/install/bin/parrot (version RELEASE_4_4_0).
sh: line 0: cd: 3rdparty/dyncall: No such file or directory
pmichaud good morning, #perl6 16:09
gfldex what's a lie
well, the morning is quite good actually :)
pmichaud was anyone able to look at the panda issue?
irclog.perlgeek.de/perl6/2012-09-29#i_6027864 16:11
16:14 lithos joined 16:15 lithos left, _edwin joined
_edwin nr: say "abcd".substr(2,Inf) 16:16
p6eval rakudo 3d31af: OUTPUT«This type cannot unbox to a native integer␤ in method substr at src/gen/CORE.setting:3639␤ in block at /tmp/e1suZY_eRd:1␤␤»
..niecza v22-6-g9e5350d: OUTPUT«Str()␤»
_edwin hi perl6! 16:17
I wonder if the above is a rakudobug, as rakudo itself suggests that Inf should be ok:
rakudo: say "abcd".substr(2,-1) 16:18
p6eval rakudo 3d31af: OUTPUT«Length argument to substr out of range. Is: -1, should be in 0..Inf; use *-1 if you want to index relative to the end␤ in method gist at src/gen/CORE.setting:9929␤ in sub say at src/gen/CORE.setting:7250␤ in block at /tmp/aulbhMTy3U:1␤␤»
16:19 Circlepuller_ joined
pmichaud _edwin: looks rakudobug-ish to me 16:19
_edwin ok, will try to file a ticket 16:20
16:20 replore left, cognominal left, Circlepuller left 16:21 replore_ joined 16:24 cognominal joined
pmichaud files pandaissue 16:27
tadzik oh, I can has 16:28
btw, I have spectest failures gist.github.com/3807433
pmichaud tadzik: what version of rakudo/parrot ? 16:29
tadzik rakudo HEAD, parrot is probably somewhat ancient
This is Parrot version 4.7.0-devel built for amd64-linux
nqp didn't complain though :)
pmichaud well, nqp shouldn't complain, as the minimum is 4.4.0 :) 16:30
tadzik :)
_edwin reported rt.perl.org/rt3/Public/Bug/Display...?id=115086
pmichaud I'll test it here.
tadzik this one is the threads branch, but it shouldn't affect anything
pmichaud _edwin++
oh, it wouldn't surprise me if the threads branch *does* affect stuff. I don't know if io_rewrite was merged into threads branch
io_rewrite would likely explain the IO-Socket-INET.t failures 16:31
(rakudo head currently expects a parrot without the io_rewrite merge 16:32
)
tadzik ah, right
pmichaud tadzik: any chance that Panda::Tester will be fixed in the next couple of hours?
tadzik oh, without
pmichaud: absolutely 16:33
pmichaud okay, I'll hold the star release for that.
16:33 cognominal left
pmichaud I definitely want to release star in the next 7 hours, though (so that we're still 09-30-2012 UTC) 16:33
er, 2012-09-30 UTC :)
tadzik I'll fix that within 30 minutes 16:34
16:35 tgt left 16:36 cognominal joined
tadzik ugh, running on debugging parrot w/o --optimize is quite awful 16:39
pmichaud all spectests pass for me with rakudo HEAD and Parrot 4.4.0 16:42
16:43 replore_ left 16:47 thou joined 16:50 tgt joined 16:55 cognominal_ joined, cognominal left 16:57 wk joined
dalek nda: c731c4d | tadzik++ | lib/Panda/Tester.pm:
[Panda::Tester] Use $*EXECUTABLE_NAME instead of hardcoded "perl6"
16:59
tadzik pmichaud: there, ready 17:00
17:13 isBEKaml left
dalek ar: 9dd84dd | pmichaud++ | tools/star/Makefile:
4.6.0 is in the supported/ directory instead of devel/ . :-|
17:17
17:18 birdwindupbird joined
pmichaud tadzik: testing, and thanks 17:18
17:21 cognominal_ left 17:23 cognominal joined 17:26 grondilu joined 17:28 cognominal left 17:31 tgt left 17:34 Kim_Breitwieser joined, Kim_Breitwieser left, cognominal joined, Kim_Breitwieser joined 17:39 sizz_ left, sizz joined 17:40 tokuhiro_ joined 17:42 cognominal left 17:43 ggoebel joined 17:46 Chillance joined 17:48 sizz left, sizz joined 17:49 spider-mario joined 17:51 cognominal joined
pmichaud tadzik: method build in lib/Panda/Builder.pm seems to make the same mistake 17:51
tadzik: line 50 17:52
grondilu I noticed that TimToady uses the sigilless style a lot on rosettacode. Since "my var = Whatever" is a syntax error anyway, what about making it a shortcut for "my \var = Whatever"? 17:55
diakopter well, there's something to be said for something to make such things stand out on declaration 17:56
since the \ is a sort of sigil
pmichaud it's also not the case that anything "sigilless" automatically ought to be a declaration 17:57
grondilu pmichaud: sure, but the shortcut would concern only declarations, precisely. 17:58
pmichaud other unsigilled terms can follow the 'my', though.
17:58 cognominal left
pmichaud if someone enters my Type = Whatever when they intended it to be my Type $x = Whatever we ought to catch that. 17:59
instead of just assuming that "Type" is being declared.
grondilu indeed. Haven't thought of that. 18:00
diakopter rn: my \sub = 3; say sub;
p6eval rakudo 3d31af: OUTPUT«===SORRY!===␤Missing block␤at /tmp/DWRbAPHvEJ:1␤»
..niecza v22-6-g9e5350d: OUTPUT«===SORRY!===␤␤Malformed block at /tmp/ojYQwBA7ny line 1:␤------> my \sub = 3; say sub⏏;␤␤Parse failed␤␤»
tadzik pmichaud: indeed, fixing 18:02
dalek nda: 2ef186a | tadzik++ | lib/Panda/Builder.pm:
[Panda::Builder] Use $*EXECUTABLE_NAME instead of hardcoded "perl6", pmichaud++
18:05
grondilu diakopter: I doubt you can overwrite keywords semantic. Even Perl6 is not that cool :)
18:06 cognominal joined
diakopter rn: class class { }; say class.new() 18:07
p6eval rakudo 3d31af: OUTPUT«===SORRY!===␤Unable to parse $*PKGDECL definition at line 2, near ".new()"␤»
..niecza v22-6-g9e5350d: OUTPUT«class.new(...)␤»
moritz r: sub if() { say '42' }; if()
p6eval rakudo 3d31af: OUTPUT«42␤»
grondilu r: sub sub { 42 }; say sub; 18:09
p6eval rakudo 3d31af: OUTPUT«===SORRY!===␤Missing block␤at /tmp/stKkyhsmHV:1␤»
grondilu r: sub sub { 42 }; say sub();
p6eval rakudo 3d31af: OUTPUT«42␤»
grondilu My bad. 18:10
18:13 cognominal left, cognominal joined 18:14 cognominal left
grondilu on second thought, even with a type, it might work. "my Type var = Whatever;' is a syntax error. And 'my Type = Whatever' doesn't mean anything unless we meen Type to be the name of the variable. 18:14
18:16 sftp left
diakopter he's saying the compiler wouldn't know whether you meant Type to be the name of the variable, or whether you accidentally the variable name (and thus should warn) 18:16
18:16 sftp joined 18:17 sftp left
grondilu you mean "accidentally forgot"? 18:17
pmichaud "doesn't know yet"
consider
my XYZ = some_expression
the compiler hasn't seen "XYZ" before
maybe it's a type that the programmer failed to declare
maybe it's meant to be a declaration
the compiler can't know. 18:18
grondilu well, if XYZ hasn't been defined yet, then it's a variable declaration.
pmichaud unless the programmer meant to write "my XYZ $x = some_expression"
grondilu does the compiler really have to assume the programmer may have made a typo? 18:19
I mean, forgetting to write "$x" is a big omission. 18:20
pmichaud sure
I'm of the opinion that anytime you create something that is sigiless, it should happen explicitly and not by accident 18:21
we already have keywords, types, and subroutine calls that are sigiless
*sigilless
18:21 bbkr joined
pmichaud oh, and operators 18:22
grondilu I know. I wouldn't have suggested that if I hadn't noticed that TimToady himself seems to lik sigilless variables.
pmichaud right, but the declaration of sigilless things happens explicitly, by virtue of the \ 18:23
anyway, as you point out, TimToady likes sigilless things so it wouldn't surprise me if the \ becomes optional in declarations... but at this stage of the game it seems potentially fragile, which argues we shouldn't rush to do it without looking at all of the ramifications first 18:24
such as things accidentally becoming declarations when they weren't intended to be
_edwin nr: my %h; %h{Any}
grondilu Notice that if you declare a variable this way: my foo = "bar", the fact that foo is sigilless is kind of explicit as well.
p6eval rakudo 3d31af: OUTPUT«use of uninitialized variable $key of type Any in string context in block at /tmp/EIgCvnrmcc:1␤␤» 18:25
..niecza v22-6-g9e5350d: OUTPUT«Use of uninitialized value in string context␤ at /home/p6eval/niecza/lib/CORE.setting line 1289 (warn @ 5) ␤ at /home/p6eval/niecza/lib/CORE.setting line 266 (Mu.Str @ 15) ␤ at <unknown> line 0 (ExitRunloop @ 0) ␤ at /tmp/KNRCAl21vP line 1 (mainline @ 3…
_edwin rakudo's message mentioning "$key" seems strange to me 18:26
grondilu Honnestly, when you declare foo like this: "my \foo = 'bar'", then one miht expect to encounter foo in this form "\foo" in the rest of the code, and not "\foo". A non initiated programmer might wonder why the backslash has disappeared. So using '\' is actually less explicit than not using one. IMHO. 18:27
diakopter rn: my \foo = 44; say \foo 18:28
p6eval niecza v22-6-g9e5350d: OUTPUT«\(44)␤»
..rakudo 3d31af: OUTPUT«44␤»
diakopter hmm
grondilu s/and not "\foo"/and not "foo"/
pmichaud well, propose the change to TimToady, see what he thinks. :-)
grondilu I would not dare. He's kind of intimidating :) He's Larry Wall, right? 18:30
pmichaud sure, but he's pretty straightforward. I've certainly been on the wrong side of Rule 1 many times. So has he, which is why Rule 2 exists. :-P 18:33
18:36 sisar left
grondilu The thing is also that if we start to use sigilless variables a lot, at some point one question will pop out: do we actually really need sigils after all? I mean, they could be nothing more than a convention in variable names. $foo and @foo would just be two different variables names that differ only by their first character. 18:41
But I've just remember that sigils provide scalar or lit context and that it's kind of useful. So forget about what I said. 18:45
lol If I wasn't so scared of losing some karma, it would make a nice troll to post on perlmonks.org :) 18:49
18:52 sirrobert joined 18:53 benabik joined, bbkr left 18:57 sftp joined
pmichaud yay, all star tests finally pass 19:06
tadzik \o/
sirrobert nice =)
sorear good * #perl6 19:07
colomon o/ 19:10
19:11 grondilu left
sorear pmichaud: how was the io_rewrite situation resolved? 19:11
pmichaud sorear: by reverting back to an older version of Parrot for 2012.09 19:12
colomon just explained to his son how the Thomas the Tank Engine turntable works (simple gears) and he immediately asked, "Is that how the tractor beam works?" Ummm..... 19:13
tadzik :) 19:14
pmichaud colomon: it's still gears, they're just really really small. :-)
colomon pmichaud++ 19:15
19:15 cognominal joined 19:24 cognominal left 19:31 cognominal joined 19:34 rummik joined, benabik left 19:35 benabik joined
dalek href="https://glitchmr.github.com:">glitchmr.github.com: 01685ad | GlitchMr++ | _posts/2012-09-30-perl-6-changes-2012W39.md:
Perl 6 changes for this week.

I know I'm late, but I totally forgot about that.
19:45
href="https://glitchmr.github.com:">glitchmr.github.com: ac1b532 | GlitchMr++ | _posts/2012-09-30-perl-6-changes-2012W39.md:
Remove leftover sentence completely.
19:46
href="https://glitchmr.github.com:">glitchmr.github.com: 88e9eb6 | GlitchMr++ | _posts/2012-09-30-perl-6-changes-2012W39.md:
Add link to expmod documentation
19:48
19:49 _edwin left 19:51 tokuhiro_ left
dalek href="https://glitchmr.github.com:">glitchmr.github.com: 71246dd | GlitchMr++ | _posts/2012-09-30-perl-6-changes-2012W39.md:
Add link to Signature documentation
19:51
19:52 GlitchMr left
dalek ar: f7ffa9a | pmichaud++ | tools/ (2 files):
Add note to update version number in Makefile.in.
19:53
ar: 5e9d266 | pmichaud++ | modules/panda:
Bump panda version to get perl6 $*EXECUTABLE fixes (tadzik++).
19:58 replore_ joined 20:01 Kim_Breitwieser left, replore_ left 20:02 whiteknight joined
gfldex did anybody test the next star on cygwin? 20:03
because i still have problems to build rakudo and it's not the rebase problem 20:04
pmichaud gfldex: I don't have a way to test it on cygwin 20:05
remind me of the problem / workaround again and I can check
gfldex pmichaud: gist.github.com/3808313 20:06
the directory in question does exist and seams to be quite happy 20:07
pmichaud I wonder if the makefile/shell doesn't like "3rdparty/dyncall" as one argument. 20:09
doesn't seem likely, though. 20:11
other places in the makefile use the "cd foo/bar" syntax. 20:12
gfldex my guess would be it's in the wrong directory
pmichaud gfldex: have you been able to get earlier versions of rakudo to build with cygwin?
gfldex it was working yesterday or the day before
pmichaud I'm kind of stumped then, afaict none of the relevant makefiles have changed at all 20:16
gfldex pmichaud: there is no makefile yet
so it can't be in it :)
pmichaud oh, that's true
it's in the middle of NQP's Configure.pl 20:17
wait, huh?
pmichaud is confused 20:19
are you using a fresh checkout of rakudo, or from a tarball, or what? 20:20
gfldex did a fresh clone
pmichaud I don't see how it can be "in the wrong directory", though.
what happens if you try it without the "nice" and the "&&", ooc? 20:21
gfldex it's dies in line 128
i will try that 20:22
pmichaud you're using a fresh nqp clone?
well, put it this way -- cd nqp and tell me the first line of "git log" 20:23
I want to know what commit the nqp instance is on
gfldex commit a0b4c579cb03fde2f4a3bc3b0c24e0ee75f67cae
pmichaud somehow your system is using the most recent nqp, instead of 2012.09.1 20:24
just a sec
gfldex that's why git clone github.com/rakudo/rakudo.git is fetching 20:25
pmichaud oh, jnthn++ bumped NQP_REVISION
if I give you a star candidate tarball, can you test it?
gfldex i can do that 20:26
what's the nqp github url?
pmichaud pmichaud.com/sandbox/rakudo-star-20...rc3.tar.gz
nqp is at github.com/perl6/nqp
20:27 PacoAir_ joined 20:28 PacoAir left, PacoAir_ is now known as PacoAir
gfldex i did a cygwin update yesterday too 20:28
that might have caused it
very odd tho
pmichaud well, this month's star release has already taken far too much time and effort from me
I'm having to chase down and troubleshoot lots of platforms and bugs for systems I don't have access to 20:29
20:33 armitage81 joined 20:36 birdwindupbird left, kst` left
gfldex pmichaud: same problem with that tar ball 20:37
likely a cygwin problem
i will try to track it down
pmichaud I'm going to guess a cygwin problem, yes; especially if it showed up after a cygwin update
we really haven't made any changes to the build system in the last month 20:38
gfldex pmichaud: i just did a cygwin update again and installed a very suspicious new perl-vendors* package 20:46
looks like star is building now 20:47
you may want to add a line about that in the release notes
them perl porters don't want us bored :)
.o(perl5 sabotage?) 20:48
nope, still not building nqp 20:49
dalek ar: 72b0780 | pmichaud++ | docs/announce/2012.09:
Update release announcement a bit (to avoid copying error into next month's release).
20:54
20:55 whiteknight left
pmichaud star 2012.09 released 20:58
ggoebel pmichaud++ 21:00
21:04 kaare__ left 21:08 flussence left 21:11 replore_ joined
sirrobert r: sub foo (:$str) { say $str; }; foo str=>'bar'; foo 'str' => 'baz'; 21:13
p6eval rakudo 3d31af: OUTPUT«bar␤Too many positional parameters passed; got 1 but expected 0␤ in sub foo at /tmp/YfQ_C9TkHY:1␤ in block at /tmp/YfQ_C9TkHY:1␤␤»
sirrobert how can I pass a Str as a var name? 21:14
21:16 replore_ left
sirrobert n: sub foo (:$str) { say $str; }; foo str=>'bar'; foo 'str' => 'baz'; 21:16
p6eval niecza v22-6-g9e5350d: OUTPUT«bar␤Unhandled exception: Excess arguments to foo, used 0 of 1 positionals␤ at /tmp/0e8TeQvKa4 line 0 (foo @ 1) ␤ at /tmp/0e8TeQvKa4 line 1 (mainline @ 6) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4198 (ANON @ 3) ␤ at /home/p6eval/niecza/lib/CORE.se…
FROGGS r: sub foo (:$str) { say $str; }; foo str=>'bar'; foo( |('str' => 'baz') )
p6eval rakudo 3d31af: OUTPUT«bar␤baz␤»
sirrobert ooh... that's funky
thanks, FROGGS 21:17
FROGGS proud to help ;o)
sirrobert writing a nice li'l datetime math module =) 21:18
DateTime.new('1994-11-05T08:15:30-0500') - days=>4;
FROGGS little and datetime
sirrobert (and so on)
FROGGS is that possibleẞ
21:18 kurahaupo joined
sirrobert heh 21:18
FROGGS ?
sirrobert thankfully p6 validates dates inside the DateTime module 21:19
so I just have to creatively abuse that
but right now I can do: my $tomorrow = $today + d=>1;
21:19 kst joined
sirrobert <d day days dd> 21:20
FROGGS what about $today++?
sirrobert good idea
easy enough to implement, I'll just pipe the postfix:<++> to the method that handles infix:<+> with an arg of 1
metaphorical pipe =) 21:21
FROGGS ya
gnight
sirrobert night
21:45 ChoHag left 21:57 cognominal left 22:03 cognominal joined 22:10 tgt joined
raiph sirrobert: fyi: I posted a couple comments on 6ing.org 22:13
cognominal is there a hash composer in nqp? 22:22
it seems interpreted as a block 22:23
and the grammar hints as much : token circumfix:sym<{ }> { <?[{]> <pblock> } 22:25
22:27 spider-mario left
TimToady a hash composer is a block, it just gets called automatically 22:28
dunno if nqp does that though
cognominal I don't see anything in the action file that would interpret it as a hash 22:33
and, I don't remember seeing a hash composer in nqp ffiles.
sorear nqp-rx at least did not support any kind of hash literal syntax 22:35
22:41 PacoAir left 22:47 ChoHag joined 22:48 cognominal left, cognominal joined
[Coke] pmichaud: any suggestions on how to get at a top level sub by name in nqp? 22:51
the best alternative I have at this point is to put all those subs in as class methods on something. 22:52
22:58 cognominal left 23:02 ChoHag left 23:14 ChoHag joined 23:23 stepnem left
diakopter n: say ** 23:36
23:36 replore joined
p6eval niecza v22-6-g9e5350d: OUTPUT«Unhandled exception: System.NullReferenceException: Object reference not set to an instance of an object␤ at Niecza.StashCursor.Core (System.String key, Boolean final, Niecza.StashCursor& sc, Niecza.Variable& v, Niecza.Variable bind_to) [0x00000] in <filen… 23:36
sorear diakopter: you found that last week, too
diakopter oh :) I'd forgotten I guess
rn: my $a; BEGIN { $a = {a=>44}; }; die $a; CATCH { say 55 }; say 66 23:41
p6eval rakudo 3d31af: OUTPUT«a 44␤ in block at /tmp/6stTfrfaZh:1␤␤»
..niecza v22-6-g9e5350d: OUTPUT«55␤Unhandled exception: {"a" => 44}␤ at /home/p6eval/niecza/lib/CORE.setting line 1437 (die @ 5) ␤ at /tmp/_ZzBoz8Wgn line 1 (mainline @ 5) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4198 (ANON @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 419…
diakopter I suppose it's time I learn how catch works
why does niecza say 55 but rakudo doesn't 23:42
23:47 rindolf joined
rindolf Hi all. 23:47
diakopter o/ 23:48
rindolf diakopter: what's up?
23:49 replore left
diakopter atomics, fences, lock-free, parallelized 23:49
rindolf diakopter: where? 23:50
diakopter in my brain mostly