»ö« 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:00
shinobicl___ joined
00:05
Leiting joined
00:06
shinobicl___ left
00:08
Leiting left
|
|||
dalek | p: 2246b9d | jnthn++ | src/HLL/Grammar.pm: Fix preclim handling in operator precedence parser to be consistent with STD's semantics. |
00:09 | |
jnthn | pmichaud: Don't worry, 2246b9d helped. :) | 00:10 | |
dalek | kudo/stdinit: 4f23c1a | jnthn++ | src/Perl6/Actions.pm: Fix assign_op calls. |
||
00:11
pernatiy joined
|
|||
dalek | p/bs: 19f1639 | moritz++ | / (2 files): [bigint] fix detection of negative numbers from binary ops This should fix RT #109740 |
00:17 | |
p/bs: 2246b9d | jnthn++ | src/HLL/Grammar.pm: Fix preclim handling in operator precedence parser to be consistent with STD's semantics. |
|||
p/bs: 239b54f | jnthn++ | / (6 files): Merge branch 'master' into bs |
|||
jnthn | sleep & | 00:31 | |
00:33
lestrrat left,
lestrrat joined
00:34
tty234_ joined
00:37
lestrrat left
00:38
lestrrat joined,
tty234_ left
00:44
thou left
00:48
whiteknight joined
01:08
woosley joined
01:18
scott__ joined
|
|||
sorear | good * #perl6 | 01:23 | |
eviltwin_b: AIUI, line buffering of stdin never(well ok there are corner cases) affects semantics | 01:24 | ||
eviltwin_b: you may be thinking of stdout, which is line buffered if terminal, block buffered otherwise | |||
TimToady | getc works for single character input as long as you call 'stty raw -echo min 1 time 1' first (on *nix) | 01:30 | |
be sure to call 'stty sane' on the way back out though | |||
01:39
woosley left
01:41
woosley joined
01:48
tty234 left
|
|||
flussence | .oO( tty internals are the scariest thing I think I've ever encountered in *nix ) |
02:02 | |
eviltwin_b already pointed to "stty -g" which is a more accurate way to save and later restore tty settings | 02:03 | ||
02:05
replore joined
02:12
sudokode left
02:15
Chillance joined
02:29
sudokode joined
02:43
mls_ left,
mls joined,
kmwallio joined
02:44
wolfman2000 joined
02:49
whiteknight left
03:19
shinobicl___ joined
03:20
carlin left
03:24
lestrrat left
03:25
lestrrat joined
03:27
DarthGandalf left
03:33
DarthGandalf joined,
kmwallio left,
wooden left
03:37
aloha left
03:38
unobe left,
aloha joined
03:41
orafu left
03:42
orafu joined
03:50
unobe joined
04:18
[Coke] left
04:23
Su-Shee_ joined
04:25
wolfman2000 left
04:26
Su-Shee left
|
|||
skids | norole A [:$b] { has $.a = $b; }; my $a = 1; $a does A[:b(42)]; $a.a.say; my $b = 1; $b does A[:b(13)]; $b.a.say; $a.a.say;m: | 04:35 | |
erk. | |||
nom: role A [:$b] { has $.a = $b; }; my $a = 1; $a does A[:b(42)]; $a.a.say; my $b = 1; $b does A[:b(13)]; $b.a.say; $a.a.say; | |||
p6eval | nom 2251cb: OUTPUT«421313» | ||
skids scratches head. | |||
sorear | you used 'does' on a variable of type 'Int' | 04:36 | |
you've modified the literal constant 1 | |||
nom: my $a = 1; $a does role { method Str { "Suprise!" } }; say 1 | |||
p6eval | nom 2251cb: OUTPUT«Suprise!» | ||
sorear | did you really mean to modify a constant? | 04:37 | |
04:37
winnerdood joined
|
|||
benabik | I'm constantly surprised that but and does modify the variable in place rather than returning a new object. | 04:37 | |
sorear | benabik: does modifies in place | 04:38 | |
benabik | But I've been doing a _lot_ of functional programming. | ||
sorear | but returns a new object | ||
that's why we have two operators! | |||
skids | Ah, well that explains why $a.a changed then :-) | ||
benabik | I thought it was because does took a role and but takes a value. | 04:39 | |
TimToady | maybe we should remove does | ||
except as a trait declartor | 04:40 | ||
04:40
ponbiki joined
|
|||
moritz | o/ | 04:41 | |
sorear | benabik: Both take both forms. | 04:42 | |
04:42
shinobicl___ left
|
|||
benabik | sorear: Oh! | 04:42 | |
I've never seen that, but neat. | 04:43 | ||
04:48
winnerdood left
05:10
birdwindupbird joined
05:40
replore left
05:44
kaleem joined
06:16
thou joined
06:30
yertalert left
06:42
cognominal___ joined
06:44
cognominal_ left
06:47
overrosy left,
Vlavv` left,
ashleydev left,
etneg left,
kshannon left,
Gothmog_ left,
TimToady left,
Yappoko___ left
06:50
kaleem left
06:51
overrosy joined,
Vlavv` joined,
ashleydev joined,
etneg joined,
kshannon joined,
Gothmog_ joined,
TimToady joined,
Yappoko___ joined
06:54
kaleem joined,
wtw joined
06:57
zby_home left
07:59
ponbiki left
08:04
mj41 joined
08:11
tarch joined
08:12
Khisanth left
|
|||
dalek | ecza: 419e3bd | sorear++ | src/niecza: Change |$ to | in src/niecza |
08:14 | |
ecza: 05e3637 | sorear++ | src/Niecza (2 files): Allow defining extra operators in the setting, and implement an efficient way to load a bunch of operators into $~MAIN in one go |
|||
ecza: de81026 | sorear++ | lib/CORE.setting: First cut at enabling Set operators |
|||
08:20
aindilis left
08:23
snearch joined
08:27
Khisanth joined
|
|||
dalek | ecza: 891be08 | sorear++ | lib/CORE.setting: Switch Set and a few other things to at_key so that slicing works more sanely |
08:27 | |
bbkr1 | JSON::RPC is back on nom, including client and server 2.0 spec :) | 08:29 | |
sorear | Yayness. | 08:30 | |
bbkr1 | moritz: your fallback hint worked perfectly - github.com/bbkr/jsonrpc/blob/maste....pm#L10-35 - thanks! Now it's the easiest client to use ever. | ||
08:31
Su-Shee_ is now known as Su-Shee
|
|||
sorear | std: constant Set term:<∅> = set(); | 08:41 | |
p6eval | std 48335fc: OUTPUT«===SORRY!===Missing initializer on constant declaration at /tmp/BUnxDw3qZd line 1:------> constant Set ⏏term:<∅> = set();Confused at /tmp/BUnxDw3qZd line 1:------> constant Set ⏏term:<∅> = set(); expecti… | ||
08:49
birdwind1pbird joined
|
|||
masak | g'morning, #perl6 | 08:53 | |
dalek | ecza: df96012 | sorear++ | lib/CORE.setting: Eliminate is equiv on multi candidates; niecza should carp on this but doesn't yet. Also, forgot term:<∅>. |
08:54 | |
sorear | g'masak morning. | ||
niecza: 1 | |||
p6eval | niecza v14-23-g0699296: ( no output ) | ||
sorear | evalbot rebuild niecza | ||
p6eval | OK (started asynchronously) | ||
dalek | Rebuild of niecza complete. | 08:56 | |
Timbus | oh god they're like telepathically linked twins that complete each others sentences | ||
and that is just creepy | 08:57 | ||
sorear | niecza: say set(2,3,4) ∩ set(3,4,5) | ||
p6eval | niecza v14-28-gdf96012: OUTPUT«set(3, 4)» | ||
masak | but creepy-good, right? :) | 08:58 | |
sorear shows off the new functionality ^^^ | |||
masak | ooh, ∩! | ||
sorear | niecza: say ∅ | 08:59 | |
p6eval | niecza v14-28-gdf96012: OUTPUT«set()» | ||
masak | niecza: say (2,3,4) ∩ (3,4,5) | ||
p6eval | niecza v14-28-gdf96012: OUTPUT«set(3, 4)» | ||
masak | \o/ | 09:00 | |
niecza: say (2,3,4) (&) (3,4,5) | |||
p6eval | niecza v14-28-gdf96012: OUTPUT«set(3, 4)» | ||
masak | (\o/) | ||
sorear | niecza: say (2,3,4) [&] (3,4,5) | ||
Timbus | oh good, i can type that | ||
p6eval | niecza v14-28-gdf96012: OUTPUT«Potential difficulties: Useless use of [] around infix op at /tmp/4AwqQzX3B_ line 1:------> say (2,3,4) ⏏[&] (3,4,5)all((2, 3, 4), (3, 4, 5))» | ||
Timbus | why not allow 'n' and 'u' | 09:01 | |
i guess its not that common to use them | 09:02 | ||
sorear thinks (&) should require more keypresses than ++ | |||
masak counts 4 for (&) and 3 for ++ | 09:03 | ||
oh, but you meant as opposed to n which requires 1. I see. | |||
yeah, I feel 'n' and 'u' are "too cute", perhaps. | 09:04 | ||
if you want them, they're two lines of code. | |||
sorear | 6 for ∩ ... I need a better input method | ||
09:04
daxim joined
|
|||
sorear | ctrl shift 2 2 2 9, mnemonic is not | 09:05 | |
Timbus | true enough, i just cant see any harm in allowing them | ||
sorear --> sleep | 09:06 | ||
09:08
mtths joined
09:09
[particle] left
09:14
snearch left
|
|||
dalek | ecs: 0c822b5 | masak++ | S32-setting-library/Exception.pod: [S32/Exception] corrected typo Spotted by Util++. |
09:16 | |
masak | I should make a Perl 6 input method for irssi, and then share it with everybody else. :) | 09:21 | |
[backlog] +1 on removing 'does' as an operator, especially since it's basically but= | 09:25 | ||
tadzik | hrm, I quite like does | 09:31 | |
09:35
flussence left,
flussence joined
09:50
alvis joined
09:51
woosley left,
dakkar joined
|
|||
masak | this course intrigues me: courses.csail.mit.edu/6.851/spring12/ -- and both notes and videos upcoming. nice! | 09:53 | |
jnthn | morning, #perl6 | ||
masak | love the colored notes! | ||
jnthn! \o/ | |||
jnthn: what *day* is it today? :D | |||
jnthn | NS day! | ||
er | |||
masak | :P | ||
jnthn | Thursday? | ||
Perl 6 day! \o/ | |||
masak | Perl 6 day! \o/ | ||
jnthn | The memory hierarchy section of courses.csail.mit.edu/6.851/spring12/ is certainly relevant to anyone working in VM/language implementation space, I suspect. | 09:55 | |
jnthn will have to at least check that one out. | |||
er, does is *not* but= | |||
masak | oh :/ | 09:57 | |
jnthn | does modifies the *object* in place. Assignment is all about scalar containers. | 09:58 | |
09:59
thou left
|
|||
masak | hm, yes. | 10:03 | |
but if I do 'my $obj = MyClass.new; $obj but= MyRole', there's never more than one instance, is there? | 10:04 | ||
moritz | but clones first | 10:05 | |
jnthn | masak: Yes, but in this case you immediately throw it away | 10:06 | |
my $obj = MyClass.new; my $orig = $obj; $obj but= MyRole; | |||
In the above $orig doesn't have the role, but still exists | 10:07 | ||
my $obj = MyClass.new; my $orig = $obj; $obj does MyRole; | |||
Now $orig and $obj (which of course point to the same object) have the role | |||
Well, one object has the role but two containers point to it | |||
Grr, not enough coffee to explain stuff | |||
masak | right. I see it now. | ||
while I appreciate the distinction, it might be that it's too confusing to have both behaviors. people seem to get 'does' and 'but' mixed up. | 10:08 | ||
Su-Shee | good morning everyone. | 10:09 | |
jnthn | masak: I'd rather fix the naming that lose functionality | ||
*tyhan | |||
oh, screw it, I'm going to make some coffee | |||
o/ Su-Shee | |||
masak | Su-Shee! \o/ | 10:10 | |
10:11
scott__ left
|
|||
tadzik | hello :) | 10:11 | |
10:12
overrosy left
|
|||
masak | tadzik! \o/ | 10:14 | |
10:15
overrosy joined
10:22
kaleem left
|
|||
moritz | bbkr1: good to hear that the fallback worked. | 10:30 | |
10:35
[particle] joined
10:39
Trashlord left
10:40
Trashlord joined
|
|||
jnthn | ok, now I'm more caffienated :) | 10:42 | |
moritz: stdinit may be worth a spectest run. As far as I know, only two test files are busted, and it's becuase somehow my $x = [=>] 1,2,3; style things are | |||
(combo of [=>] reduction and assignment) | 10:43 | ||
moritz: Also your $*HAS_SELF stuff should work on top of this branch :) | 10:48 | ||
moritz | jnthn: does it require a newer nqp? | 10:55 | |
10:55
kfo left
|
|||
jnthn | moritz: Requires the preclim patch I did yesterday, yeah | 10:56 | |
moritz: oh, but I forgot to bump NQP_REVISION | |||
moritz | ok | 10:58 | |
11:03
mtk left
11:14
birdwind1pbird left,
lestrrat left
11:15
lestrrat joined
11:18
lestrrat left
11:19
lestrrat joined
11:25
jaldhar left,
ab5tract joined
11:30
ab5tract left
11:31
ab5tract joined
11:34
au left
11:58
fasad joined
|
|||
fasad | std: sqrt( 3++ ); | 11:59 | |
p6eval | std 48335fc: OUTPUT«ok 00:01 108m» | ||
fasad | rakudo: sqrt( 3++); | ||
p6eval | rakudo 2251cb: OUTPUT«Cannot assign to a non-container» | ||
fasad | :( | ||
niecza: sqrt ( 3++ ); | |||
p6eval | niecza v14-28-gdf96012: OUTPUT«Unhandled exception: Writing to readonly scalar at /tmp/N1CYVd6L9q line 1 (mainline @ 2)  at /home/p6eval/niecza/lib/CORE.setting line 3746 (ANON @ 3)  at /home/p6eval/niecza/lib/CORE.setting line 3747 (module-CORE @ 65)  at /home/p6eval/niecza/lib… | ||
fasad | :( | 12:00 | |
pugs: sqrt( 3++ ); | |||
p6eval | pugs b927740: OUTPUT«*** Can't modify constant item: VInt 3 at /tmp/CC0SR6oAV0 line 1, column 7-11» | ||
jnthn | fasad: There's this other operator that will work on literal values, "+1" :) | ||
perl6: say sqrt(3+1) | |||
p6eval | pugs b927740, rakudo 2251cb, niecza v14-28-gdf96012: OUTPUT«2» | 12:01 | |
jnthn | ;) | ||
fasad | what does the rakudo error mean ? | ||
jnthn | fasad: What you can't assign to something if it's not a container | ||
*That | |||
++ expects to get a variable | |||
fasad | jnthn: yeah, but ++ is supposed to work (?) | 12:02 | |
jnthn | nom: my $a = 3; $a++; say $a | ||
p6eval | nom 2251cb: OUTPUT«4» | ||
jnthn | Works fine. | ||
You can't do 3++ because you'd be trying to modify the number 3 | 12:03 | ||
Which is a constant/literal. | |||
fasad | std says the sqrt( 3++ ) is correct syntax | ||
*that | |||
jnthn | Sure | ||
It's fine *syntax*. | |||
It's not semantically correct, though. | |||
fasad | oh ! duh. | 12:04 | |
jnthn | std: class A { }; A.does_not_exist | ||
p6eval | std 48335fc: OUTPUT«ok 00:01 107m» | ||
fasad | ! | ||
jnthn | That's another example of fine syntax. But won't work if you run it :) | ||
12:05
bluescreen10 joined
|
|||
fasad | perl (v5) is an interpreter; perl6 (rakudo) is... ? | 12:08 | |
i mean there is a virtual machine in between rakudo and the machine, so what does it make rakudo? | 12:10 | ||
jnthn | A compiler. | ||
It compiles your program into code for the virtual machine. | |||
moritz | fasad: both p5 and Rakudo (and basically all modern implementations of dynamic languages) are a hybrid between compiler and interpreter | 12:11 | |
fasad: the distinction blurs | |||
fasad: though rakudo is maybe a bit more compiler-y. Hard to tell. | |||
jnthn | Yeah. It's not such a useful distinction once you start asking interesting questions about what's really going on :) | 12:12 | |
fasad | hmm. Is gcc a "pure" compiler? | ||
moritz | in particular, both p5 and p6 need the facility to execute code at compile time (more than just constant folding) | ||
jnthn | The virtual machine itself may be doing either interpretation or (JIT/AOT) compilation. | 12:13 | |
moritz | fasad: much more so than rakudo and parrot | ||
fasad: but it also provides some runtime library stuff, so it's not 100% "pure" compiler | |||
fasad | jnthn: AOT ? | ||
moritz | ahead of time compilation | 12:14 | |
masak | perl6: say exp(pi * sqrt 163) - 640320 ** 3 | ||
p6eval | rakudo 2251cb: OUTPUT«-12032460128» | ||
..pugs b927740, niecza v14-28-gdf96012: OUTPUT«256» | |||
masak | neither of those results correspond to en.wikipedia.org/wiki/Complex_multi...onsequence | ||
moritz | nom: say exp(pi * sqrt 163) | 12:15 | |
p6eval | nom 2251cb: OUTPUT«2.62537400608308e+17» | ||
masak | loss of precision, most likely. | 12:16 | |
moritz | perl6: 640320 ** 3 | ||
p6eval | pugs b927740, rakudo 2251cb, niecza v14-28-gdf96012: ( no output ) | ||
moritz | perl6: say 640320 ** 3 | ||
p6eval | pugs b927740, rakudo 2251cb, niecza v14-28-gdf96012: OUTPUT«262537412640768000» | ||
moritz | masak: but it's worrysome that the numbers diverge so much | ||
nom: say 262537412640768000.Num | |||
p6eval | nom 2251cb: OUTPUT«2.62537412640768e+17» | ||
masak | niecza: say exp(pi * sqrt 163) | ||
p6eval | niecza v14-28-gdf96012: OUTPUT«2.6253741264076826E+17» | ||
masak | Niecza carries a few more significant digits, is all. | 12:17 | |
so it fares better. | |||
dalek | p/bs: ffeec9c | jnthn++ | src/6model/serialization.c: Set SC on objects as we deserialize them. |
||
p/bs: 7275a66 | jnthn++ | src/6model/serialization.c: Serialize/deserialize v-table and method cache from STable. |
|||
p/bs: 2ea450f | jnthn++ | src/6model/serialization.c: Introduce concept of a cloned code reference; this will be used when implementing closure serialization. |
|||
masak | still, 256 isn't so close to the expected 744, either... | 12:18 | |
moritz | jnthn: I can confirm your results from spectesting stdinit | 12:19 | |
jnthn | moritz: OK. So just the reduction operator thingy to fathom. | ||
moritz | jnthn: right, and bumping NQP_REVISION | 12:21 | |
jnthn | moritz: Feel free to pull your $*HAS_SELF patch into that branch too, or some other way to try them in combination. | ||
moritz: I'm pretty sure the "has $!x = $!y" issues are now fixed. | |||
moritz | jnthn: I'll try it | ||
colomon | niecza: say "a" ∈ <a b c d e> | ||
p6eval | niecza v14-28-gdf96012: OUTPUT«Unhandled exception: System.Collections.Generic.KeyNotFoundException: The given key was not present in the dictionary. at System.Collections.Generic.Dictionary`2[System.String,Niecza.P6any].get_Item (System.String key) [0x00000] in <filename unknown>:0 … | 12:22 | |
colomon | ! | ||
jnthn | If Pm shows up today, maybe he'll have some hints on the reduction issue. | ||
(or feel free to poke if you've got any ideas) | |||
I can't quite figure out how STD gets it right. | |||
colomon | p6eval: rebuild niecza | 12:23 | |
dalek | kudo/nom: 828e4d6 | moritz++ | src/core/Exception.pm: allow numification of X::AdHoc This is a bit questionable, but a spectest requires it In the end we might want to make X::Adhoc a wrapper around a payload, and only use the stringification for HLL interop. |
12:24 | |
moritz | evalbot rebuild niecza | ||
p6eval | OK (started asynchronously) | ||
dalek | Rebuild of niecza complete. | ||
moritz | jnthn: it's a parse issue? | ||
the error comes from REDUCE_METAOP_RIGHT where it tries to invoke infix:<=>> with one argument | 12:25 | ||
jnthn | moritz: Yes, precednece issue in parsing | 12:26 | |
my $x = [+] 1,2,3; say $x | |||
That also shows it much more simply. | |||
It stops parsing at the , for some, because of the precedence limit. | 12:27 | ||
s/for some,// | |||
masak | because the = imposes scalar assignment? | 12:30 | |
moritz | the precedence limit from infix:<=> ? | ||
masak | inneresting -- that's correct from the viewpoint of the infix:<=>, but the [+] creates a new parsing context "one level down", so to speak, which should lift that constraint. | 12:32 | |
jnthn | moritz: Correct | ||
masak: Yes, and I fail to see where STD does that. | |||
masak | std: my $x = [+] 1, 2, 3; | 12:33 | |
p6eval | std 48335fc: OUTPUT«ok 00:01 112m» | ||
12:33
pernatiy left
|
|||
masak | clearly it does that, though. | 12:33 | |
moritz | well no | ||
it wouldn't syntax-error | |||
jnthn | right | ||
moritz | (my $x = [+] 1), 2, 3 is also valid p6 | 12:34 | |
jnthn | std: (my $x = [+] 1), 2, 3 | ||
p6eval | std 48335fc: OUTPUT«ok 00:01 113m» | ||
jnthn | yeah, and the 2 and 3 ain't warned about | ||
masak | huh. | ||
indeed. | |||
jnthn | Well | ||
I'm only guessing STD gets it right because Niecza does | |||
It's possible Niecza has got something STD hasn't got here. | 12:35 | ||
masak | check how Niecza does it :) | ||
jnthn wonders if :sub<e=> in %list_prefix would fix it | |||
12:35
am0c joined
|
|||
jnthn | or in reduce at least | 12:35 | |
12:36
am0c left
|
|||
jnthn | alas, no | 12:39 | |
moritz | do prefixes generally reset the prec limit? | ||
jnthn | Don't believe so | 12:40 | |
masak just had an insight: unary prefixes are very loose on the term level, and list prefixes are very loose on the expression level | 12:41 | ||
12:53
tarch left
12:58
au joined
|
|||
cognominal___ | I was discussing with rgs and elbeho on #perlfr about Mathematica. I note something which is interesting for people fearing typing weird symbol. Expressions have a fullform and a short form. In the full form, everything is expressed like C functions except as bracket instead of parentheses. | 13:02 | |
The programmer types code in a form that is a mix of full and short form. | |||
Example of short from : a*b + c | 13:03 | ||
Coreesponding full form: Plus[Times[a,b],c] | 13:04 | ||
Operators which are unicode can be typed in full form to avoid unicode but will eventually appear in short form | 13:06 | ||
reference.wolfram.com/mathematica/t...guage.html | |||
flussence | I guess in vim you could write a bunch of ":imap <Leader>intersect ∩" lines too | 13:12 | |
masak | not a bad idea. | ||
and then have the same shortcuts in irssi... :) | 13:13 | ||
flussence | though with that you have to type the entire thing in one go without a single typo or it aborts, so maybe not for everyone :) | ||
masak | oh. | ||
maybe something more like \cap in TeX? | 13:14 | ||
cognominal___ | You don't have to type: a*b+c in longform though | ||
Before knowing about compiler internals, I probably got from Mathematica the idea that program are really not lines but trees. | 13:16 | ||
moritz | +1 to exposing all set operations as (ASCII-named) methods (or subs) | 13:17 | |
cognominal___ | Chomsky would talk about surface syntax, but I am not sure TimToady likes Chomsky too much. | 13:18 | |
moritz: that could be a trait. | |||
masak | I never fully bought into the concept of surface syntax. it seems to have contradictory meanings in the literature. | 13:19 | |
moritz | cognominal___: a trait? how so? | ||
cognominal___ | …specifying how to go form the long form to the short one. how so, not to sure yet. | 13:21 | |
flussence | macros :) | 13:22 | |
cognominal___ | In mathematica that's a tree pattern matching transformation. | ||
flussence | (and I think maybe it should be the other way around, latin-1 should be the canonical form and unicode should be the sugar on top) | 13:23 | |
cognominal___ | With signatures, we do pattern matching already except they are expressed in a weird "short form". | 13:24 | |
13:25
skids left
|
|||
moritz | Mathematica is very Lisp-y under the hood | 13:25 | |
cognominal___ | Well perl has always been about short forms except TimToady calls that huffman coding. | ||
I think Mathematica as a cross of Lisp and Prolog. | 13:26 | ||
moritz | ProLisp :-) | ||
cognominal___ | Should go Back in 2 or 3 hours | 13:27 | |
masak | there's two sides to Huffman coding. sometimes things get longer names because of it, too. | ||
13:29
ab5tract left
|
|||
arnsholt | masak: As (more or less) a linguist, I don't really buy the Chomskian deep/surface distinction either =) | 13:31 | |
If it's any consolation | |||
masak | it is. it mostly serves to confuse me. | 13:32 | |
as a computer scientist, I don't see it having rigour enough. | |||
dalek | kudo/stdinit: 7b6cf5d | moritz++ | src/ (3 files): Merge remote branch 'origin/has-self' into stdinit |
||
kudo/stdinit: 48c50ff | moritz++ | tools/build/NQP_REVISION: bump NQP revision to get preclim fix |
|||
arnsholt | Yeah, that's my main beef with Chomskian linguistics in general | ||
jnthn | moritz: has $!y = $!x # works in stdinit? | 13:33 | |
arnsholt | They make a great issue of economy and some vague notion of "possible to compute", but Chomskian linguistics are pretty much completely absent from NLP/compling | ||
Transformational syntax is just too hairy to implement as a computer program | 13:34 | ||
(Only counter-example I can think of is something called tree-adjoining grammar, but that's pretty old) | |||
moritz | jnthn: I haven't tested it specifically, but the merge only added passing TODOs to the spectest run, so I guess "yes" | 13:35 | |
13:35
pernatiy joined
|
|||
jnthn | moritz: yay | 13:36 | |
So, just need to fathom this reduce thingy and then it can be merged. | |||
Am working on the serialization bits at the moment, though. | |||
arnsholt | And speaking of unicode operators and vim, it should be possible to set up imaps so that the texas operators are magically transformed into unicode ops | ||
13:37
benabik left
|
|||
moritz | jnthn: yes, works | 13:39 | |
jnthn | \o/ | 13:41 | |
masak | arnsholt: that might go wrong, though. think of %h<bar>».foo -- I wouldn't want vim to turn that into %h<bar»>.foo | 13:49 | |
arnsholt | Oooh, good point | ||
moritz | jnthn: yes, works | 13:50 | |
jnthn | moritz: The same thing you told me works 11 minutes ago? ;) | 13:51 | |
moritz | jnthn: now Ronja told you :-) | ||
jnthn | :D | ||
masak | she's getting much better at typing words. | 13:52 | |
13:52
ajox joined
|
|||
moritz | amazing, isn't it? she must have learned a lot from me :-) | 13:56 | |
13:58
[Coke] joined
14:00
mtk joined
14:03
ab5tract joined
|
|||
dalek | ecza: 6a63017 | (Solomon Foster)++ | lib/CORE.setting: Restore the immutability of Set and Bag. |
14:23 | |
14:23
chra left
14:24
chra joined
|
|||
masak | colomon: an interesting case of how easy it is to accidentally break encapsulation by handing out references through accessor methods. | 14:26 | |
14:27
tarch joined,
birdwind1pbird joined
|
|||
colomon | masak: yup | 14:27 | |
14:30
etneg_ joined,
Vlavv` left,
Gothmog_ left,
etneg left,
Gothmog_ joined,
Vlavv` joined
|
|||
dalek | ast: 8f304c2 | (Solomon Foster)++ | S02-types/key (2 files): Unfudge tests that work after sorear++'s changes last night. |
14:31 | |
14:36
birdwindupbird left
14:44
skids joined
|
|||
skids | which git branch to use for most functional REPR stuff, e.g. CStruct? | 14:49 | |
masak | nom, I think. | 14:50 | |
jnthn | Right. | ||
Note the implementation of CStruct actually lives in the NQP repo | 14:55 | ||
skids | Will nom fetch the newest with --build-nqp? | 14:56 | |
erm, --gen-nqp? | |||
14:57
PacoAir joined
|
|||
jnthn | skids: It'll fetch recent enough (more) | 14:57 | |
There hasn't been any additions to CStruct et al in the last couple of weeks | 14:58 | ||
14:58
unobe left
|
|||
skids | Thanks, jnthn++ | 14:59 | |
14:59
birdwind1pbird left,
unobe joined
15:10
tty234 joined
15:23
kaleem joined
15:26
GlitchMr joined
|
|||
moritz | but if you want to patch stuff, you should 'git checkout master; git pull' in nqp before you start | 15:29 | |
15:30
kaleem left
|
|||
[Coke] | # 02/09/2012 - niecza at 99.64% | 15:30 | |
"niecza", 19553, 150, 732, 1582, 22017, 22863 | |||
"rakudo", 19623, 32, 616, 1977, 22248, 22873 | |||
sorear, colomon: note that niecza has 150 failures atm. | 15:31 | ||
moritz | [Coke]++ # test statistics, feeding the friendly competition | ||
masak | nom: sub postfix:<%>($n) { $n / 100 }; say "Rakudo at {(1/99.64% * 100).fmt("%6.2f")}%" | 15:32 | |
p6eval | nom 828e4d: OUTPUT«Rakudo at 100.36%» | ||
moritz | masak: could I add you as possible mentor for the custom sprintf implementation in wiki.enlightenedperl.org/gsoc2012/ideas ? | 15:33 | |
masak | yes. | ||
[Coke] | the detailed reports are at feather.perl6.nl/~coke/ *.out | 15:35 | |
jnthn | hmm, I need to review that multi dispatch one | ||
I did a bunch of the work there already | |||
moritz | jnthn: btw rakudo commit 33fb020a12b6eccc2b1e0118d9c1a362ecd27d39 contains a commented-out multi method that causes circularity | 15:37 | |
I wonder if that's legit | 15:38 | ||
jnthn | Unlikely | 15:39 | |
(unlikely to be legi) | |||
*legit | |||
PerlJam | There's only 3 gsoc ideas for Rakudo? | ||
[Coke] | rakudo is haaaaaaard. | 15:40 | |
PerlJam | given the number of Perl projects under the TPF moniker, it seems unlikely that Perl 6 will get much love. | 15:42 | |
15:42
kaleem joined
|
|||
moritz | PerlJam: so far we've always got enough slots for Perl 6 projects, once we had interested and good students | 15:43 | |
15:44
Psyche^ joined
|
|||
PerlJam | well, that's really the trick anyway, isn't it? Finding good students. | 15:44 | |
dalek | p/bs: b06857a | jnthn++ | src/6model/reprs/P6opaque.c: P6opaque should ensure its REPR data is calculated before any serialization of it takes place. |
15:45 | |
p/bs: f6f2e8a | jnthn++ | t/serialization/03-closures.t: Add initial test for handling of cloned code refs (not testing outer handling yet, though - just very simple case of cloning). |
|||
p/bs: f31afe1 | jnthn++ | src/6model/serialization. (2 files): Initial changes to add a closures table. |
|||
p/bs: 317ff89 | jnthn++ | src/6model/serialization. (2 files): Start sketching out cloned code ref serializtion, in prep for really doing closure support. |
|||
p/bs: b81e767 | jnthn++ | src/6model/serialization.c: Add initial code for deserializing a row from the closures table; this will eventually grow to be the full closure deserialization, but doing something much simpler for now. |
|||
p/bs: be303bd | jnthn++ | t/serialization/03-closures.t: Update test case to actually really use the static code object. |
|||
p/bs: bf9b58e | jnthn++ | src/pmc/nqplexinfo.pmc: Get NQPLexInfo to remember the Sub it is attached to. |
|||
p/bs: 664e87c | jnthn++ | src/6model/serialization.c: Locate static code ref that a closure is based on, plus a few other fixes. First tests for cloned code objects now pass; this is the first pre-requisite for closure serialization done. |
|||
PerlJam starts crafting an appropriate email to the local CS club about the GSoC | |||
[Coke] should really do better outreach to the local schools. (RPI is one of the locals, I should really be able to find someone there. ;) | 15:46 | ||
15:47
Patterner left,
Psyche^ is now known as Patterner
|
|||
[Coke] | what does the bs in nqp/bs stand for? | 15:50 | |
tadzik | Boom! Serialization! | ||
PerlJam | "I can't be bothered to come up with a real name" :) | ||
tadzik | Multiple Dispatch Optimization in Rakudo -- isn't this already done by jnthn++? | 15:51 | |
15:51
kaare_ joined
|
|||
flussence | I guess the b is binary | 15:51 | |
tadzik | bounded | ||
flussence | .oO( as opposed to xml serialisation... ew. ) |
||
15:57
kaleem left
16:02
benabik joined
|
|||
jnthn | bounded serialization :) | 16:04 | |
16:04
yertalert joined
|
|||
masak | tadzik: yes, but the project suggestions are from last year. | 16:07 | |
tadzik | yeah, I think so | ||
well, sprintf is new | |||
masak | tadzik: it's likely that it can be updated to do even cooler optimizations. | ||
tadzik sniffs for a nice task for this year | |||
jnthn | Yeah, I'm pondering the best way to update that task :) | 16:08 | |
colomon | [Coke]: I already sent a list of failing test files to sorear++ via e-mail. :) | 16:14 | |
16:18
wtw left
|
|||
TimToady | Ooh, set ops, shiny! Used to be I couldn't spell mathmatishun, and now ir1. | 16:20 | |
16:25
mj41 left
16:32
Trashlord left
|
|||
masak | niecza: say "a" ∈ <a b c d> | 16:36 | |
p6eval | niecza v14-29-g6a63017: OUTPUT«Unhandled exception: System.Collections.Generic.KeyNotFoundException: The given key was not present in the dictionary. at System.Collections.Generic.Dictionary`2[System.String,Niecza.P6any].get_Item (System.String key) [0x00000] in <filename unknown>:0 … | ||
masak | something the matter there, though. | ||
16:37
Trashlord joined,
benabik left
16:43
fasad left
16:46
kaleem joined
|
|||
TimToady | maybe we need a sqrt(Rat, :precision) that returns a Rat | 16:47 | |
.oO(square rats) |
16:48 | ||
or some variant of ** that returns a Rat | 16:49 | ||
masak | could anon slurpy arrays *@ be made lazy? | 16:52 | |
sorear | good * #perl6 | ||
TimToady | o/ | ||
masak | sorear! \o/ | 16:53 | |
sorear | TimToady: sqrt(2).Rat(1e-9) isn't enough? | ||
TimToady | irclog.perlgeek.de/perl6/2012-02-09#i_5123826 | ||
masak: maybe it's too early, or too late, but I can't picture what you're asking | 16:54 | ||
jnthn | masak: Lazy as in, just throw away the rest of the values? | ||
masak: Rather than actually make an array? | |||
Though Rakudo may do that already... | |||
masak | jnthn: right. | ||
so you can pass lazy, potentially infinite lists to the sub. | 16:55 | ||
jnthn | masak: But you should already be able to do that for the named ones... | ||
masak | I was looking at the first example of en.wikipedia.org/wiki/Corecursion#Discussion | ||
and thinking how to port it to Perl 6. | |||
nom: sub fibgen { $^x, fibgen $^y, $x + $y }; .say for fibgen 0, 1 | |||
p6eval | nom 828e4d: OUTPUT«maximum recursion depth exceeded in sub fibgen at /tmp/UI8CzVd3TC:1 in sub fibgen at /tmp/UI8CzVd3TC:1 in sub fibgen at /tmp/UI8CzVd3TC:1 in sub fibgen at /tmp/UI8CzVd3TC:1 in sub fibgen at /tmp/UI8CzVd3TC:1 in sub fibgen at /tmp/UI8CzVd3TC:1 in sub fibg… | ||
sorear | masak: (backlog) I'd be +1 to dehuffmanizing does, perhaps to .APPLY_ROLE_IN_PLACE (lc?) or something like that | 16:56 | |
masak | sorear: sounds good. | ||
sorear | making it a (meta?) method would hint at the fact that it mutates the object | ||
masak | sorear: meta sounds about right for it. | ||
jnthn | Doesn't need to be uppercase. It's not *that* scary. | ||
masak | .^distort | 16:57 | |
TimToady | I was completely unsuccessful in getting hamming recursion to work last night on either niecza or nom | ||
.oO(use MONKEY_DOES) |
|||
jnthn | masak: huh | ||
.^mixin | |||
Call it what it does! | |||
masak | ooh | ||
jnthn | We don't need to make new words for everything :) | ||
PerlJam | jnthn: +1 | ||
masak | I didn't think of that you can verb 'mixin'. | ||
jnthn | Surely it's a nonification of "to mix in" ;) | 16:58 | |
16:58
thou joined
|
|||
jnthn | nom: class A { }; role R { method foo() { 42 } }; my $a = A.new(); $a.^mixin(R); say $a.foo | 16:58 | |
p6eval | nom 828e4d: OUTPUT«42» | ||
jnthn | It even works already. :) | ||
sorear | masak: "interesting case" - red herring. Niecza still treats all methods as 'is rw', which is the problem here | 16:59 | |
16:59
fsergot joined
|
|||
fsergot | o/ | 16:59 | |
masak | sorear: oh! I considered whether that might be part of it. | 17:00 | |
sorear | o/ | ||
TimToady | perl6: constant @foo = 1, @foo; say @foo[3] | 17:01 | |
p6eval | pugs b927740: OUTPUT«pugs: *** Undeclared variable: ("@foo",MkPad (padToList []),[PCompiling {pc_pad = MkMPad {mp_id = 140635094937585, mp_pad = <ref:0x7fe828ae7d99>}}]) at /tmp/HXoh5Rds_j line 1, column 20-24» | ||
..rakudo 828e4d: OUTPUT«===SORRY!===Variable @foo is not declaredat /tmp/RRmhwfflvi:1» | |||
..niecza v14-29-g6a63017: OUTPUT«Any()» | |||
masak | still, we've established that the *general* problem of DTRT with encapsulation of private data structures is unsolvable, or at least never solved satisfactorily in a language with assignment. | ||
TimToady | perl6: my @foo; @foo.push: 1, @foo; say @foo[3] | ||
p6eval | rakudo 828e4d, niecza v14-29-g6a63017: OUTPUT«Any()» | ||
..pugs b927740: OUTPUT«» | |||
masak decommutes | |||
jnthn | TimToady: iirc, we'd discussed ".plan" instead of ".push" to make cases like that work. | 17:03 | |
er, if I understand what you were after :) | |||
TimToady | er, right | ||
perl6: my @foo; @foo.plan: 1, @foo; say @foo[3] | |||
p6eval | rakudo 828e4d: OUTPUT«Method 'plan' not found for invocant of class 'Array'» | ||
..pugs b927740: OUTPUT«*** No such method in class Array: "&plan" at /tmp/8X_UxfXLnX line 1, column 10-28» | |||
..niecza v14-29-g6a63017: OUTPUT«Any()» | |||
jnthn | Hm. Seems we didn't implement .plan in Rakudo, though... | 17:04 | |
TimToady | still don't work though | ||
17:04
ajox left
|
|||
PerlJam | .plan ?? | 17:05 | |
daxim | perlmonks.org/index.pl?node_id=952765 | ||
17:09
kaleem left
17:10
benabik joined
17:12
MayDaniel joined
|
|||
[Coke] hopes kikuchiyo filed a bug report! | 17:12 | ||
jnthn sighs about Rakudo's list handling | |||
flussence | nom: my $s; for 1..10 {$s+=1/$_**2}; say $s | 17:13 | |
p6eval | nom 828e4d: OUTPUT«1.54976773116654» | ||
flussence | nom: my $s; for 1..10 {$s+=1/$_**2}; say $s.WHAT | 17:15 | |
p6eval | nom 828e4d: OUTPUT«Rat()» | ||
flussence | nom: my $s; for 1..358 {$s+=1/$_**2}; say $s.denominator | 17:16 | |
p6eval | nom 828e4d: OUTPUT«1449787577947121375205308609556609711535433536157696434138530380517766506486305567414633608794650140470225443769804050741336943542145049679650936206123191521214587589518173757956538010055687965209269408060586721810178407168365269586498897970105441515066452356030319783… | ||
flussence | nom: my $s; for 1..358 {$s+=1/$_**2}; say $s.denominator.chars | ||
p6eval | nom 828e4d: OUTPUT«304» | ||
flussence | 304 looks familiar... decimal exponent for the largest 32-bit float, I think | 17:17 | |
TimToady | it works find it Num arithmetic, if you cange the 1/ to 1e0/ | ||
*change | |||
flussence | nom: my $s; for 1..359 {$s+=1e0/$_**2}; say $s.denominator.chars | 17:18 | |
p6eval | nom 828e4d: OUTPUT«Method 'denominator' not found for invocant of class 'Num'» | ||
flussence | wha | ||
TimToady | Nums don't have denominators | ||
perl6: my $s; for 1..1000 {$s += 1e0/$_**2};say $s | 17:19 | ||
p6eval | niecza v14-29-g6a63017: OUTPUT«Use of uninitialized value in numeric context at /home/p6eval/niecza/lib/CORE.setting line 1221 (warn @ 3)  at /home/p6eval/niecza/lib/CORE.setting line 255 (Any.Numeric @ 6)  at <unknown> line 0 (ExitRunloop @ 0)  at /tmp/BEs41VM9GV line 0 (mainli… | ||
..pugs b927740: OUTPUT«1.6439345666815598031390580238222155896521» | |||
..rakudo 828e4d: OUTPUT«1.64393456668156» | |||
TimToady | niecza gets the correct answer, but you can't see it for the noise | 17:20 | |
PerlJam | pugs++ too | ||
TimToady | perl6: my $s = 0; for 1..10000 {$s += 1e0/$_**2};say $s | 17:21 | |
17:21
jaldhar joined
|
|||
p6eval | rakudo 828e4d: OUTPUT«1.64483407184807» | 17:21 | |
..pugs b927740: OUTPUT«1.644834071848059769806081833310310903538» | |||
..niecza v14-29-g6a63017: OUTPUT«1.6448340718480652» | |||
dalek | ecza: 7cb1d49 | sorear++ | lib/CORE.setting: Fix (elem) private method issue |
||
sorear out | |||
TimToady | nom: my $s; for 1..358 {$s+=1/$_**2}; say $s.WHAT | 17:26 | |
p6eval | nom 828e4d: OUTPUT«Rat()» | ||
moritz | daxim: thanks for the link, I've written a reply | ||
TimToady | is it really a FatRat in disguise? | ||
moritz | yes | 17:27 | |
in rakudo, each Rat is a FatRat :/ | |||
jnthn | moritz: Is there a (huge amount) more to a first crack at fixing that beyond "has Int $.numerator; has int $.denominator;" ? | 17:28 | |
moritz | jnthn: well, handling overflow | 17:29 | |
jnthn | ah, yes. | 17:30 | |
jnthn just checked the relevant part of S02 and is happy to see we don't auto-promote to FatRat :) | |||
17:31
Tedd1 left
|
|||
daxim | "rancorousness", hah | 17:31 | |
TimToady | and it's supposed to be Rat[Int,Uint64], actually | 17:32 | |
17:33
snearch joined
|
|||
TimToady | I don't know where moritz++ got 2**128 from... | 17:33 | |
but I like the way he replied better than the way I didn't :) | |||
17:34
Tedd1 joined
|
|||
jnthn | oh...the O(N**2) is not due to the iteration. *phew* | 17:35 | |
[Coke] | moritz++ | 17:36 | |
moritz | TimToady: memory gone wrong | 17:37 | |
niecza: say ( 1 / 2**65).WHAT | 17:41 | ||
p6eval | niecza v14-29-g6a63017: OUTPUT«Num()» | ||
moritz | jnthn: maybe if we make infix:</> sufficiently magic... | ||
and build the rest of the Rat arithmetic based on that instead of Rat.new | 17:42 | ||
dalek | ast: 355851a | (Solomon Foster)++ | S02-types/keybag.t: Make the multiple-element access tests stronger. |
17:53 | |
17:56
MayDaniel left
|
|||
moritz | niecza: my $f = FatRat.new(1, 1); my $r = 1.0; say ($f * $r).WHAT; say ($r * $f).WHAT | 17:56 | |
p6eval | niecza v14-29-g6a63017: OUTPUT«FatRat()FatRat()» | ||
flussence | perl6: say (1..'potato')[^10]; # www.reddit.com/r/programming/commen...to_potato/ | ||
moritz | so FatRat is contagious? | 17:57 | |
p6eval | rakudo 828e4d: OUTPUT«(timeout)» | ||
..niecza v14-29-g6a63017: OUTPUT«Unhandled exception: Cannot parse number: potato at /home/p6eval/niecza/lib/CORE.setting line 1359 (die @ 3)  at /home/p6eval/niecza/lib/CORE.setting line 3318 (ANON @ 10)  at /home/p6eval/niecza/lib/CORE.setting line 3320 (NumSyntax.str2num @ 4)  … | |||
..pugs b927740: OUTPUT«» | |||
TimToady | "The best approach to Perl 6 is to ignore it." --educated_foo | ||
.oO(if only he would...) |
|||
jnthn | No, no. "troll about" is a synonym of "ignore" these days :P | 17:58 | |
17:58
pernatiy left
|
|||
TimToady | yes, FatRat is contagious, which is why we try never to make one implicitly | 17:59 | |
17:59
fasad joined
18:02
retup-work joined
18:03
Teratogen left
18:09
dakkar left
|
|||
moritz | jnthn: is there a way to write a sub or block in the setting which is inlined? | 18:20 | |
jnthn | moritz: What do you mean by "inlined"? In the optimization sense? | 18:22 | |
moritz | jnthn: yes | ||
jnthn | moritz: The optimizer already takes care of some basic cases of that, but we're a bit limited in what we can do until we can serialize ASTs properly. | 18:23 | |
moritz: It already will inline things it knows how to when compiling CORE.setting, though. | |||
moritz | that's... vague | 18:24 | |
jnthn | moritz: For something more concrete, see add_inlining_info_if_possible in Actions.pm, and inline_call in Optimizer.pm. | 18:26 | |
18:27
tarch_ joined
|
|||
moritz | only single statements. That won't do for my purpose :( | 18:28 | |
18:29
tarch left
|
|||
jnthn | moritz: Yeah, it's very limited right now. | 18:29 | |
moritz: I can extend it a bit, I suspect. But given it's mostly going to get a lot easier to do when we have serialization (which I'm working on now) and AST being 6model objects (which is up afterwards) I don't want to write too much to throw away. | 18:30 | ||
moritz | jnthn: 's ok | 18:32 | |
jnthn | moritz: What's the use case, ooc? | ||
18:33
fasad left
|
|||
moritz | jnthn: I thought about a sub that takes two Rational-ish types, a numerator and a denominator, and automagically makes a FatRat, Rat or Num | 18:33 | |
jnthn | moritz: Do you expect a serious performance regression if you do it that way and we don't have inlining of it just yet? | 18:34 | |
moritz | jnthn: well, one additional call per arithmetic operation | ||
18:35
preflex_ joined,
preflex left
18:36
preflex_ is now known as preflex
|
|||
jnthn | moritz: We can probably stomach that for the time being, in return for corrector semantics. | 18:37 | |
18:40
tarch__ joined
18:44
tarch_ left
|
|||
dalek | p/bs: e4f5e80 | jnthn++ | t/serialization/03-closures.t: Add a failing test for closure serialization. |
18:45 | |
p/bs: 40269bf | jnthn++ | src/6model/serialization.c: Add a column to the closures table for the outer context. |
|||
p/bs: 9bdbaa1 | jnthn++ | src/6model/serialization. (2 files): Update serialize/deserialize code to set up for contexts table and data segment. |
|||
p/bs: 5ee3a41 | jnthn++ | t/serialization/03-closures.t: Correct test count. |
|||
jnthn | Time for dinner break. | ||
colomon | moritz: what would be the purpose of such a sub? shouldn't it just be Rat or Num? | 18:48 | |
or I guess my question is, what are the circumstances in which you'd want to choose between those three choices, given two Ints? | |||
moritz | colomon: I consider how to write all the numeric ops | 18:49 | |
my idea ist | |||
multi sub infix:<+>(Rational $a, Rational $b) { | 18:50 | ||
my Int $nu = ...; | |||
my Int $de = ... ; | |||
MAKE_NUMBER($nu, $de, $a.WHAT, $b.WHAT) | |||
} | |||
colomon | ah | ||
moritz | and depending on the actual types of $a and $b, that can return Rat, FatRat or Num | ||
colomon | though if you're going as far as Rational, there are a lot more choices than Rat and Num, right? | 18:53 | |
moritz | yes | ||
which means that we just need to make MAKE_NUMBER more general in the long run | |||
18:55
PZt left
|
|||
colomon | bonus points if you make the conversion to Num smarter than just $nu.Num / $de.Num.... | 18:55 | |
moritz | assuming that $nu and $de are already shortened, is there a smarter way? | 18:56 | |
18:56
PZt joined
|
|||
moritz | (or how do you call that? cancled out? /me bad at math English) | 18:57 | |
ah, cancled down probably | |||
18:58
MayDaniel joined
|
|||
eviltwin_b | mormalized? | 19:02 | |
er | |||
normalized | |||
19:06
birdwindupbird joined
19:13
cogno joined
19:15
zby_home_ joined
|
|||
colomon | moritz: sorry I got distracted. The case I'm worrying about is that $nu.Num or $de.Num maybe be Inf, but the ratio of the two parts would make a perfectly good Num. | 19:18 | |
moritz | colomon: oh right. Then it might make sense to divide them both by an appropriately large integer first | 19:20 | |
colomon | really, this seems like the sort of thing the bigint library ought to already be smart enough to do. :) | 19:21 | |
but yeah, dividing by an appropriately large integer would probably be an okay approach | |||
19:26
cogno left
19:27
pernatiy joined
|
|||
moritz | colomon: can you think of a different appraoch than dividing by a large int? | 19:32 | |
colomon | I was thinking more like $nu div $de, and only looking at ($nu % $de) / $de if needed | 19:36 | |
but you're likely to end up dividing the last expression by a large int if $de.Num == Inf, it's true... | 19:37 | ||
moritz | that sounds a bit cleverer, actually :-) | ||
19:37
bluescreen10 left
|
|||
PerlJam | I don't know what else the Swedes have contributed to the world, but right now I'm very thankful for swedish meatballs. | 19:39 | |
colomon | swedish meatballs++ | ||
tadzik | is that called 'shotbullars' or something like this? | 19:40 | |
moritz | tadzik: that's how it's pronounced, but it's spelled differently, iirc | ||
with kj in the beginning, or so | |||
tadzik | yeah, I don't recall seeing it written anywhere :) | ||
moritz | erm, just k | 19:41 | |
"köttbullar" it seems | |||
PerlJam | the only problem is that I don't have enough of them. | 19:42 | |
(But I guess that's really a blessing so I don't get fat from eating too much) | 19:43 | ||
moritz | PerlJam, colomon, tadzik: can I motivate you to write some strategies for the prisoner's dilemma? | ||
(see perlgeek.de/blog-en/perl-6/iterated...lemma.html for the details) | |||
colomon | moritz: I've been meaning to, but my tuits are completely messed up at the moment | ||
I'll make no promises, but I'll see what I can do. | |||
tadzik | moritz: certainly, counting from tomorrow :) | ||
(I have one last exam tomorrow on 8AM | 19:44 | ||
) | |||
moritz | \o/ | ||
tadzik | then I should be back to the usual slacking o^W^Whacking routine | ||
colomon is the only healthy person in his immediate family, meaning he is on childcare duty, supposedly also working a full time job, and is superhumanly tired | 19:45 | ||
tadzik | ouch | 19:46 | |
colomon.energy++ | |||
moritz | colomon: it's similar here, though I can reduce the "full time job" part as needed | ||
colomon | admittedly I'm messing around with Bags at the moment, because I don't have enough brainpower handy to do $work | ||
PerlJam | moritz: maybe | 19:47 | |
Though to do anything but someple simple I'd need time to play with it and time always seems to be in short supply | 19:48 | ||
s/someple/something/ # wow. | |||
19:49
daxim left,
bluescreen10 joined
|
|||
PerlJam | moritz: here's one now though: sub (:@theirs, *%) { +@theirs %% 2; } # :-) | 19:52 | |
pyrimidine | moritz: it's best not to feed the _foo, he never comes around | 20:01 | |
moritz | pyrimidine: I fear I can't resist at the moment :( | 20:02 | |
20:08
tarch__ left
|
|||
pyrimidine | moritz: I think he misses a major point. Where would Perl 5 be if Perl 6 never existed? Would perl 5.10 have happened? Would there be a Moose? | 20:09 | |
moritz | pyrimidine: there are a whole lot of points he is missing | 20:10 | |
pyrimidine | yup. he likes strawmen | ||
jnthn back from le dinner | 20:11 | ||
moritz | jnthn: was it French? :-) | 20:12 | |
jnthn | No, I just wanted to sound classy and stuff. | 20:13 | |
dalek | ecza: b1a1194 | (Solomon Foster)++ | lib/CORE.setting: Port KeyBag improvements back to Bag. |
20:20 | |
ast: 8d18a30 | (Solomon Foster)++ | S02-types/bag.t: 70 more tests for Bag. |
20:21 | ||
tadzik wonders if *Bags are Rakudo-stealable | 20:23 | ||
jnthn | Should be fairly possible :) | 20:24 | |
PerlJam wonders what it would take to silence the perl6-grouches of the world. | |||
masak | I hereby dub the person in any post about Perl 6 who writes the inevitable comment saying "Perl 6 is failing/a farce/irrelevant/worthless", or something to that effect, causing deeply nested comments from insiders and outsiders alike that never lead anywhere, "the sponge". | 20:25 | |
please consider carefully how much time you want to waste on the sponge. ;) | 20:26 | ||
jnthn | Is that the sponge I wash up with, or sponge pudding? | ||
PerlJam | jnthn: it's a dirty, nasty used sponge with bacteria oozing from it's insides. | 20:27 | |
jnthn | Eww. OK, 'cus wasting time on sponge pudding woulda been tempting. :) | ||
PerlJam | masak: I wasted just enough time to read the thread(s), but that was time I was going to waste doing something frivolous and non-coding anyway | 20:28 | |
masak | nodnod | ||
well, the time that sponges mostly suck up is if you enter a conversation with them. | |||
PerlJam starts down voting moritz's node because of the sponge he helped inflict upon us ;) | 20:30 | ||
s/node/nodes/ | |||
tadzik | colomon: why is %elems in github.com/sorear/niecza/blob/b1a1...ting#L2128 Bool? | 20:32 | |
Su-Shee | PerlJam: it would take a couple of cool projects out there for everybody to use. some must-haves. | 20:33 | |
tadzik | without the constraint the implementation passes tests on Rakudo | ||
colomon | tadzik: because I copied and pasted without noticing that, and apparently niecza doesn't check | ||
tadzik++ | |||
tadzik | :) | ||
applies for a nieczabug I suppose | 20:34 | ||
jnthn | tadzik++ | ||
masak | this is why I don't type my attributes. :) | ||
tadzik | if anyone wants an LHF, gist.github.com/1782889 passes a similar set of tests that niecza does, on the first glance | 20:35 | |
I should probably be learning for my exam instead :) | |||
masak | nom: class A { has Int @.a }; my $a = A.new(:a(1, 2, "OH NOES")); say "alive" | ||
p6eval | nom 828e4d: OUTPUT«alive» | ||
tadzik | works for hashes | ||
jnthn | Works for individual array alements | ||
But not assignment. | |||
masak | I don't like to write code that could fail in the future when the implementation gets better. | ||
moritz: the technical comment about why Rat is slow is great. the personal comment about the 'educated_' prefix is not over-the-top in any way, and it's your pen, but... it's feeding the sponge, and nothing more. | 20:39 | ||
dalek | ecza: 760a302 | (Solomon Foster)++ | lib/CORE.setting: Fix embarrassing mistake noticed by tadzik++. |
20:40 | |
tadzik | that may have been my first niecza contribution of some sort :) | 20:41 | |
masak | moritz: if nothing else, it's evident from the followups that those two comments led to. the one with the high blood pressure in it even attracted chromatic. | 20:43 | |
tadzik | are we talking about some perlmonks discussion? | ||
masak | yeah. | ||
colomon | geez, my head is so fuzzy I just completely botched a simple Thomas the Tank engine layout. | ||
pyrimidine | tadzik: perlmonks.org/index.pl?node_id=952765 | 20:44 | |
colomon is probably going to regret looking... | |||
masak | nom: .say for "", { $_ ~ "potato".substr(.chars, 1) } ... "potato" | 20:47 | |
p6eval | nom 828e4d: OUTPUT«ppopotpotapotatpotato» | ||
masak | Rakudo can count to potato :D | ||
nom: .say for "", { $_ ~ "potato".substr(.chars, 1) // last } ... * | 20:48 | ||
p6eval | nom 828e4d: OUTPUT«(timeout)ppopotpotapotatpotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotato… | ||
masak | nom: .say for "", { $_ ~ ("potato".substr(.chars, 1) // last) } ... * | ||
hm. | |||
p6eval | nom 828e4d: OUTPUT«(timeout)ppopotpotapotatpotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotatopotato… | ||
masak .oO( "I know how to count to potato, but I don't know when to stop..." ) | 20:49 | ||
tadzik | banananananananana | ||
masak | nom: say "ba" ~ "na" x (2..20).roll | ||
p6eval | nom 828e4d: OUTPUT«banananananananananana» | ||
20:55
pernatiy left
20:56
pernatiy joined
20:57
bluescreen10 left
20:58
birdwindupbird left
21:04
lestrrat left
21:05
lestrrat joined
21:08
GlitchMr left
|
|||
skids | specwise, if two roles/classes with a same-named attribute are composed, does the overridden one still exist enough to, well I guess, "take up space?" | 21:09 | |
jnthn | If you compose two roles with the same named attribute, it's a conflict. I'm not sure what you mean about composing two classes. | 21:10 | |
skids | OK good. | 21:14 | |
21:15
bluescreen10 joined
|
|||
masak | perl6: role A { has $!x }; role B { has $!x }; class C does A does B {}; say "alive" | 21:16 | |
p6eval | rakudo 828e4d: OUTPUT«===SORRY!===Attribute '$!x' conflicts in role composition» | ||
..pugs b927740: OUTPUT«alive» | |||
..niecza v14-32-g760a302: OUTPUT«===SORRY!===Attribute '$!x' is provided by both 'A[curried][...]' and 'B[curried][...]' at /tmp/fnAJyZgvin line 1:------> B { has $!x }; class C does A does B {}⏏; say "alive"Unhandled exception: Check failed a… | |||
masak | Niecza likes curry. | ||
jnthn | LTA that Rakudo doesn't tell you which roles. | ||
Could optimize the currying out in that case. | 21:17 | ||
21:27
fsergot left
|
|||
skids | nom: class A { has $!a; }; class B is A { has $!a }; my B $a .= new(); $a.HOW.attributes($a).say | 21:28 | |
p6eval | nom 828e4d: OUTPUT«$!a $!a» | ||
colomon | tadzik: I should warn you that I plan significant changes still for Set and KeySet. | 21:32 | |
tadzik | okay :) | 21:33 | |
I'm not in a hurry | |||
the more situations like this appear the more I think about something along STD.pm6, but for CORE.setting | |||
colomon | you mean a standard setting for more than one implementation? | 21:35 | |
tadzik | aye | ||
look at what we're doing now | |||
copying This and That from Rakudo to Niecza, then other This and That from Niecza to Rakudo | |||
colomon | true | ||
but usually there are at least minor changes when we do that | |||
tadzik | now it was adding : before %elems in BUILDs, and changing the %e{$a}:delete expressions to the method call equivalents | 21:37 | |
dalek | p/bs: 44d674d | jnthn++ | src/6model/serialization. (2 files): First crack at one-level-deep closure serialization; survives, though not done deserialization yet. |
21:40 | |
21:48
kaare_ left
|
|||
[Coke] | I think that's a very reasonable goal to have that shared, but I think we're going to get there organically, rather than by attempting to force it. | 21:51 | |
21:53
MayDaniel left
21:54
Chillance left
|
|||
colomon | what [Coke] said. | 21:54 | |
[Coke] ponders graduate studies. | 21:57 | ||
and perl6. | |||
22:07
skids left
22:12
preflex_ joined,
preflex left
|
|||
colomon | moritz: so, is that prisoner's dilemma harness *the* harness for the competition, or not? | 22:12 | |
22:12
preflex_ is now known as preflex
|
|||
cognominal___ | jonathan: you meant "le dîner"? :) | 22:22 | |
[Coke] | that question makes me think you're trying to game the system, sirrah! | ||
22:22
benabik left
|
|||
cognominal___ | or may be "le diner". There has been a spelling reform that is ignored both by the litterate or the sms generation, that invents its own language. | 22:24 | |
masak | [Coke]: no, it makes sense to know how the competition will be judged. | 22:26 | |
cognominal___ | it is funny to see that the spelling of words like jeanfoutre (jerker) is regulated by law : www.academie-francaise.fr/langue/or...phies.html | ||
someday, we will have legal trouble in France, if we try to verb names. :) | 22:28 | ||
Apparently, with antidote, the software, one can chose the spelling, mordern, ancient or both | 22:31 | ||
indeed, the new spelling drop the accent. | 22:32 | ||
*modern *drops | |||
antidote++ | |||
www.druide.com/antidote.html | |||
*literate (but from litteratus) | 22:34 | ||
masak | cognominal___: I would be sorry to see the accents go. I like most of them. | 22:46 | |
jnthn tries not to make a joke about ze French accent | 22:48 | ||
cognominal___ | the new rule specifies dropping or changing accents where French people are confused to start with so in practice it does not change anything. | 22:49 | |
masak | right. people who were confused prior to the reform will remain so :) | ||
22:49
yertalert left,
nimiezko joined
|
|||
masak | rule of thumb: don't reform for the confused. :) | 22:49 | |
bonne nuit, #perl6 | 22:50 | ||
cognominal___ | but I remember there have been an outcry when some conporary book recent publication has been rectified. | ||
jnthn | branoc, masak | ||
nimiezko | rakudo: qx/ls/ | 22:51 | |
p6eval | rakudo 828e4d: OUTPUT«qx, qqx is disallowed in safe mode in sub restricted at src/SAFE.setting:2 in sub QX at src/SAFE.setting:9» | ||
nimiezko | rakudo: q:x/ls/ | ||
p6eval | rakudo 828e4d: OUTPUT«===SORRY!===Colons may not be used to delimit quoting constructs at line 1, near ":x/ls/"» | ||
22:52
snearch left
|
|||
cognominal___ | that's very French to publish laws that are totally ignored. I think one third of them don't have a application decret signed by the president meaning that le legislative process is ignored by him even when it has been intiated by him at a time it was mediatically opportune to do so. | 22:52 | |
s/le/the/ | |||
nimiezko | nieczca: qx/ls/ | 22:53 | |
What is the status on quoting forms (Q with adverbs) from S02 in rakudo ? | 22:54 | ||
cognominal___ | aren't they macros? | 22:55 | |
22:55
cognominal___ is now known as cognominal
|
|||
jnthn | nimiezko: The general Q with adverbs form isn't implemented in Rakudo yet, as far as I'm aware. | 22:55 | |
22:56
REPLeffect joined
|
|||
jnthn | Don't think we're missing anything especially major to implement it, just didn't happen yet. | 22:56 | |
nimiezko | so only abreviated forms works for now ? | 22:57 | |
jnthn | Correct. | ||
nimiezko | thanks a lot | ||
23:09
Gothmog_ left,
chra left,
sudokode left,
awwaiid left,
y3llow left,
Gothmog_ joined,
awwaiid joined,
chra joined,
sudokode joined,
y3llow joined
23:11
y3llow left
23:12
y3llow joined
23:13
y3llow left
23:14
y3llow joined
23:16
y3llow left,
y3llow joined
|
|||
dalek | p/bs: 0505b08 | jnthn++ | src/6model/serialization.c: Don't attempt to serialize an outer that'll simply never work out. |
23:16 | |
p/bs: cf55512 | jnthn++ | src/6model/serialization.c: Start to sketch out overall closure deserialization process. |
|||
p/bs: 3b9c867 | jnthn++ | src/6model/serialization.c: First crack at closure deserialization. Passes one of the tests, fails another...something still a bit off. |
|||
p/bs: 84c2256 | jnthn++ | src/6model/serialization.c: Fix a couple of silly thinkos; basic closure serialization tests now pass. |
|||
23:17
leontopod joined
|
|||
leontopod | If you guys can come out with Perl 6.0.0, I will start coding in it. =) | 23:17 | |
cognominal | we don't believe in numerology. :) | 23:18 | |
leontopod | you know, Perl 6, Version 1 | 23:19 | |
tadzik | leontopod: what is that you don't like about the current version? | 23:20 | |
leontopod | I don't think it is ready to produce production code yet. | 23:22 | |
Is anybody using Perl 6 to do anything Real? | 23:23 | ||
tadzik | masak does | ||
leontopod | Like, avionics, or controlling a nuclear power plant | ||
I know, I talked to masak. | |||
He nice guy! =) | |||
I promised him I wouldn't troll, so I better stop. | |||
flussence | "$language doesn't do $completely-unrealistic-requirement, $language sucks!" | 23:26 | |
so what language is your nuclear reactor and/or air control tower currently using? | |||
timotimo | cobol? | 23:27 | |
hopefully ada or something similar | |||
tadzik | cobol I guess | 23:32 | |
23:37
whiteknight joined
|
|||
timotimo | did you come here to protect poor perl6-in-distress, whiteknight? :) | 23:38 | |
whiteknight | timotimo: is perl6 in distress? | ||
I came online to look up funny pictures of cats, but I'll help if help is needed | |||
timotimo | a troll just came here who's all like "but i cannot use perl6 in a nuclear power plant yet! so clearly it's not ready to be used!" | 23:39 | |
but i was mostly kidding, as was he | |||
whiteknight | oh, then I won't say anything mean about him :) | ||
tadzik | oh, I wouldn't exaggarate and call that trolling | ||
it's more like the usual "when will you hit 1.0" | |||
23:40
damsel_in_distre joined,
damsel_in_distre is now known as DamselInDistress,
nimiezko left
|
|||
DamselInDistress | Help me, whiteknight, I need to learn perl6 to please a nice guy who could probably be more than just a friend, if you catch my drift ^^ but I need to learn perl6 to help him code a server for a supercool RPGgame that I need to write ;-) it has everyting a traditional RPG has and will also have awesome features and allow much better rpggeneration. Canyouhelpmeplz? ^^'; | 23:44 | |
flussence | .oO( didn't we hit 1.0 some time around 1985? ) |
||
whiteknight | DamselInDistress: ha, that's the coolest request for help I've ever heard. Unfortunately, I'm probably not best for the job | ||
my knowledge of P6 is not great | |||
DamselInDistress | shucks | 23:45 | |
23:45
DamselInDistress is now known as lisa_schwarzhaar
|
|||
lisa_schwarzhaar | perl6 sounds cool though, I shall hang out in here for a while | 23:45 | |
leontopod | flussence, probably ADA | ||
timotimo | is it ADA, not Ada? | 23:46 | |
leontopod | I know a lot of air traffic control systems and even some avionics use Jovial | ||
tadzik | lisa_schwarzhaar: what do you need help with? | ||
leontopod | which is a really really old multithreaded/tasking version of Algol | ||
tadzik | lisa_schwarzhaar: do you have previous Perl/programming experience? | ||
whiteknight | lisa_schwarzhaar: now, if you want to learn C, and have some extra hair that you don't mind ripping out, I can help :) | ||
lisa_schwarzhaar | whiteknight, tadzik I can code c/c++ already and my hair is sacred | 23:47 | |
As for learning perl6, I guess I'll read a book / the internet and nag some of the local nerds | |||
tadzik | and is schwarz | ||
whiteknight | timotimo: Probably Ada. It's named in honor of Ada Lovelace | ||
tadzik | lisa_schwarzhaar: try the Using Perl 6 Book | ||
timotimo | yup, wikipedia claims so as well | ||
whiteknight | lisa_schwarzhaar: excellent strategy | ||
lisa_schwarzhaar | tadzik: sounds good | ||
tadzik | lisa_schwarzhaar: perl6.org/documentation/ generally | 23:48 | |
lisa_schwarzhaar | I can still nag you with general questions, right? | ||
23:48
nimiezko joined
|
|||
tadzik | sure thing | 23:48 | |
timotimo | "so, how do i computer?", lisa_schwarzhaar? | ||
whiteknight | I can program some NQP, which is not quite what you want :) | ||
timotimo | what exactly is nqp? it seems to have something to do with native calls and belongs to Parrot VM? | 23:49 | |
lisa_schwarzhaar | timotimo: Like I told you before, you gotta make sure your computer is feeling well. Treat it / him / her to some nice juicy electricity and generally treat it well... | ||
tadzik | timotimo: it's a subset of Perl 6 in which the core compiler is written | ||
flussence | it's perl6 without any syntactic sugar at all | ||
timotimo | oh, interesting/terrible | ||
whiteknight | timotimo: yeah, NQP is a subset of perl used for bootstrapping the compiler | 23:50 | |
so Rakudo perl6 is written in perl6 | |||
timotimo | cool, i totally didn't know that | ||
jnthn | NQP is also self-hosting. :) | ||
leontopod | Rakudo runs Parrot Assembly Language I thought | 23:51 | |
timotimo | so it's a little bit like pypy in that regard? | ||
wait. it's a subset of perl? or perl6? | |||
jnthn | Subset of Perl 6. | ||
whiteknight | jnthn: yes, it's turtles all the way down | ||
Until you finally get down to a single exhausted bit, flipping on and off extremely fast | 23:52 | ||
timotimo | until you reach elephants? | ||
leontopod | you know what was cool about the Atari ST, is that video memory was just part of main memory, and you had the ability with a small C program to reset the video pointer to anywhere in memory you wanted | 23:53 | |
so if you set it to low memory | |||
each pixel represents one bit | |||
so you can see counters counting up, bits flipping on and off, chunks of disk being read in | 23:54 | ||
it was pretty neat! | |||
oh right, and what made this all possible is the video chip ran asynchronously to the main cpu (68000) chip | |||
you can't do that easily with 80x86 architectures because video memory is separate from main memory | |||
lisa_schwarzhaar smiles happily while daydreaming of better times | 23:55 | ||
leontopod | really it hearkened back to the days when computers had lights on the console, and gleaming rows of toggle switches! | ||
Toggle switches so you could toggle in bootstrap code. | 23:56 | ||
timotimo | those were better times | ||
how did we get to this topic? | |||
lisa_schwarzhaar | I heard they had hybrid computers too.. I even got to touch one.. | ||
leontopod | yes, the computing power in an android phone used to take up a large room in the 1960s | 23:57 | |
I programmed on some of those beasts. | |||
timotimo | uh | ||
an android phone would take more than just one large room | |||
leontopod | well, ok! | ||
=) | |||
an entire fricking building! | |||
timotimo | those phones usually host dual-core processors and sometimes dedicated graphics processors? not sure. | ||
lisa_schwarzhaar | just clean out all the bloat and it would run on a decent old computer... | 23:58 | |
timotimo | and then there's the GSM chip that runs its own realtime-OS | ||
leontopod | I am seriously looking into the android scripting environment | ||
timotimo | i would suppose you couldn't even get to the performance due to bandwidth limitations in the whole thing and the problem of parallelizing things | ||
leontopod | I'd like to write an android app in Perl | ||
timotimo | you mean SL4A? | 23:59 | |
leontopod | I don't think it is QUITE there yet |