»ö« | perl6-projects.org/ | evalbot: 'perl6: say 3;' | irclog: irc.pugscode.org/ | UTF-8 is our friend!
Set by moritz_ on 17 June 2009.
eternaleye tann: the ... operator is not implemented yet 00:03
In rakudo, at least. Pugs handles it. 00:05
pugs: .say for 1, 1 ... &[+]; 00:06
p6eval pugs: OUTPUT«1␤all(VInt 0,VList [VInt 1,VInt 2,VInt 3,VInt 4,VInt 5,VInt 6,VInt 7,VInt 8,VInt 9,VInt 10,VInt 11,VInt 12,VInt 13,VInt 14,VInt 15,VInt 16,VInt 17,VInt 18,VInt 19,VInt 20,VInt 21,VInt 22,VInt 23,VInt 24,VInt 25,VInt 26,VInt 27,VInt 28,VInt 29,VInt 30,VInt 31,VInt 32,VInt 33,VInt 34…
eternaleye Hm. It seems not to do it correctly, though
00:19 viklund left 00:24 kst left 00:25 kst joined
pugs_svn r27156 | kyle++ | [t/spec] Change more Pugs todo flags to fudge commands 00:29
00:30 amoc left
pugs_svn r27157 | kyle++ | [t/spec] Change more Pugs todo flags to fudge commands 00:36
00:38 DemoFreak left 00:41 dukeleto joined 00:44 justatheory joined 00:48 bacek joined 00:49 kyle2 joined 00:51 twigil joined
pugs_svn r27158 | kyle++ | [t/spec] Change more Pugs todo flags to fudge commands 01:01
01:20 amoc joined
pugs_svn r27159 | kyle++ | [t/spec] Change more Pugs todo flags to fudge commands 01:20
01:32 Chillance joined 01:44 meppl joined 01:52 Sunbeam left, Sunbeam joined 01:55 kst left 01:56 kst joined, xinming_ joined 01:57 molaf_x joined 02:03 xinming__ joined 02:04 xinming left 02:11 alester joined 02:12 Chillance left 02:15 molaf_xx left 02:20 xinming_ left 02:23 alanhaggai joined 02:25 Sunbeam left, payload left 02:42 M_o_C left, justatheory left 02:45 xinming__ left 02:46 xinming joined 02:48 hercynium joined 03:07 sri_kraih left 03:08 sri_kraih joined 03:11 last left 03:20 donaldh left, donaldh joined 03:21 cotto joined, kst left 03:22 kyle2 left, ihrd joined, ihrd left 03:23 kst joined 03:26 nihiliad left 03:33 s1n1 joined 03:38 s1n1 left 03:40 Whiteknight joined 03:43 s1n1 joined, meppuru joined 03:51 meppl left, meppuru is now known as meppl 03:54 lpsmith joined 03:58 Whiteknight left 04:05 cotto left 04:14 iblechbot joined 04:36 justatheory joined 04:38 cotto joined 04:40 s1n1 left 04:48 kst left 04:49 kst joined 04:51 iblechbot left 04:52 cotto left, cotto joined 05:16 eMaX joined 05:24 justatheory left 05:36 alanhaggai_ joined 05:41 skids left 05:52 alanhaggai left 05:57 ZuLuuuuuu joined 06:10 xinming_ joined 06:17 kst left, xinming_ left 06:18 kst joined 06:20 xinming_ joined, actualeyes joined
actualeyes How do I do stdin in Perl6?\ 06:21
06:23 xinming left
actualeyes my $something = $*IN.readline; gives me 06:27
Method 'readline' not found for invocant of class 'IO'
06:31 eMaX left, eMaX joined 06:39 azawawi joined
azawawi hi 06:39
actualeyes: hi
06:39 bacek left
azawawi actualeyes: my $line = $*IN.get; 06:40
actualeyes: or if you need to ask a question to the user, use my $line = prompt("your question");
06:43 alester left
actualeyes Awesome thanks. 06:44
azawawi actualeyes: np 06:46
actualeyes: what do u use to edit Perl 6? vim? Padre? 06:47
twigil what is Padre? 06:50
06:50 eMaX_ joined, sri_kraih left 06:52 eMaX left
actualeyes vim 06:52
I am actually starting to play with it.
Last time I picked up parrot I tried to use <STDIN> 06:53
and I got a stack trace
the current build is much more mature
Padre is a new IDE written in Perl for Perl 06:54
you can get it in cpan
I tried it once and liked it but, it seemed a bit lightweight.
that may have been 3 months ago. 06:55
I'll probably try it in another 6 months
06:56 xinming joined 07:06 xinming__ joined 07:11 xinming_ left 07:13 xinming left, eMaX_ left 07:20 donaldh left, donaldh joined 07:28 azawawi left 07:41 DemoFreak joined 07:46 cotto left 07:47 alanhaggai_ left, kst left 07:48 kst joined 08:13 buubot_ joined, buubot_ left 08:17 ZuLuuuuuu left 08:33 viklund joined 08:39 xinming__ left 08:40 bacek joined 08:41 xinming joined 08:44 finanalyst joined
finanalyst how do i convert a rakudo program to a binary so i can run without re-parsing? 08:46
viklund finanalyst: rakudo --target=pir --output=file.pir file.pm 08:57
You can only do it with modules
s/rakudo/perl6/
finanalyst i thought it was possible for scripts too
viklund not that I now of 08:58
but just put the entire program in the .pm file 08:59
it will get executed once you 'use' it
finanalyst suppose i have MyModule.pm and MyModule.pir in the same directory, and then use MyModule, which version gets 'used' 09:01
viklund the pir-version
finanalyst thanx
viklund so remember to recompile when you've made a change
09:02 eMaX joined, kst left 09:03 kst joined
finanalyst i have most functions in modules anyway. 09:06
the change in speed is noticeable when the modules are precompiled
rakudo is parsing and running much much faster recently anyway
09:08 phenny joined 09:09 nsh_ joined, sbp joined 09:10 nsh left, Jedai joined, ejs joined 09:11 nsh_ is now known as nsh 09:12 Su-Shee joined
Su-Shee good morning. 09:12
viklund good morning 09:15
araujo morning 09:16
09:16 azawawi joined
azawawi viklund: hi 09:16
viklund o/
azawawi viklund: any update from pmichaud on the profiler? 09:17
viklund not that im aware of
azawawi viklund: ok
09:21 finanalyst left 09:26 azawawi left 09:36 pmurias joined 09:44 ejs left 09:56 drbean left 10:07 ejs joined 10:11 IRSeekBot left 10:13 hercynium left, flexibeast left, IRSeekBot joined 10:17 tann left 10:24 Whiteknight joined 10:25 Jedai left 10:27 Jedai joined 10:28 ejs left 10:34 payload joined 10:48 kst left 10:49 kst joined 10:58 Muixirt joined 11:03 lpsmith left 11:17 cotto joined 11:20 donaldh left, donaldh joined 11:22 viklund left 11:37 cotto left 11:41 drbean joined 11:44 mj41 joined 11:45 d4l3k_ joined 11:47 sbp left, nsh left, phenny left, molaf_x left, Molaf left, mj41_ left, buubot left, cls_bsd left, eternaleye left, hatseflats left, frodwith left, allbery_b left, sbp joined, nsh joined, phenny joined, molaf_x joined, mj41_ joined, buubot joined, cls_bsd joined, eternaleye joined, hatseflats joined, rgs joined, allbery_b joined, frodwith joined, Molaf joined 11:48 d4l3k_ is now known as dalek 11:49 eternaleye_ joined 11:53 Whiteknight left 12:01 eternaleye left, mj41_ left 12:12 kst left 12:13 kst joined 12:26 bacek left 12:29 bacek joined 12:33 cotto joined, last joined 12:41 fridim_ joined 12:50 masak joined
masak o/ 12:51
phenny masak: 20 Jun 19:16Z <Matt-W> tell masak yes I was referring to your blog entry
masak :)
phenny: tell WhiteKnight yes, I'm coming to YAPC::EU. will do a talk about Web.pm. 12:56
phenny masak: I'll pass that on when WhiteKnight is around.
13:01 frew|work joined 13:03 frew|work is now known as frew
payload hi. perl 6 has a gradual type system. where is it documentated which optimizations and speed ups should be possible with these type informations? 13:05
masak payload: the answer is either 'nowhere' or 'here and there'. I'm not so sure. 13:06
payload: I get the impression that the designers haven't started thinking deeply about the possible optimisations due to typing. 13:07
they're mentioned now and then, but (also AFAIK) no implementation does any of those optimisations.
Matt-W o/
masak and that's tantamount to saying that nobody has started thinking about it. :)
Matt-W: \o
13:08 M_o_C joined 13:09 jonalv joined
masak Matt-W: if I knew the reaction from my SVG experiments would be "you're living in the future", I would have attempted them much sooner. :) 13:09
Matt-W haha 13:10
13:10 Whiteknight joined
Matt-W I just thought that was funny 13:10
and it tied in with a Wil Wheaton blog entry from last week too
pmichaud I'd say that the designers have been keeping optimization in mind in building the language so as not to preclude good optimizations
jonalv o/
Say that I wanted to print something like ten million 13:11
that's and awful lot's of zeros
masak 10_000_000
jonalv How would you group them for readability?
masak jonalv: did I guess your question right? :)
Matt-W: URL? 13:12
pmichaud rakudo: say 10_000_000
p6eval rakudo 1b06df: OUTPUT«10000000␤»
jonalv masak: yes, I am not convinced though. I know that some lagnuages use "," and "."
masak also, 1e7.
13:12 flexibeast joined
pmichaud Perl 6 uses underscores. 13:12
masak jonalv: wait, are you complaining about the choice of separator?
jonalv no
masak it's underscores, I promise! 13:13
Matt-W rakudo: say 10_000_000
p6eval rakudo 1b06df: OUTPUT«10000000␤»
Matt-W masak: wilwheaton.typepad.com/wwdnbackup/2...y-one.html
masak Matt-W: hvala.
Matt-W jonalv: see, underscores :) 13:14
jonalv I trust you :)
It's just that I was asking more genrally. A bit off topic I know. But I was hoping for some sort of pretty print function or something like that 13:15
Matt-W oh
I'm writing that
jonalv you are? :)
Matt-W yes
it'll be part of the Form.pm module
jonalv so I take it I ahve to wait then? :) 13:16
Matt-W the numeric formatting stuff includes adding commas or other separator characters you might like
yes you have to wait
13:16 M_o_C left
masak jonalv: or roll your own just for this purpose. 13:16
jonalv: or help Matt-W :)
Matt-W Form has some othe rfeatures to do first... like, any kind of number formatting at all :)
masak it's very close now.
Matt-W yes 13:17
jonalv masak: yes I could definitly roll my own. Which brings my bak to original question. How would you group them for readability?
masak jonalv: I misunderstood your question, sorry. you want to _output_ numbers, not enter them into your source code.
Matt-W just when I can sit down with my brain and do it
masak jonalv: by threes.
jonalv masak: yes, and would you do spaces between?
masak jonalv: that's up to you, I guess.
whatever suits you best. 13:18
jonalv masak: I think that's the swedish approach and it might not be so international...
Matt-W commas is what we use in england, in groups of three
masak jonalv: no, periods ('.') is the Swedish approach.
Matt-W but some other european languages use . in groups of three
jonalv masak: oh
:)
masak jonalv: we got that from the French, methinks.
Matt-W So English would be 1,000,000.00 but Swedish is 1.000.000,00, I believe 13:19
jonalv Hm I wonder if I can get LaTeX to just add a small space between the groups?
Matt-W probably, but it might be quite complicated 13:20
jonalv (I guess that was the wrong forum) :)
Matt-W yeah my LaTeX isn't very good
I can write an essay in it
masak jonalv: something like '\ '.
jonalv masak: yea
so then I just need to get Perl6 to split my numbers correct and add that between...
13:21 jan_ left
masak jonalv: www.giss.nasa.gov/tools/latex/ltx-185.html 13:22
jonalv masak: perfect 13:23
masak: now, the question just is. Do I hard code the numbers or do I write code for doing the pretty printing?
How hard could it be? :)
masak jonalv: the latter.
hold on.
rakudo: sub group($num is copy) { return reverse gather while $num > 0 { take $num % 1000; $num = int($num / 1000) } }; say group(123456789).join(".") 13:25
p6eval rakudo 1b06df: OUTPUT«123.456.789␤»
masak et voilà.
jonalv masak: uhm "$num is copy"? 13:27
masak jonalv: just so I can modify $num inside the sub.
jonalv oh
cool
masak without harming the original argument.
jonalv: just so you know what you have to look forward to in Matt-W's work, please skim through this document: search.cpan.org/dist/Perl6-Form/Form.pm 13:28
13:28 kst left 13:29 kst joined
payload rakudo: say "\x2002" # should be a small space when i remember the unicode syntax in perl 6 correctly 13:30
p6eval rakudo 1b06df: OUTPUT« ␤»
masak apparently that was the syntax. 13:31
jonalv heads to try and get his first "sub" to work
payload rakudo: sub group($num is copy) { return reverse gather while $num > 0 { take $num % 1000; $num = int($num / 1000) } }; say group(1234567890).join("\x2002")
p6eval rakudo 1b06df: OUTPUT«1 234 567 890␤»
masak rakudo: sub group($num is copy, $size = 3) { my $d = 10 ** $size; return reverse gather while $num { take $num % $d; $num = int($num / $d) }; say group(1234567890).perl 13:33
p6eval rakudo 1b06df: OUTPUT«Unable to parse block; couldn't find final '}' at line 2, near ""␤in Main (src/gen_setting.pm:0)␤»
masak oops.
rakudo: sub group($num is copy, $size = 3) { my $d = 10 ** $size; return reverse gather while $num { take $num % $d; $num = int($num / $d) } }; say group(1234567890).perl
p6eval rakudo 1b06df: OUTPUT«[1, 234, 567, 890]␤»
jonalv rakudo: sub group($num is copy, $size = 3) { my $d = 10 ** $size; return reverse gather while $num { take $num % $d; $num = int($num / $d) } }; say group(1234567890).join(\\,) 13:35
p6eval rakudo 1b06df: OUTPUT«Statement not terminated properly at line 2, near "(\\\\,)"␤in Main (src/gen_setting.pm:0)␤»
masak still need to put strings in quotes.
jonalv oh "duh" :) 13:36
rakudo: sub group($num is copy, $size = 3) { my $d = 10 ** $size; return reverse gather while $num { take $num % $d; $num = int($num / $d) } }; say group(1234567890).join("\\,")
p6eval rakudo 1b06df: OUTPUT«1\,234\,567\,890␤»
jonalv runs his script and hopes the pdf will look good :) 13:37
rakudo: sub group($num is copy, $size = 3) { my $d = 10 ** $size; return reverse gather while $num { take $num % $d; $num = int($num / $d) } }; say group(1000000).join("\\,") 13:38
p6eval rakudo 1b06df: OUTPUT«1\,0\,0␤»
jonalv hm...
masak oh!
sorry, fixing.
jonalv :) 13:39
masak rakudo: sub group($num is copy, $size = 3) { my $d = 10 ** $size; return reverse gather while $num { take sprintf '%03d', $num % $d; $num = int($num / $d) } }; say group(1000000).perl
p6eval rakudo 1b06df: OUTPUT«["001", "000", "000"]␤»
masak hm.
rakudo: sub group($num is copy, $size = 3) { my $d = 10 ** $size; return reverse gather while $num { take (sprintf '%03d', $num % $d).subst(/^ 0+/, ''); $num = int($num / $d) } }; say group(1000000).perl 13:40
p6eval rakudo 1b06df: OUTPUT«["1", "", ""]␤»
masak hm... :/
rakudo: sub group($num is copy, $size = 3) { my $d = 10 ** $size; return reverse gather while $num { take (sprintf '%03d', $num % $d).subst(/^ 0+ <!before $>/, ''); $num = int($num / $d) } }; say group(1000000).perl 13:41
p6eval rakudo 1b06df: OUTPUT«["1", "0", "0"]␤»
masak wow, wrong again.
13:41 s1n1 joined
masak how do I say 'remove leading zeroes, unless they constitute the whole string?' 13:41
jonalv thinks it was not so easy after all...
13:42 azawawi joined
masak jonalv: no, it is. I just haven't had my coffee yet. 13:42
jonalv masak: you don't drink coffee...
masak oh noes!
I _really_ haven't had my coffee yet.
payload my $a = $b.triml("0") ?? $a !! $b or something like that? 13:43
can't test... rakudo is compiling ^^
masak rakudo: sub group($num is copy, $size = 3) { my $d = 10 ** $size; return reverse gather while $num { take (sprintf '%03d', $num % $d) || (sprintf '%03d', $num % $d).subst(/^ 0+/, ''); $num = int($num / $d) } }; say group(1000000).perl
p6eval rakudo 1b06df: OUTPUT«["001", "000", "000"]␤»
jonalv stares wide-eyed at that code for a while 13:44
masak rakudo: sub group($num is copy, $size = 3) { my $d = 10 ** $size; return reverse gather while $num { take (sprintf '%03d', $num % $d) && (sprintf '%03d', $num % $d).subst(/^ 0+/, ''); $num = int($num / $d) } }; say group(1000000).perl
p6eval rakudo 1b06df: OUTPUT«["1", "", ""]␤»
masak grumbles
13:44 hudnix left
azawawi hi 13:45
masak rakudo: sub group($num is copy, Int $size = 3) { my $d = 10 ** $size; return reverse gather while $num { my $s = sprintf("%03d", $num % $d); take $s ~~ /^ 0+ $/ ?? $s !! $s.subst(/^ 0+/, ""); $num = int($num / $d) } }; say group(1e6).perl 13:47
p6eval rakudo 1b06df: OUTPUT«sh: ./perl6: No such file or directory␤»
masak jonalv: there you go. that works.
but rakudo is rebuilding right now in the server. 13:48
azawawi: hi!
jonalv masak: I will try that then :)
masak Matt-W: really looking forward to number formatting in Form.pm :P
jonalv that worked (And it looks very nice too) thanks masak++ 13:53
masak thanks. I'll be here all week. 13:54
no really, I will.
and the next one, too.
rakudo: sub group($num is copy, Int $size = 3) { my $d = 10 ** $size; return reverse gather while $num { my $s = sprintf("%03d", $num % $d); take $s ~~ /^ 0+ $/ ?? $s !! $s.subst(/^ 0+/, ""); $num = int($num / $d) } }; say group(1e6).perl
p6eval rakudo 1b06df: OUTPUT«["1", "000", "000"]␤»
14:04 a3r0 joined
azawawi std: module A; module B; 14:06
p6eval std 27159: OUTPUT«##### PARSE FAILED #####␤Too late for semicolon form of module definition at /tmp/NSDhAAjXCa line 1:␤------> module A; module B;␤ expecting any of:␤ trait␤ whitespace␤FAILED 00:02 35m␤»
azawawi std: module A { } module B {}
p6eval std 27159: OUTPUT«##### PARSE FAILED #####␤Whitespace is required between alphanumeric tokens at /tmp/pBaJKTUaTE line 1:␤------> module A { } module B {}␤FAILED 00:02 36m␤»
azawawi std: module A { }; module B { }
p6eval std 27159: OUTPUT«ok 00:02 35m␤»
azawawi std: module A::B { }; module B { } 14:07
p6eval std 27159: OUTPUT«ok 00:02 35m␤»
azawawi std: module A::B { }; module B::C { }
p6eval std 27159: OUTPUT«ok 00:02 35m␤»
azawawi std: package A::B { }; package B { }
p6eval std 27159: OUTPUT«ok 00:02 35m␤»
azawawi std: package A::B { }; package B::A { }
p6eval std 27159: OUTPUT«ok 00:02 35m␤»
masak std: module A {}; module B;
p6eval std 27159: OUTPUT«ok 00:02 35m␤»
masak std: module A { module B; } 14:08
p6eval std 27159: OUTPUT«ok 00:02 35m␤»
masak we're quite lenient these days.
azawawi masak: sorry :) 14:09
masak azawawi: for what?
azawawi for STD flooding :)
masak I meant that STD.pm has a lenient policy for statement-form package declarations.
azawawi: no, flood on. 14:10
azawawi ah i see
masak there's plenty of backlog room left. :)
also, accusing you of flooding right now would be a bit hypocritical of me. :P
azawawi is making some screenshots from Ecliptic+Perl6 on Padre for masak :)
14:10 jonalv left
masak :) 14:11
14:18 skids joined
azawawi masak: see the screenshots for ecliptic+perl6 in action... feather.perl6.nl/~azawawi/quick_fix/ 14:21
masak: it is now released on CPAN :)
masak azawawi++ 14:22
azawawi masak: perl 6 rename var and extract method is next on my agenda
masak: along with world domination ofcourse :) 14:23
masak azawawi: I'm curious... do you use STD.pm or 'perl6 --taget=parse' for this?
azawawi masak: STD ofcourse;
masak: you have the option of switching to STD or PGE 14:24
masak aha.
do you have a link to the source code that does this?
I'm guessing you use YAML at some critical point.
azawawi: found a slight wart: the quick-fix menu option has an unnecessary question mark: "Insert a space after if?" 14:26
azawawi: otherwise it looks really good.
14:29 kst left 14:30 kst joined
azawawi masak: sure... 14:30
masak: svn.perlide.org/padre/trunk/Padre-Plugin-Perl6 14:31
masak: Perl6::Document
masak thank you.
azawawi masak: it is not refactored yet though :)
masak: and the fixes are not 100% error proof :) 14:32
masak I'm more interested in porting this to Perl 6 than in refactoring. :)
azawawi masak: tonight im going to blog heavily about it 14:33
masak hey, look! I'm mentioned in a comment! :)
azawawi masak: first real blog :)
masak: S29-functions?
masak yep.
azawawi masak: i think once hinrik gets grok working; we can move to a better solution... 14:34
masak azawawi: anyway, great work! keep it up.
azawawi: yes, great hope lies in grok.
but it's only half the excellent implementation literal++ will write.
azawawi masak: will it restore the balance to the force? :) 14:35
masak the other half is the excellent documentation itself.
azawawi: it will almost tip the balance over the other way.
masak catches himself writing the ternary operator as a?b!c in Java 14:37
azawawi masak: i should write a quick fix for that :)
masak yes, but the other way around. 14:38
azawawi std: a ? b : c;
p6eval std 27159: OUTPUT«Undeclared routines:␤ b used at 1 ␤ c used at 1 ␤ok 00:02 39m␤»
masak writing ?? :: happens sometimes too.
azawawi i think std used to warn about it
masak std: "foo" ? "bar" : "baz"
p6eval std 27159: OUTPUT«##### PARSE FAILED #####␤Obsolete use of ?: for the conditional operator; in Perl 6 please use ??!! instead at /tmp/X1IFdrPABt line 1:␤------> "foo" ? "bar" : "baz"␤FAILED 00:04 36m␤»
masak it does.
but somehow it didn't trigger for you.
azawawi std: a == "foo" ? "bar" : 1
p6eval std 27159: OUTPUT«##### PARSE FAILED #####␤Obsolete use of ?: for the conditional operator; in Perl 6 please use ??!! instead at /tmp/WchfLq8igP line 1:␤------> a == "foo" ? "bar" : 1␤Undeclared routine:␤ a used at 1 ␤FAILED 00:04 36m␤» 14:39
masak azawawi: ah, if a, b, c are listops, what you wrote first actually parses.
azawawi masak: one thing i didnt perfect; is the regexp for a perl 6 identifier 14:40
masak: Foo::Bar-In::C
14:42 lichtkind joined 14:44 azawawi left 14:54 zamolxes joined 14:56 sri_kraih joined 14:58 alester joined
masak rakudo: my $n = 1; for ^10 { say $n; $n = $n.subst(/(\d) $0*/, { $/.chars ~ $0 }, :g) } 15:03
p6eval rakudo 1b06df: OUTPUT«1␤11␤21␤1211␤111221␤312211␤13112221␤1113213211␤31131211131221␤13211311123113112211␤»
masak Conway sequence. 15:04
15:08 alester left 15:11 bacek left 15:13 barney joined, jan___ joined 15:18 meppl left 15:20 donaldh left, donaldh joined 15:28 a3r0 left 15:30 twigil left
japhb Happy Father's Day, papas! 15:32
masak I had to make sure earlier today that it isn't Father's Day here in Sweden. 15:34
apparently, ours is in November (the month).
Su-Shee here it's mostly a very annoying binge drinking. ;) 15:36
15:44 leed0 joined
Muixirt Su-Shee, and you are annoyed because the binge drinking is taking place without you? 15:44
Su-Shee No! :) I don't drink anyway but maybe a glass of wine from time to time (where time = month) 15:45
it's more the utterly drunken "dads" you're encountering. ;) 15:46
15:49 leed0 left 15:51 kst left, kst joined 15:57 iblechbot joined
lichtkind is classify operator gone? 16:01
pugs_svn r27160 | azawawi++ | [S:H:P6] Added tests for previous STD bugs 16:03
16:04 azawawi joined, cavelife^ left
pmurias lichtkind: not it's not 16:07
lichtkind pmurias: thanks
pmurias++ 16:09
16:09 M_o_C joined
lichtkind perl 6 is madness www.perlfoundation.org/perl6/index....le_index#c 16:10
pugs_svn r27161 | azawawi++ | [S:H:P6] version 0.63 contains the latest STD.pm with the fixed symbol table bug
r27161 | azawawi++ | [S:H:P6] 'module Foo::Bar { }; module Bar { };' # redeclared Bar
r27161 | azawawi++ | [S:H:P6] TimToady++
pmurias lichtkind: moritz_ was attempting something vaguely similiar with misc/perlhints 16:13
masak and u4x is also a similar effort.
lichtkind pmurias: yes he told me 2 years ago on german perl workshop but thats something with different task 16:14
masak ...but with a CLI client thrown in.
lichtkind and in u4x isn much to steal from yet :)
i mean take
masak true. 16:15
it's still in its early stages.
even the high-flying plans for it are in their early stages. :)
16:15 jferrero joined
lichtkind masak: so iont see reason to drop that effort if it brings me so much nice klingon pain 16:15
masak lichtkind: of course not. keep up the good work. 16:16
16:16 viklund joined
pmurias lichtkind: was hoping for some kind of synergy rather than encouraging you to drop your effort 16:17
lichtkind pmurias: there isnt that much synergy since my page is just a index of an perl 6 lexicon and moritz tries to explain whole lines of perl 6 with his programm 16:18
16:18 s1n1 left
azawawi masak: what mistakes do u keep running into when writing p5->p6? like the 1==1 ? "a": "b" => ?? !! 16:18
masak azawawi: not many, I think. I can context-switch quite well these days. 16:19
Matt-W I tend to make more mistakes in Perl 5, thinking I can do Perl 6 things
lichtkind pmurias: only some resource lists could be shared but moritz didn't much in last months
masak and I make very few Perl5-inspired mistakes in my Perl 6, since the latter is my main tongue.
ah, what Matt-W said.
16:20 Psyche^ joined
Matt-W My default 'Perl' thoughts are Perl 6 ones 16:20
azawawi hmmm nice
pmurias and ? ... : ... is unintuitive enough that it doesn't get used accidently
viklund y0 6-ers
masak viklund: whoz op?
viklund BUILD in november
masak ya, I saw.
viklund++
viklund I only need to run some more tests and then I'll push 16:21
masak YaY
Matt-W a lot of people seem to think it's ?? :: in Perl 6, they get caught by the !!
16:21 ZuLuuuuuu joined
viklund oh, and I found a BUILD related bug as well 16:22
#66792
masak yes, that's the one I saw.
azawawi pmurias: i postponed re-mildew runtime support in Padre Perl 6 until i get it running :) 16:23
pmurias np
viklund it clobbers defaults in roles as well
pmurias azawawi: i'll likely add it myself if i switch to padre
masak pmurias: do you and ruoso have weekly meetings in #perl6-soc? 16:24
azawawi pmurias: cool :)
pmurias masak: no
masak pmurias: literal and I were talking about it today. we decided on Wednesdays at 19:00. you're welcome to join, if you feel it would be of value.
viklund what's the "soc" postfix? 16:25
Summer of Code?
masak aye.
I'm a mentor this summer.
viklund masak: mmm, I have your druid svg in a tab, I don't want to close it ;) 16:26
masak 哈哈
bet it's one of the latter two, with real perspective. 16:27
viklund yep
masak now, imagine that same image, but containing an ongoing game, with clickable surfaces, a set of rotation buttons, and js all the way to make things respond.
viklund shiver me timbers 16:28
16:30 Patterner left, Psyche^ is now known as Patterner
masak I hope I have something like that working by the end of the summer. but it sort of depends on Web.pm too. 16:30
16:35 payload left 16:39 kst left 16:40 kst joined, s1n1 joined 16:41 s1n1 left
lichtkind Appendix has now 361 entry 16:43
i think i make just 2 more today
16:49 s1n1 joined
masak 'Disruptive innovation tends to appear “off the radar” of the established players. It is often inferior to the established product in many ways. It tends to start in some small niche where it happens to work better than the established technology. The majors ignore it, as it clearly can’t handle the “real” problems they are focused on. Over time, the new technology grows more competent and eats its way upward, consuming the previous 16:55
market leader’s lunch.'
From "The Language Designer's Dilemma" -- gbracha.blogspot.com/2009/04/last-w...-lang.html
16:57 latch joined, codeguy joined 16:58 latch left 16:59 codeguy left 17:04 rfordinal left 17:05 rfordinal joined, PacoLinux left 17:06 PacoLinux joined 17:10 masak left
moritz_ re 17:13
17:14 s1n1 left
japhb How would you import namespace aliases in a lexical scope? In other words, let's say I have a bunch of modules under OpenGL::Math::, such as OpenGL::Math::Mat4x4 and OpenGL::Math::Vec4. When I 'use OpenGL::Math;' can I arrange for the caller to be able to say 'my Vec4 pos .= new;' without polluting the top-level namespace globally, but only in the scope that used OpenGL::Math? 17:14
Tene japhb: that's specced as the default 17:15
but it's NYI in Rakudo
oh, I kinda misread.
japhb What, what?
oh, heh
Tene oh, no, I was right the first time, as long as OpenGL::Math exports Vec4. 17:16
That's what I rmemeber from the spec, at least, that all imports are lexical. 17:17
japhb Still, it sounds like you're saying this is not one problem, but two (one of which is solved in the spec): 1) Alias namespaces on import, 2) affect only lexical space in "user".
So you're saying,
class OpenGL::Math::Vec4 is export('Vec4')
or somesuch?
Tene Yeah. Lemme check if that works now. 17:18
17:20 azawawi left
Tene ah, no, not so much. 17:20
japhb :-) 17:21
17:22 payload joined
moritz_ masak++ # 3D SVG for druid 17:23
japhb moritz_: link?
Tene use.perl.org/~masak/journal/39152 17:24
japhb masak++ # RAWK. 17:25
17:29 actualeyes left 17:30 justatheory joined
lichtkind can anybody confitm the string method flip ? 17:33
confirm 17:34
moritz_ rakudo can ;-) 17:35
rakudo: say "foo".flip
p6eval rakudo 1b06df: OUTPUT«oof␤»
moritz_ S32 can, too
and the test suite
17:36 barney left
skids lichtkind: history on that -- .reverse was for all 3 hash, list, string. It was changed to .flip for string and .invert for hash (with altered behavior) 17:36
because it was mondo confusing 17:37
lichtkind skids++ moritz++ thanks
17:38 justatheory left 17:40 jdv79_ joined, jdv79 left
lichtkind forces flip string context? 17:43
moritz_ aye 17:44
rakudo: say 24.flip
p6eval rakudo 1b06df: OUTPUT«42␤»
moritz_ wow, this feels like the good old times half a year ago: I come back from a weekend being offline, and have two new rakudobugs sitting in my mail queue
www.perlmonks.org/?node_id=773394 # my current thoughts about the pugs repo and the test suite 17:45
lichtkind moritz_: why its rarely these days? 17:47
moritz_ lichtkind: because I don't tend to find so many new rakudobugs
(and I don't spend so many weekends hacking Perl 6 either :/ ) 17:49
lichtkind moritz_: so jnthn improved his buf shiding skillz?
bug hiding 17:50
moritz_ lichtkind: hey, they aren't all hidden, some even get fixed ;-) 17:51
lichtkind ... rumors 17:52
invert revertes the key => value relation?
17:52 kst left, s1n1 joined
moritz_ rakudo: my %a = (a => 3, 'foo' => [<bar baz>]); say %a.invert.perl 17:52
p6eval rakudo 1b06df: OUTPUT«[3 => "a", "bar" => "foo", "baz" => "foo"]␤» 17:53
17:53 kst joined
lichtkind wie ich mir dachte, thanks 17:54
17:54 s1n1 left
pugs_svn r27162 | moritz++ | [t] rename TASKS to spec/TODO 17:55
r27163 | moritz++ | [t/spec] s/MONKEY_PATCHING/MONKEY_TYPING/ as per r26973
r27164 | moritz++ | [t/spec/TODO] update with recent spec changes
17:55 s1n1 joined 17:56 justatheory joined
pmurias moritz_: re moving to git - using git-svn is always the option 17:58
moritz_ pmurias: I do that now... but if we move the test suite out of the pugs repo one day, then we can just as well use a different version control system 17:59
pmurias what are the benefits of moving it out?
moritz_ basically getting rid of the association with pugs 18:00
which, in the mind of most people, is a dead animal
and it doesn't help to view the spec test as being implementation independent, either
anyway, I'm not sure if it's worth the trouble 18:01
18:02 Molaf left, Molaf joined
pmurias throwing pugs out of the pugs repo would be a better solution ;) 18:02
moritz_ yes, but it kinda feels... rude
18:03 aindilis joined
s1n1 how do i import subs into (or export from) a module so that i can invoke them without the class/namespace? 18:06
18:06 s1n1 is now known as s1n_yapc
skids s1n1: add an "is export" trait. 18:07
18:07 justatheory left
s1n_yapc skids: s10? 18:07
moritz_ module A { sub foo is export { ... } }; 18:09
then in another file
use A;
foo();
Su-Shee ha, I had the same question on my mind, thanks for the anwser. :) 18:10
s1n_yapc moritz_: how can i say all subs are exported?
skids (also works with methods, but exports a sub with invocant as the first parameter) 18:11
moritz_ s1n_yapc: by marking them all with 'is export'. I don't think there's a magic for that.
skids (that part is in S12) 18:12
s1n_yapc moritz_: nothing like 'module A is export { sub foo {...}; sub bar { ... } }'?
moritz_ s1n_yapc: don't know.. something similar exists for classes and 'is rw', so the idea can't be off very far ;-) 18:13
s1n_yapc suggests spec change
moritz_ suggests thinking more about it first ;-) 18:14
skids once you had a module that exported everything by default, how would you indicate a non-exported sub when you wanted one? 18:18
moritz_ very good point 18:19
moritz_ found a (hypothetical) way to access previous elements from gather/take 18:22
my @a := gather { for @list { take $_; # access @a here } } 18:23
skids moritz: or @a <== gather {...}
moritz_ skids: that's even nicer ;-) 18:24
skids (hope you don't expect it to work already, then :-)
moritz_ I had the faint hope that my idea might work
that would allow an implementation of infix:<...> that would magically become lazy onces lists/arrays are lazy 18:25
skids It's specced in S07
But I doubt it will be available before laziness. 18:26
18:29 tann joined
moritz_ rakudo: say 2 % 1 18:30
p6eval rakudo 1b06df: OUTPUT«0␤»
s1n_yapc rakudo: sub foo($opt?, $other) { say "opt {$opt} other {$other}" }; foo(1, 2); 18:34
p6eval rakudo 1b06df: OUTPUT«opt 2 other 1␤»
s1n_yapc is that right?
moritz_ s1n_yapc: no, should be compile-time error 18:35
s1n_yapc submits
moritz_ s1n_yapc: all optional positionals must go after mandatory ones, iirc
s1n_yapc moritz_: but it was supposed to fail to compile? 18:36
moritz_ s1n_yapc: yes 18:37
skids S06: "Arguments destined for required positional parameters must come before those bound to optional positional parameters." and "Required parameters are specified at the start of a subroutine's parameter list" 18:38
s1n_yapc rt# 49812 could probably be closed now 18:41
moritz_ not sure... I'll ask pmichaud and jnthn for an update 18:43
s1n_yapc moritz_: he was standing in front of me and he said it should probably closed
i mentioned it so someone could check it and do something :) 18:44
moritz_ s1n_yapc: thanks, I'll close it
s1n_yapc moritz_: here to help
Muixirt hi moritz_ did building with clang work? 18:51
moritz_ Muixirt: no 18:52
Muixirt what was the problem? 18:53
moritz_ Muixirt: it send some of the scripts that process PMCs into an infinite loop, and i have no idea why
*sent
progress report: 18:54
$ perl6 -e '1...3'
Could not find non-existent sub infix:...
Tene nice progress 18:55
moritz_ before it tried to parse the ... as . .. and failed to construct a range
Tene Ah. 18:56
moritz_ now it just seems a SMOP 18:58
rakudo: my $x = 1; repeat { say $x++ } until 1; 18:59
p6eval rakudo 1b06df: OUTPUT«1␤»
moritz_ rakudo: my @a = 1, 2, 4; sub f($a, $b) { say "$a|$b" }; f(@a[1..2]) 19:01
p6eval rakudo 1b06df: OUTPUT«too few arguments passed (1) - 2 params expected␤in sub f (/tmp/8bpYRTI3hZ:1)␤called from Main (/tmp/8bpYRTI3hZ:2)␤»
moritz_ rakudo: my @a = 1, 2, 4; sub f($a, $b) { say "$a|$b" }; f(|@a[1..2])
p6eval rakudo 1b06df: OUTPUT«2|4␤»
moritz_ rakudo: my @a = 1, 2, 4; sub f($a, $b) { say "$a|$b" }; f(|@a[*-2..2])
p6eval rakudo 1b06df: OUTPUT«2|4␤»
moritz_ rakudo: my @a = 1, 2, 4; sub f($a, $b) { say "$a|$b" }; f(|@a[*-2..*-1])
p6eval rakudo 1b06df: OUTPUT«2|4␤»
moritz_ doesn't understand why his code doesn't work, then 19:02
19:02 PacoLinux left
moritz_ rakudo: my @a = 1, 2, 4; sub f($a) { say $a }; f(|@a[*-1..*-1]) 19:03
p6eval rakudo 1b06df: OUTPUT«argument doesn't array␤in sub f (/tmp/2x4tmnOO68:1)␤called from Main (/tmp/2x4tmnOO68:2)␤»
amoc rakudo: my @a=1; sub f($a) { say $a }; f(|@a); 19:04
19:04 PacoLinux joined
p6eval rakudo 1b06df: OUTPUT«1␤» 19:04
moritz_ rakudo: my @a = 1, 2, 4; sub f($a) { say $a }; f(|@a[1..1]) 19:06
p6eval rakudo 1b06df: OUTPUT«argument doesn't array␤in sub f (/tmp/a56cpyUqNl:1)␤called from Main (/tmp/a56cpyUqNl:2)␤»
moritz_ rakudo: my @a = 1, 2, 4; sub f($a) { say $a }; f(|@(@a[1..1])) 19:07
p6eval rakudo 1b06df: OUTPUT«2␤»
amoc rakudo: my @a=1,2,4; @a[1..1].WHAT.say; 19:09
p6eval rakudo 1b06df: OUTPUT«Int()␤»
moritz_ right
rakudo: sub f($x) { $x }; f(|1)
p6eval rakudo 1b06df: OUTPUT«argument doesn't array␤in sub f (/tmp/YVDArezQYc:1)␤called from Main (/tmp/YVDArezQYc:2)␤»
moritz_ not very dwimmy, but I'm not sure it's a bug
rakudo: sub f($x) { $x }; say f(|@(1)) 19:10
p6eval rakudo 1b06df: OUTPUT«1␤»
19:13 kst left, kst joined 19:15 wormphlegm joined 19:20 donaldh left, donaldh joined
s1n_yapc if i overload a parent's method, can i call the original parent version from the overloaded one? 19:23
moritz_ yes
(don't ask how, though ;)
s1n_yapc moritz_: syntax?
lol
moritz_ S03 mentions $obj.Class::method 19:24
though the usage in S12:1526 seems to contradict that (?) 19:25
TimToady: any thoughts on the last few lines?
19:42 jferrero left
moritz_ any idea if t/oo/positional_parameters_in_BUILD.t makes any sense? 19:42
seems not. 19:46
pugs_svn r27165 | moritz++ | [t/spec] fudge "use Test" directive for Rakudo 19:47
r27166 | moritz++ | [t/spec] tests for non-lazy infix<...>
r27166 | moritz++ |
r27166 | moritz++ | Also fudged rest of the file for rakudo (hopefully)
r27167 | moritz++ | [t] remove outdated/unspecced test
moritz_ rt.perl.org/rt3/Ticket/Display.html?id=66826 # that's what happened when I tried to implement infix:<...>. Pity. 19:51
pugs_svn r27168 | kyle++ | [t/spec/TODO] Add a link to a discussion about moving old Pugs tests. 19:56
20:00 azawawi joined
azawawi hello 20:01
20:01 ZuLuuuuuu left
azawawi moritz_: ahmadzawawi.blogspot.com/2009/06/pa...iptic.html 20:02
moritz_ consttype.blogspot.com/2009/06/futu...erl-5.html # another, altogether different very good read
azawawi: very nice 20:03
azawawi thx
starwars movie & :) 20:04
20:04 azawawi left
Khisanth moritz_: hopefully it isn't $obj.Class::method, it looks horrible :) 20:22
moritz_ Khisanth: what kind of syntax would you prefer? 20:23
Khisanth something that wouldn't require me to specify the class! 20:24
moritz_ like $obj.SUPER::method? 20:25
that's the Perl 5 way 20:26
20:26 M_o_C left
moritz_ but it's a bit imprecise when multiple inheritance comes into play 20:26
Khisanth I am fine with Class::C3's next::method() 20:28
having to memorize family trees is no my idea of fun
moritz_ well, maybe reading S12 will tell you how it's done 20:29
20:33 kst left 20:34 kst joined
Khisanth waits for FF to stop thrashing 20:36
20:39 pmurias left 20:44 cotto left 20:50 mikehh_ joined 20:51 hercynium joined 20:54 ejs joined, hercynium left 20:57 digitalise joined, synth left, digitalise left 21:02 justatheory joined 21:03 Su-Shee left, cotto joined
japhb Who is the working tell bot right now? 21:05
moritz_ phenny is, I think 21:06
japhb phenny: tell azawawi In ahmadzawawi.blogspot.com/2009/06/pa...ptic.html, the last bullet point is incorrect: "Use of C++ constructor syntax (in Perl 6 new Foo should be written Foo->new)." 21:07
phenny japhb: I'll pass that on when azawawi is around.
japhb moritz_: thank you!
moritz_ japhb: you're welcome 21:08
perlgeek.de/blog-en/perl-6/new-oper....writeback summary of my activity tonight
21:09 iblechbot left 21:13 mikehh left 21:15 ejs left 21:16 frew left 21:30 ejs joined 21:31 s1n_yapc left, dukeleto left 21:32 Whiteknight left 21:36 payload left 21:40 ejs left, frew joined 21:42 yahooooo left 21:43 kidd_ joined 21:45 frew left 21:59 kst left 22:00 kst joined 22:02 yahooooo joined 22:03 cotto left 22:09 cotto joined 22:13 viklund left 22:22 eMaX left 22:30 fridim_ left 22:33 nihiliad joined 22:51 mikehh_ is now known as mikehh 22:54 baest left 22:55 flexibeast left 22:59 PacoLinux left 23:05 ihrd joined 23:19 sri_kraih left 23:20 donaldh left
lichtkind night 23:20
23:20 lichtkind left, donaldh joined 23:24 sri_kraih joined 23:31 Eevee joined, bacek joined 23:32 mjk joined 23:33 Muixirt left 23:34 kst left, kst joined 23:35 mjk left 23:36 payload joined 23:59 lichtkind joined
lichtkind moritz_: did you see i included your blog on www.perlfoundation.org/perl6/index....umentation 23:59