»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'perl6: say 3;' or rakudo:, niecza:, std:, or /msg p6eval perl6: ... | irclog: irc.perl6.org/ | UTF-8 is our friend!
Set by sorear on 4 February 2011.
00:09 thou joined
dalek ecza: b3cb68b | sorear++ | src/niecza:
Remove non-enum uses of trivial_eval
00:10
00:11 pat_js left 00:14 Boonfarm joined
[Coke] sorear: yay, I also feel guilty about that a bit, but I did add a feature or two. (and copy half a dozen from rakudo.) 00:14
00:15 Boonfarm left 00:20 thou left 00:28 benabik joined
sorear rakudo: enum Foo <a b c>; say Foo.^roles 00:28
p6eval rakudo 7006f7: OUTPUT«Method 'roles' not found for invocant of class 'Perl6::Metamodel::EnumHOW'␤ in method dispatch:<.^> at src/gen/CORE.setting:788␤ in block <anon> at /tmp/E0L1e5Iq6r:1␤ in <anon> at /tmp/E0L1e5Iq6r:1␤»
sorear rakudo: enum Foo <a b c>; say Foo.^role_typecheck_list
p6eval rakudo 7006f7: OUTPUT«Method 'role_typecheck_list' not found for invocant of class 'Perl6::Metamodel::EnumHOW'␤ in method dispatch:<.^> at src/gen/CORE.setting:788␤ in block <anon> at /tmp/6v8HiUVYDG:1␤ in <anon> at /tmp/6v8HiUVYDG:1␤»
sorear rakudo: enum Foo <a b c>; say Foo.^mro
p6eval rakudo 7006f7: OUTPUT«Foo() Int() Real() Cool() Any() Mu()␤»
00:29 [particle] joined
sorear rakudo: enum Foo <a b c>; say Foo.^does_list 00:29
p6eval rakudo 7006f7: OUTPUT«1␤»
00:36 LlamaRider joined 00:39 PacoAir left 00:40 Chillance left 00:47 zjmarlow joined 00:49 whiteknight joined 00:55 muixirt left, wooden left 00:58 tokuhirom joined
dalek ecza: 98c7c82 | sorear++ | / (2 files):
Change CommonEnum et al to be a role
01:05
01:06 replore_ joined 01:11 LlamaRider left 01:14 tokuhirom left
[Coke] should .isa take string reps of class names? 01:34
(there are spec tests for that, but it seems wrong.
01:34 wooden joined, wooden left, wooden joined
dalek ecza: 03689a4 | coke++ | t/spectest.data:
run S29-any/isa.t
01:36
ast: 116f2dd | coke++ | S29-any/isa.t:
fudge for niecza
01:46 fridim_ left
cognominal we will have to find another logo to denote world domination : www.worldipv6launch.org/wp-content/...-trans.png 02:06
ho, I forgot. we already got one. camelia, world domination thru butterfly effect. 02:07
02:23 dnewkirk left 02:31 shinobicl___ joined 02:33 whiteknight left 02:44 replore_ left
colomon o/ 02:59
sorear /o
colomon what's the word with nextwith? 03:06
03:33 orafu left 03:35 orafu joined 03:36 wolfman2000 joined 03:39 Psyche^ joined 03:42 Patterner left, Psyche^ is now known as Patterner
sorear colomon: bit of a bad spec interpretetation is all 03:59
TimToady: ping
TimToady hah, just sat down at my computer... 04:00
sorear o/
TimToady: S06:2804 04:01
if 'nextwith' (or the handler for the exception nextwith throws) is going to add 'self' in, then I guess CallFrame.args has to strip it out
TimToady [Coke]: in general, a classname should be looked up with ::($string) 04:02
sorear presumably it would strip out the self iff .sub ~~ Method 04:03
is this a reasonable interpretation?
TimToady I think that's what the user will expect
04:06 am0c left
sorear ponders the value of callframe.args(:all) 04:11
dalek ecza: b723f45 | sorear++ | / (2 files):
In nextwith/CallFrame.args, hide the invocant of methods

  irclog.perlgeek.de/perl6/2012-01-20#i_5019037
04:17
04:18 Trashlord left 04:20 Trashlord joined
sorear colomon: try that 04:21
04:22 shinobicl___ left 04:33 bonsaikitten is now known as DrEeevil 04:40 thou joined 04:43 birdwindupbird joined
dalek ecza: 06b3d2a | sorear++ | / (4 files):
Switch enums to using the proper evaluator; turn Order into a true enum
04:59
05:04 ponbiki joined
dalek ecza: e748acd | sorear++ | src/ (3 files):
mergeback; kill off qpvalue and trivial_eval for real
05:20
05:28 birdwindupbird left 05:29 birdwindupbird joined 05:40 ponbiki left 06:24 PacoAir joined 06:28 PacoAir left 06:29 am0c joined 06:30 molaf joined, JimmyZ_ joined
JimmyZ_ nom: class A { has $.a = 1; has @.a = 2,3; } ; say A.new.a; 06:32
p6eval nom 7006f7: OUTPUT«1␤»
JimmyZ_ nom: class A { has @.a = 2,3; } ; say A.new.a;
p6eval nom 7006f7: OUTPUT«2 3␤»
JimmyZ_ how can I get the second attr value? 06:33
06:33 alabala joined
JimmyZ_ nom: class A { has @.a = 2,3; has $.a = 1; } ; say A.new.a; 06:33
p6eval nom 7006f7: OUTPUT«2 3␤»
TimToady perl6: class A { has $.a = 1; has @.a = 2,3; } ; say A.new.a; 06:44
p6eval niecza v13-313-ge748acd: OUTPUT«===SORRY!===␤␤Two definitions of method a (see line 1) at /tmp/tocHFz3Pjs line 1:␤------> class A { has $.a = 1; has @.a ⏏= 2,3; } ; say A.new.a;␤␤Unhandled exception: Check failed␤␤ at /home/p6eval/niecza/boot/lib/CO…
..rakudo 7006f7: OUTPUT«1␤»
..pugs b927740: OUTPUT«*** ␤ Unexpected ","␤ expecting "_", fraction, exponent, term postfix, operator or "}"␤ at /tmp/BQzFMXD4yp line 1, column 35␤»
TimToady niecza has the correct response here
JimmyZ_ :) 06:45
geekosaur that did seem pretty wrong... 06:46
06:46 kaleem joined
JimmyZ_ wonders where it is speced 06:46
06:47 wolfman2000 left
JimmyZ_ perl6: my @a = 1,2,3 ; my $a = 1; 06:47
p6eval niecza v13-313-ge748acd: OUTPUT«Potential difficulties:␤ @a is declared but not used at /tmp/Fzqoch7oQZ line 1:␤------> my ⏏@a = 1,2,3 ; my $a = 1;␤ $a is declared but not used at /tmp/Fzqoch7oQZ line 1:␤------> my @a = 1,2,3 ; my ⏏$a = 1;␤␤»… 06:48
..pugs b927740, rakudo 7006f7: ( no output )
geekosaur indirectly, I think; it's specced as generating a getter method, by necessity only one such with a given name can exist
06:52 JimmyZ_ left 06:54 wtw_ joined
geekosaur and, well, I cannot imagine the silent overwriting that rakudo appears to be doing is correct; even if overwriting were correct, it should produce a warning 06:54
moritz can imagine it 07:03
moritz has a pretty good imagination
geekosaur oh, I can imagine *someone* doing it, but it seems inconsistent with the goals of p6 07:06
07:08 nebuchadnezzar left 07:09 nebuchadnezzar joined
nebuchadnezzar hi 07:09
moritz hello nebuchadnezzar 07:12
07:15 alabala left 07:18 koban joined
jnthn Rakudo isn't silently overriding it at all 07:32
It checks if such a method was already defined.
And if it was, then doesn't generate an accessor
Since the user may be supplied their own.
Of course, that means that the first accessor is generated, and the second is not. 07:33
perl6: class A { has $.a; method a() { } } 07:34
p6eval niecza v13-313-ge748acd: OUTPUT«===SORRY!===␤␤Two definitions of method a (see line 1) at /tmp/hoZ8P_namn line 1:␤------> class A { has $.a; method a⏏() { } }␤␤Unhandled exception: Check failed␤␤ at /home/p6eval/niecza/boot/lib/CORE.setting line 919…
..pugs b927740, rakudo 7006f7: ( no output )
jnthn Niecza is wrong on this, given previous discussions.
moritz but if the user wants to supply his own accessor, shouldn't he use $!a instead? 07:38
commute & 07:39
jnthn moritz: No, because then .has_accessor will be false in attribute introspection
07:39 carlin left
jnthn And that'd in turn mean you couldn't set it in .new() 07:39
07:42 thou_ joined, thou left
geekosaur so really both are partly wrong. seeing that one has been declared by the user, fine; but double implicits with no manual declaration should generate at least a warning and probably an error 08:06
sorear jnthn: ...so rakudo doesn't install accessors until compose time? 08:10
moritz nom: class A { has $.x; BEGIN { say A.new(x => 5).x } } 08:11
p6eval nom 7006f7: OUTPUT«===SORRY!===␤Method 'new' not found for invocant of class 'A'␤»
dalek kudo/nom: 0291402 | moritz++ | src/core/Range.pm:
Return an Int from Range.pick(1)

It is not very consistent, but that is what some spectests want. Oh well.
08:14
08:32 domidumont left 08:36 domidumont joined 08:38 thou_ left 08:40 am0c left, am0c joined 08:53 araujo left 08:54 daxim joined
sorear -> sleep 08:59
jnthn sorear: I think it's even spec that they should be installed then. 09:02
moritz nom: role R { has $.x }; class A does R { }; use MONKEY_TYPING; augment class A { }; 09:11
p6eval nom 029140: ( no output )
moritz nom: use MONKEY_TYPING; augment class Date { };
p6eval nom 029140: ( no output )
masak mornin', #perl6 09:14
moritz \o masak
masak what a beautiful day for macro hacking! 09:18
moritz immediately has a haunting melody, "what a beautiful morning in my life" 09:19
masak maros: say "OH HAI" 09:27
macros: say "OH HAI"
tadzik o/ 09:28
moritz p6eval: help
p6eval moritz: Usage: <(nom|pugs|nqplua|perlesque|nqprx|yapsi|alpha|highlight|partcl|nqpnet|star|mildew|nqp|niecza|std|rakudo|b)(?^::\s) $perl6_program>
masak moritz++ # thanks
tadzik: \o
moritz yapsi: say 1
p6eval yapsi: OUTPUT«1␤»
moritz std: \o 09:29
p6eval std 40d10f7: OUTPUT«===SORRY!===␤Undeclared routine:␤ 'o' used at line 1␤Check failed␤FAILED 00:01 107m␤»
moritz std: \o/
p6eval std 40d10f7: OUTPUT«===SORRY!===␤Bogus term at /tmp/oJItbv0aBA line 1 (EOF):␤------> \o/⏏<EOL>␤Undeclared routine:␤ 'o' used at line 1␤Parse failed␤FAILED 00:01 109m␤»
masak hm, something seems to have bitrotted in the macros branch... 09:31
$ ./perl6 -e 'macro foo { quasi { my $a = 5; say $a } }; foo'
Cannot assign into a PMCNULL container
I can't recall having that error before.
moritz did you merge newest nom into the branch?
masak no. that's one of the things I'm planning to do today.
moritz then how come it bitrotted? 09:32
did you change the nqp revision or something?
masak not really.
it could be that I never tried that case.
need tests... :)
ok, so plan for today: (1) rebase to latest nom. (2) write some tests. (3) start attacking the outer-fixup problem. 09:33
moritz I happen to have an auld build of the macro branch lying around, unchanged since the dawn of that branch... well, since Oct 12
and it reports the very same error
masak goodie.
yeah, it's highly unlikely that it's something new. 09:34
moritz: I think this is the error you found around that time:
$ ./perl6 -e 'macro foo { my $a = 5; quasi { say $a } }; foo'
Null PMC access in find_method('gist') in sub say at src/gen/CORE.setting:4937
09:39 overrosy left
masak heh -- git conflict when trying to rebase macros on nom. :) that's alright -- I didn't expect less. 09:39
masak gets to work
09:40 overrosy joined
masak conflict resolved. rebase complete. spectesting. 09:43
09:44 zhangkaizhao joined, zhangkaizhao left 09:45 zhangkaizhao joined
moritz that conflict didn't seem to take much work to resolve :-) 09:49
masak: do you know about git-rerere?
masak rerere? no.
moritz it stands for "Reuse recorded resolution of conflicted merges" 09:50
masak moritz: most conflicts I get in git projects are of the "if git had access to the editor changes made, it could resolve this itself" kind.
moritz basically you set rerere.enabled = 1 in your ~/.gitconfig
masak hm.
moritz and then whenever you do a merge conflict, and resolve it, it remembers your resolution
and if you get the same conflict again, it reuses your resolution
masak neat. 09:51
moritz very convenient -- I don't know why it's not enabled by default
masak sets this flag
10:15 mj41 joined 10:43 donri joined 10:46 bacek joined 10:50 kaleem left
masak getting two failures in t/spec/S12-methods/multi.rakduo. (tests 5 and 11) 10:59
that's on the macros2 branch, which I'm about to push. haven't tried it on the nom branch yet -- will do that now. 11:00
moritz 11 fails on nom too 11:01
masak but not 5?
moritz not ok 5 - Call with wrong number of args should complain about args# TODO RT #66006
it's TODOed 11:02
how can it fail?
ah, maybe your test harness doesn't like the # in the reason
masak oh!
no, it's just me being a bit rusty.
it *does* fail, because TODO tests most often do. I ran it outside of the harness. 11:03
even noticed the TODO comment, but ignored it...
dalek ast: f8abad9 | moritz++ | S12-methods/multi.t:
make fudging a bit more robust

seems some test harnesses do not like the # character inside a TODO or SKIP notice
masak ok, so macros2 is no worse than nom, then.
dalek kudo/macros2: 646b7d1 | masak++ | / (5 files):
implemented quasi quotes and macros

This works:
  - Macro declarations
  - Calling a macro (using `macro()` and `macro` and operators)
  - Quasi quotes
11:07
kudo/macros2: 23057ef | masak++ | src/Perl6/Actions.pm:
decontainerize quasi AST before attr lookup

Many nqp ops will decontainerize for you, but getattr is not one of them. Occasionally the quasiquote would be hidden inside a container layer and the getattr would fail. This is now fixed.
kudo/macros2: b857759 | masak++ | src/Perl6/Actions.pm:
make it possible to return from macros

Kudos to moritz++ for discovering this use case.
masak sorry about the commit spam. I was afraid that might happen.
these are all old commits, but since they've been rebased, dalek reports them as new ones.
I see no reason to keep the 'macros' branch around on github, so I'm deleting it. 11:08
there's a class which I planned to call Perl6::AST (by analogy with Perl6::Compiler etc). right now in the branch it's called AST because of namespace restrictions in World at the time I wrote it. 11:13
those might've been fixed -- I'll see about renaming it.
but jnthn and I were discussing perhaps naming it Perl6::Quasi or something instead.
I'm a bit doubtful -- it feels like referring to a string as a "qq" or whatever. "qq" and "quasi" are things pertaining to the literal for creating the object, not the object itself. 11:14
moritz QuasiAST :-) 11:15
masak er... sounds like QQStr to me. 11:17
once it's a Str, the "qq" is gone. once it's an AST, the "quasi" is gone. 11:18
moritz well, if the string has interpolations, it never becomes a Str inside the compiler 11:19
masak right. its evaluation will have to be delayed till runtime. 11:21
but an AST never survives till runtime, I think. 11:22
it's purely a compile-time object.
oh! it might be that there *is* a distinction worth making here... 11:23
a Perl6::QuasiAST might be a pre-macro-evaluation AST with the "holes" still in there. 11:24
moritz well, macro compile time and macro apply time
masak exactly.
and a Perl6::AST is a "finished" AST with all the pieces in place.
since I'm not doing holes yet, all I have is Perl6::AST.
11:34 GlitchMr joined
jnthn Just don't call it QAST :P 11:38
masak :P
11:56 araujo joined, araujo left, araujo joined
masak huh -- suddenly I'm getting errors about not finding $*ST -- oh! because those are runtime errors, because contextuals are dodgy :) 12:02
well. easy enough to fix.
jnthn dodgy? :) 12:04
It's called $*W now, though :) 12:05
masak yeah, I know.
I applied my old patches during the rebase, and didn't think to comb them for occurrences of $*ST.
jnthn ah :)
masak I'm on it.
renaming AST to Perl6::AST still doesn't work. that sucks. we need to be able to serialize things in namespaces eventually. 12:06
jnthn masak: Well, you're a Rakudo developer, you have the ower to track down and fix issues as well as say they suck :) 12:07
*power
I doubt it's anything to do with serialization per se in this case.
Perhaps that the Perl6:: namespace in Metamodel.pm is GLOBAL-merged into CORE.setting's GLOBAL 12:08
I'm pondering making all those things lexical classes to avoid that.
masak ok.
(dang, now I can't just complain and have others fix things for me? outrageous!) 12:09
jnthn
.oO( It sucks that macros don't work in Rakudo yet! )
:P :P
masak *lol*
masak cries "uncle" :) 12:10
12:14 kaleem joined
masak TimToady: what does a `map` on a multidimensional slice do? what does a `grep` on a multidimensional slice do? can I hyperop a multidimensional slice with something that has the same shape but isn't declared to have the same shape? 12:19
12:24 kaleem left 12:27 kaleem joined 12:28 bluescreen10 joined
dalek kudo/macros2: 0890cc1 | masak++ | src/Perl6/Actions.pm:
chased SymbolStable --> World rename
12:31
masak now there's some other problem. debugging. 12:32
moritz wha' abou' i'? 12:33
12:33 kaleem left
moritz met a lady from middle england who swallows all the t's a' the end of syllables 12:33
it's quite funny to listen to :-) 12:34
12:34 lichtkind_ joined
masak sounds like I imagine Cockney. 12:34
moritz: getting ===SORRY!=== 12:35
too few positional arguments: 2 passed, 3 (or more) expected
moritz when you do what?
masak at parse time, without file or line.
when I declare a macro.
currently investigating.
probably something changed from under me.
12:36 lichtkind left, lichtkind_ is now known as lichtkind
moritz did you try --ll-exception 12:36
masak no, but now I will. 12:37
12:43 bluescreen10 left 12:44 lichtkind left 12:46 am0c left
masak routine that dies is create_signature_object, called from macro_def. 12:51
yup, my invocation only has two args, while all the others in Actions.pm have three. 12:52
moritz does it miss $/ maybe? 12:53
12:53 bluescreen10 joined
masak yeah, something like that. 12:54
seems to be an addition since the 'macros' branch base.
fixing.
moritz yes, for better error reporting
guess who complained about missing line numbers :-) 12:55
masak I can't imagine.
12:56 jaldhar left, jaldhar joined
masak tadzik: actually, the name "Niecza" comes from some half-understood lyrics of a Czech music video on Youtube. we originally thought it meant "nie mamy czas", but it turned out they were really singing "my mamy czas" :) 12:56
("we don't have time" and "we have time", respectively) 12:57
12:57 bluescreen10 left 12:58 bluescreen10 joined
masak the music video in question is humorously subtitled with what it *sounds* like in Swedish. the words in the chorus sound like "min man e kass" ("my husband is worthless") 12:58
13:01 jaldhar left
dalek kudo/macros2: 071c4db | masak++ | src/Perl6/Actions.pm:
fixed another Red Queen

The's now one extra parameter to create_signature_object. Adjusting macro_def accordingly.
13:05
13:05 ggoebel left
jnthn masak: my *mame* cas :) 13:06
13:10 pat_js joined
masak ah. 13:10
13:16 donri left 13:21 donri joined 13:55 slavik left
[Coke] can someone install libgd 2.0.28 or h 13:56
igher on feather?
not strictly perl related, but definitely open source. ;)
moritz [Coke]: I'll take a look 13:58
[Coke] appreciates it, thanks. 13:59
dalek ast: c491713 | (Solomon Foster)++ | S (5 files):
Niecza refudge to deal with the Order issue.
14:00
14:01 cj left
dalek ecza: 20527e1 | (Solomon Foster)++ | t/spectest.data:
Turn off tests which no longer work due to Order issue.
14:01
[Coke] :(
moritz [Coke]: gd 2.0.36 installed 14:02
[Coke] moritz: \o/ ! 14:03
github.com/coke/famflags will be very happy now, thank you. :)
14:03 zhangkaizhao left
moritz also runs a system upgrade 14:03
[Coke] So, who changed the tests to use the Order enum instead of the equivalent numbers? 14:04
isn't that sort of raising the bar for raising the bar's sake frowned upon?
jnthn No, it's fixing the tests.
Enums stringify to the enum's name. 14:05
And the ops are spec'd as returning the enum
14:05 zhangkaizhao joined
jnthn If left as they were, a correct implementation that did this would fail the tests.; 14:05
moritz that would be very much LTA 14:06
14:06 fsergot joined
jnthn Yes, testing for correct behavior tends to be preferable. ;) 14:06
colomon The tests could have been fixed in such a way to remain compatible with, you know, every version of Perl 6 that existed before this week.
fsergot o/
colomon indeed, it would have been easier... 14:07
jnthn colomon: er. How exactly?
fsergot 'somefile'.lines still works?
colomon Numify the result of the comparisons
jnthn Great, then tests for comparison ops are also testing enum numification.
moritz fsergot: it returns all lines in the string 'somefile', which is just one 14:08
[Coke] jnthn: they're already testing enum stringification: that's better? ;)
fsergot So, i should give there filehandle?
[Coke] s/already/now/
fsergot Works now, moritz++ :) 14:09
moritz fsergot: yes. open('somefile').lines
[Coke] (actually, I'm not sure they are, based that on a previous comment here.) 14:10
In any case, I just want us to be careful to segregate what we're testing so that implementations that do one thing aren't forced to do another unrelated thing in order to pass that test. that's all. (having fought that with no support from the test suite authors on partcl, it's no fun.) 14:11
14:12 daxim left
jnthn [Coke]: imho, the tests as they stand now are the most obvious spectests to write for the ops in question 14:12
masak fsergot: or do a cast. 'somefile'.IO.lines 14:15
fsergot Oh, it's great. masak++ 14:16
moritz dislikes the cast for opening files
fsergot Why? :)
moritz for one it hides the fact that there's much more going on than a coercion
if you want to grep for locations where you read files, it's much nicer if you can just grep for 'open' 14:17
[Coke] jnthn: best we can hope for, thank you. ;)
moritz it also means that we have to support IO operations on unopened IO objects that auto-open 14:18
masak moritz: the cast doesn't open the file.
moritz masak: right, the .lines does
masak: which is the really weird part
IO on unopened file handles?
what could possibly go wrong?
masak I don't mind it.
[Coke] curses. GD.pm still isn't happy.
masak moritz: now writing is another matter.
moritz: but making reading easier is fine. 14:19
fsergot Interesting...
moritz masak: it means that reading from previously-exhausted file handles can automagically go back and re-open the file
unless we explicitly mark such filehandles as "dead", or so 14:20
hm, maybe we should.
14:22 sayu joined, koban left
moritz hm, the dist-upgrade on feather broke all perl modules 14:23
"ooops"
Juerd All? 14:24
moritz ah no, aptitude offers me a small downgrade
[Coke] ah, is that why GD.pm is borked?
moritz commute, bbi30
[Coke]: maybe
masak moritz: yes, I think we should. 14:25
easy enough to create a fresh IO object. 14:26
I never really liked IO objects either. the only thing worse than IO objects is the IO spec :/
we can't even rename "IO" to the much more sensible "File", because they're some odd mix of file, path, and STDIN-like thingy. 14:27
14:36 PacoAir joined 14:39 PacoAir_ joined, PacoAir left, PacoAir_ is now known as PacoAir 15:06 nornagest joined
flussence I'd be happy with a 1:1 copy of perl5's IO stuff 15:11
pat_js open $foo = 'filename'? 15:19
i'm glad that doesn't work in perl6 anymore
flussence well, minus stuff like 2-arg open...
pat_js that's one arg open 15:20
flussence two arg is bad enough :)
15:34 wtw_ left 15:37 mj41 left
colomon sorear: last night's patches seem to help a lot. Thank you! 15:37
moritz [Coke]: do you use the system mono on feather? 15:38
[Coke] moritz: yes. 15:43
(/usr/bin/mono) 15:44
moritz it seems to be causing problem in an upgrade :/ 15:46
jnthn yay, course done :) 15:49
jnthn preps for decommute
[Coke] moritz: I can regroup if you have to upgrade it. 15:51
jnthn bbi 3h 15:53
15:54 fsergot left 15:56 thou joined 15:57 hundskatt left
moritz [Coke]: if a bit of downtime is OK for you, I'd remove it, upgrade the rest of the system, and then try to install it again 16:00
and if that fails, put a non-debian binary in /usr/local/
moritz does it 16:06
moritz must remember to install mono-complete afterwards 16:07
16:15 fsergot joined 16:17 MayDaniel joined
moritz short poll: does anybody use any GUI stuff on feather? 16:17
it seems we have a complete X server, desktop environment etc. installed 16:18
even gimp
I can't imagine wanting to use a program like gimp over SSH....
16:20 fsergot left
[Coke] it's ok with me, yes. 16:21
and the only thing I wanted was libGD so I could do some image manipulation once in a blue moon.
[Coke] doesn't need any other GUI stuff.
moritz [Coke]: does GD.pm work now?
[Coke] checking. 16:23
Nope, fail. 16:24
moritz how?
[Coke] /home/coke/.cpanm/build.log
Might very well be a GD issue.
16:25 kaare_ joined
Juerd moritz: Every time I do a dist-upgrade on feather, I'm amazed at what people installed on it 16:28
moritz Juerd: I'll go with forgiveness > permission and remove the X environment 16:29
Juerd moritz: It's good to see that you have the same reaction, it makes me feel slightly more normal :)
moritz if somebody wants it back, they'll complain :-)
[Coke] or reinstall it.
Juerd xlibs and such are useful to get stuff like inkscape, which can also produce output on the command line.
But gimp... a desktop environment... nahhh
16:31 alvis left 16:34 zjmarlow left
moritz we also have both apache and nginx 16:34
[Coke] is that needed for feather.perl6.nl ? (I use that.) 16:35
moritz apache2 is needed for that. nginx not, afaict
16:35 birdwindupbird left 16:36 MayDaniel left 16:40 fsergot joined 16:45 fsergot left, ggoebel joined 16:47 az5112 joined
az5112 Hello. Label/loop/next question. Has the label syntax been agreed on already? Can I 'next' to the outer loop? 16:50
16:53 spine_ joined
moritz rakudo doesn't implement labels yet 16:54
not sure about niecza
az5112 thanks moritz
moritz [Coke]: the GD thing doesn't look like an obviously misinstalled libgd or so, no idea what the problem is 16:59
[Coke]: but note that the system perl comes with a hopefully working GD.pm 17:00
17:03 araujo left 17:09 pat_js left
[Coke] moritz: ooh. 17:09
[Coke] will try the sysperl.
(can you install modern perl? ;) 17:10
er, Modern::Perl, to be specific. (and it's only a nice to have.) 17:11
hurm. feather.perl6.nl/~coke/ is 404ing.
17:37 alvis joined 17:40 arlinius joined
moritz [Coke]: Modern::Perl installed 17:43
17:43 kaleem joined 17:50 crashtest joined 17:53 slavik joined 17:57 Chillance joined 17:58 fsergot joined
masak my, what an elegant board game: www.cameronius.com/games/span/ 17:59
I was going to suggest a Perl 6 implementation, but perhaps a JS implementation for browsers would be more apt...
[Coke] perl -MModern::Perl -e1; -> dies 18:02
/usr/local/bin/perl ?
moritz++ 18:10
18:16 MayDaniel joined
moritz [Coke]: oh sorry, something went wrong with /usr/bin/perl 18:17
[Coke]: fixed now 18:19
installing mono now 18:21
18:21 spine_ left 18:25 GlitchMr left
[Coke] moritz++ 18:25
moritz installs debfoster and prepares himself for a loong rung 18:26
*run
18:27 zhangkaizhao left
moritz wow, there's a g++3.3 installed on feather 18:30
and a 4.0 18:32
and a 4.5
moritz keeps only the latter
... and a 4.2 18:33
... and a 4.4
slavik lol?
moritz I'm not sure if that still counts as "amusing" 18:34
moritz removes the first patch of 155 packages, half a gig of disc space freed 18:38
we also had 3 different mediawiki versions installed 18:39
benabik oy
moritz and lots and lots and lots of perl modules
bank of america payment processing modules
and stuff like that
oh, and another webserver, lighttpd 18:40
[Coke] imagines some people will be surprised when they return. 18:44
moritz that could happen, yes 18:46
but considering that recently cron hasn't been running for a month, and nobody noticed... I wouldn't count on it 18:48
[Coke] dns just vanished. 18:50
moritz that is... unfortunate 18:53
moritz debugs
$ root@feather:~# cat /etc/resolv.conf
nameserver 127.0.0.1
18:54 birdwindupbird joined
moritz ... and no DNS server running. Great. 18:54
Juerd: is there a DNS server that feather can use? or should it resolve itself?
18:55 wolfman2000 joined
Juerd moritz: Hm, it should be running unbound as a local cache 18:55
moritz: Which in turn can use 193.200.132.160 as its source
(That .160 is redundant)
moritz Juerd: I might have accidentally uninstalled unbound. Will reinstall it
Juerd I see
Please configure it to use 193.200.132.160 18:56
moritz ok
benabik I used to love debfoster. I tend to use aptitude's "mark as auto-installed" flag now.
18:57 MayDaniel left
moritz Juerd: is there a backup of /etc/unbound/ easily available from somewhere? 18:59
Juerd No, I have full system backups but it takes a few hours to restore something :) 19:00
I'd rather reconfig it myself :D
moritz Juerd: ok, then it's easier if I read up on how to do it :-)
Juerd Don't worry, I'll do it
19:01 araujo joined
[Coke] hopes niecza is using the distracted moritz time to pull ahead. ;) 19:01
moritz Juerd: ok, thank you
and sorry for breaking it in the first place :/
[Coke] dns back, yay. 19:08
... and gone again, whoops.
moritz if Juerd++ doesn't need to test unbound right now, I can put the IP of a public DNS server into resolv.conf 19:09
until it's configured again
Juerd Fixed 19:10
[Coke] no rush. I got my stuff out in the moment it was back. ;)
Juerd++ moritz++ 19:12
19:12 araujo left
moritz [Coke]: feather.perl6.nl/~coke/rakudo_summary.out is also back 19:12
TimToady nom: .say for Date.new("2012-01-01") .. Date.new("2012-12-31"); 19:14
p6eval nom 029140: OUTPUT«No applicable candidates found to dispatch to for 'Numeric'. Available candidates are:␤:(Mu:U \$v, Mu %_!)␤␤ in method Numeric at src/gen/CORE.setting:649␤ in sub infix:<==> at src/gen/CORE.setting:2276␤ in method infinite at src/gen/CORE.setting:4207␤ in method r…
TimToady nom: .say for Date.new("2012-01-01") ... Date.new("2012-12-31"); 19:15
moritz nom: my $x = Date.today; say ++$x;
p6eval nom 029140: OUTPUT«(timeout)»
nom 029140: OUTPUT«Date.new(2012, 1, 21)␤»
moritz nom: say Date.today.succ
p6eval nom 029140: OUTPUT«Date.new(2012, 1, 21)␤»
masak nom: class A { has @.a = 2,3; has $.a = 1 }; say "alive", A.new.a 19:17
p6eval nom 029140: OUTPUT«alive2 3␤»
masak anyone submit this rakudobug?
or maybe it was submitted long ago?
moritz nom: say Date.today cmp Date.today.succ
p6eval nom 029140: OUTPUT«Order::Increase␤»
masak submits rakudobug, Justin Case
niecza: class A { has @.a = 2,3; has $.a = 1 }; say "alive", A.new.a 19:18
p6eval niecza v13-313-ge748acd: OUTPUT«===SORRY!===␤␤Two definitions of method a (see line 1) at /tmp/3qmxK2RJYF line 1:␤------> class A { has @.a = 2,3; has $.a ⏏= 1 }; say "alive", A.new.a␤␤Unhandled exception: Check failed␤␤ at /home/p6eval/niecza/boot/…
TimToady you can submit the Date bugs too, unless moritz fixes it :)
moritz masak: did you see jnthn++'s explanation in the backlog?
masak: he says it's intentional, and it makes sense to me 19:19
masak no. looking.
moritz nom: say (Date.today cmp Date.today.succ) < 1
p6eval nom 029140: OUTPUT«Bool::True␤»
masak now I see it. it may make sense to you -- I think the above should be an error.
TimToady masak: speaking of backlog, excellent questions, meaning I'll have to think more about hyper/map stuff
masak because it indicates that the user is confused.
TimToady: :) 19:20
geekosaur see my later response to jnthn about it
masak sees it 19:21
moritz geekosaur: if we want it that way, we have to spec it
masak I agree with geekosaur.
and I say error. 19:22
two different-sigiled public attrs, one in parent and one in child, are of course fine.
moritz should has $!x; has @!x; also error out?
masak no.
hm, wait :)
moritz should has $.x; method x() { $!x } error out?
masak no. 19:23
TimToady not according to current spec, but the other way is arguable
moritz so, it's ok to not generate one accessor, but it's not ok to not generate two accessors?
masak I like the fact that $.x; method x doesn't error out.
moritz: yes.
moritz that is... confusing.
masak moritz: I have a rationale, too.
geekosaur no, which was jnthn's case, and my response was that that is acceptable and correct, it's specifically the case of multiple implicitly generated accessors that should somehow indicate that there is a conflict
(also note that the case of { has $.x; has @;x; method x() } is also fine) 19:24
er, @.x
geekosaur kan tipe
masak hm. yes, that case should be fine, but "don't do that" :) 19:25
moritz: if I add another public attribute with a different sigil but the same name, I *want to know* that I did, at the earliest possible moment.
moritz: not thought a silent logical bug when I run the wrong accessor. 19:26
moritz: if I add a method that overrides an auto-generated attribute, I'm only happy if I don't have to go in and change the attribute's twigil from dot to bang, because both I and the compiler know what I just did.
moritz nom: say (1..*).perl
p6eval nom 029140: OUTPUT«1..Inf␤»
masak that's why it's two different behaviors. 19:27
nom: say (*..1).perl
p6eval nom 029140: OUTPUT«-Inf..1␤»
moritz nom: say 'Inf' ~~ Inf
p6eval nom 029140: OUTPUT«Bool::True␤»
masak nom: say '*' ~~ *
p6eval nom 029140: OUTPUT«Bool::True␤»
masak :D
benabik nom: 'dsfahj' ~~ * 19:28
p6eval nom 029140: ( no output )
benabik nom: say 'dsfahj' ~~ *
geekosaur yes, that, exactly
p6eval nom 029140: OUTPUT«Bool::True␤»
geekosaur trying to split attention over too many places, brain is not braining enough :/
TimToady whatever always matches anything
masak appends all this to the ticket so that jnthn knows what to fix :)
moritz masak: fwiw I think that's something you could fix yourself if you wanted 19:29
19:29 sayu left
moritz the attribute generation code is all Perl 6, and quite accessible 19:29
masak oh right, I'm an implementor!
(dang!) 19:30
[Coke] nom: say *~~*..*
p6eval nom 029140: OUTPUT«Bool::False␤»
masak includes this in the ticket too so that jnthn can nag him
[Coke] nom: say *--*~~*..*
p6eval nom 029140: OUTPUT«WhateverCode.new()␤»
[Coke] wonders how long we can make that. ;)
moritz nom: say (*..1)[0..4] 19:31
p6eval nom 029140: OUTPUT«-Inf -Inf -Inf -Inf -Inf␤»
moritz nom: say (*..1).list
p6eval nom 029140: OUTPUT«Failed allocation of 4096 bytes␤Parrot VM: PANIC: Out of mem!␤C file src/gc/alloc_memory.c, line 105␤Parrot file (not available), line (not available)␤␤We highly suggest you notify the Parrot team if you have not been working on␤Parrot. Use parrotbug (located in parr…
moritz nom: say (1..*).list
p6eval nom 029140: OUTPUT«...␤»
moritz fwiw the Date range bug is that Range.infinite checks $.max == Inf 19:33
and that calls Date.Numeric
which in turn dies
TimToady huh
moritz "huh" sums it up pretty well 19:34
TimToady that's the first bug
moritz I know that ... is a different beast, yes
TimToady why does the ... form timeout?
19:34 pat_js joined
moritz because Date has no ACCEPTS method 19:35
and thus it falls back to Any.ACCEPTS, which uses === semantics
TimToady which should work
if it's an immutable value type
moritz how could === possibly know that Date is immutable? 19:36
TimToady by the fact that .WHICH returns something that compares that way
moritz hm, right
TimToady === is just .WHICH eqv .WHICH really
maybe Date.Numeric should just return something arbitrary like # of days since 2000 19:38
or the Julian day, or whatever
nom: say Date.new(0) 19:39
p6eval nom 029140: OUTPUT«Default constructor only takes named arguments␤ in method new at src/gen/CORE.setting:561␤ in block <anon> at /tmp/DEuySNezl4:1␤ in <anon> at /tmp/DEuySNezl4:1␤»
TimToady LTA error there too
nom: say Date.new(0,0,0)
p6eval nom 029140: OUTPUT«month out of range. Is: 0, should be in 1..12␤ in method check-value at src/gen/CORE.setting:8071␤ in method check-date at src/gen/CORE.setting:8079␤ in method new at src/gen/CORE.setting:8387␤ in method new at src/gen/CORE.setting:8393␤ in block <anon> at /tmp/U… 19:40
TimToady nom: say Date.new(20120101)
p6eval nom 029140: OUTPUT«Default constructor only takes named arguments␤ in method new at src/gen/CORE.setting:561␤ in block <anon> at /tmp/W_QoMQ6r3m:1␤ in <anon> at /tmp/W_QoMQ6r3m:1␤»
TimToady nom: say v2012.1.1
p6eval nom 029140: OUTPUT«===SORRY!===␤Confused at line 1, near "say v2012."␤» 19:41
19:41 dukeleto left
TimToady lunch & 19:41
19:42 dukeleto joined, dukeleto left, dukeleto joined, dukeleto left 19:43 dukeleto joined, dukeleto left, kaleem left, dukeleto joined, dukeleto left 19:44 dukeleto joined, dukeleto left, dukeleto joined, dukeleto left 19:45 dukeleto joined, dukeleto left 19:46 dukeleto joined, wolfman2_ joined 19:47 dukeleto left, dukeleto joined 19:48 ashleydev left, ashleydev joined 19:49 wolfman2000 left
jnthn "it's specifically the case of multiple implicitly generated accessors that should somehow indicate that there is a conflict" - I love the "somehow" in this. Please remember that custom meta-attributes and custom accessor generation will be quite a common meta-programming pattern - or afaik Moose meta-hackers do such things quite often. 19:55
I agree with the goal, just not quite sure how to factor it so the "so was this generated" magic goes in the right place.
masak noted.
I see the need for such caution. 19:56
all I'm arguing for is for the default to be helpful :)
jnthn I mean, the obvious way for me to deal with the ticket is to put some hack into Attribute.compose. But I can already see the followup pain. :)
masak let's plan ahead as much as makes sense. 19:57
I mean, we don't want attribute metanauts to curse us forever, either.
jnthn Maybe we should detect it at an actions/world level.
masak sounds like a composition thing, to me. 19:58
jnthn ?
moritz $ ./perl6 -e 'say (Date.new(2012,1,18)..Date.today).list'
2012-01-18 2012-01-19 2012-01-20
masak "did this group of similarly-named private attrs all want an attribute? hang them!"
moritz $ ./perl6 -e 'say (Date.new(2012,1,18)...Date.today).list'
2012-01-18 2012-01-19 2012-01-20
doy perl -Moose -E'has foo => (is => "ro"); has bar => (reader => "foo")' # You are overwriting an accessor (foo) for the foo attribute with a new accessor method for the bar attribute at ...
for what it's worth
moritz hm, maybe we just need a bit more introspection facility 19:59
jnthn doy: Does it complain if you wrote your own method foo already?
masak doy: yes, but Moose doesn't have subs overriding those declarations. Perl 6 does.
doy jnthn: no
19:59 wolfman2000 joined
masak right. 19:59
jnthn oh
I know
moritz not only "does this thing have an accessor", but also "was it autogenerated"
jnthn ClassHOW.compose's loop over the attribute meta-objects to compose them could easily do it and throw
doy what do you mean "subs overriding those declarations"?
jnthn Or warn.
masak it's easy: human-generated trumps (and silences) autogenerated. several autogenerateds conflict. 20:00
doy: just a 'sub foo {}' after your example.
jnthn: throw sounds excellent. 20:01
jnthn: but only if there's no explicit method!
jnthn masak: er
20:01 wolfman2_ left
jnthn masak: OK, example time! :) 20:02
masak heh :)
jnthn class A { has $.a; method a() { } } # no throw
masak nod
jnthn class A { has $.a; has @.a;} } # throw
masak nod
jnthn (er, not 'cus of the extra } )
masak :P
go on.
jnthn class A { has $.a; has @.a; method a() {} } # also throw
masak nope.
jnthn No?
masak not in my twisted universe. 20:03
jnthn irons masak's universe
masak human-generated always wins.
well, actually.
I don't mind if that one throws.
jnthn masak: OK, human generated is the "safety valve" for "I know what I'm doing"?
masak right.
jnthn masak: Well, to me it means something REALLY odd is going on.
masak because it suppresses the autogenerated ones, it removes the conflict.
jnthn I mean, for one what is A.new(a => ...) gonna do?
masak you're not allowed to do that with attributes that have no publ... oh wait :P 20:04
jnthn I'm worried about more than just the accesosr generation conflict. :)
masak but srsly. my way makes sense, and indicates there's a third thing we don't have a name for.
jnthn Hm. 20:05
masak A.new(a => ...) is suspect *every time a method has overridden the autogenerated accessor*.
[Coke] Hm is not a good name for it.
masak *lol*
20:05 molaf left
jnthn [Coke]: How about "UmmmmDunno" :P 20:05
[Coke] much better. 20:06
jnthn masak: How so?
masak: We don't call the accessor to set the attribute.
masak jnthn: yeah. and that's weird.
jnthn masak: Otherwise you'd only be able to set "is rw" attrs with new.
masak hm, true.
masak needs to slow down and think
jnthn Also please don't make object construction even slower than we already make it. :) 20:07
masak rightright.
but something sunky is goin' on here.
jnthn masak: I'm inclined to do the conservative thing and throw on my third case for the time being.
masak: I'm gonna do it in ClassHOw 20:08
*ClassHOW
Which is subclassable. :)
masak why do we override the autogenerated accessor with out own? because we made a refactor inside our encapsulation and we want to honor the API.
so we're moving from the autogenerated accessor to more of a derived-value accessor.
moritz so we need a custom .new too 20:09
masak like if we switch from $!students which only counts 'em to @!students which knows their names, too.
dalek kudo/nom: 21107e5 | moritz++ | src/core/Range.pm:
fix non-numeric, no-Str ranges
kudo/nom: 6f8846b | moritz++ | src/core/Temporal.pm:
custom Date.WHICH
masak or from $.students to @!students + method students { +@!students }, rather. 20:10
feels like a reasonable refactor to do.
but the .new(students => 7) call will break expectations, and there's no automatic way to fix it.
jnthn No, in some cases you have to write code. :) 20:11
(e.g. a BUILD method :))
masak right, custom constructor.
jnthn *submethod
20:11 ashleydev left, ashleydev joined
masak jnthn: I'm fine with $.a and @.a conflicting, even if there's a method a :) 20:12
I'm fine with it throwing, I mean.
jnthn masak: OK. And as I said, I'll do it in ClassHOW, so folks can write a module to do otherwise if they wish. :) 20:14
Makes me much happier than my actions/world suggestion.
masak jnthn++ # happiness-driven development
jnthn pulls latest stuffs
20:15 wolfman2000 left 20:16 not_gerd joined
not_gerd hello, #perl6 20:16
moritz jnthn: I have to admit I haven't fully spectested the last two commits
jnthn moritz: ok :)
moritz nom: say ('Ine' ... 'Inf').list
p6eval nom 029140: OUTPUT«Ine Inf␤»
not_gerd jnthn: could you test if NQP still builds with gist.github.com/1649338 applied?
jnthn moritz: Of your revertfest earlier, what made it back in? 20:17
masak not_gerd! \o/
moritz jnthn: everything except <prior>
not_gerd jnthn: on non-Cygwin Windows, that is
jnthn moritz: OK
not_gerd: Yeah, I don't do Cygwin Windows. :) 20:18
moritz tests not_gerd's patches on linux
jnthn Happy you're fixing it for those who do, though. :)
not_gerd: Trying it now. 20:19
not_gerd jnthn, moritz: thanks
btw, how did the DLLs get copied on valilla-Windows? 20:20
win32_libparrot_copy got set, but never used...
jnthn not_gerd: No, they didn't...there's a trac ticket abotu that. 20:21
Seems the line in question got lost at some point.
OK, it builds and passes tests with that patch here. 20:22
not_gerd: Do you have a commit bit, or want me to apply?
moritz same here (though some qregex tests still fail, due to the backtrcking-into-subrules thing=
jnthn (will wait for moritz++'s result too)
moritz: Yeah, I'll get onto those tomorrow.
not_gerd feel free to apply - I probably won't do any more fixes in the near future 20:23
(aside from a corresponding rakudo-fix, that is...)
dalek p: 4319fd2 | jnthn++ | / (2 files):
Cygwin build fixes. Patch courtesy of not_gerd++.
20:25
20:27 bluescreen10 left
moritz $ perl Configure.pl 20:29
/home/moritz/p6/rakudo/install/bin/nqp: error while loading shared libraries: libparrot.so.3.11.0: cannot open shared object file: No such file or directory
not_gerd :(
moritz that's rakudo's configure
jnthn moritz: I...thought you just said it worked? :)
moritz nqp passed all its tests
and it installed
jnthn oh, *Rakudo's*
moritz but rakudo doesn't work with the installed nqp :(
jnthn hm. It did here.
not_gerd it shouldn't actually do anything on non-Windows platforms... 20:30
could you paste the generated Makefile?
moritz sure, just a sec
not_gerd: moritz.faui2k3.org/tmp/Makefile 20:31
oh wait, that's the rakudo makefile
you want the nqp Makefile, no?
not_gerd yes, please
moritz not_gerd: moritz.faui2k3.org/tmp/nqp-Makefile
20:32 MayDaniel joined 20:33 sftp left
moritz it's the first time I've built with parrot 3.11.0 20:34
maybe it's not even related to the nqp patch
20:34 ksi joined
moritz let me check a few things before you invest too much time in debugging 20:34
jnthn afk for a little bit 20:36
20:39 bluescreen10 joined
moritz not_gerd, jnthn: never mind, cannot be reproduced after a clean rebuild 20:40
20:41 crashtest left 20:42 az5112 left
not_gerd moritz: could you check if LIBPARROT is now set in NQP's Makefile? 20:42
if so, then that was the error
dalek ast: 1c8bdfe | moritz++ | S03-operators/range.t:
unfudge a now passing test
20:43
moritz not_gerd: not set 20:44
20:44 dnewkirk_ joined
moritz not_gerd: I think that I recompiled parrot and didn't reconfigure nqp 20:45
not_gerd: which is usually fine, but not if you upgrade between parrot versions
because then the paths change
not_gerd from what I can see, you somehow ended up with an empty inst_libparrot_ldflags 20:47
20:50 tarski joined
moritz is the current DateTime also immutable? 20:51
20:51 araujo joined, araujo left, araujo joined
masak in the spec? yes. 20:51
tarski will perl6 like perl5 be postmodern: support topicalization, context, TIMTOWTDI, etc
moritz yes
tarski good to hear 20:52
moritz though it does try to offer one obvious way, in addition to various other ways to do stuff :-)
tarski one obvious way is fine, as long as that obvious way gets out of your way, otherwise youre now talking modernism 20:54
masak tarski: I have a little mental bell going off whenever people ask "will perl6..." as if it exists solely in the future. 20:55
moritz masak: I was also very close to writing "it already has" 20:56
masak I think it's worth pointing out that there is software, *today*, under the name "Perl 6".
tarski: not laying any blame, just gently pointing out. you should try Rakudo or Niecza, they're both great. :) 20:57
tarski masak: will do.
masak \o/ 20:59
moritz perl6: say 'OH HAI I EXISTS' 21:00
p6eval pugs b927740, rakudo 6f8846, niecza v13-313-ge748acd: OUTPUT«OH HAI I EXISTS␤»
moritz somehow the name "taski" rings a bell, but I have trouble locating it... does that name appear in a mathematical theorem? 21:01
doy en.wikipedia.org/wiki/Banach%E2%80%...ki_paradox
tarski moritz: yes tarski's theory of truth, and he laid much of the framework for model theory
moritz doy: that was the one I was thinking of, yes 21:02
masak moritz: "Some people, when faced with a problem, say 'I know, I'll use the Banach-Tarski theorem!'"
a recent tweet by someone ;) 21:03
moritz :-)
moritz loves meta jokes
dalek ast: 02f41d9 | moritz++ | S32-temporal/Date.t:
Date objects should smart-match correct
21:05
moritz nom: say Date.today ~~ Date.today
p6eval nom 6f8846: OUTPUT«Bool::True␤»
moritz nom: say ~(Date.new('2012-01-14) .. Date.today) 21:06
p6eval nom 6f8846: OUTPUT«===SORRY!===␤Unable to parse postcircumfix:sym<( )>, couldn't find final ')' at line 2␤»
moritz nom: say (Date.new('2011-01-14') .. Date.today).elems
p6eval nom 6f8846: OUTPUT«372␤»
moritz nom: say (Date.new('2011-01-14') ... Date.today).elems
p6eval nom 6f8846: OUTPUT«372␤» 21:07
moritz both Date problems fixed that TimToady++ discovered earlier
(and tested)
TimToady nom: say Date.today 21:08
p6eval nom 6f8846: OUTPUT«Date.new(2012, 1, 20)␤»
TimToady that should .gist to .Str, not to .perl, I think
nom: say ~Date.today
p6eval nom 6f8846: OUTPUT«2012-01-20␤»
moritz then we don't know from the output that it's a Date 21:09
[Coke] nom: my $a="100.B".."102.B";say $a;say "$a";
p6eval nom 6f8846: OUTPUT«"100.B".."102.B"␤100.B 101.B 102.B␤»
TimToady .gist is supposed to lose information, or something like that...
it's obvious that anything that starts 2012- is a date
[Coke] moritz++ 21:10
moritz TimToady: yeah, that it's a date, but not that it's a Date (SCNR) :-)
TimToady I would go so far as to say that a human will recognize 2012-01-20 much faster than Date.new(2012, 1, 20)
21:15 birdwindupbird left, bluescreen10 left 21:17 araujo left
TimToady rosettacode.org/wiki/Last_Fridays_of_year#Perl_6 thanks to moritz++ 21:19
not_gerd Rakudo Cygwin patch: gist.github.com/1649678 21:21
should unbreak --gen-nqp --gen-parrot
[Coke] I am tempted to go through and rosettacode everything in coldfusion. 21:26
...
... ok, that passed, good.
mikemol Do it.
[Coke] I would rather continue to muck the stalls of niecza & rakudo. 21:27
TimToady: is the [1..12] needed there? 21:29
TimToady [0] is Any() 21:30
I could do .month-1
[Coke] eh.
this way looks nicer.
TimToady yeah, eh
[Coke] TimToady++
TimToady well, I'm going to replace $_ with .Str
though I wish .gist did that
21:32 y3llow_ joined 21:33 pothos_ joined 21:34 pothos left, y3llow left 21:35 y3llow_ left, y3llow joined
masak perl6: say "2012-01-01".Date 21:36
p6eval pugs b927740: OUTPUT«*** No such method in class Str: "&Date"␤ at /tmp/8ZwzYudqxZ line 1, column 5 - line 2, column 1␤»
..niecza v13-313-ge748acd: OUTPUT«Unhandled exception: Unable to resolve method Date in class Str␤ at /tmp/MQUuo_DsbY line 1 (mainline @ 2) ␤ at /home/p6eval/niecza/lib/CORE.setting line 3107 (ANON @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 3108 (module-CORE @ 60) ␤ at /home/…
..rakudo 6f8846: OUTPUT«Method 'Date' not found for invocant of class 'Str'␤ in block <anon> at /tmp/z8cowbKDql:1␤ in <anon> at /tmp/z8cowbKDql:1␤»
21:36 pothos_ left, pothos joined
TimToady arguably Date("2012-01-01") should work 21:36
21:37 y3llow left, y3llow joined
masak aye, maybe that's clearer. 21:38
but... aside from namespace pollution, I see no harm in having a Cool.Date method.
21:39 pothos left
masak it'll make someone somewhere happy :) 21:39
colomon I want a Cool.Date
:)
21:39 pothos joined
masak there you go :) 21:39
[Coke] I'd settle for Any.Date
masak :P
21:39 y3llow left
masak blog post: "Perl 6 gets a Cool.Date" 21:39
21:40 y3llow joined 21:41 pat_js left
masak actually... having it sit on Cool doesn't confer any real advantage compared to having it sit on Str... but somehow, on Str it feels more clutter-y and difficult to defend. 21:44
tadzik o/ 21:45
masak \o 21:46
jnthn back, though a tad headachey 21:47
not_gerd jnthn: gist.github.com/1649678
(test needed)
jnthn k 21:48
testing 21:49
21:49 dnewkirk_ left, dnewkirk joined 21:52 MayDaniel left 21:57 Trashlord left
jnthn not_gerd: built fine here 21:59
not_gerd jnthn: great 22:00
it *should* not affect non-Windows builds, but feel free to get confirmation before applying...
not_gerd looks at moritz 22:01
jnthn OK. It's commited locally already, but will wait a moment for pushing in case somebody else has chance to test it.
22:02 REPLeffect left, dalek left
masak TimToady: that last-Fridays solution is woefully imperative, and wastes resources. here's how it should be done: 22:03
nom: my $year = 2038; say ~.value.reverse.first: *.day-of-week == 5 for (Date.new("$year-01-01") .. Date.new("$year-12-31")).classify: *.month
22:03 p6eval left
masak p6eval: hey! 22:03
jnthn chuckles
22:03 dalek joined, ChanServ sets mode: +v dalek
masak must be a year 2038 bug. 22:04
anyway, it works locally :)
22:04 p6eval joined, ChanServ sets mode: +v p6eval
masak nom: my $year = 2038; say ~.value.reverse.first: *.day-of-week == 5 for (Date.new("$year-01-01") .. Date.new("$year-12-31")).classify: *.month 22:04
geekosaur crashing the bot was so much fun the first time that you want to do it again? :p 22:05
p6eval nom 6f8846: OUTPUT«2038-01-29␤2038-02-26␤2038-03-26␤2038-04-30␤2038-05-28␤2038-06-25␤2038-07-30␤2038-08-27␤2038-09-24␤2038-10-29␤2038-11-26␤2038-12-31␤»
masak geekosaur: I don't see why it should crash the bot.
p6eval nom 6f8846: OUTPUT«2038-01-29␤2038-02-26␤2038-03-26␤2038-04-30␤2038-05-28␤2038-06-25␤2038-07-30␤2038-08-27␤2038-09-24␤2038-10-29␤2038-11-26␤2038-12-31␤»
masak there we go!
22:05 REPLeffect joined
masak it even got the first one :) 22:05
my motto: use .classify more :) 22:06
22:09 dnewkirk left
TimToady fell free to add a second solution :) 22:12
feel, even
masak does so
not_gerd will be back in a minute 22:14
22:14 not_gerd left 22:16 not_gerd joined, kaare_ left
masak rosettacode.org/wiki/Last_Fridays_of_year#Perl_6 now has the alternative solution. 22:19
is there a sub form of classify? 22:20
nom: say &foo.WHAT
p6eval nom 6f8846: OUTPUT«===SORRY!===␤Symbol '&foo' not predeclared in <anonymous> (/tmp/aPf3k2EWx5:1)␤»
masak nom: say &classify.WHAT
p6eval nom 6f8846: OUTPUT«Sub()␤»
masak oh, there is! 22:21
masak twiddles
22:21 icwiener joined 22:22 dalek left, dalek joined, ChanServ sets mode: +v dalek 22:24 d4l3k_ joined 22:25 dalek left
TimToady niecza: my sub infix:<_> ($a,$b) is equiv(&infix:<==>) { $a eqv $b }; say "foo" !_ "bar" 22:26
p6eval niecza v13-313-ge748acd: OUTPUT«===SORRY!===␤␤Cannot negate _ because like infix:<==> operators are not iffy enough at /tmp/olpCGKoStx line 1:␤------> &infix:<==>) { $a eqv $b }; say "foo" !_⏏ "bar"␤␤Parse failed␤␤»
TimToady sorear: ^^ doesn't think _ is chaining
22:27 d4l3k_ is now known as dalek
TimToady niecza: my Bool sub infix:<_> ($a,$b) is equiv(&infix:<==>) { $a eqv $b }; say "foo" !_ "bar" 22:27
22:27 ChanServ sets mode: +v dalek
TimToady niecza: say "hi" 22:29
nom: say "hi" 22:30
masak p6eval is a bit slow today.
TimToady hmmm
masak give her a minute.
TimToady the 'my Bool' was already 3 minutes ago
p6eval niecza v13-313-ge748acd: OUTPUT«===SORRY!===␤␤Cannot negate _ because like infix:<==> operators are not iffy enough at /tmp/AffjXr_7mq line 1:␤------> &infix:<==>) { $a eqv $b }; say "foo" !_⏏ "bar"␤␤Parse failed␤␤» 22:31
niecza v13-313-ge748acd: OUTPUT«hi␤»
nom 6f8846: OUTPUT«hi␤»
TimToady heh, didn't know p6eval could hold its breath that long
in any case, an infix that returns Bool should be considered iffy 22:32
bbl & 22:33
jnthn not_gerd: Pushing your patches, if any Linux-folk find they bust things I'm sure they'll yelp, but it looks unlikely. 22:34
dalek kudo/nom: 8d9c2fe | jnthn++ | docs/ChangeLog:
Update ChangeLog.
kudo/nom: 25967be | jnthn++ | / (3 files):
Fix build on Cygwin; patch courtesy of not_gerd++.
kudo/nom: f5da44b | jnthn++ | docs/ChangeLog:
Mention Cygwin build fixes in ChangeLog.
kudo/nom: 5dbca1f | jnthn++ | src/core/Temporal.pm:
Use native types in ymd-from-daycount, shaving ~7% off masak++'s example.
22:35
not_gerd jnthn: next stop: cross-compiling native Win64 binaries from Cygwin 22:41
masak nom: my @a = <a b c>; say @a>>.uc
p6eval nom 6f8846: OUTPUT«A B C␤»
masak nom: my @a = <a b c>; say .>>uc given @a 22:42
p6eval nom 6f8846: OUTPUT«===SORRY!===␤Confused at line 1, near "say .>>uc "␤»
masak niecza: my @a = <a b c>; say .>>uc given @a
p6eval niecza v13-313-ge748acd: OUTPUT«===SORRY!===␤␤Unsupported use of bare 'say'; in Perl 6 please use .say if you meant $_, or use an explicit invocant or argument at /tmp/jQud39_6rN line 1:␤------> my @a = <a b c>; say⏏ .>>uc given @a␤␤Confused at /tmp/…
masak huh.
std: my @a = <a b c>; say .>>uc given @a
p6eval std 40d10f7: OUTPUT«===SORRY!===␤Unsupported use of bare 'say'; in Perl 6 please use .say if you meant $_, or use an explicit invocant or argument at /tmp/IjR_hkdgsK line 1:␤------> my @a = <a b c>; say⏏ .>>uc given @a␤Confused at /tmp/IjR_hkdgsK lin…
masak oh, all right! :P
so I can't have .>>meth for some reason... :) 22:43
jnthn er, it's @a>>.foo, not @a.>>foo :)
masak oh! 22:44
nom: my @a = <a b c>; say >>.uc given @a
p6eval nom 6f8846: OUTPUT«===SORRY!===␤Preceding context expects a term, but found infix > instead at line 1, near ">.uc given"␤»
masak niecza: my @a = <a b c>; say >>.uc given @a
p6eval niecza v13-313-ge748acd: OUTPUT«===SORRY!===␤␤Unsupported use of bare 'say'; in Perl 6 please use .say if you meant $_, or use an explicit invocant or argument at /tmp/fIpJxj_DiM line 1:␤------> my @a = <a b c>; say⏏ >>.uc given @a␤␤Method call found… 22:45
masak std: my @a = <a b c>; say >>.uc given @a
p6eval std 40d10f7: OUTPUT«===SORRY!===␤Unsupported use of bare 'say'; in Perl 6 please use .say if you meant $_, or use an explicit invocant or argument at /tmp/OpXVfjFafv line 1:␤------> my @a = <a b c>; say⏏ >>.uc given @a␤Method call found where infix e…
masak I was confused, but my point still holds. :)
hah! this is how magical macros are: 22:46
$ ./perl6 -e 'my @a; push @a, 2; macro foo { push @a, 1; quasi {} }; say @a.perl; foo' 22:47
Array.new(1, 2)
(yes, that actually runs locally)
jnthn heh :)
nice ;)
masak I know!
something to blow people's noodles with in Erlangen :P 22:48
jnthn prefers his noodles stir-fried rather than blown, but ok... :P 22:50
dalek kudo/nom: e3c0af1 | jnthn++ | src/core/Hash.pm:
Speed up hash indexing dramatically by avoiding a bunch of delegation. Re-use is good, but not on such a hot path. Shaves a further 11% off masak++'s date example (and probably shaves a bit off many programs).
22:53
masak huh!
$ ./perl6 -e 'macro foo { quasi { foo } }; say foo'
AST.new()
I... I don't think that's correct.
should this be just an infinite recursion?
I can easily see people accidentally using infix:<+> inside of their macro infix:<+>... 22:54
aha! now I get why it returns that. :) 22:55
the macro is entered twice -- once at parse time, and once at run time. 22:56
TimToady: when a macro is called in the &foo() form, what does it return? 22:57
oh, the spec actually says. 22:58
the AST from &foo() is supposed to be intercepted, and eval'd.
just like I guess the arguments have to be intercepted at the front of the run-time macro call, and ASTized. 22:59
22:59 jferrero left
masak jnthn: do you think it's a good idea to auto-wrap macros under the hood so they behave like this? 22:59
jnthn "auto-wrap"? 23:00
masak I mean, wrap as an automatic part of passing from compile to run.
sorear good * #perl6
masak sorear! \o/
jnthn masak: Not sure if that'll do it
masak: macro foo() { blah blah blah }; BEGIN { &foo() }
sorear looks like too much scrollback 23:01
23:01 araujo joined, araujo left, araujo joined
masak oh, but it's such nice scrollback 23:02
jnthn: dang.
23:02 araujo left
masak jnthn: guess the dispatch'll have to typecheck on Macro then. 23:02
jnthn :S
masak: Or macro arguments are implicitly coerced to AST 23:03
masak: Which is a no-op if it gets an AST
masak that works in that end, but not in the other end.
jnthn Which other end? :)
masak returning an AST.
23:04 nornagest left
masak 'sides, it's gonna piss off someone who wants to runtime-call macros on actual ASTs :) 23:04
jnthn Huh? What I suggested will not break that.
masak no, maybe not.
jnthn Returning bit is still le tricky though.
masak it'll just create a discontinuity that people may not expect.
23:05 molaf joined, jferrero joined 23:06 araujo joined, araujo left, araujo joined
masak question is, how will we even dispatch if the macro expects a bunch of ASTs and the arguments are Int, Str etc? 23:06
:/
sorear colomon: What's the Order issue? How did I break Order? 23:07
masak it's almost like the wrapping into ASTs has to be done *before* dispatch, as soon as we realize that the object is a Macro.
jnthn masak: That's why I said coercion.
as AST
Or whatever the new syntax is :)
masak well, AST(Int).
jnthn No, 'cus that'll bust it when the compiler really does pass an AST :) 23:08
AST() I guess :)
masak time to sleep here. 23:09
'night, #Perl6
jnthn 'night o/
23:10 whiteknight joined
jnthn Time for a good, long sleep... & 23:19
23:24 cooper left, cooper joined
colomon sorear: you didn't break Order. But we don't really support it yet. 23:25
23:25 p4 left
colomon sorear: it's there, I see. Just need to chance all the comparison operators to support it. 23:26
sorear: I'll take a stab at it after Henry is asleep.
23:32 tokuhirom joined 23:40 Trashlord joined 23:42 sftp joined 23:49 donri left 23:59 ksi left