»ö« 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:02 benabik joined 00:03 arlinius joined 00:07 arlinius left 00:13 arlinius joined 00:28 fgomez left 00:31 arlinius left, pmurias left 00:32 Chillance left
grondilu rn: class Foo { multi talk { say "hi" } }; Foo.talk; 00:35
p6eval rakudo e6e158: OUTPUT«No such method 'talk' for invocant of type 'Foo'␤ in block at /tmp/BjoGQmlbNn:1␤␤»
..niecza v22-44-g0247fe5: OUTPUT«Potential difficulties:␤ &talk is declared but not used at /tmp/Dqfz8oCBMK line 1:␤------> class Foo { multi talk ⏏{ say "hi" } }; Foo.talk;␤␤Unhandled exception: Unable to resolve method talk in type Foo␤ at /tmp/Dqfz8oCBMK line 1 (ma…
grondilu rn: class Foo { multi method talk { say "hi" } }; Foo.talk; 00:36
p6eval niecza v22-44-g0247fe5: OUTPUT«Unhandled exception: Cannot call talk; none of these signatures match:␤ Foo, Any␤ at /tmp/tLZSMqpd43 line 1 (mainline @ 5) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4211 (ANON @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4212 (module-CORE…
..rakudo e6e158: OUTPUT«hi␤»
grondilu Shouldn't a routine by a method by default inside a class?
Shouldn't a routine *be* a method by default inside a class? 00:37
(so we don't have to explicitely say "mutli method" or "proto method") 00:38
(thus saving seven letters)
diakopter I like the idea 00:42
00:43 bowtie left 00:48 fgomez joined
benabik rn: class Foo { multi method talk { say "hi" } }: Foo.new.talk 00:51
p6eval niecza v22-44-g0247fe5: OUTPUT«===SORRY!===␤␤Illegal use of colon as invocant marker at /tmp/REBoXaJlWs line 1:␤------> Foo { multi method talk { say "hi" } }:⏏ Foo.new.talk␤␤Unhandled exception: Check failed␤␤ at /home/p6eval/niecza/boot/lib/CORE.…
..rakudo e6e158: OUTPUT«===SORRY!===␤Confused␤at /tmp/4cWqSAdkrb:1␤»
benabik rn: class Foo { multi method talk { say "hi" } }; Foo.new.talk
p6eval niecza v22-44-g0247fe5: OUTPUT«Unhandled exception: Cannot call talk; none of these signatures match:␤ Foo, Any␤ at /tmp/ldSphf1lub line 1 (mainline @ 6) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4211 (ANON @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4212 (module-CORE…
..rakudo e6e158: OUTPUT«hi␤»
benabik huh. 00:52
00:59 whiteknight joined 01:13 hypolin joined 01:22 PacoAir left 01:42 thou joined 01:43 thou left, thou_ joined 02:05 whiteknight left 02:12 cooper left 02:13 gootle joined 02:23 thou_ left 02:45 yamita joined
dalek rl6-roast-data: 4ff44cf | coke++ | / (3 files):
today (automated commit)
03:03
03:06 grondilu_ joined
[Coke] hurls github.com/coke/perl6-roast-data/c...bb2#L2R211 for some intrepid rakudo hacker. (invalid free) 03:08
03:09 grondilu left
[Coke] rn: my $oldOUT = $*OUT; my $output; $*OUT = class { method print(*@args) {$output ~= @args.join;}}; print "hi there\n"; $*OUT = $oldOUT; print "XX" ~$output; 03:13
p6eval rakudo e6e158: OUTPUT«XXhi there␤»
..niecza v22-44-g0247fe5: OUTPUT«Unhandled exception: Writing to readonly scalar␤ at /tmp/N7zvzvGQIn line 1 (mainline @ 5) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4211 (ANON @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4212 (module-CORE @ 578) ␤ at /home/p6eval/niecza/li…
[Coke] sorear: ^^
(need that for the rosettacode tests) 03:14
sorear I think niecza is right
hmm, could go either way 03:15
03:32 grondilu_ is now known as grondilu
grondilu rn: print $*OUT, "testing redirection syntax" 03:34
p6eval niecza v22-44-g0247fe5: OUTPUT«TextWriter()<instance>testing redirection syntax» 03:35
..rakudo e6e158: OUTPUT«-testing redirection syntax»
grondilu rn: print $*OUT "testing redirection syntax"
p6eval niecza v22-44-g0247fe5: OUTPUT«===SORRY!===␤␤Two terms in a row at /tmp/LYZn69cZ8q line 1:␤------> print $*OUT ⏏"testing redirection syntax"␤␤Parse failed␤␤»
..rakudo e6e158: OUTPUT«===SORRY!===␤Confused␤at /tmp/2YpqVSRDwC:1␤»
03:41 orafu left, orafu joined 03:42 rurban_ joined 03:46 atrodo left 03:47 rindolf joined
[Coke] r: 1..4.map(**2) 03:47
p6eval rakudo e6e158: OUTPUT«===SORRY!===␤HyperWhatever (**) is not yet implemented. Sorry. ␤at /tmp/kOiSxqgrg7:1␤»
[Coke] r: 1..4.map(* * *)
p6eval rakudo e6e158: OUTPUT«Not enough positional parameters passed; got 1 but expected 2␤ in block at /tmp/9i9glizIab:1␤␤»
03:57 japhb_ joined
japhb_ supernovus, FROGGS, etc: Please take a look at gist.github.com/4158939 ; it's a design for an S11-compliant, hopefully reasonably efficient layout for module files on disk. It uses the pure filesystem when it can, falling back to easily-parsed text files for disambiguation. 04:00
It also tries hard not to fall into the trap of some other dynamic language module systems of requiring LOTS of FS operations to find a module file to load, or a binary database with all the unhappy that entails. 04:01
04:02 rurban_ left
diakopter ooo specs 04:02
er, design 04:03
diakopter has to click Raw to get the lines to wrap
04:05 rurban_ joined
japhb_ Sorry about that, diakopter! 04:05
decommute & 04:07
04:07 japhb_ left, Exodist left 04:08 Exodist joined 04:23 am0c joined 04:24 am0c left, am0c joined 04:36 Psyche^ joined 04:39 Patterner left, Psyche^ is now known as Patterner
japhb thought of an extension to that design on the way home that includes full @*INC support, but needs to cogitate on how to best merge it into the existing design 04:42
sorear I hate @*INC 04:44
it has caused niecza nothing but trouble
japhb sorear, would you mind explaining exactly why? 04:45
sorear allowing precompiled modules which are compared against existing source code to set their own source code paths has created a permanent scar in the space-time continuum in the center of the niecza module loader
I could reasonably support @*INC iff I removed the entire precompilation system 04:46
04:47 tokuhiro_ left, tokuhiro_ joined
japhb sorry, distracted for a moment ... 04:49
when you say "set their own source code paths", do you mean that the compiled versions are allowed to specify what file they were created from, and this doesn't have to match a simple naming convention conversion? 04:50
sorear japhb: the really hair-falling-out crying-in-a-corner moments come when you have to deal with diamonds
if a module is "use"d twice with two different @*INC values, does it get compiled twice? 04:51
if not, which @*INC values do you use in it?
and how does this interact with caching?
I've spent weeks on this; I think there is literally no answer 04:52
japhb takes a few moments to respect the difficulty there.
04:52 rurban_ left
sorear and TImToady has made vague statements in the past that I have interpreted as "P6 doesn't really need @*INC" 04:52
japhb Hmmm, interesting.
sorear although roast currently does
japhb I'm not sure how lack of @*INC interacts with the principle of least surprise. 04:53
sorear it interacts with the principle of "things that make the implementors want to give up and start a nightclub are not good for users" 04:54
japhb
.oO( DNA Lounge )
japhb wonders if "*spec* the most conservative reasonable behavior" is a compromise that could save it 04:56
diakopter lolz nightclub 04:57
japhb (As in, don't leave decisions about your diamond questions to implementors, make a conservative decision and codify it)
japhb needs to find noms now ...
&
sorear at this time? 04:58
05:10 skids left 05:20 telex left 05:30 integral left 05:31 integral joined, integral left, integral joined 05:35 telex joined 05:42 replore_ joined 05:43 replore_ left 05:44 birdwindupbird joined 05:45 kaleem joined
moritz \o 05:47
05:47 Kharec joined
sorear o/ moritz 05:47
dalek ar: 9fadd7d | isBEKaml++ | tools/build/Makefile.in:
Modified Makefile template to include p6doc in installed modules. Fixes #12
05:48
05:53 thou joined 05:57 anuby joined 06:11 tokuhiro_ left, tokuhiro_ joined
dalek kudo/nom: aa635da | (Tobias Leich)++ | src/ (2 files):
added indirection and typed exception for X::Backslash::UnrecognizedSequence
06:14
kudo/nom: 7bcefdd | (Tobias Leich)++ | src/ (2 files):
typed exception X::Backslash::NonVariableDollar
kudo/nom: beea5df | (Tobias Leich)++ | src/Perl6/Grammar.pm:
there is no self.sorry but self.panic
kudo/nom: bfbb051 | moritz++ | src/ (2 files):
Merge pull request #92 from FROGGS/x_backslash

typed exceptions: X::Backslash::UnrecognizedSequence, [...]::NonVariableDollar
06:16 rindolf left 06:17 rindolf joined
dalek kudo/nom: 797af56 | (Amir E. Aharoni)++ | / (2 files):
Signature.ACCEPTS(Signature)

The method was mostly written by jnthn.
06:18
06:19 rindolf left 06:24 GlitchMr joined 06:28 am0c left
lue (just some quick thoughts before bed) japhb: what happens in the case of a module's auth being Any? (e.g. use My::Module:auth<Any>;) 06:31
About S11, why does it seem that C<require> can use either a module name or a filename, but C<use> can only take a module name? 06:32
moritz because C<use> is evaluated at compile time, and variables are typically only initialized after compile time 06:33
re auth, 'Any' is as good a string as any (sic) other
if you don't care about authority, you'd either leave it off completely, or do something like :auth(*) 06:34
lue would much prefer "*.pm" to "Any.pm" (except for the fact that * is a shell wildcard...) 06:35
sorear moritz: auth values must be URIs, in particular they must contain a colon 06:37
:auth<cpan:SOREAR>
06:37 fhelmberger joined, SamuraiJack joined 06:39 kurahaupo left
lue Lastly before I go, I have to agree with sorear on @*INC. My thought would be something along the lines of C/C++, where you can provide a module name (which is searched for in standard directories) or a string literal. (use A::B; or use "./a/b.pm"; but not use $string;) 06:40
lue & 06:46
06:54 Tene left 07:07 popl left 07:14 PacoAir joined
japhb lue & moritz, re: auth 'Any': sorear++ is correct that an auth must contain a colon according to Spec, and I rely on that. 'Any' is a mnemonic choice for an intentionally invalid value. 07:25
07:37 wamba joined 07:43 fhelmberger left 07:55 domidumont joined 08:02 yamita left 08:05 yamita joined 08:09 Kharec left, GlitchMr left 08:10 domidumont left 08:11 fhelmberger joined 08:15 Kharec joined 08:16 hoelzro|away is now known as hoelzro 08:35 FROGGS joined 08:44 kresike joined
kresike good morning all you happy perl6 people 08:45
FROGGS morning
moritz \o
FROGGS moritz: thanks for the merge 08:53
moritz fwiw I've uploaded the star tarball 08:55
just haven't done the announcement yet
08:56 Kharec left
FROGGS any changes since RC0? 08:56
the panda thing, right?
08:57 thou left 09:01 Kharec joined 09:23 dayangkun joined 09:25 sqirrel joined 09:26 erkan left 09:27 cognominal joined 09:30 erkan joined, erkan left, erkan joined 09:33 dakkar joined 09:38 wamba left 09:39 wamba joined 09:42 am0c_ joined 09:43 am0c_ is now known as am0c
dalek rlito: aed21d6 | (Flavio S. Glock)++ | / (4 files):
Perlito5 - js2 - caret Var fix
09:50
09:53 wamba left 09:59 daxim joined 10:00 marloshouse left 10:02 azawawi joined
azawawi hi 10:02
10:03 azawawi_ joined 10:05 hypolin left
azawawi_ paste.debian.net/212959/ # memory + cpu performance bottleneck for 1 == any(@stuff) for 10k+ 10:06
10:06 azawawi left 10:07 azawawi_ is now known as azawawi 10:10 azawawi_ joined 10:11 azawawi left
grondilu rn: class Foo { has ($.a, $.b) is rw }; my Foo $x .= new; $x.a = 13; say $x.perl; 10:15
p6eval rakudo 797af5: OUTPUT«Cannot assign to a readonly variable or a value␤ in block at /tmp/tDfWA5S4P5:1␤␤»
..niecza v22-44-g0247fe5: OUTPUT«Unhandled exception: Unable to resolve method a in type Foo␤ at /tmp/7zzaq9Ntci line 1 (mainline @ 7) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4211 (ANON @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4212 (module-CORE @ 578) ␤ at /home/p6ev…
grondilu r: class Foo { has $.a is rw }; my Foo $x .= new; $x.a = 13; say $x.perl;
p6eval rakudo 797af5: OUTPUT«Foo.new(a => 13)␤»
grondilu do I have to repeat the 'is rw' ? 10:16
moritz seems like, yes
jnthn gah, you want *what* to work... :/
grondilu yes, I want to distribute it
10:16 marloshouse joined
grondilu r: class Foo { has ($.a is rw, $.b is rw) }; my Foo $x .= new; $x.a = 13; say $x.perl; 10:17
p6eval rakudo 797af5: OUTPUT«Cannot assign to a readonly variable or a value␤ in block at /tmp/DDro9vO0W7:1␤␤»
jnthn That one should probably work
grondilu n: class Foo { has ($.a is rw, $.b is rw) }; my Foo $x .= new; $x.a = 13; say $x.perl;
p6eval niecza v22-44-g0247fe5: OUTPUT«Unhandled exception: Unable to resolve method a in type Foo␤ at /tmp/nvjnjG803U line 1 (mainline @ 7) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4211 (ANON @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4212 (module-CORE @ 578) ␤ at /home/p6ev…
jnthn But it's...quite horrible.
Because the thing is parsed as a signature. 10:18
grondilu but according to specs, 'has ($.a, $.b) is rw' should be ok, right? 10:19
jnthn Maybe
It's just horrible to make work.
Because STD has us parsing a signature after a declarator
We then have to go back and undo the signature nature of it.
But only if what follows is not a bind operator in which case we need to emit something different. 10:20
It's a bit "special" :/
grondilu well, I guess I can just write 'has $.a is rw; has $.b is rw' for now. 10:21
jnthn Yes, that's better
No signature mess
azawawi_ star: my @stuff = 1..10000; say "Found" if 1 == any(@stuff); 10:27
p6eval star 2012.10: OUTPUT«(timeout)»
azawawi_ star: my @stuff = 1..1000; say "Found" if 1 == any(@stuff);
p6eval star 2012.10: OUTPUT«Found␤»
azawawi_ jnthn: any clue why is rakudo so slow processing any(@stuff) where @stuff = 1..1000 10:29
jnthn: it also consumes a lot of memory (2.5G+) 10:32
10:34 azawawi_ is now known as azawawi
azawawi what so wrong with any() performance in rakudo 10:38
azawawi tries niecza
10:41 anuby left 10:48 wamba joined
azawawi paste.debian.net/212965/ # Niecza is faster in junction performance than latest rakudo 10:50
paste.debian.net/212966/ # a more accurate comparison 0m8.875s rakudo vs 0m0.963s Niecza 10:52
10:53 SamuraiJack_ joined 10:55 SamuraiJack left 11:00 Kharec left
jnthn azawawi: As I've told you before, that the auto-threader is anything but smart. 11:00
azawawi: It was written way back as a "need something that works" and didn't get optimized yet. 11:01
11:02 Kharec joined, cognominal left, Kharec left, Kharec joined 11:03 imarcusthis- left 11:05 imarcusthis joined, Su-Shee_ joined 11:06 Su-Shee left, Su-Shee_ is now known as Su-Shee 11:09 cognominal joined 11:22 azawawi left
masak oh hai, #perl6 11:22
11:22 mtymula joined
mtymula hello 11:23
11:23 cognominal left 11:24 cognominal joined
masak hello, mtymula 11:25
n: class Foo { multi method talk { say "hi" } }; Foo.new.talk
p6eval niecza v22-44-g0247fe5: OUTPUT«Unhandled exception: Cannot call talk; none of these signatures match:␤ Foo, Any␤ at /tmp/Cl9krQ7IMP line 1 (mainline @ 6) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4211 (ANON @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4212 (module-CORE…
masak sorear: that looks... wrong. :/
tadzik Juerd: ping
masak sorear: [backlogon the bright side, I think you'd 11:28
g'ah.
sorear: [backlog] on the bright side, I think you'd make a pretty decent nightclub.
11:31 yamita left
mtymula r: sub order-beer($type, $pints) { say ($pints == 1 ?? 'A pint' !! "$pints pins") ~ " of $type, please." }; order-beer(type => 'Hogoblin', pints => 1); 11:31
p6eval rakudo 797af5: OUTPUT«Not enough positional parameters passed; got 0 but expected 2␤ in sub order-beer at /tmp/QSW8MI5nr7:1␤ in block at /tmp/QSW8MI5nr7:1␤␤»
mtymula does named parameters work ??
or i am doing something wrong... 11:32
hoelzro :r sub order-beer(:$type, :$pints) { say "$pints $type" } order-beer(:type('Hobgoblin' 11:33
:r sub order-beer(:$type, :$pints) { say "$pints $type" } order-beer(:type('Hobgoblin'), :pints(1))
there we go
apparently the eval bot doesn't care for me =( 11:34
mtymula ok, so there shuld be a semicolon before the name of a parameter?
masak grondilu: consistency is the reason 'multi' doesn't mean 'multi sub' outside of class/role blocks and 'multi method' inside of them.
hoelzro I believe so
masak grondilu: I used to want them to, just like you. I no longer do.
grondilu: the thing that convinced me, I think, is that (unlike in Perl 5) a sub in a class (or even in a method) is a completely valid thing, separate from methods. 11:35
mtymula r: sub order-beer($type, $pints) { say ($pints == 1 ?? 'A pint' !! "$pints pins") ~ " of $type, please." }; order-beer(:type => 'Hogoblin', :pints => 1);
p6eval rakudo 797af5: OUTPUT«Cannot call 'Numeric'; none of these signatures match:␤:(Mu:U \v: Mu *%_)␤␤ in method Numeric at src/gen/CORE.setting:796␤ in sub infix:<==> at src/gen/CORE.setting:2806␤ in sub order-beer at /tmp/6qy0MJBNsF:1␤ in block at /tmp/6qy0MJBNsF:1␤␤»
masak grondilu: so while you in your use case wanted it to mean 'multi method', it's actually quite concievable that someone else would want it to mean 'multi sub'.
hoelzro mtymula: I think it's just type => 'Hobgoblin'
rather than :type
masak aye.
:type<Hobgoblin> works too 11:36
but :type => 'Hobgoblin' creates a Pair with a Pair as a key.
11:36 SmokeMachine left
masak rn: say (:type => 'Hobgoblin').perl 11:36
p6eval rakudo 797af5, niecza v22-44-g0247fe5: OUTPUT«"type" => Bool::True => "Hobgoblin"␤»
masak rn: say (:type => 'Hobgoblin').key.perl
p6eval rakudo 797af5, niecza v22-44-g0247fe5: OUTPUT«"type" => Bool::True␤» 11:37
11:37 SmokeMachine joined
masak infix:<< => >> is right-associative according to S03. so both Rakudo and Niecza should've put in parens there. 11:37
rn: say ('type' => (Bool::True => 'Hobgoblin')).perl 11:38
p6eval rakudo 797af5, niecza v22-44-g0247fe5: OUTPUT«"type" => Bool::True => "Hobgoblin"␤»
masak otherwise you can't distinguish it from this case.
11:38 hoelzro is now known as hoelzro|away
masak (which really could be written without parens) 11:38
moritz I wonder if Pair.perl should use :key(value) in general 11:39
because if we change it (key => 'value'), it can't be used as a named argument anymore
masak I don't see what you mean. surely people don't use .perl output as named arguments? 11:41
mtymula this: order-beer(:type<Hogoblin>, :pints<1>);
does not work...
masak mtymula: oh, and then there's the problem that you're passing named arguments to positional parameters.
and no, that does not work.
(it used to. we lobbied for changing it. I think the resulting spec got rather confusing.) 11:42
jnthn That's OK, I didn't implement the confusing parts :P
mtymula indeed.... it is confusing...
jnthn r: sub foo($positional) { }; foo(1)
mtymula co how do I make it work?? 11:43
p6eval rakudo 797af5: ( no output )
jnthn r: sub foo(:$named) { }; foo(named => 1)
p6eval rakudo 797af5: ( no output )
masak here's the spec change in question: github.com/perl6/specs/commit/94d0...733d0aec04
mtymula: just pass 'Hobgoblin', 1
mtymula: if you don't make the parameters named, why are you passing in named arguments?
jnthn masak: I think mtymula wants to know how to write/use named parameters. 11:44
masak oh.
I also see hoelzro|away proposed a fix in the backlog.
r: sub order-beer(:$type, :$pints) { say "$pints $type" } order-beer(:type('Hobgoblin'), :pints(1))
p6eval rakudo 797af5: OUTPUT«===SORRY!===␤Confused␤at /tmp/gHjN7xb_Ij:1␤»
mtymula becouse i want to make a call on a sub that does not care about the order of parameters
masak r: sub order-beer(:$type, :$pints) { say "$pints $type" }; order-beer(:type('Hobgoblin'), :pints(1))
p6eval rakudo 797af5: OUTPUT«1 Hobgoblin␤»
masak mtymula: there you go. hoelzro++
r: sub order-beer(:$type, :$pints) { say "$pints $type" }; order-beer :type<Hobgoblin>, :pints(1) 11:45
p6eval rakudo 797af5: OUTPUT«1 Hobgoblin␤»
jnthn Yeah but it should be :$pints where $pints > 1. One hobgoblin aint' enough :P
masak r: sub order-beer(:$type, :$pints where $pints > 1) { say "$pints $type" }; order-beer :type<Hobgoblin>, :pints(1)
p6eval rakudo 797af5: OUTPUT«Constraint type check failed for parameter '$pints'␤ in sub order-beer at /tmp/AxZAQfHU2q:1␤ in block at /tmp/AxZAQfHU2q:1␤␤»
masak r: sub order-beer(:$type, :$pints where $pints > 1) { say "$pints $type" }; order-beer :type<Hobgoblin>, :pints(5)
p6eval rakudo 797af5: OUTPUT«5 Hobgoblin␤»
masak jnthn: better? :)
jnthn yes :)
masak gets uneasy when seeing 'where' without a block 11:46
jnthn Blocking on superstition... :P
teaching time :) 11:47
11:50 bowtie joined
masak .u bowtie 11:50
phenny U+22C8 BOWTIE (⋈)
masak :D
Unicode -- for when you want to look stylish for the party next door. 11:51
bowtie don't for get to self tie :)
masak I'm sorry, self-tying bowties weren't invented until 2044. 11:52
bowtie lol 11:53
masak (that's twelve whole years after the Singularity)
11:53 mtymula89 joined 11:55 hoelzro|away is now known as hoelzro
hoelzro I did? 11:55
11:57 mtymula left
masak yes, right at irclog.perlgeek.de/perl6/2012-11-28#i_6192060 11:57
actually, github.com/perl6/specs/commit/94d0...733d0aec04 is looking quite sane now that I'm reading it. 11:58
TimToady++
jnthn: if I put in a new red cell in the compiler features table, would you start thinking about implementing it in Rakudo? :P 11:59
hoelzro huh.
oh, yeah, that
EBADCONTEXT
masak as the one implementing macros in Rakudo, I can tell you in no uncertain terms that context is everything. 12:01
hoelzro haha 12:06
12:19 benabik left 12:22 mtk joined 12:35 tokuhiro_ left, tokuhiro_ joined 12:53 gootle left 12:54 mtymula89 left
grondilu I had a weird error trying to compile with --target=pir 12:55
===SORRY!===
Serialization Error: Unimplemented object type 'QRPA' passed to write_ref
moritz grondilu: which rakudo version is that? 12:57
grondilu This is perl6 version 2012.10-153-gbf472b0 built on parrot 4.10.0 revision RELEASE_4_10_0 12:58
13:00 SamuraiJack_ left
FROGGS 4.10, wow 13:02
grondilu yeah, I like to live on the edge :) 13:05
grondilu runs debian sid
that's possibly also why I like Perl6 so much: I can see it's the future. 13:06
FROGGS grondilu: well, I'm running ubuntu ;o) 13:07
ya, it is
it's sad sometimes hacking Perl 5 at work... could be so much nicer
13:23 benabik joined
masak I often enjoy hacking Perl 5 at work. I realize some things could be better, but Perl 5 is still preferable to, say, Java, or PHP. 13:23
jnthn grondilu: Could you possibly golf it? But I may have a guess...file it either way. 13:25
After Saturday I actually get to haz tuits again :) 13:26
13:27 isBEKaml joined
isBEKaml OHHAI, #perl6! 13:27
phenny isBEKaml: 27 Nov 13:45Z <jnthn> tell isBEKaml once December comes, $dayjob gets much less intense and I expect to get some initial JVM things pushed, and will probably have LHF tasks for interested hackers. ;-)
isBEKaml jnthn: Looking forward to it! :) 13:29
13:42 isBEKaml left 13:44 Pleiades` left 13:45 am0c left 13:46 dayangkun left 13:48 dayangkun joined 13:51 Pleiades` joined 13:58 benabik_ joined, benabik left, benabik_ is now known as benabik 13:59 atrodo joined 14:02 Pleiades` left 14:08 Pleiades` joined 14:20 bluescreen10 joined
FROGGS masak: the only language that I enjoy the same to Perl 5 is actually C, the others you mentioned cant compete to it 14:23
and I would use Perl 6 if it would be a bit faster and if there were the modules I need :/
tadzik Go is awesome 14:24
[Coke] what modules are you missing?
masak I can see the attraction to C, yes. it's not a niche I end up writing a lot in, but when I do, I definitely come off with a respect for C.
tadzik: what makes Go a nice alternative to C, in your opinion?
moritz more importantly, what do you use Go for? 14:25
I've wanted to learn Go for a while, but so far I haven't had a project that was well suitable for Go which I could have used for learning
14:25 d_fallen_god joined
d_fallen_god ello? 14:26
moritz EHLO
tadzik masak: I enjoy it more than C
d_fallen_god can I ask
?
FROGGS [Coke]: SOAP::Lite, DateTime::SpanSet, Net::EMI, PDF::Create, to mention a few
PerlJam d_fallen_god: 42
d_fallen_god huh? 14:27
daxim go ahead and ask
d_fallen_god I want to ask about ilbot
moritz d_fallen_god: try #ilbot
d_fallen_god how to set it up
#ilbot
14:27 brrt joined
d_fallen_god thanks 14:27
moritz you're welcome
14:28 d_fallen_god left
moritz wonders where people still find references to #perl6 in the context of ilbot 14:28
masak this wasn't a person, though, it was a fallen god.
tadzik moritz: I don't use it for nothing serious, when I'm writing compilers for fun for example I prefer Go to C
masak .oO( "don't ... nothing" -- you must be from Poland ) :P 14:29
tadzik haha
masak tadzik: have you tried writing a compiler in Haskell?
I hear that's a really nice experience, too. 14:30
tadzik nope, I don't know haskell at all
I used to do that in C, now I do that in Go
brrt i like go a lot too 14:33
nice, decoupled design with interfaces
[Coke] (haskell) hey. if you're going to do that, we have one that could use some love
brrt proper runtime type information, garbage collection 14:34
little syntactic niceties
tadzik it feels like a "better C"
masak that's the feeling I've gotten from it, too.
brrt it is much much bigger than C, though 14:35
grondilu ;;blocks
tadzik well, the standard library is bigger
brrt the language is bigger, too
tadzik the language itself? Slightly
brrt maybe i'm overestimating the smallness of C
14:36 cognominal left
brrt but go comes with defer, panic, recover; goroutines, closures, interfaces 14:36
slices, obviously, too 14:37
14:38 dayangkun left
moritz panic and recover? is that, like, exceptions? 14:41
brrt somewhat
panic() is like throw 14:42
recover() is like catch
14:42 birdwindupbird left
tadzik a bit 14:42
brrt but recover() only works inside deferred functions
tadzik exceptions are generally discouraged
brrt which is nice
imho
tadzik it's advised to return errors, which is easy for you can return multiple values 14:43
yeah, I like the idea too
moritz it just forces you to handle them on every level
brrt in theory, exceptions are 'better', because you can 'bubble' errors to the levels that are able d
to deal with them
in practice
that fails 14:44
tadzik not on every level. On one level :)
you know where they may pop out
grondilu ;;blocks
tadzik what is more, Go checks if you actually handle them
unless you ignore all return values
14:45 cognominal joined
tadzik so while foo, err := bar(); is ok, foo := bar() is not 14:45
you can explicitely ignore them with foo, _ := bar() though
masak grondilu: why do you keep saying ';;blocks'?
tadzik: ooh, I hadn't realized that. that's kinda nice.
14:45 benabik left, benabik_ joined 14:46 benabik_ left
tadzik yeah. Either you don't care about the result, or you _have_ to handle them 14:46
(them errors)
14:46 benabik joined
grondilu masak: sorry, wrong channel 14:46
brrt the effect is also that most functions return an error parameter 14:47
which could be constructed as manually 'bubbling' the error
tadzik well, all functions that can fail
masak grondilu: now I'm just so curious which channel that would be a sensible thing to say :P 14:48
#lisp? :P
grondilu masak: not programming
masak surely programming. it has semicolons and blocks in it.
grondilu masak: bitcoin related
masak oh!
well, carry on then. keep those bitcoins rolling. 14:49
14:49 kaleem left
brrt i'm actually wondering why i like the error return thing so much 14:49
tadzik because you don't like exceptions? :) 14:50
14:50 stopbit joined
brrt possibly, but - in theory - exceptions should lead to less code 14:50
cognominal Hi. I think there was an infrastructure in nqp to create compilers from scratch. Has it disappeared? 14:51
brrt in go, if i have foo, e := bar(); if e != nil { return nil, e }; - that is just a 'rethrow' in a way
tadzik so try { foo = bar(); catch { $_.rethrow } } 14:52
brrt pretty much all your code is going to look like that
tadzik not too different
brrt no, indeed
but rethrowing is a bit senseless in many cases
tadzik yup
masak the design problem is making people care about handling about exceptions without being as much of a nuisance about it as Java is.
brrt again, in theory, i'd be better off if the error that i cannot handle fails to my superior
masak seems Go struck a nice balance there. 14:53
moritz the point about exceptions is that the exception is rethrown automatically
brrt i totally agree that it feels nice
tadzik people treat exceptions like a control flow mechanism
brrt i just can't comprehend quite why
tadzik I know a fellow pythoner who claims that they are one
moritz well, they certainly are
tadzik "but they're lightweight! Perfect for control flow"
brrt :-D
but in seriousness, p6 works with 'control exceptions' too, right? 14:54
moritz yes
tadzik it's a programming pattern, not a language design decison, imho
brrt they are dynamically scoped control structures
the horror of the programmer who has to implement those
tadzik, in python you actually stop iteration by throwing an exception 14:55
dalek ast: 8d88d57 | (Tobias Leich)++ | S32-exceptions/misc.t:
test for "$" X::Backslash::NonVariableDollar

Error message: Non-variable $ must be backslashed
tadzik really?
brrt it is beyond me why, but yes
StopException afaik
tadzik I almost wrote my compilers assignment in it
now that I have the parser (mostly) read the assigner said "nono, I changed my mind, write it in C, not Python" 14:56
brrt why?
tadzik because big files and performance 14:57
don't even ask me :)
moritz I think python diectionaries also throw an exception if you look up a key that isn't there
tadzik awesome
brrt moritz, they do
its called a KeyError
tadzik it's like those java JSON parsers,which throw exception on invalid JSON, but have no isValidJSON method
dalek ast: 98bd346 | (Tobias Leich)++ | S32-exceptions/misc.t:
test for "\u" X::Backslash::UnrecognizedSequence

Error message: Unrecognized backslash sequence: '\u'
14:58
tadzik Yoda would be enraged
brrt adding some insult to injury, catch is called except
and you HAVE TO TABULATE THAT STUFF
tadzik hm 14:59
brrt so either you do: if 'foo' in bar: yadayada()
tadzik it seems that JSON::Tiny does the same
brrt or: try: yadayada(foo['bar']): except KeyError: something()
moritz thinks it's quite sane
[Coke] (exceptions are flow control) ... of course they are, says tcl. 15:00
moritz I mean, an isValidJSON routine would have to do the same parsing as the decoder
tadzik well, maybe a Failure would be better here?
brrt a Failure object would be nicer
moritz it's just try from-json($str); not $!
tadzik hehe
brrt tadzik++ for being first
moritz once we have sink context, I'll change it to Failure 15:01
tadzik cool
brrt does perl6 have multiple return arguments, and if so, how do they differ from returning an array?
tadzik Failure feels a bit Go-ish
15:02 skids joined
tadzik like "it's alright if you don't care about the result 15:02
"
it may happen to be a bit of an action-at-a-distance though
brrt nm, i have my answer 15:03
masak you can also set Python tables to return a default instead of throwing an exception.
brrt masak, really? how? 15:04
brrt would like that feature
masak I don't know offhand.
15:08 gaussblurinc joined
masak ah, here. see the entry d[key] under docs.python.org/2/library/stdtypes.html#dict 15:09
15:09 kaare_ joined, jaldhar left
moritz today I learned an evil way to determine the string length of $_ in perl 5, which is one character shorter than lenght: y///c 15:11
*length
brrt how, does that work? 15:12
moritz y is an alias for tr 15:13
so it's the same as tr///c
15:13 rindolf joined
moritz and /c complements the search list 15:13
15:13 tokuhiro_ left
moritz so it searches for any character 15:13
and since the replacement is empty, does nothing
and counts the number of finds
15:13 tokuhiro_ joined
brrt nice 15:13
15:14 bluescreen10 left, clkao| left, arlinius joined, bluescreen10 joined
[Coke] moritz++ 15:15
masak moritz: not to mention how much readability is improved. ;) "length" is so opaque and divorced from the task at hand -- "y///c" is more or less self-documenting.
moritz masak: which is why I labeled it "evil" up-front 15:16
[Coke] masak==
moritz fwiw that trick is attributed to Abigail
masak Abigail++
15:18 GlitchMr joined 15:22 bluescreen10 left 15:24 isBEKaml joined
isBEKaml moritz: thanks for the merge. :) 15:24
moritz isBEKaml: you're welcome 15:29
isBEKaml masak: about y///c, wait until somebody mangles it even further. :P y;;;c or whatever.
moritz the version I saw first was y===c
masak heh :)
isBEKaml yep, I remember reading about in perl hacks.
masak eval: $_ = "four"; say y...c
buubot_backup masak: ERROR: syntax error at (eval 20) line 1, near "say y...c" 15:30
masak eval: $_ = "four"; y...c
buubot_backup masak: 4
masak :)
moritz eval: $_ = 'four'; yc 15:31
buubot_backup moritz: 4
moritz (there are three chr(2) characters in there)
but it certainly *looks* even shorter :-)
isBEKaml heh. That's even more awesome. :) 15:32
dalek rlito: bd4c687 | (Flavio S. Glock)++ | / (5 files):
Perlito5 - operators - "gt", "lt"
15:33
isBEKaml I just typed y^w^w^wc into my cmd prompt and it printed 4. :) 15:34
15:34 bluescreen10 joined
[Coke] wonders if anyone else gets linkedin requests from random perl people they've never met. 15:34
moritz [Coke]: I do 15:35
FROGGS has no linkedin account
isBEKaml moritz, [Coke]: You guys are famous! 15:36
15:36 obra joined
[Coke] isBEKaml: O_o 15:37
well, maybe moritz, sure.
15:37 obra left
masak isBEKaml: I get linkedin requests for random people (perl or no) I've never met. 15:39
er, meant for [Coke].
moritz is famous in #perl6 and maybe on perlmonks, but not outside 15:40
brrt wear your fame with pride
FROGGS moritz: hey, I saw your video in the bundestagsausschusssitzung!
'was about open source, not just perl6
moritz I hope to become more famous by widening the circle of Perl 6 users :-)
FROGGS: ... where I was invited by a perlmonks acquaintance :-) 15:41
FROGGS well, I made two maybe-Perl 6 hackers, you just one from what I know ;o)
15:41 rurban_ joined 15:42 gaussblurinc left
moritz seen pmichaud 15:42
aloha pmichaud was last seen in #parrot 14 hours 15 mins ago joining the channel.
15:42 rurban_ left
masak joins don't mean much in light of netsplits. 15:43
wonder why aloha assumes they're meaningful.
15:43 hash_table joined 15:44 am0c joined
arnsholt Whoever implemented it didn't think of netsplits, probably 15:44
15:45 am0c left, am0c joined
masak an excusable mistake. still, it makes the seen function less useful. 15:45
arnsholt Indeed. Who is responsible for running aloha? 15:48
15:48 thou joined
moritz bacek was 15:48
15:48 thou left
kresike bye folks 15:49
15:49 kresike left
skids ponders sending [Coke] a linkedin request just to be a bastard 15:50
moritz often I don't decline those requests for a while because there are some perl folks I only know by nick name
though waiting rarely makes it better 15:51
masak if the invitation has the default invitation message (and not e.g. "remember me? we met at X"), I usually decline. 15:53
FROGGS masak: good to know and good that I already met you ;o) 15:54
(even if you cant remember) 15:55
masak FROGGS: I can't, but I'm glad you're here on #perl6, and helping with tickets and patches. :) 15:57
FROGGS++
FROGGS well, I wanna benefit from it at some point (right now it is just fun, later I hope I can make better software using it) 16:02
masak aye.
FROGGS I believe the game that I started using Perl 5 would be just a fifth of lines of code an much more readable 16:03
masak I feel I got my general introduction to programming languages in the past seven-or-so years. Perl 6, and the ideas in Perl 6, are inextricably tied up into that.
FROGGS well, my knowledge increased when porting the libSDL to Perl 5, can't say that I have learned much about Perl 6 yet 16:04
and I learned a bit at $dayjob too of course, calculating fees for our employees can be challenging too 16:05
moritz ah yes, the fun world of business applications 16:07
FROGGS well, this part is fun actually
moritz (our internal business app is much more fun to hack than OTRS, for example) 16:08
FROGGS what I really dont enjoy is "yet another workflow thing"
masak business applications can be lots of fun. the domains are often non-trivial.
brrt i agree again :-) 16:09
that is to say
you can often get away with an autogenerated CRUD
but if you want your users to be better by using your software, you have to go a bit farther 16:10
masak this is what DDD is getting at. 16:11
focus on the domain, because it's often worth focusing on.
16:11 clkao_ joined
moritz wonders what the domain of his app is 16:11
brrt too
moritz probably "run the business of an IT outsourcer and ISP" 16:12
brrt by the way 16:13
is there a 'good' or 'correct' way to store event data in a cqrs design?
FROGGS moritz: who is he in "his app"? 16:14
moritz FROGGS: me
FROGGS ahh
16:25 brrt left
grondilu rn: say do for ^3 { $_ } 16:25
p6eval niecza v22-44-g0247fe5: OUTPUT«Nil␤»
..rakudo 797af5: OUTPUT«0 1 2␤»
grondilu I kind of expected just "2" 16:26
FROGGS rn: say do { $_ } for ^3
p6eval rakudo 797af5: OUTPUT«Any()␤Any()␤Any()␤»
..niecza v22-44-g0247fe5: OUTPUT«0␤1␤2␤»
FROGGS grondilu: say will be done 3 times, no? 16:27
rn: say ( do for ^3 { $_ } )
p6eval niecza v22-44-g0247fe5: OUTPUT«Nil␤»
..rakudo 797af5: OUTPUT«0 1 2␤»
FROGGS hmmm
moritz no, say is only done once
grondilu not in 'say do for'
moritz but 'for' is really just the same as 'map'
so it returns the list of return values from the block
16:28 sirrobert joined
moritz (what pythonistas call "list comprehension") 16:28
isBEKaml yep, for completes, and yields back to say.
for comprehensions.
sirrobert hiya =)
grondilu And had say been called three times, there would be linefeeds between 0, 1 and 2
moritz \o sirrobert
FROGGS sirrobert: hi
grondilu: right
isBEKaml hello, sirrobert 16:29
grondilu to me, "say do for ^3 {...}" === "say (do for ^3 {...})"
moritz that's correct
masak sirrobert! \o/
sirrobert masak: =)
grondilu isn't 'do' supposed to return only the last evaluated expression?
16:30 Kharec left
masak what makes you think that? 16:30
moritz grondilu: yes, and the last evaluated expression is the for-loop
grondilu ok
masak it's not what 'do' evaluates to that matters, it's what the 'for' loop evaluates to.
moritz well, if you chain the two, both of them matter :-)
grondilu well, not ok actually
masak and it evaluates to the last evaluated expression *in all of its iterations*. 16:31
'do' just makes an expression of a statement or block.
grondilu is confused
sirrobert is there any profiler (like NYTProf) available?
moritz sirrobert: not quite as fancy
sirrobert moritz: I don't need fancy =)
moritz sirrobert: but perl6 --profile script.pl 2>profile.log
exists
grondilu Well I guess I just should read a bit about the exact semantics of this thiing 16:32
sirrobert moritz: oohh didn't know that. cool
moritz and then kcachegrind profile.log
r: sub loopy { for ^3 { $_ * $_ } }; say loopy()
p6eval rakudo 797af5: OUTPUT«0 1 4␤»
moritz no 'do' involved
isBEKaml masak: We should do something like remember this said by someone. :) 16:33
moritz subroutines also return the return value from the last statements
as does any block
grondilu ok, good to know
isBEKaml <masak> 'do' just makes an expression of a statement or block. 16:34
moritz that's actually not quite true
a block already is an expresion
but do BLOCK always runs the block (ie makes it an immediate block) 16:35
masak ah; fair enough.
what moritz++ said :)
moritz wonders if we should call 'do' the "JIT phaser" 16:36
grondilu that's S04, right?
moritz grondilu: aye
grondilu will read this again
isBEKaml moritz: well, yeah. We should say that 'do' always evaluates whatever immediately follows it. 16:37
moritz grondilu: IME stuff gets clearer by using it, less by re-reading it (though I don't want to discourage you from reading)
sirrobert is that different than the behavior of do-while in p5? 16:38
skids yay someone used the word "immediate" I was worried it was out of fashion. (that's sooo ASM :-)
isBEKaml finds the trackpad on his laptop annoying to the point of interfering with typing. :/
[Coke] r: do do do do do do do say 3;
p6eval rakudo 797af5: OUTPUT«3␤»
16:38 grondilu left
[Coke] r: do do do say do do do 3; 16:38
p6eval rakudo 797af5: OUTPUT«3␤»
[Coke] whee.
sirrobert skids: I like the word "immediate"... I've also lately enjoyed using "mediate" similarly...
isBEKaml skids: Well, English confuses me. :P 16:39
sirrobert isBEKaml: it was a good use of the word =) 16:40
isBEKaml: the relationship between "do" and "block" is not mediated by any other "intermediary" element =)
isBEKaml sirrobert: Mediate and immediate aren't the same!
16:41 wamba left
sirrobert isBEKaml: the adjective "mediate", not the verb 16:41
16:41 atrodo left
moritz my dictionary only knows it as a verb 16:41
sirrobert isBEKaml: immediate is the negation of mediate with the prefix "im-" (which was "in-" but the "n" gets assimilated to an "m" when it comes before another "m") 16:42
isBEKaml moritz: I think sirrobert meant immediate to be an adjective. If that's an adjective, it's new to me unless he's talking of intermediary or something like it.
16:42 MayDaniel joined
sirrobert isBEKaml: nod. you said "immediately" which is the adverbial form of the adjective "immediate" 16:42
moritz "immediate" (adject) = without dely 16:43
*delay
*adjective
so, "mediate" (adjective) = possibly with delay ?
isBEKaml sirrobert: I'm not a native speaker. Grammar gives me painful memories. :)
sirrobert moritz: nod, but "delay" is a metaphor there. It is really "unseparated", but the common usage is unseparated in time
skids wictionary has the adjective form as "acting through a mediating agency" 16:44
sirrobert Example-- in philosophy you can refer to "immediate" or "mediate" causes of various effects
isBEKaml moritz: immediate would also suggest proximity. Nearby things.
moritz sirrobert: ah, that makes a lot of sense
sirrobert moritz: =)
isBEKaml: yeah. it's a closer relation than "proximal" 16:45
isBEKaml sirrobert: aye.
shachaf Example++
16:46 atrodo joined
isBEKaml #perl6++ I didn't know something as trivial as a word could kick off a whole new conversation on this channel! 16:47
FROGGS well, it's about language... 16:48
if TimToady would be here right now...
16:48 daxim left 16:50 wamba joined
isBEKaml ... he'd extract missing words out of seemingly correct sentences and take us into a verbalate' 16:53
:P
sirrobert word play is good play =) 16:55
isBEKaml *nod* *nod* 16:56
16:57 arlinius left 17:04 FROGGS left 17:14 SamuraiJack_ joined 17:16 wamba left 17:19 hoelzro is now known as hoelzro|away
masak isBEKaml: I used to regard grammar with skepticism. I got a much healthier relation to it when I realized that it fills a role similar to mathematics; it allows us to speak precisely about phenomena that may interest us. 17:28
PerlJam It also allows us to speak imprecisely too. (Ambiguity is quite important; especially on #perl6 :-) 17:29
isBEKaml masak: so grammar is design patterns for language? You can tell me that after you've had teachers quoting W & M all day in high school. :) 17:30
masak I don't know what W & M is. some book, I guess. 17:31
tadzik moritz++
the y///c trick is awoseme
isBEKaml masak: Wren & Martin. Grammar reference stuff.
masak PerlJam: oh, I meant on a meta level. grammar allows us to speak precisely about *language*.
PerlJam ah. 17:32
(what I said still applies ;-)
masak aye.
one common way to misunderstand grammar is to think that what we were taught at school is all there is to language, and everything else is improper use. 17:33
in reality, language is more like a living organism, and we can capture some things precisely, other things not.
PerlJam oddly, that's the same problem in mathematics too
isBEKaml masak: exactly my point. Language evolves and should never be allowed to be tied down by grammar lawyers. :) 17:34
PerlJam There's still a pervasive "one right answer" philosophy in much of western education systems, even when it's not true.
17:35 wamba joined
masak isBEKaml: it's not so much that we can't describe it exactly. it's more like that's not the point of the exercise. 17:36
the point is more to be able to describe what was said/written, and why it was said/written in that way.
PerlJam masak: communication is still hard no matter the utility of language. A couple of week ago, I asked my wife a question and her answer was not to the question I asked, but she thought she was answering me. It took 3 tries to get her to understand that she wasn't answering me and what I was actually asking. Even though my use of language was precise in this case, it didn't matter. 17:37
isBEKaml the former falls under semantics, while the latter is the realm of grammar. Grammar's just for talking about structure. I see nothing more than that. 17:38
masak PerlJam: sometimes I'm amazed that brains can communicate through sound waves at all. 17:39
PerlJam indeed
isBEKaml: "just"? 17:40
isBEKaml masak: Well, if you're thinking of telepathy, I can think of horrible communication mishaps where one person's visualisation is very much different from another's. ;) 17:41
PerlJam: Well, the teachers I have had were mostly W&M toting maniacs. They'd throw all those confusing buzzword sounding terms like participle, past participle, intransitive, imperfect tense. I was even surprised I made it through at all. 17:43
masak I wasn't thinking of telepathy. just the fact that it seems to me that brains are different enough to essentially be running on unique protocols, and that spoken/written language sometimes seems to fall very short of bridging the gap.
PerlJam sound waves are just an agreed-upon intermediate representation that compiles to thought patterns via our brains, only brains are kind of lossy compilers. 17:44
isBEKaml masak: I'm even amazed that humans even thought of communication needs at all. 17:45
17:45 FROGGS joined
PerlJam isBEKaml: *that* was a darwinian thing. 17:45
FROGGS {sitting on couch}++
isBEKaml PerlJam: Mistaken evolution. 17:46
PerlJam our species plays the hand they are given. 17:47
gfldex i'm trying to build rakudo-star-2012.11-RC1 on cygwin right now
0 [main] parrot 3068 child_info_fork::abort: C:\cygwin\bin\cygicudata48.dll: Loaded to different address: parent(0x910000) != child(0x7B0000)
Can't spawn child process
current instr.: 'spawnw_cmd' pc 643 (tools/dev/pbc_to_exe.pir:216)
if rakudo wants to be commited about supporting cygwin avoiding fork where ever possible would be desireable 17:48
windows--
isBEKaml PerlJam: if anybody were to follow our evolution, they'd either be laughing at all this tamasha or slapping their heads in agony.
gfldex: that looks like an error from parrot build. Can you nopaste the entire thing? 17:50
gfldex i will in a few
masak "tamasha". wonderful word, and useful.
तमाशा 17:51
isBEKaml++
isBEKaml masak: one of the few words that made it from Indian languages to English. :)
masak I had never heard it before. 17:52
PerlJam either
17:53 dakkar left
isBEKaml masak: well, you do now. Here's another: catamaran. (If you want to go hunting down its etymology :P) 17:53
17:54 Chillance joined
masak I know the word; didn't know it came from Tamil. :) 17:56
"tied wood" :)
isBEKaml yep, kattu-maram. more like "tied tree" 17:57
masak oh, ok. 17:58
isBEKaml: what languages do you speak?
gfldex isBEKaml: gist.github.com/4162887 17:59
rebaseall did not help
isBEKaml masak: english, tamil and a smattering of hindi. 18:00
masak nice.
from Wikipedia: "Tamil is one of the longest surviving classical languages in the world." -- wow. 18:01
PerlJam heh, I was just reading that as well :)
masak and Tamil literature has existed for over 2k years.
I wonder how it stacks up agains Chinese.
isBEKaml gfldex: that's not good. I was able to build RC0 y'day (without ICU, though). 18:02
masak granted, Chinese has a bit of a discontinuity since the classical, written language was replaced by the common, spoken language.
isBEKaml masak: I've been trying to learn some Chinese just to kill time. It just feels so disjoint at the alphabetic level. :) 18:03
masak isBEKaml: OMG you're the ones with the alphabet where all letters look like cute little kittens! :D
isBEKaml masak: Oh, come on! That's telugu and kannada. We don't kill kittens, honest! 18:04
masak oh. :)
yes, seems I was thinking of the Telugu script. 18:05
isBEKaml: more and more, my brain tends to do short things in Chinese. thinking "我们到了吗?" instead of "have we arrived yet?"
Mandarin has a distinct Forth feel to it. 18:06
isBEKaml masak: more like APL than Forth. :D
masak yes, that might be a better comparison, actually.
it clearly feels like a composable, functional language.
isBEKaml masak: so much that I have just given up and started squinting around alphabets to see how they look in pictures. :P 18:07
masak "pictures"? do you mean hanzi? 18:08
isBEKaml masak: for example, the word for "mouth"(kuo) in traditional chinese - I just see an open mouth!
18:09 kaleem joined
isBEKaml masak: for man (ren), a torso less body with two legs astride! 18:09
18:10 spider-mario joined
masak oh, that effect. yeah, definitely. 18:10
isBEKaml masak: I tend to think whoever instituted these words must have either been in a drugged state or were blind. 18:11
masak I'm already at a stage where I hallucinate radicals to the right thing most of the time, and have a hard time understanding how hanzi noobs don't. "what do you mean, not a dog? 犬 is totally a dog."
isBEKaml: also recall that we're seeing the effects of thousands of years of simplification/stilization. 18:12
PerlJam feels incredibly occidental
isBEKaml masak: that is why you should have as few letters in alphabet as possible, but no fewer. :P 18:13
masak PerlJam: if you get occidental enough, eventually you'll end up in East Asia :P
isBEKaml: it's not an alphabet :) 18:14
isBEKaml masak: alphabets are composable enough to form new words, but I can't say the same of sounds. They don't seem to follow any definite pattern. :)
masak Pinyin has an alphabet. hanzi are just a character set.
"logograms". boy, there are so many terms for this. 18:15
isBEKaml Oh, I use neither. I'm just reading off a book.
PerlJam: Careful there, you'd just be looking far-eastern mysticism.
gfldex: where did you get RC1 from, btw? 18:20
gfldex wget "moritz.faui2k3.org/tmp/rakudo-star-...C1.tar.gz" 18:21
18:22 REPLeffect left 18:23 fhelmberger left
cognominal speaking of language, the entry about emic and etic was anemic (no pun intended), it has been considerably extended these last few days. en.wikipedia.org/wiki/Emic 18:23
18:31 kaleem left 18:43 rurban_ joined
isBEKaml gfldex: I just built R* successfully here. 18:43
gfldex: do you have any space issues? 18:44
gfldex no
isBEKaml: if you want to read up about the fork issue: cygwin.com/faq-nochunks.html#faq.using.bloda 18:45
isBEKaml: do you got cygwin in a vm or are you running it on a broadly used windows system?
18:46 rurban_ left
isBEKaml gfldex: It's not on a vm. It's on a standalone windows installation. 18:46
18:46 rurban_ joined
isBEKaml gfldex: you may want to check with rurban on #parrot. He helped me with cygwin issues before and also maintains cygwin builds of parrot. 18:48
18:53 cognominal left
isBEKaml anybody seen this error before? Method 'cuid' not found for invocant of class 'NQPMu' 18:56
Happens with p6doc on my machine here.
18:59 rurban_ left 19:00 rurban_ joined 19:02 cognominal joined 19:07 zby_home_ joined, telex left 19:08 telex joined 19:10 Tene joined 19:11 rurban_ left 19:13 rurban_ joined
isBEKaml perl6 --doc is broken :( 19:13
moritz seems to be related to lexpads in some way
19:14 rurban_ left
dalek rlito: 5879509 | (Flavio S. Glock)++ | / (7 files):
Perlito5 - parser - fix eval-string signature; caret-var fix; 3 more lex.t tests pass
19:14
isBEKaml moritz: could it be? command_eval but command_line is what is called from main.nqp. 19:17
moritz Method 'cuid' not found for invocant of class 'NQPMu' 19:18
current instr.: 'add_phaser' pc 19602 (src/gen/perl6-symboltable.pir:7167) (src/Perl6/World.pm:1414)
moritz tries a fix 19:20
dalek ar: a02870e | moritz++ | tools/star/release-guide.pod:
small update to release guide
19:22
rlito: 0bc2e7a | (Flavio S. Glock)++ | / (5 files):
Perlito5 - parser - fix package autovivification; 3 more lex.t tests pass
19:27
kudo/nom: 110a8e4 | moritz++ | src/Perl6/Actions.pm:
fix --doc option, reported by isBEKaml++
19:37
masak moritz++ # fix early, fix often
isBEKaml moritz++
masak did the signature of add_phaser change, breaking this code? 19:38
ISTR jnthn changing it recently for some other phasers.
dalek ar: a67c183 | moritz++ | tools/star/release-guide.pod:
fix mailing list address
19:38 SamuraiJack_ left
moritz masak: not the signature, only whether the optional argument needs to be present in certain cases 19:40
masak ah. 19:46
19:46 bluescreen10 left, isBEKaml left
masak there's a research paper all on its own: "Caller breakages when callee preconditions change" :) 19:47
jnthn Will it reference the paper "Things that don't have test coverage more likely to get broken"? :)
masak moritz++ # Star release 19:49
19:56 REPLeffect joined 19:57 noggle joined
felher moritz++ # release 19:59
moritz jnthn: we really need a plan for testing stuff which doesn't belong into roast 20:00
non-specced command line options, REPL, precompilation
masak that is more or less the problem I had with crypt last year. the "interactive" parts were non-testable. 20:06
solution: DI.
20:06 HarryS left
moritz DI? 20:06
masak Dependency Injection. 20:07
pmichaud good afternoon, #perl6
moritz isn't so sure
masak pmichaud! \o/ \o/
moritz \o pmichaud
masak moritz: or, equivalently but from a FP perspective: make the system under test into a function, and pass the environment as parameters.
pmichaud can't stay long today... just wanted to note that I'll be able to make the Star .msi release again this month
will do that in the next day or so
moritz++ # star release
moritz already has an assault planned on pmichaud
masak :) 20:08
moritz pmichaud: could please turn github.com/rakudo into an organization?
pmichaud: this month we couldn't give our release manager a commit bit, and that was annoying
masak moritz++
moritz (compiler releaes manager, that is)
pmichaud could've sent me an email :)
moritz yes, I guess i could have 20:09
but still, wouldn't hurt to scale, IMHO
tadzik 2100 moritz | jnthn: we really need a plan for testing stuff which
| doesn't belong into roast
so, the 'make test' stuff? 20:10
pmichaud currently we still require CLAs for commitbits to the rakudo repo, though.
moritz tadzik: yes, but the 'make test' stuff has much less infrastructure right now than we need for that stuff
pmichaud: yes, but iirc we already made temporary exceptions for release managers
pmichaud moritz: okay, give me a day or two to think about it; I had reasons for not moving it instantly to an organization repo 20:11
moritz pmichaud: ok
pmichaud but I do still read email :) 20:12
jnthn o/ pmichaud :)
FROGGS btw, I sent the CLA (via email and mail)
jnthn moritz: Is --doc not spec, ooc? 20:13
20:13 rurban_ joined
jnthn moritz: Agree with your point otherwise, though 20:13
moritz jnthn: oh, it is
tadzik --doc is spec
pmichaud jnthn: o/ 20:14
20:16 supernovus joined
supernovus Hmm, perlfoundation.org still does not resolve from my location. :( 20:18
20:19 kurahaupo joined
japhb o/ 20:19
FROGGS hi japhb 20:20
japhb Other than comments about not liking @*INC (which wasn't part of the original idea), and a question about use of 'Any', did anyone have any other thoughts on the S11-compliance design I posted last night?
Hi FROGGS! 20:21
20:21 cognominal left
FROGGS japhb: have missed it, but will read now 20:22
japhb FROGGS, ah, OK, thank you.
20:23 rurban_ left
japhb phenny, tell azawawi I'll add your any(@array) benchmark to perl6-bench. Any other micro-benchmarks you'd like to see added, or particular performance gotchas you've found? 20:25
phenny japhb: I'll pass that on when azawawi is around.
japhb As a matter of fact, that's open to everyone: If you know of a scaling or other performance weakness in one of the Perl compilers, please let me know, and I'll try to add relevant benchmarks to perl6-bench for it. 20:26
dalek ast: 127f694 | moritz++ | / (2 files):
basic sanity tests for --doc command line option
20:27
kudo/nom: 247f875 | moritz++ | t/spectest.data:
run test for --doc command line option
supernovus japhb: It looks pretty good to me, with one caveat: we need to decide how to encode the Auth portion into a directory-friendly version. Since Auth is meant to store a URI, it must contain a colon, and may contain slashes as well.
20:27 Chillance left
moritz file:/// exists 20:28
moritz hasn't read the draft yet
20:28 Chillance joined
FROGGS japhb: I like it 20:30
currently thinking of circumstances where it can went wrong...
20:30 sirrobert left
japhb Are there any filesystems in which : is verboten? (I know Windows uses the *first* colon as a drive separator when using \ directory separators, but I don't know if that applies to when it parses / syntax, or if it makes all : disallowed.) 20:30
FROGGS, Excellent.
moritz japhb: I think it does forbid subseqent :s 20:31
(not quite sure though) 20:32
flussence windows tries its hardest to stop you using those funny characters, but IIRC you can force NTFS into POSIX mode in linux
japhb But in any case, it may be a matter of URL-encoding the auth on filesystems that can't handle it.
20:32 spider-mario_ joined
supernovus Say for instance :auth<github:supernovus> or :auth<github.com/supernovus/> If we want to go with dead simple, we could say, encode both : and / to _, collapsing to a single _ character in a row, and stripping trailing _ characters, making the folders for the previous examples 'github_supernovus' and 'http_huri.net' respectively. 20:32
20:32 sirrobert joined
sirrobert jnthn: my using the debugger, it doesn't seem to step into method calls as I would expect (it defaults to stepping over them). Is there some setting I should look at? 20:33
japhb And the slash character is an interesting question ... that does kindof push the URL encoding idea.
sirrobert (using the R* 2012.11-RC1 debugger)
FROGGS japhb: <> is forbidden too 20:34
japhb The other idea is to do what supernovus suggests, just accepting that this will increase the number of times you may get collisions and have to consult the state/manifest file.
20:34 leont joined
supernovus URL encoding schema doesn't work either, as using % characters is not guaranteed to work. 20:34
20:34 spider-mario left
japhb What FS breaks %? 20:34
20:34 spider-mario_ is now known as spider-mario
japhb (OOC) 20:34
FROGGS japhb: I would go for \w only file filenames, just to be sure, you dont know if this has to work someday on an android or whatever will be
japhb >.<
I Hate FS. 20:35
FROGGS ;o)
there you are
pmichaud I'll be back again soonish
will post a .msi soonish
japhb Or rather, I hate the fact that there are FS that disallow anything other than / and NUL.
supernovus japhb: Honestly, the chances of collisions is there, but not too serious.
diakopter japhb: disallow? 20:36
supernovus japhb: and if we use your suggestion, in the case of auth collisions, refer to the state file.
japhb supernovus, true.
moritz japhb: fwiw the last time we've discussed module file names (back in the pre-nom days when discussing module versioning), we decided to do allow A/B.anythiing.pm for module A::B
FROGGS japhb: please consider too that the full path should not be longer than 255 chars, or some backup system wont operate on these paths
japhb diakopter, Meaning, characters not allowed in a directory entry's name portion.
FROGGS so maybe a full url might be too long
moritz japhb: and then the compiler is free to maintain a cache with version and auth, or otherwise must read all candidate files that match that pattern 20:37
japhb FROGGS, ooh, interesting point.
moritz (mostly because it's ugly to map anything to file names, and because we didn't have great ideas back then)
diakopter japhb: so the directory entry's name portion can contain only / and NUL?
moritz things you need to consider: module names, auth etc. might be non-ASCII, not all file systems can map it
FROGGS right you are 20:38
supernovus moritz: Well, we can incorporate that into the scheme, by having say lib/XML/Grammar.github_huri.3.0.0.pm6 for example
moritz then you need facilities to allow module names that only differ in case, on case insensitive file systems
japhb diakopter, Ah. English ambiguity: "Or rather, I hate the fact that there are FS whose disallowed-character set is anything other than the set containing just / and NUL."
20:38 wamba left
diakopter japhb: oh I see :) boy, I feel dumb 20:39
20:39 arlinius joined
japhb diakopter, Nope, it's a real ambiguity, your brain just settled on the wrong local maxima of disambiguation probability. 20:40
supernovus which would match a "use XML::Grammar:auth<github:supernovus>:ver(v3.0.0 .. *);" statement.
20:41 leont left
supernovus Still need to work out what to do in the cases where a major version is over 10, as the version literal syntax currently breaks (confirmed in both Rakudo and STD). 20:41
japhb supernovus, moritz: I still like doing Module/Name/auth/ver.pm rather than Module/Name_auth_ver.pm, partly because I'm paranoid about filename length, partly because it's cleaner to my eyes, and partly because the directory form has fewer ambiguities.
supernovus, methinks that is merely a copy-pasted bug lacking sufficient tests. :-) 20:42
FROGGS hmmm, s/\w+/_/g might work well if the name is long enough, but I guess it is unlikely that two similar named authors fiddle on the same module
japhb I assume you mean s:g/\W+/_/ ;-) 20:43
FROGGS ya, whatever :P
japhb Just teasing.
FROGGS np, I can stand it
supernovus japhb: I like your proposal, with the subdirectories instead of filenames. 20:44
spider-mario argh
make: *** [src/stage1/QASTNode.pbc] Segmentation fault (core dumped)
when building nqp
FROGGS including the authors name and the version in the modulename makes sense for modules where you have many sub-namespaces 20:45
moritz spider-mario: I've had that too on one machine
spider-mario: i used a newer parrot, which helped 20:46
supernovus I guess within that scheme lib/XML.pm would get installed as lib/XML/github_supernovus/3.0.0.pm6 (or whatever the version specified in A.) the module itself, or B.) the META.info file, happens to be.)
spider-mario oh, ok
japhb OK, so do we need to agree on a single filename mapping that fits the least common denominator of every FS we think might be used, or do we declare that the character mapping to the filesystem is platform-dependent, all ambiguities therefrom are resolved by the state/manifest file, and the user is "none the wiser"?
FROGGS otherwise you will have many dirs that have the authors name
spider-mario I guess I’ll have to wait for parrot 4.10 to be packaged in my distro, then
it’s currently 4.9
diakopter I agree that author should come before module name, since it's much more likely for an author to have multiple modules than a module to have multiple authors 20:47
FROGGS japhb: I vote for one mapping for all, not a platform or filesystem depended one
japhb diakopter, yes, and also because S11 specs that auth must be considered before ver in all cases.
spider-mario thanks, moritz
FROGGS like they did on cpan, author comes first, but then it doesnt play that well with Any 20:48
diakopter japhb: no I mean before XML
supernovus If author comes before module name, then we'll need to use the state file, and won't be able to depend on directory based lookups.
japhb FROGGS, the advantage to picking (as you did) one mapping for all, is that it is easier for the implementors of the module system to write cross-platform module handling code.
FROGGS right 20:49
diakopter supernovus: oh
japhb diakopter, Oh, I see, sorry. I disagree then, because when you're trying to load a module, you don't want to traverse every auth directory trying to find the module's first part.
supernovus If I do "use XML" it's really easy to find "lib/XML/Any/Any.pm6" and not have to look in the state file. If the folder is "lib/github_supernovus/XML" instead, then to look it up, we need to look in the map. 20:50
japhb Which I guess supernovus++ beat me to saying. :-)
flussence ooh, I just thought of something
diakopter well, you would still have to traverse authors of XML::*, just there would be much fewer 20:51
FROGGS think of a dist with modules like: ABC, ABC::DEF, ABC::EFG; ABC::EFG::XYZ, whats the style with the least amount of dirs? I guess the lib/ABC/DEF_FROGGS_1.0.0.pm6 structure
flussence you could have "lib/XML/Any/Any.pm.d/$auth-thingy.pm"
(lots of linux stuff is doing that pattern these days)
moritz
.oO( just develop a content-addressable file system and force everybody to use it ... )
japhb FROGGS, the downside to picking one mapping for all, is that as soon as we decide on a mapping that should work everywhere, someone invents a "more broken FS"
And perhaps we need to embrace the eventual FAIL.
FROGGS thats why \w only 20:52
moritz FROGGS: but you know that \w matches more than [a-zA-Z0-9_] ?
FROGGS no umlauts nor accents
well, I basically mean [a-zA-Z0-9_]
japhb FROGGS, you still have FAT, or ASCII limited, or EBCDIC, or whatever the hell VMS does.
FROGGS no locale involved
japhb (FAT having both character set and severe length limitations) 20:53
FROGGS ohh, there might be 8.3 style filenames :/
japhb ISTR VMS has some funky limitations too.
And amazingly, I still see VMS patches float by, even for Parrot IIRC.
moritz forget about FAT16 and VMS 20:54
supernovus Ultimately instead of depending on the filesystem at all, we could use a manifest for all lookups, and have a 'lib/github_supernovus/XML/3.0.0/{XML.pm6,XML/Grammar.pm6} type structure and in the manifest, have XML and XML::Grammar listed with pointers to the versions.
moritz you can't decide the future while clining to all parts of the past
japhb moritz, I'm just saying that's a valid argument for saying "we can't find a LCD of FS naming that anyone wants" and calling it platform-dependent behavior. I'm not saying this is an overriding concern. ;-)
moritz japhb: agreed 20:55
japhb Personally, I favor FROGGS
FROGGS me in person?
japhb er, I favor his suggested mapping, more or less.
FROGGS ;o)
moritz :-)
japhb DEK
(Damn Enter Key)
20:55 wamba joined
FROGGS well, would be nice to campare these strategies with real world (Perl 5) modules 20:56
just one with two authors/versions and a few submodules
supernovus So using FROGGS mapping, we'd have lib/XML_github_supernovus_3.0.0.pm6 and lib/XML/Grammar_github_supernovus_3.0.0.pm6 ? 20:57
japhb supernovus, I am still clinging to the idea that the filesystem representation is understandable to mere humans, and that FS lookup is a fast path that should work in most cases, only forcing parsing of the text file when really needed.
FROGGS its not really my invention, but moritz's iirc
but it has less dirs
japhb supernovus, I'd say .../XML/github_supernovus/3.0.0.pm6
diakopter what about having a directory name for the module's filename as well... so lib/XML/github_supernovus/3.0.0/XML.pm6
japhb diakopter, Makes the 'Any' magic not work, as well as the collapsed file disambiguation id not work. 20:58
s/file/filename/
diakopter or lib/XML/Simple/github_supernovus/3.0.0/Simple.pm6
I don't know what those two requirements are
japhb Oh, mentioned in my design gist. 20:59
20:59 GlitchMr left
diakopter I seem to have lost the url; paste plz? 20:59
japhb It's how it maintains a fast path for 'use' when the user doesn't care about version, or the FS has collapsed names because e.g. it is non-case-sensitive.
sure, hold on
gist.github.com/4158939 21:00
FROGGS so if you have no seperate dir for author and version an Any-lookup would be: lib/Module-(*)-(*).pm6 # * means highest version for example
japhb FROGGS, and then you are parsing directories in user space, instead of letting the kernel find it AFAP.
supernovus Uhg. I don't really like the duplication of the module name. lib/XML/github_supernovus/3.0.0.pm6 or lib/XML.github_supernovus.3.0.0.pm6 are both potential candidates in my mind. I do like japhb's proposal to be honest, along with the s/\w+/_/ applied to the auth names. 21:01
diakopter I don't like how the main file has a version number as its filename but modules in child directories don't 21:02
japhb diakopter, what makes you think that?
moritz oh, while we are at it
please consider how development works
people will just want to edit always the same files
FROGGS well, I can't tell if I like this lib/XML/github_supernovus/3.0.0.pm6 or that more lib/XML.github_supernovus.3.0.0.pm6, both is pretty fine 21:03
moritz and then at some point, mark it as a certain version
diakopter japhb: let's say XML::Simple contains XML::Simple::Foo:Bar
moritz so they will run a 'make release VERSION=1234' or so
diakopter what does the directory/filename structure look like under the author
moritz and that will copy the files to the right name/location
FROGGS moritz: the filenames can be build that way when installing
moritz FROGGS: correct
japhb diakopter, so it will look like XML/Simple/Foo/Bar/auth/ver.pm. It's .../auth/ver.pm all the way down. 21:04
moritz but it means the old mode (without any version in the file name) must be supported for development too
FROGGS .. or when calling ./Build dist
japhb moritz, that's actually part of what I was cogitating in my (not yet posted) proposal for handling @*INC, but I was caught off guard by the @*INC hate before I pasted that idea. 21:05
I wanted to make sure my idea still worked when thinking about sorear++'s concerns.
diakopter I really don't like that idea. I think trying to optimize module loading is very premature; I think simplicity is much more important. there will never be a case where traversing a few directories when loading each module will dominate the time of a script. startup won't be that fast 21:06
japhb diakopter, At my dayjob, we already have scripts whose startup time is dominated by FS effects from badly-designed module loaders.
moritz diakopter: I agree. Much of the module locating stuff can be sped up with caching 21:07
japhb Not Perl 6, mind you: PHP, Ruby, etc.
moritz -> sleep
japhb g'night, moritz
21:07 rurban_ joined
FROGGS the usual case will be to load a module without specifying the author or version, this will end up beeing lib/Module/AUTH/VER.pm 21:08
flussence argh... now I'm reminded how dumb PHP's built in autoloader is
FROGGS simple lookup
japhb flussence, EXACTLY.
diakopter japhb: I think that's fine, but for a module with several packages several layers deep, the number of directories gets huge
japhb FROGGS, Right, that was my intent.
diakopter, yes -- that's the way Perl 5 is now. 21:09
And I think it works pretty well.
diakopter I'm saying the number of directories in your proposal would be quadratically more than P5
japhb (Remember Perl 5 has auto directories, and share directories, and such, not just Foo/Bar/Baz.pm) 21:10
FROGGS diakopter: I believe you just get twice the amount of dirs than P5
(without auto)
diakopter lib/Module/AUTH/VER.pm is bad.. lib/Module/AUTH/VER/Module.pm is much better 21:11
s/much//
(imho)
FROGGS why?
japhb diakopter, even disregarding that Perl 5 has more directories per module than most people think about, I think a mild explosion of auth/ver directories is to be expected in a multi-install design like S11.
21:12 wamba left
japhb diakopter, I don't understand why lib/Module/AUTH/VER/Module.pm is a win. That adds another directory layer! 21:12
diakopter well if you're already going to have a pointer to which version is active, why not have a pointer to which author is active and put author at the top loevel
FROGGS you mean lib/AUTH/VER/Module.pm then 21:13
japhb diakopter, the auth has to go below the module name, unless you always want to search the disambiguation file.
diakopter it's trivial to serialize a hash for that 21:14
FROGGS btw, does it makes sense anymore that a submodule needs to be in a subfolder?
diakopter (like the caching moritz suggested)
japhb diakopter, then you lose the idea of the FS structure actually making sense to the average sysop.
FROGGS, I am not sure there's a good way of avoiding that which won't end up with searching up and down directory trees trying to find the closest-but-not-exact filename match. 21:15
diakopter japhb: I don't think Module/AUTH is any easier to understand than AUTH/Module 21:16
japhb sorry, I'm not sure there's a good way of having all submodules in the same folder as their parent module.
21:16 kaare__ joined
japhb diakopter, If you're looking for Blitz::Blum, where do you look? 21:16
FROGGS no, then the Any would break... 21:17
japhb Also, I was responding to both lib/AUTH/Module, and lib/HASH
diakopter like I said, the preloaded hash in memory tells you which author to use
supernovus None of this takes into account multiple resource directories or binaries in 'bin' either. I think using a manifest for lookups may be better, and simpler. Just stuff the entire contents of any given module distribution into '$auth/$distname/$ver' and depend on the manifest to determine the newest version. Each of those directories has its own 'lib', 'bin', 'doc', 'share', 't', etc. folders.
diakopter ++
japhb diakopter, preloaded *when*? We're trying to avoid having to do a huge caching at startup.
diakopter the current proposal is also weak for uninstalling 21:18
deserialized from the disambiguation thing
japhb diakopter, How do you figure?
diakopter oh, I guess if there's a manifest
japhb Right. :-)
diakopter I think supernovus' comment is spot-on. 21:19
supernovus Using the manifest version, we could also allow the package manager to switch the "active" binary put into the path.
diakopter japhb: deserialized from the disambiguation thing
21:20 Rix joined
diakopter deserialization and then a hash lookup or two can be quite fast 21:20
supernovus I've been thinking about the fact that many module distributions contain more than just 'lib' and most proposals up til this point have been focused entirely on versioning the contents of 'lib', but what if the binary in 'bin' depends on a specific version of the library (very likely), my updated proposal would save the entire contents of the distribution into a folder. 21:21
japhb OK, but I'm saying you are forcing the parsing of all the disambiguation files in all include trees in order to do *any* module loading at all.
diakopter sure, why not 21:22
japhb supernovus: If the distribution is named "XML-Simple", but the user says "use XML::Simple::Foo::Bar", or even worse "use XMLHelper::Baz", how do you find it?
21:22 kaare_ left
japhb Just relying on the manifest file? 21:23
supernovus supernovus: The manifest would map module names to dists.
japhb heh
FROGGS every module must be indexed, to know in what dist it is
japhb nodnod
FROGGS like on cpan/pause
21:23 fgomez left
japhb Just making sure we're on the same page; we've had a few accidental talking-past moments in this discussion. :-) 21:24
21:24 fgomez joined
japhb OK, so let's see if we're in general agreement: 21:24
1. We need a mapping of files in the distro to filenames on disk.
2. We favor the idea of using one standard mapping for this. 21:25
3. We need to consider more than just lib files.
Any disagreements with that so far?
supernovus That being the one potential pitfall of a manifest-based system. Pros: easy handling of an entire distribution with all of its files. Cons: must parse up to four manifest files in order to find modules.
21:26 kcwu_ joined
FROGGS four? why four? 21:26
japhb supernovus, or min(4, +@*INC), if we support that.
FROGGS ahh, okay
japhb FROGGS, the current design has 4 lib roots
FROGGS ya, sure
supernovus Yeah, that also depends on if @*INC is going to be in there too.
japhb OK, so disagreements: 21:27
21:27 wamba joined
supernovus I can't see how to get rid of @*INC, as it is useful in some circumstances, such as test files with custom libraries. 21:27
japhb A. Is the manifest *always* used for lookups, or just when the filesystem doesn't give an immediate unambiguous match?
FROGGS to 1), I believe its not about files, but modules+auth+version, if you need the bin-dir or share-dir you wnat that of a given module-version
japhb FROGGS, I understand and agree. 21:28
21:28 hjsteffens joined 21:29 ashleydev joined
FROGGS well, I'd say the first match might be Module.pm (without author and version) in @*INC, for development 21:29
japhb B. Do we attempt to mash all files from all distributions into a fixed bin/Foo/BAR, lib/Foo/Bar, share/Foo/Bar/, etc., or do we do distro/{lib,bin,share..}
21:29 kaare__ left
diakopter I know which one OS package managers would prefer 21:30
FROGGS I vote for laste approach
-e
japhb C. Do we consider the text of the use ("use Foo::Bar") pre-eminent in FS layout design, or the auth+manifest?
Do I have the areas of agreement and disagreement about covered?
Any I'm missing?
Oh, I guess in honor of sorear: 21:31
D. Do we support @*INC at all?
21:31 rurban_ left, hash_table left
FROGGS I dont understand C 21:31
21:31 zby_home_ left
japhb FROGGS, in other words does the start of the tree go Foo/Bar/<something>, or auth/distro/Foo/Bar? 21:32
FROGGS and for D, I dont want to install my module that I'm currently hacking on just for testing
japhb I agree. Despite implementer pain, I think @*INC just needs to exist.
21:33 stopbit left, Vlavv_ left, kcwu left, Khisanth left, ashleyde1 left
japhb ... but seeding it sanely might vastly cut down on the frequency of @*INC changes in the real world. 21:33
PerlJam japhb: searched first or last or what?
supernovus Currently we split up 'bin', 'lib', 'share' into separate folders, which is very unix-like, but doesn't work well if we're tracking multiple versions. I think $auth/$distname/$ver/{lib,bin,share,doc,t} with some form of mapping is better. That said, we need to be able to support the current system as well.
FROGGS japhb: D) if @INC is empty by default and I'll be able to add something to it that would suffice 21:34
japhb PerlJam, I *assumed* that the default @*INC would include the four standard roots.
sorear good * #perl6
PerlJam japhb: ok.
diakopter strawberry perl doesn't use symlinks for its bin directories; it uses .bat wrappers for stuff installed there
21:34 sqirrel left
japhb sorear, Hello there! 21:34
FROGGS japhb: for C) I dont care if the files will be looked up by manifests 21:35
hi sorear
supernovus If I am testing something, with a custom @*INC, I want to be able to load somedir/Foo.pm6 by calling "use Foo".
japhb The one big thing about the all-manifests-all-the-time approach is that if we're supporting @*INC ... what supernovus said. 21:36
diakopter right, you don't want to have to 'make' it
FROGGS supernovus: right, but I woulnt care to put a use lib right before use Foo
japhb Which brings back one of the reasons I favor the FS-first-then-manifest approach.
supernovus Basically, the ability to support the current structure, unchanged, as well as a new structure with versioning and authority information taken into account.
japhb supernovus, right, so the design has to handle both ... unless we decide that we're going to nix the old way. 21:37
sirrobert what does $distro refer to in "$auth/$distro/$version/" ?
as in name of project?
supernovus sirrobert: The name of the project. 21:38
sirrobert ok
flussence speaking as a real end-user: any solution to this where I can't tab-complete from an obvious starting point and have to resort to `locate` is a huge WTF. 21:39
21:39 stopbit joined
supernovus I cannot resolve perlfoundation.org, can someone see who I should e-mail my CLA to? 21:40
japhb flussence, that matches my thinking
FROGGS supernovus: I can, hold on
21:40 Khisanth joined
japhb supernovus, note that tadzik emailed a scan of the signed printout, IIRC. 21:40
diakopter web.archive.org/web/20110721223648/...ation.org/
FROGGS supernovus: I mailed it to [email@hidden.address] which is the only address you get there
21:40 Vlavv_ joined
PerlJam japhb, flussence: watching this discussion makes me wish that filesystem paths weren't even in it. 21:41
FROGGS japhb: I did that too
flussence (as an aside, this is already the case now that ~/.perl6 is no longer used)
supernovus FROGGS: e-mailing it there worked for you?
flussence: where do modules go if not in ~/.perl6 ?
sirrobert flussence: it isn't?
FROGGS well, I was able to send the mail last wek
week
but you wont get any answer according to masak or tadzik or me yet
flussence as far as I can tell, for me they're all in ~/code/rakudo/install/lib/parrot/4.4.0-devel/languages/perl6/site/ 21:42
japhb supernovus, %*CUSTOM_LIB< home site vendor perl>
sirrobert supernovus: I would love to have deps installed in a project root (a la node.js). per-project libs.
I think node.js nailed it on that one.
japhb sirrobert, understood and agreed that is useful. 21:44
sirrobert fwiw, as an end-user myself, I would prefer something like <lib>/$auth/$distro/$ver/Foo/Bar.pm myself, I think. 21:45
japhb sirrobert, where do you stand on the location of bin/ and share/ files and the like? 21:46
PerlJam I think that we'll need an actual implementation before any of us *really* knows what to think :)
sirrobert japhb: if I understand the problem correctly, I'd put them under $auth/$distro/$ver/[lib|bin|share] 21:47
diakopter for the bin directories, you also should consider what the user does with the PATH
FROGGS an example (including bin and share) would be helpful I guess
diakopter you don't want the user to have to add version-specific dirs to the path
sirrobert diakopter: but you want them to be able to, unless the libs are project-specific.
FROGGS diakopter: if you have several versions of a binary installed, you need to have a version as a dir somewhere 21:48
diakopter I realize, but the user will just want "a version"
what's the use of installing a module with an executable if you can't execute it right off the bat 21:49
sirrobert then just do the most recent version (by number)
japhb diakopter, this discussion reminds me of the Debian alternatives concept.
You have lots of stuff installed, and a directory of symlinks for the version a shell user will see.
diakopter alternatives++
(stub shell scripts that dispatch to particular versions)? 21:50
(already done on strawberry)
japhb mildly fears stub shell scripts that start off by parsing the manifest files ... 21:51
sirrobert is the problem with executables that they wouldn't be in $PATH? 21:52
supernovus sirrobert: per-project deps, that's pretty awesome actually.
sirrobert supernovus: I thought it was pretty neat when I first read about it
supernovus: then I used it in several projects... I was wrong, it's The Right Thing. 21:53
=)
japhb supernovus, see also Ruby bundles.
sirrobert japhb: bundles++
japhb sirrobert, yeah, the path explosion problem is a biggie, if you have lots of uninstalled module packages, each with bin/ dirs. 21:54
sirrobert fwiw, when I install r* right now, I do it in: ~/.perl6/rakudo-star-2012.11/install
japhb Just remembering to set $PATH properly can be a pain, especially with version-dependent directories.
(Well, assuming that my 'Any' version proposal doesn't win) 21:55
21:55 arnsholt joined
supernovus So many possibilities. We want to keep Perl 6 as flexible as possible, but still have sane defaults to back up to. Maybe having versioning in the "use statements" isn't important at all, if we have per-project bundles, the ability to say "panda install XML -version 3.0.0 -to ./my-project/lib" would be more useful. 21:55
sirrobert the script I use automatically symlinks: ln -s ~/.perl6/rakudo-star-2012.11/install/bin ~/.perl6/bin-2012.11; rm ~/.perl6/bin; ln -s ~/.perl6/bin-2012.11 ~/.perl6/bin 21:56
my path contains $PATH:~/.perl6/bin
a system like that could help.
japhb supernovus, I think some of the original S11 design concept was that multiple versions of modules could be installed by the system package manager, not just by individual users. 21:57
sirrobert basically the "latest version" is symlinked to something in my $PATH on install
japhb sirrobert, I do something similar. :-) 21:58
supernovus japhb: Yeah, the per-package system is great, but the ability to also have shared versions installed system-wide is desirable too. How to keep it flexible, supporting both, without making it a monstrosity?
japhb I think you've just summarized the last hour or so. :-) 21:59
sirrobert I think a developer version of "use" that uses some canonical path, but also gives a warning (which developers can ignore) could be a good idea. 22:00
japhb OK, I think the gist of discussion is that my proposal was a decent starting point, but there is a lot more that needs to be considered for a second draft.
sirrobert, why make a different 'use'?
What does that gain you?
sirrobert japhb: doesn't have to be a different "use", necessarily... but someone (FROGGS?) was saying they don't want to have to install while developing. 22:01
(which makes sense)
but I think treating developers differently than end-users is reasonable, as long as you don't treat them *worse* =) 22:02
supernovus Well, that's pretty much what it boils down to. We want to be able to support many different ways of using Perl 6, which includes %*CUSTOM_LIB, @*INC, "use lib", project-specific library-sets, system-wide library installations, etc. While not turning into something entirely insane at the same time.
japhb sure. My question is, do we gain by keeping the loading systems separate, or on the other hand by making use DWIM?
oops
22:02 wamba left, wamba1 joined 22:03 skids left
japhb is going to have some serious tanking to do. 22:04
22:04 rurban_ joined
sirrobert What we gain from keeping it separate is a sense of "best practice" (without a mandate) 22:05
supernovus There, e-mailed the CLA. I'll snail-mail it too.
sirrobert but people using the system differently at least know how they are using it. Sometimes transparency is desirable, but sometimes we should prefer a certain amount of *training* for new users 22:06
for a given practice, it will be very DWIMmy, and a tiny bit of training helps reduce headaches, unless someone wants to deviate *on purpose* =)
supernovus Well, if we want to use a project-specific folder, we can do a "use lib './lib';" type statement, which would be the same as doing "BEGIN @*INC.unshift: './lib';" and then we'd need a way to make panda install modules into that directory. 22:08
22:09 rindolf left
sirrobert supernovus: according to tadzik, there's already a param you can pass in to panda to do that. making it default should be easy enough. 22:10
diakopter japhb: I don't see anything wrong with using symlinks anywhere, FYI. Windows distributions can always include a utility to do the symlinking on Windows (since Windows 2000)
er 22:11
japhb diakopter, Good to know.
Thanks. :-)
22:11 DarthGandalf joined
diakopter junctions since 2000, symbolic since Vista 22:11
japhb "junctions"? 22:12
diakopter junction is sufficient
en.wikipedia.org/wiki/NTFS_symbolic_link
links to junction
japhb Weird. dir-only symlink, basically 22:13
sirrobert heh 22:14
FROGGS gnight pals, I'll read the logs and I'm really looking forward to it... japhb++
tadzik according to me? :)
22:14 FROGGS left
sirrobert tadzik: you told me that a long time ago, I believe =) 22:15
tadzik oh, DESTDIR
sirrobert yep
tadzik it may work, yes :>
sirrobert heh
tadzik or if you mean a Panda object, then for sure
probably also called destdir
22:15 rurban_ left
tadzik emmentaler uses that to test modules in a "sandbox" 22:15
22:19 donaldh joined
TimToady is limping along on GoogleWiFi because our home network is offline; currently in the middle of an upgrade from DSL to almost-fiber, and our copper isn't cutting it... 22:22
at least we have GoogleWiFi--there are a few advantages to living in GoogleTown
masak TimToady! \o/ 22:23
sorear \o/ 22:25
22:25 bluescreen10 joined, spider-mario left 22:26 pmurias joined 22:28 bluescreen10 left 22:29 bluescreen10 joined
sirrobert =) 22:29
lue hello o/ 22:31
pmurias re mapping module versions to filenames does any of the proposed schemes supports finding a version matching a given range? 22:33
phenny pmurias: 25 Nov 00:32Z <jnthn> tell pmurias !cursor_next handles it; the bstack survives and it hands back a 1 for restart, which makes the generated code jump straight to fail (and thus it backtracks and produces the next feasible cursor)
22:33 supernovus left
lue I again vote for removing @*INC and having C<use> work in like C/++'s #include (name of module in standard path or string literal to file in a nonstandard path) 22:33
pmurias a searching the whole @*INC everytime doesn't seem a particulary good solution 22:34
22:34 fgomez left
lue s:s/in like/like in/ 22:35
22:36 bowtie left
pmurias lue: and the standard path is? 22:36
lue e.g. use Foo::Bar; or use "./lib/Foo/Bar.pm"; (the string literal would accomplish what BEGIN { @*INC.push } does)
pmurias: what's configured before compiling the compiler (although I don't know what specific paths would be best)
pmurias that's a bad idea 22:38
lue As far as I know, that's how gcc works (or am I wrong there?). 22:39
pmurias yes 22:40
flussence `man ld-linux.so` mentions some absolutely horrible things, now that you mention it...
pmurias but the C build model is the last thing we want to emulate
flussence ("/usr/lib/sse2/acpi/" is a valid shared lib directory and it'll look in there) 22:42
lue In any case, I'd much prefer use "local/file.pm6"; to BEGIN { @*INC.push("local"); }; use file; (and have always missed being able to do this. Sometimes I don't want to think of an included file as a module.) 22:43
dalek rl6-roast-data: a2b7b7a | coke++ | / (3 files):
today (automated commit)
22:44
lue (I know there's C<require>, but I don't remember it working.)
lue wonders what's so wrong with the C build model 22:45
pmurias do you have looked at a build system for a large C(++) program? 22:46
lue I've seen them, but never worked in them. 22:47
pmurias you have read the Makefiles? 22:48
lue yes. (But Makefiles never look fun) 22:49
flussence the makefiles aren't the worst part... :)
22:50 bowtie joined
pmurias the autoconf tools are worse ;) 22:50
huf i've had better experiences with hand-written hand-editable makefiles that source a platform-specific settings-makefile 22:51
lue That's not the C build model to me though, that's the Makefile build system.
huf than with auto*
lue has only heard legends of auto*'s awfulness 22:53
22:55 fgomez joined
lue I'm not sure I actually see what benefit @*INC provides over an #include style use. 22:57
huf the language knows what it has included 22:58
geekosaur it's awful, but most of the alternatives I've seen are worse. it's a hard problem
lue (not the preprocessor aspect of #include, but the "I can include a local file easily" part) 22:59
donaldh local to where?
@*INC separates environment from program. 23:00
huf #include has an INC too
have fun trying to make gcc print it tho :D
donaldh Even C includes should just be relative to -I path
23:00 sftp left
huf altho i think i found some odd way a few weeks ago... hmm 23:00
lue Instead of using @*INC in a BEGIN phaser to test a library, you just do use "../lib/File.pm6"; 23:01
donaldh lue: and what is your working directory?
huf cwd, like perl5's require :)
logical but mostly useless :) 23:02
lue P6 has require too, but it hasn't always worked and is runtime instead of compiletime.
donaldh So the program can only run in a fixed location.
huf p5's require is also runtime
lue can @*INC be changed any time after the program starts (including phasers into the starting process)? 23:03
huf and surely if your program modifies its INC before loading stuff, it can do aaanything
lue If you can change @*INC during execution ("now that I've parsed your input file, let's change @*INC !"), that feels like a Bad Thing™ (and thus I agree with sorear). 23:04
.oO(why not give perl6 a -I commandline option too?)
23:05
huf lue: but you often want the lib/ dir next to the executable
sirrobert lue: there already is one 23:06
huf that's i think the most common reason people muck with the INC at runtime
sirrobert lue: perl6 -Iblib/lib foo.p6
donaldh perl 5 too 23:07
lue Cool, I thought there wasn't.
donaldh Interesting. In perl6 -I is not documented in --help 23:09
It says: PERL6LIB="lib" perl6 example.pl
lue I'm afraid I still don't see the benefits of a runtime-modifiable @*INC (if you need to modify @*INC before C<require>ing something, well, C<require> accepts paths in a string variable) 23:10
donaldh sophisticated module management. 23:14
e.g. bundling DBD drivers in their own INC directories. 23:15
huf well, depends. but you're right, it's more useful to modify it in the middle of compile :)
donaldh require a which in turn uses b and c which use ... 23:16
I think, a path argument to require only solves one level of indirection. 23:17
huf yeah, hence use lib in perl5 (and also require accepting package name barewords, but only as literals) 23:18
23:21 Chillance left
donaldh it's really important to separate environment from program, so that libs are portable across environments. 23:21
lue doesn't get how modifying @*INC in-program separates the environment from the program...
sirrobert phenny: tell jnthn I think the perl6-debug in rakudo-star-2012.11-RC1 steps over method/function calls by default, instead of stepping into them. 23:22
phenny sirrobert: I'll pass that on when jnthn is around.
23:25 hash_table joined
donaldh DB.connect("sqlite:fred") might then do @*INC.push($driverDir ~~ '/' ~~ $driver); require $driver; so that sqlite can load its own modules. 23:26
The sqlite driver would then be independent of its environment. 23:27
23:28 stopbit left
lue where does $driverDir come from? 23:28
&
23:28 whiteknight joined
donaldh A hypothetical configuration variable for DB. 23:28
huf lue: most common p5 use: use lib dirname(__FILE__).'/lib'; use My::Very::Own::Wiggle; # so now wherever you run foo.pl from, it'll find its own lib/ dir next to itself. 23:29
flussence r: qp{o/n.m}
p6eval rakudo 247f87: OUTPUT«===SORRY!===␤CHECK FAILED:␤Undefined routine '&qp' called (line 1)␤Undefined routine '&o' called (line 1)␤Undefined routine '&n' called (line 1)␤»
23:30 bluescreen10 left
huf ... and also wherever you move foo.pl and its lib/ it'll still work. 23:30
sorear nodejs and the CLR do that automatically 23:31
23:31 hash_table left
flussence oddly enough, the last serious thing I wrote in PHP used almost exactly that line... 23:32
huf yes, it's not the nicest of the incantations...
donaldh sorear: local indirection? Do they? nice.
flussence (if anyone was wondering: function __autoload($class) { require dirname(__FILE__).'/lib/'.strtr($class,'\\','/').'.phps'; } ) 23:33
sorear donaldh: yeah, one of the default module search paths is relative to the location of the using code
donaldh sorear: hopefully the first one. 23:35
donaldh thinks he'd always want to search self relative lib first. 23:36
23:37 skids joined 23:40 donaldh left 23:47 whiteknight left 23:48 wamba1 left 23:51 PacoAir left
masak 'night, #perl6 23:52
23:52 benabik left