Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2010-07-13

Perl 6 | Reference Documentation | Rakudo

| Channels | #perl6 index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:00 sorear ingy: OOH YAML-P6?
00:01 * sorear would love to see a p6rules version of YamlReference
00:02 ingy jnthn: see the bottom of http://github.com/ingydotnet/yaml-pm6/blob/master/t/dump.tml
00:02 ingy jnthn: does that look sane?
00:02 ingy sorear: I'm just dumping for now
00:02 ingy but I can do circular refs and objects
00:02 ingy I think I will try a p6rules parser though
00:02 jnthn ingy: Well, I'm not particularly familiar with YAML so maybe not the best person to ask. ;-)
00:03 ingy ok
00:03 ingy TimToady: see the bottom of http://github.com/ingydotnet/yaml-pm6/blob/master/t/dump.tml
00:03 sorear ingy: just curious, is there anything out there explaining the origins of 'ingydotnet'?
00:03 ingy TimToady: does that look sane?
00:04 jnthn ingy: It looks at least plausible. :-)
00:05 ingy jnthn: other langs would probably make $!x, just x
00:05 ingy anyway, I think it will be useful to me
00:06 pugssvn r31652 | lwall++ | [Temporal] time is now a pseudo-constant like now, rand, etc
00:06 ingy now I can try to dump my testml object treee
00:06 pugssvn r31653 | lwall++ | [STD] term:sym<time>
00:08 ingy HOLY FUCK
00:08 ingy IT JUST WORKED!
00:08 ingy gist upcoming...
00:13 ingy jnthn, TimToady, sorear: check this bad boy out: http://gist.github.com/473265
00:13 jnthn "Perl 6. HOLY FUCK IT JUST WORKED!"
00:13 jnthn :-)
00:13 pugssvn r31654 | lwall++ | [S06] defined callsame/nextsame in terms of callwith/nextwith and callframe
00:14 jnthn ingy: Nice :-)
00:16 ingy that was a 3 day yak shaving session to allow me to not go crazy debugging testml dev
00:18 dduncan joined #perl6
00:19 * jnthn -> sleep, if I can in this heat :S
00:19 jnthn o/
00:20 TimToady \o
00:20 dduncan TimToady, regarding my addition of Blob literals to S02 yesterday, is the format I chose acceptable to you or do you forsee there being problems with it?  AFAIK, it does not conflict with any valid numeric or other string literals.
00:23 TimToady but it doesn't extend with :4<...> notation
00:24 dduncan well what about :N'...' ?
00:24 dduncan eg, :b'11001'
00:24 TimToady on the other hand, how is a blob different from a large number?
00:24 dduncan or :16'45F'
00:25 dduncan the concept is different
00:25 TimToady perhaps Blob(:2<1001010100100101010001011010001010100101010010100100010110100010100000>) is good enough
00:26 tylercurtis std: :2<11001>.Blob
00:26 dduncan well that's certainly better than Blob(2=>'11100101010101010') say
00:26 p6eval std 31651: OUTPUT«ok 00:01 110m␤»
00:26 TimToady hmm, though it would be hard to extract the base unit from the number
00:27 Chillance joined #perl6
00:27 dduncan my preference is something that doesn't look like a function call
00:27 TimToady the current spec is not extensible and looks like a mistake of 0b for :2
00:27 dduncan I see Blob being at least as fundamental as Str, in different ways
00:28 TimToady fundamental should not be confused with common
00:29 TimToady we do huffmanization based on commonness, not fundametality
00:29 dduncan well, my number one desire, greater than looking like anything specific, is to have *a* canonical terse way of writing a Blob literal
00:29 dduncan so Blob(:2<...>) would fit that bill
00:29 TimToady well, there are other options, perhaps
00:30 dduncan basically, while things can be changed later, I would like for the spec to have *something* now rather than being silent on the matter
00:30 dduncan which is the point of my addition yesterday
00:30 TimToady for instance, :2{11000101010} isn't taken at the moment
00:30 dduncan and that something can be anything that doesn't conflict with other syntax, barring that being changed too
00:31 dduncan I would be quite happy with :2{...}, moreso than Blob(...)
00:31 dduncan for that matter ...
00:31 cognominal TimToady, I think the spec should be more explicit about mmd descending to pattern match inner signature. See #76486 for an example.
00:31 dduncan is :2[...] taken for anything?
00:32 dduncan the reason is, I see square brackets being a mneumonic for something ordered, while curly braces are a mnemonic for something unordered, though blocks defy that
00:32 dduncan actually, nevermind
00:33 dduncan :100[...] taken
00:33 blubblub joined #perl6
00:33 dduncan I'll update my additions to S02 to use :N{...} for now, barring a better option presenting shortly
00:34 dduncan but I also like people being able to use [b|o|x], so ...
00:35 tylercurtis Perhaps a quoting construct similar to that for paths?
00:35 dduncan how does :0b{...} being an alias for :2{...} sound?
00:35 xinming_ joined #perl6
00:35 blubblub left #perl6
00:36 tylercurtis q:blob(2){11000101010}?
00:37 dduncan I recognize user-defined delimiters being useful for Str, but I don't see the use for Blob, since they have a very small column domain like with numerics
00:38 sorear Is != considered a derived operator?
00:38 tylercurtis dduncan: interpolation might be useful for Blobs,
00:39 sorear dduncan: user-defined delimiters are handled at a very low level in STD.pm6, supporting them is easier than not
00:39 dduncan so maybe we could do that then
00:40 dduncan make the Blob literal into a quotelike syntax of a string
00:40 dduncan sure, interpolation is useful
00:41 dduncan for some reason I'm reminded of "formats"
00:41 TimToady there is a problem unless we define types like uint3
00:42 takadonet joined #perl6
00:42 TimToady unless we make the Blob role take a number instead of a numeric type
00:42 takadonet hey everyone
00:42 phenny takadonet: 11 Jul 17:14Z <moritz_> tell takadonet to look at <http://nopaste.snit.ch/21946>, which is a working example of lazy matching with Rakudo
00:42 ashleydev joined #perl6
00:42 takadonet wow.... first time someone left me a message....
00:43 dduncan now, I consider a Blob to be a string of bits specifically, with an octet-Blob to be a subtype whose strings are all multiples of 8 bits in length, etc ...
00:43 dduncan this is different from a string of arbitrary integers
00:43 dduncan which is different from a string of characters
00:44 pugssvn r31655 | lwall++ | [S02] revise blob literals a bit
00:44 dduncan TimToady, thank you for giving attention to this
00:45 TimToady I just invent Uint as a role that takes a number of bits
00:45 TimToady not sure if that'll fly, but didn't want to bless 'uint\d+' as a productive notation just yet
00:46 TimToady I suppose there will be people who want int24 though
00:46 TimToady or uint24
00:46 sorear TimToady: Should &say call .Str or .Stringy?
00:46 sorear perl6: say Bool::True
00:46 p6eval pugs, rakudo 94d01f: OUTPUT«1␤»
00:47 TimToady say is supposed to call .Str as a low-level primitive
00:47 sorear what, not True?
00:47 TimToady that doesn't thread
00:47 dduncan I agree that a role approach is better than uint\d+ being magical
00:53 sorear why make uint a role and not a class?
00:55 pugssvn r31656 | lwall++ | [S12] define more forced actions on enum values
00:56 TimToady classes aren't parameterized
00:56 sorear TimToady: is t/spec/S02-builtin_data_types/bool.t:58 now wrong?
00:59 pugssvn r31657 | Darren_Duncan++ | add 2-bits/col blob example
01:01 dduncan I would have had that 4th example before had I used numeric bits/col specifiers
01:06 * TimToady is now considering whether roles that instantiate native types should be lowercase, like uint[3]
01:08 sorear A role can instantiate a native type?
01:09 pugssvn r31658 | lwall++ | [bool.t] align bool tests with new stringification spec
01:09 TimToady well, they would be highly specialized roles
01:09 TimToady with a circularity saw right under the surface :)
01:09 TimToady but I don't really wish to predefine int[7]
01:10 TimToady int7 rather
01:11 TimToady and Int is supposed to be the generic object, which would be confusing to also have as the native creating role
01:12 TimToady or maybe it should be de-huffmanized to native_uint[7] or some such
01:12 dalek niecza: f9a7172 | sorear++ |  (3 files):
01:12 dalek niecza: Add NIL-accessible control structures
01:12 dalek niecza: review: http://github.com/sorear/niecza/commit/f9a71726c650465186d8db889aed6579d69dfded
01:12 dalek niecza: 919c9fe | sorear++ | Niecza/Grammar.pm6:
01:12 dalek niecza: Better error message for malformed NIL ops
01:12 dalek niecza: review: http://github.com/sorear/niecza/commit/919c9fe750701f6cb4bf55b2c5968dc36495cf60
01:12 dalek niecza: ab166f7 | sorear++ |  (3 files):
01:12 dalek niecza: Fix conditional parsing; implement NIL comparison operators
01:12 dalek niecza: review: http://github.com/sorear/niecza/commit/ab166f73b8cef77d89c82f6bc886c93d5a325bad
01:12 dalek niecza: e92f5a9 | sorear++ |  (2 files):
01:12 dalek niecza: Handle infix:<< < >> syntax; implement Num*Num -> Bool operators
01:12 dalek niecza: review: http://github.com/sorear/niecza/commit/e92f5a90ead2921934ac76c47f8f75793c04abf9
01:12 dalek niecza: a22df56 | sorear++ | setting:
01:12 dalek niecza: Move functions after types; add Bool.Str
01:12 dalek niecza: review: http://github.com/sorear/niecza/commit/a22df56e26e626be6e2d2611c3d7ca4514c53dd9
01:12 dalek niecza: fdc147c | sorear++ | Niecza/Actions.pm:
01:12 dalek niecza: Implement most basic case of CHAIN
01:12 dalek niecza: review: http://github.com/sorear/niecza/commit/fdc147ce1f44d349aaff8831c69851ffd1f5442a
01:12 takadonet ...
01:13 TimToady we need bitfields of arbitrary size if we're going to be able to emulate modern C declarations, for instance
01:23 cls_bsd joined #perl6
01:29 TimToady I'm wondering if it's a mistake to leave time returning fractional seconds when POSIX doesn't define it
01:29 TimToady and people should use now instead for that anyway
01:36 pugssvn r31659 | lwall++ | [S02] s/Uint/uint/ for speculative native role
01:36 pugssvn r31660 | lwall++ | [S32] revert C<time> to POSIX integer seconds; don't try to do C<now>'s job
01:37 dduncan were 'time' and 'now' aliases before this split?
01:37 dduncan nevrmind
01:40 dduncan about the uint role thing, perhaps more than just [3] could be made role ... eg, why not have the [2] and [4] as well at least?
01:40 dduncan if not all of them
01:47 sorear TimToady: I'd like a nice way to get at gettimeofday(2) functionity, if available
01:47 sorear the whole tv_secs + tv_usecs / 1000000.0 thing gets annoying after you've typed it five hundred times
01:49 jaldhar joined #perl6
01:49 dduncan I don't like the whole usecs thing myself
01:49 dduncan time should be either whole seconds or arbitrary fractions
01:51 dduncan or if you have to pick a fractional quantum, then something closer to what the computer actually works in makes more sense, like a power of 2
01:53 sorear what the computer actually actually works in is 1/1193182 second quantums
01:53 sorear do you really want that?
01:53 sorear (for PCs)
01:53 sorear I'm happy to have a nice round number portable quantum
01:54 sorear even if it means some rounding error
01:56 dduncan I'd rather just have an arbitrary Num or Rat
01:56 dduncan let the system give the fractions in whatever resolution it has
01:56 Kodi joined #perl6
01:56 dduncan I suspect it isn't the same on every computer ... or at least clock-driven CPU/etc speeds differ
01:56 dduncan just truncate it to the resolution you want to use
01:57 sorear the master timebase is only 1,1193182 Hz on PC compatibles
01:57 dduncan will it be forever?
01:57 sorear yes, since it's part of the hardware interface
01:57 dduncan but Perl might run on other things in the future
01:58 dduncan the point is, hard-coding nanoseconds is a bad idea
01:58 sorear hard coding microseconds is not our choice to make
01:58 dduncan CPUs already execute several instructions in a nanosecond, and would get faster, so I'd think the clock resolution is better than nanoseconds
01:59 sorear not nanoseconds
01:59 sorear microseconds
01:59 dduncan me brb
01:59 dduncan er /me brb
01:59 Kodi One issue with making 'time' return an integer is that 'now', given that it uses atomic seconds, is (I imagine) difficult to implement, whereas 'time' is in most cases just a system call. So letting 'time' return non-integers should generally give greater access fractional seconds.
01:59 plobsing joined #perl6
01:59 Kodi *"access *to* fractional seconds".
02:00 sorear http://www.opengroup.org/onlinepubs/009695399/functions/gettimeofday.html
02:00 sorear also, while the CPU clock may be at >4GHz, CPU clocks are extremely unstable and useless for timekeeping
02:00 sorear this is actually on purpose
02:02 sorear the 1.193182 MHz comes from a crystal oscillator and has quite good stability, around 1 ppm
02:06 tylercurtis sorear: so, e.g., a computer with a PPC or ARM processor might have a different clock resolution?
02:06 sorear tylercurtis: even an intel mac could have a different one
02:06 sorear the clock rate I just gave is set for historical reasons
02:07 sorear it was decided because that's what kind of crystal IBM could get cheaply in 1983
02:08 sorear NTSC color decoding crystals (12 * 1.193182) are still pretty abundant, so it's not implausible a different computer maker would choose the same frequency
02:08 sorear though I suspect I'm arguing past dduncan
02:09 sorear my point is that using microsecond interfaces is annoying and I'd like to get Nums back instead
02:10 tylercurtis It sounded as though dduncan was arguing that hardcoding a specific precision is a bad idea.
02:13 sorear we have to hardcode a specific precision in the implementation
02:13 Kodi left #perl6
02:13 sorear we don't have to expose it to user code, and I'd rather we didn't
02:13 sorear traditionally (Sys6 era) the Mac timebase was 60Hz
02:13 sorear I suspect they've added a higher res timer since then
02:19 tylercurtis Right. Don't specify a specific precision in the spec.
02:21 xinming joined #perl6
02:25 lue hi o/
02:26 sorear stefan@stefans:~/niecza$ ./niecza -e 'say(2 > 3); say(3 > 2);'
02:26 sorear Bool::False
02:26 sorear Bool::True
02:26 sorear \o/
02:26 lue \o/
02:27 agentzh joined #perl6
02:31 dalek niecza: ce81a8f | sorear++ | CodeGen.pm:
02:31 dalek niecza: Fix control operators with net stack effects
02:31 dalek niecza: review: http://github.com/sorear/niecza/commit/ce81a8fcdf37103c1f80fde27b2f2d638f61bd94
02:35 eternaleye joined #perl6
02:36 sorear std: anon $x;
02:36 p6eval std 31660: OUTPUT«ok 00:01 111m␤»
02:36 sorear rakudo: anon $x;
02:36 p6eval rakudo 94d01f:  ( no output )
02:36 sorear rakudo: anon $x; say $x;
02:36 p6eval rakudo 94d01f: OUTPUT«Any()␤»
02:36 TimToady er
02:36 TimToady std: anon $x; say $x
02:36 p6eval std 31660: OUTPUT«[31m===[0mSORRY![31m===[0m␤Variable $x is not predeclared at /tmp/C_DnpkKq0P line 1:␤------> [32manon $x; say $x[33m⏏[31m<EOL>[0m␤Check failed␤FAILED 00:01 109m␤»
02:37 TimToady I suspect it's just aliased to 'my'
02:37 TimToady (in rakudo)
02:38 TimToady mildew: anon $x; say $x
02:38 p6eval mildew: OUTPUT«[31m===[0mSORRY![31m===[0m␤Variable $x is not predeclared at c96b5a83a04304000173dd458e5f392a line 1:␤------> [32manon $x; say $x[33m⏏[31m<EOL>[0m␤Check failed␤»
02:38 TimToady mildew++ ;)
02:43 xinming joined #perl6
02:44 lue what exactly is the purpose of anon?
02:45 tylercurtis std: class Rabbit {...}; my $hat = anon Rabbit sub {...};
02:45 p6eval std 31660: OUTPUT«ok 00:01 111m␤»
02:46 tylercurtis Also, lue: "The anon declarator allows a declaration to provide a name that can be used in error messages, but that doesn't put into any symbol table:"
02:47 lue I read S02's explanation, but I don't see how that's useful [ or even used :) ]
02:47 tylercurtis rakudo: anon sub marine () { say "If this shows up, it's a bug."; }; marine();
02:47 p6eval rakudo 94d01f: OUTPUT«If this shows up, it's a bug.␤»
02:48 tylercurtis rakudo: my $secret = anon sub marine () {...}; $secret(42);
02:48 p6eval rakudo 94d01f:  ( no output )
02:48 xinming_ joined #perl6
02:49 tylercurtis That should theoretically fail/die with something like "Too many arguments to sub marine."
02:49 dduncan sorear, tylercurtis, I was arguing that arguing a specific precision (other than to whole seconds) is a bad idea
02:50 dduncan I prefer Nums
02:50 dduncan or Rats
02:51 ajs left #perl6
02:53 * dduncan getting off ... IRC is often too distracting to productivity
02:53 dduncan left #perl6
02:53 xinming joined #perl6
02:54 lue hm. could where_blockify in Actions.pm (line 3125) be what causes 'where' to work in parameters?
02:54 lue rakudo: sub xy($a where 0..10) { say $a }; xy(5); xy(34); xy(2);
02:54 p6eval rakudo 94d01f: OUTPUT«5␤»
02:55 lue .oO(Not having an error print is confusing)
02:55 tylercurtis Locally:
02:55 tylercurtis 5
02:55 tylercurtis Constraint type check failed for parameter '$a'
02:56 lue > sub xy($a where 0..10) { say $a }; xy(5); xy(34); xy(2);
02:56 lue Too many positional parameters passed; got 2 but expected 1
02:56 lue my tinkering broke it! :)
02:59 sorear std: my $x; say $$x
02:59 p6eval std 31660: OUTPUT«ok 00:01 109m␤»
02:59 sorear Umm
02:59 sorear What does that mean and why is it legal
02:59 sorear STD.pm6 claims to be doing "hard reference" syntax
02:59 sorear I thought explicit refs were dead?
03:01 lue rakudo: my $x; say $$x # I thought I could make it worth more :)
03:01 p6eval rakudo 94d01f: OUTPUT«===SORRY!===␤Confused at line 20, near "say $$x # "␤»
03:01 lue rakudo: my $x; say $$x; # I thought I could make it worth more :)
03:01 p6eval rakudo 94d01f: OUTPUT«===SORRY!===␤Confused at line 20, near "say $$x; #"␤»
03:04 tylercurtis sorear: $$foo is $($foo)
03:04 sorear What is $()
03:05 tylercurtis The scalar contextualizer function. Apparently essentially equal to "item".
03:05 sorear My understanding is that .item is always called when something is bound to a $scalar
03:06 sorear so $$foo should always be $foo
03:06 tylercurtis There's an example in S03 of calling $$capture to get the invocant of a capture for interpolation purposes.
03:07 tylercurtis Or at least, that's what it looks like.
03:08 lue rakudo: my $a = 3; say $$a
03:09 p6eval rakudo 94d01f: OUTPUT«===SORRY!===␤Confused at line 20, near "say $$a"␤»
03:11 tylercurtis Describing interpolating a functions return value into a the arguments to push: it says that "push |func();" is equivalent to "my $capture = \(func()); push $$capture: @$capture, %$capture;"
03:12 tylercurtis Well, actually, it says, it is equivalent to that "or some such".
03:13 takadonet joined #perl6
03:13 hercynium joined #perl6
03:18 xinming joined #perl6
03:22 Teedev_ joined #perl6
03:25 PenThrive joined #perl6
03:41 aindilis joined #perl6
04:01 cono joined #perl6
04:07 diakopter mildew: say &say
04:07 sorear perl6: sub bar() { say "Hello"; rand }; class Foo { say (has $.x = bar) }
04:07 p6eval mildew: OUTPUT«unknown method "Str" at message line 134 file build/s1p/src/code.c␤»
04:07 p6eval pugs: OUTPUT«Hello␤0.9335998365268111␤»
04:07 p6eval ..rakudo 94d01f: OUTPUT«␤»
04:08 sorear obviously pugs is doing something wrong
04:08 sorear I'm wondering what the correct behavior here is
04:08 sorear Hello is not supposed to be printed; stuff assigned to has variables is only run at BUILD time
04:08 sorear but that leaves wide open the question of what has returns
04:10 PZt joined #perl6
04:26 meppl joined #perl6
04:40 ashleydev joined #perl6
04:53 sorear stefan@stefans:~/niecza$ ./niecza -e 'my $x; $x = 42; say($x)'
04:53 sorear 42
04:56 dalek niecza: e7d59a1 | sorear++ |  (3 files):
04:56 dalek niecza: Allow intermingling Perl6 terms in NIL
04:56 dalek niecza: review: http://github.com/sorear/niecza/commit/e7d59a15c6aaa7f05fb17a90eb890434573989c4
04:56 dalek niecza: 8517d2f | sorear++ | Niecza/Actions.pm:
04:56 dalek niecza: Implement variable reference syntax
04:56 dalek niecza: review: http://github.com/sorear/niecza/commit/8517d2f9feed6472882b95fdaa3052150deb649e
04:56 dalek niecza: 2fbc8c5 | sorear++ |  (2 files):
04:56 dalek niecza: Implement variable declarations
04:56 dalek niecza: review: http://github.com/sorear/niecza/commit/2fbc8c54e04ffa65b7b478e880dfa2fa8b7f9d7b
04:56 dalek niecza: e22978c | sorear++ |  (3 files):
04:56 dalek niecza: Implement assignment (rw checking woefully inadequate atm)
04:56 dalek niecza: review: http://github.com/sorear/niecza/commit/e22978c44e01319b8c90d3d6fc82a7165cb56f78
04:58 tylercurtis joined #perl6
05:25 sorear std: sub foo($x) { my $x; }
05:25 p6eval std 31660: OUTPUT«Potential difficulties:␤  Useless redeclaration of variable $x (see line 1) at /tmp/ctqhNvD1Ou line 1:␤------> [32msub foo($x) { my $x[33m⏏[31m; }[0m␤ok 00:01 114m␤»
05:29 pragma_ joined #perl6
05:42 PZt joined #perl6
05:48 moritz_ std: use v6\ ;
05:48 p6eval std 31660: OUTPUT«ok 00:01 110m␤»
05:58 uniejo joined #perl6
06:00 ashleydev joined #perl6
06:04 cjk101010 joined #perl6
06:19 sorear std: sub foo() { :($x); }
06:19 p6eval std 31660: OUTPUT«ok 00:01 113m␤»
06:19 sorear std: sub foo() { :($x) := 2; }
06:19 p6eval std 31660: OUTPUT«ok 00:01 112m␤»
06:19 sorear How does that work?
06:19 sorear rakudo: sub foo() { :($x) := 2; }
06:19 p6eval rakudo 94d01f:  ( no output )
06:20 sorear rakudo: sub foo() { :($x) := 2; }; foo(); say("Alive")
06:20 p6eval rakudo 94d01f: OUTPUT«Alive␤»
06:20 sorear What is the 2 being bound to?
06:20 moritz_ std: :(x)
06:20 p6eval std 31660: OUTPUT«[31m===[0mSORRY![31m===[0m␤In parameter declaration, typename 'x' must be predeclared (or marked as declarative with :: prefix) at /tmp/nLEp_gaLUN line 1:␤------> [32m:(x[33m⏏[31m)[0m␤Parse failed␤FAILED 00:01 109m␤»
06:20 moritz_ std: :($x)
06:20 p6eval std 31660: OUTPUT«ok 00:01 109m␤»
06:22 mberends joined #perl6
06:23 cxreg rakudo: my $a := 1; $a++
06:23 p6eval rakudo 94d01f:  ( no output )
06:24 moritz_ dies
06:24 moritz_ but p6eval is not good with error reporting :(
06:26 sorear moritz_: do you have a clue what's wrong?
06:26 moritz_ sorear: I only know that it started when I put in the safe mode code
06:26 sorear p6eval level or rakudo level?
06:26 moritz_ p6eval level
06:28 baest joined #perl6
06:28 sorear hrm.  token parameter  is a bit on the long side
06:41 HarryS joined #perl6
06:42 masak joined #perl6
06:43 masak morning, #perl6!
06:43 masak up early. what a concept. :)
06:44 lue ohai masak o/
06:44 lue It's almost midnight here :)
06:44 sorear hello masak!
06:45 sorear I've added variables, assignment, booleans, and comparison operators to niecza.
06:45 masak sorear: nice!
06:46 sorear right now I'm working on signatures - soon you'll be able to write subs in pure Perl 6
06:46 sorear rather than sub square { Q:NIL { =[0] } * Q:NIL { =[0] } }
06:46 masak sounds promising.
06:46 masak what's NIL?
06:47 sorear niecza intermediate language
06:47 sorear it's a bizarre hybrid between Perl 6, C#, and Forth
06:47 araujo other language?
06:48 sorear =[0] pushes the 0th positional argument onto the stack
06:48 masak heh :)
06:49 sorear the CLR uses stack-based bytecode; I wrote a code generator to abstract a few presentation details
06:49 sorear $cg->pos(0);  etc
06:50 sorear when I needed to start writing glue code, it occurred to me that I could just invent a concrete syntax for codegen calls
06:50 sorear which makes for a somewhat bizarre language, but it works
06:53 masak yay! TimToady changed so that True stringifies to "Bool::True" \o/
06:53 masak TimToady++
06:53 sorear already implemented in niecza
06:53 sorear :)
06:54 masak heh :)
06:55 sorear the change occured while I was asking about how to implement niecza's Bool.Str
06:55 sorear it's quite possible these are related
06:57 sdo joined #perl6
06:58 masak how would this be done in Perl 6? http://blogs.perl.org/users/alberto_simoes/2010/07/combinatory-substitution.html
07:01 sorear ("$_[0]aa$_[1]"  for ($word =~ m:ex/(.*) oo (.*)/))) is the best I can come up with
07:04 moritz_ m:g would probably do
07:04 sorear skimming S05 again, the correct syntax appears to be "$_[0]aa$_[1]" for ($word ~~ m:ex/(.*) oo (.*)/; @())
07:05 lue rakudo: my $word = 'noogoo'; say ($word ~~ m/oo/g)
07:05 p6eval rakudo 94d01f: OUTPUT«===SORRY!===␤Unsupported use of /g; in Perl 6 please use :g at line 20, near ")"␤»
07:05 lue rakudo: my $word = 'noogoo'; say ($word ~~ m:g/oo/)
07:05 p6eval rakudo 94d01f: OUTPUT«===SORRY!===␤Unable to parse postcircumfix:sym<( )>, couldn't find final ')' at line 20␤»
07:05 sorear m:ov would do; m:ex != m:ov only when oo is a regex which can match multiple lengths
07:06 diakopter niecza: my $x; $x = 42; say($x)
07:06 sorear if the word is "vrooom", :g -> vraaom, :ov/:ex -> vraaom, vroaam
07:07 cxreg does niecza work on mono?
07:07 lue I was thinking of getting a list of all places (StrPos' if they weren't NYI) where 'oo' is found, .pick one from the list, and substitute.
07:07 sorear cxreg: yes
07:07 cxreg ah, looks like it does indeed
07:07 sorear lue: .pick doesn't make an exhaustive list
07:08 masak "Sadly the feedback from the Perl 6 decision makers on IRC after presenting my first draft was not very positive, i almost gave up right there." -- http://blog.kraih.com/a-logo-for-perl -- I wonder how _sri got that impression.
07:08 masak I hope it wasn't something I said. :)
07:10 masak of the butterflies on that page, I like the last pair the best.
07:10 moritz_ masak: from our discussions in #perlde I gathered that _sri want soembody to give him directions what to do in order to make the official logo
07:10 sorear I think that /is/ the official logo
07:11 moritz_ it wasn't that our feedback was negative, but that it wasn't what he expected
07:11 sorear the TPF onion is the same onion whether it's a .jpg file or a sheet of paper
07:11 sorear camelia is the same, but the requirements for being a camelia are slightly looser
07:11 _sri masak: what moritz said
07:12 sorear like Perl 6 itself, the logo is given by spec, not product ;)
07:12 moritz_ _sri: I just wished you would formulate it as such on your blog. The current formulation seems a bit unfair
07:12 masak _sri: I agree with moritz_.
07:12 masak _sri: as far as I know, no-one here ever discouraged you.
07:13 lue I never got a chance to look at those logos, and I have to say I like them.
07:13 _sri masak: the general apathy was very discouraging, so it was mroe what was not said
07:14 masak _sri: I think you expect too much of a bunch of loosely organized volunteers.
07:14 _sri i do realize that i had the wrong expectations
07:14 masak to reiterate, there was no discouragement involved, yet your post makes it seem like there was.
07:15 sorear _sri: I don't understand how you see "apathy" here
07:15 HarryS joined #perl6
07:16 _sri sorear: there is no interest in any kind of marketing here, which i have accepted now
07:17 sorear marketing a product with perl 6's level of maturity is very bad form
07:17 sorear we call the practice 'vaporware' here
07:17 masak we do? :)
07:18 masak I thought the concept "vaporware" wasn't applicable on a product developed in the open.
07:18 _sri the real problem i see is that there is nobody responsible for marketing, be it perl 5 or 6
07:18 sorear the logo is good and will be used
07:18 masak _sri: you'd probably like to talk to Ovid about that.
07:18 _sri tpf marketing is just an urban myth and does not exist
07:19 masak _sri: he has a marketing role in TPF.
07:19 sorear ooh, Ovid doesn't exist?
07:19 * sorear gets popcorn.
07:19 _sri i've just gone rogue now
07:20 * _sri is a perl marketing guerilla
07:20 _sri viva la revolucion!
07:20 * lue .oO(PREVIOUSLY, on _The Perl Foundation_ ...)
07:20 masak _sri: I like you. :)
07:20 * _sri hugs masak
07:20 masak just please try not to call us apathetic and discouraging. :) we're really not.
07:21 _sri thats the vibe i got
07:21 masak well, try to pick up the right vibe next time. :)
07:21 * lue packs up all the bad vibes and sends them to Microsoft
07:22 _sri it's not cool to hate on microsoft anymore
07:22 lue s/Microsoft/Microsoft®/
07:22 _sri these days it's apple
07:22 * cxreg hates both just to be sure
07:23 * lue notices that the CEO's of both Microsoft® and Apple®™ have the first name of 'Steve'
07:25 _sri that poor ballmer dude has not made a single good decision in like a decade
07:25 sorear I don't hate on anybody.
07:26 sorear I'm a very happy person nowadays.
07:26 masak same here.
07:27 lue .oO(All this talk of marketing and such has given me the urge to patent something ridiculous, like patents, or the color white)
07:28 skids joined #perl6
07:28 sorear I think both of those are already patented.
07:28 sorear I know UPS has been granted a trademark on the color brown.
07:29 lue I know there's a patent for the hyperlink :)
07:31 * diakopter
07:31 * sorear
07:31 * masak
07:33 masak the people over at http://news.ycombinator.com/item?id=1508071 think that the difference between 'while EXPR' and 'repeat while EXPR' is a bit subtle. I agree, but I also expect of any non-crappy programmer to notice such a difference.
07:33 masak especially since the difference is situated right at the left end of the line, where all the important information is supposed to be located.
07:35 sorear it's no more subtle than the difference between $x + $y and $x - $y
07:35 masak ooh. I'll write that :) sorear++
07:35 lue rakudo: my $a; say $a.WHO ~~ $a.WHAT # just wondering
07:36 p6eval rakudo 94d01f: OUTPUT«0␤»
07:36 apribadi joined #perl6
07:38 masak time to hop on a train, travel to a small township, and be a teacher for a week. o/
07:38 lue hm, I need to recharge myself. Goodnight o/
07:47 tadzik joined #perl6
07:49 drbean_ joined #perl6
07:50 rv2733 joined #perl6
07:51 sorear stefan@stefans:~/niecza$ ./niecza -e 'sub square($x) { $x * $x }; say(square(5))'
07:51 sorear 25
07:51 dalek niecza: 60c9436 | sorear++ |  (2 files):
07:51 dalek niecza: Add signature parsing
07:51 dalek niecza: review: http://github.com/sorear/niecza/commit/60c9436df5b564e69b3a6ee8827eda68ab675f04
07:51 dalek niecza: 31c63f2 | sorear++ |  (4 files):
07:51 dalek niecza: Implement signature binder for subs
07:51 dalek niecza: review: http://github.com/sorear/niecza/commit/31c63f2f022a6046c85684d238f805e3bac78824
08:08 kloeri joined #perl6
08:10 arnsholt joined #perl6
08:21 dalek niecza: eba37ef | sorear++ | setting:
08:21 dalek niecza: Use named variables in setting after Any available
08:21 dalek niecza: review: http://github.com/sorear/niecza/commit/eba37ef4f72fe475f55fd59b22a0f1f4bb9ca826
08:28 dakkar joined #perl6
08:30 cono joined #perl6
08:33 thebird joined #perl6
08:39 moritz_ I have a patch for Bool, but it works only half-ways:
08:39 moritz_ ./perl6 -e 'say ~True; say True.Str'
08:39 moritz_ 1
08:39 moritz_ Bool::True
08:39 arnsholt joined #perl6
08:39 moritz_ which is kinda... surprising :-)
08:40 mathw yes
08:40 mathw but Bool is weird
08:40 mathw in the current impl.
08:41 moritz_ aye
08:41 moritz_ kinda-like-an-enum-but-not-quite
08:45 sorear phenny: tell TimToady I found a buglet in STD.pm6; after sub infix:<=>($x,$y) { ... }; $x = $x + 1 is parsed as ($x = $x) + 1
08:45 phenny sorear: I'll pass that on when TimToady is around.
08:45 sorear phenny: i.o.w., within the setting standard operator precence is ignored, the sub{} makes STD forget its default precedence rules
08:46 sorear phenny: tell TimToady i.o.w., within the setting standard operator precence is ignored, the sub{} makes STD forget its default precedence rules
08:46 phenny sorear: I'll pass that on when TimToady is around.
08:46 dalek niecza: b1b78bb | sorear++ | Niecza/Actions.pm:
08:46 dalek niecza: Implement postfix operators
08:46 dalek niecza: review: http://github.com/sorear/niecza/commit/b1b78bbbfd1a9b7caeafc63f42c9f53c7aec6e6d
08:46 dalek niecza: d9f32f0 | sorear++ | Niecza/Actions.pm:
08:46 dalek niecza: Implement prefix operators
08:46 dalek niecza: review: http://github.com/sorear/niecza/commit/d9f32f060d90e8bc466dd9a220f65e42845872c6
08:46 dalek niecza: e7d7f2c | sorear++ | Niecza/Actions.pm:
08:46 dalek niecza: Implement (expr)
08:46 dalek niecza: review: http://github.com/sorear/niecza/commit/e7d7f2cc28af4b79210edd9715689a408dca0977
08:46 dalek niecza: cd88b18 | sorear++ | setting:
08:46 dalek niecza: Implement ++ and --
08:46 dalek niecza: review: http://github.com/sorear/niecza/commit/cd88b188d11741788cc1151560e222d4a21110d4
08:49 sorear ok, I just need control operators and binding and I will have caught up to yapsi
08:49 moritz_ yapsi: my $x := 1; say $x
08:49 p6eval yapsi: OUTPUT«Couldn't handle instruction `bind '$x', <constant>`␤»
08:50 moritz_ yapsi: my $x = 1; my $y := $x; say $y
08:50 p6eval yapsi: OUTPUT«1␤»
08:53 muixirt joined #perl6
09:01 clintongormley joined #perl6
09:05 moritz_ phenny: tell masak reminder: today is #phasers, if you don't make it, you can pre-post a report :-)
09:05 phenny moritz_: I'll pass that on when masak is around.
09:09 jackyboy joined #perl6
09:15 cono joined #perl6
09:28 Ross joined #perl6
09:29 cono joined #perl6
09:31 timbunce joined #perl6
09:34 mantovani joined #perl6
09:36 pmurias joined #perl6
09:42 moritz_ rakudo: say ?(all("a" => 1, "b" => 2) ~~ Pair)
09:42 p6eval rakudo 94d01f: OUTPUT«0␤»
09:42 moritz_ it always surprises me that type checks don't autothread
09:43 kfo_ joined #perl6
09:43 bbkr good localtime()
09:44 Mowah joined #perl6
09:49 arnsholt Is there some kind of approval of modules for Rakudo *, or should I just put my module on the list? =)
09:50 moritz_ arnsholt: if you think it could be useful for people, add it to the list
09:50 bbkr what is the name of the library that iss required to enable icu?
09:51 arnsholt On Debian-likes you need icu and icu-dev (IIRC)
09:51 arnsholt Lemme check
09:51 arnsholt libicu-dev
09:52 bbkr ok, thanks. exactly: libicu-dev
09:52 arnsholt There. Added Algorithm::Viterbi to the Rakudo * list
09:52 moritz_ btw that's also mentioned in the README
09:52 moritz_ aptitude install build-essential libicu-dev subversion
09:54 tadzik joined #perl6
10:00 * sorear starts on a C replacement for App::Persistant with a few extra frills for p6eval mildew and niecza
10:02 dju joined #perl6
10:06 moritz_ rakudo: multi a([]?) { say "there" }; a()
10:07 p6eval rakudo 94d01f: OUTPUT«there␤»
10:07 Guest88700 joined #perl6
10:13 Mowah joined #perl6
10:14 pmurias sorear: you want to reimplement the client in C?
10:15 pmurias sorear: or the server part?
10:15 sorear pmurias: with a little bit of redesigning
10:15 moritz_ mildew: say 1 + 2
10:15 p6eval mildew: OUTPUT«Could not find variable &infix:+ in the lexical scope.␤»
10:25 sorear moritz_: would it be useful for me to experiment with setting up niecza on a feather?
10:28 pmurias sorear: why not make it compatible with the orginal?
10:29 pmurias sorear: does App::Persistent have any obvious flaws?
10:31 sorear other than the complete lack of security, no
10:32 sorear but I have a bad feeling about the protocol
10:32 pmurias what's wrong with the protocol?
10:33 pmurias sorear: setting the file permissions on the socket should provide enough security?
10:33 sorear no
10:34 sorear unix-domain sockets ignore all filesystem access bits
10:34 pmurias wrap it in a directory?
10:34 sorear as for the protocol... it's too tightly coupled to the design of the client, imo
10:35 pmurias two different clients exists for App::Persistent
10:36 pmurias that reminds me that i should fix the way the one i wrote finds the socket
10:39 pmurias sorear: how is your protocol different?
10:39 sorear In the Linux implementation, sockets which are visible in the file sys‐
10:39 sorear tem  honor  the permissions of the directory they are in.  Their owner,
10:39 sorear group and their permissions can be changed.  Creation of a  new  socket
10:39 sorear will  fail if the process does not have write and search (execute) per‐
10:39 sorear mission on the directory the socket is created in.  Connecting  to  the
10:39 sorear socket  object  requires  read/write permission.  This behavior differs
10:39 sorear from many BSD-derived systems which ignore permissions for  Unix  sock‐
10:39 sorear ets.  Portable programs should not rely on this feature for security.
10:39 sorear irssi-- failing to autowrap if and only if I expect it to
10:40 pmurias sorear: where's the quote from?
10:40 sorear unix(7)
10:41 pmurias did any one verify that?
10:42 sorear oh, the most important reason not to like the protocol: it's undocumented
10:42 pmurias you could fix that easily
10:42 sorear no
10:42 sorear you could
10:42 sorear but I don't understand every single quirk of the protocol yet
10:42 baest FreeBSD seem only to require write permission for the socket(file)
10:43 sorear because the protocol definiton is split between a multi-module program
10:43 pmurias sorear: you have seen bin/pclient.pl?
10:44 sorear I assume it's a buggy WIP
10:44 sorear it's far too short to be complete
10:48 sorear also, I was trying to generalize
10:48 sorear provide a low level discovery + autostart + authentication + communication system
10:48 sorear and a forking + stdio thing on top of that
10:49 sorear so I could reuse the lower level for other kinds of persistant programs besides short-lived ones
10:49 Mowah joined #perl6
11:00 pmurias sorear: re bin/pclient.pl i think the only omission is that it doesn't send and EndOfFile message and the significant bug is that it has a hard-wired socket path
11:00 dual joined #perl6
11:00 pmurias sorear: and how do you plan to achive security in you plan?
11:02 Ross joined #perl6
11:06 sorear create a mode 0600 file with 64 bytes from /dev/urandom
11:06 sorear server generates it and stores the token
11:06 sorear clients must correctly send the token
11:06 sorear (this procedure stolen directly from X11)
11:07 pmurias X11 had a few security holes with it's authentication mechanisms
11:08 sorear yes
11:09 sorear so, they got rid of their old auth mechanism and replaced it with the one I just described
11:09 sorear the old mechanism was based on a hosts access list
11:09 sorear among other things, because localhost was always trusted, local users could exploit it
11:11 frettled sorear: ¿ http://jani.at.ifi.uio.no/other/X-minimal-security.txt ?
11:13 sorear frettled: yes
11:14 sorear I'm cloning xauth, basically
11:14 sorear except it can be much simpler because ssh has been invented
11:14 frettled I should have updated that document years ago, when OpenSSH arrived with its fancy-schmancy -X option, and then later with its -Y option.  :)
11:14 sorear so I don't need to support having >1 tokens
11:14 frettled mm
11:16 frettled sorear: BTW, irssi's autowrap failed because what you pasted was from a multi-line source.  Normally, irssi ought to warn you about pasting that long stuff and ask that you press ctrl+k to continue, or abort.
11:18 sorear frettled: it does, but the warnings are wildly inaccurate when autowrap is being used, so I ignore the line counts
11:18 sorear usually I paste 8 lines and irssi sends 2 lines to the server
11:24 frettled sorear: I haven't managed to confuse irssi yet, but then again, for long pastes, I usually use nopaste-websites.  And it's been a while since I used 0.8.12.
11:24 frettled But back to something more on-topic:
11:25 frettled why do you need to store the result from urandom in a file?
11:25 moritz_ #perl6 - the place where even off-topic discussions are interesting :-)
11:26 moritz_ sorear: sorry, was gone for lunch... p6eval doesn't run on feather, so it doesn't matter to me where you experiment
11:26 moritz_ sorear: as long as the result is a set of instructions that I can follow :-)
11:26 sorear frettled: so the client can find it.  c.f. .Xauthority
11:27 moritz_ why does it feel you're re-inventing a wheel? :-)
11:27 Lorn joined #perl6
11:30 frettled There's something buzzing in my head that says there should be some sort of cryptography involved here.  Hmm.  :)
11:31 Ross joined #perl6
11:31 dalek niecza: e821de7 | sorear++ | Niecza/Actions.pm:
11:31 dalek niecza: Implement bare blocks
11:31 dalek niecza: review: http://github.com/sorear/niecza/commit/e821de7274462c4948e5d88eb195ebdcc8a4e7a9
11:31 dalek niecza: 7241a06 | sorear++ |  (2 files):
11:31 dalek niecza: Implement if-statements
11:31 dalek niecza: review: http://github.com/sorear/niecza/commit/7241a06f60ea647924f0ad4db349eda22329bdf7
11:31 dalek niecza: 7a830e4 | sorear++ |  (2 files):
11:31 dalek niecza: Implement while and until loops
11:31 dalek niecza: review: http://github.com/sorear/niecza/commit/7a830e444e66378246bb6cdd80e160b678588f79
11:31 dalek niecza: 91580e7 | sorear++ | setting:
11:31 dalek niecza: Use a p6 conditional in Bool.Str
11:31 dalek niecza: review: http://github.com/sorear/niecza/commit/91580e73f9ad3a87bea5070a28ce51fcda200f49
11:33 moritz_ btw Bool.Str and Bool.perl return the same result
11:39 frettled rakudo: my Bool $a = False; $a.perl.say; $a.Str.say;
11:40 p6eval rakudo 94d01f: OUTPUT«Bool::False␤Bool()<0x601c200>␤»
11:40 frettled moritz_: Did you mean something else?
11:40 dalek rakudo: ae4538a | moritz++ | src/core/Bool.pm:
11:40 dalek rakudo: Bool.Str
11:40 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/ae4538a4f92c455f9758732736e5f28ad0a806e6
11:41 moritz_ frettled: now they do. And that's what the spec says
11:41 frettled moritz_: aha
11:41 * frettled does a git pull locally.
11:42 moritz_ I had that patch locally for some hours, but forgot to push
11:42 moritz_ frettled++
11:42 frettled Nono, moritz++, your fix
11:43 moritz_ we can both have karma :-)
11:44 frettled without unnecessary memes, too! :D
11:45 moritz_ LOL?
11:45 jnthn plz can haz more memes? kthnxbai
11:45 moritz_ ./pls install memez
11:45 frettled /o\
11:46 moritz_ I'm now spectesting a patch which removes the match-bool.pm cheat
11:46 frettled Apparently, my old Parrot was so old that I had to remove the entire Parrot tree.
11:46 frettled Now where can the bird sit while I download?
11:46 moritz_ that's what it got wings for.
11:47 frettled The risk is that Parrot goes awk.
11:47 moritz_ hey, has anybody implemented awk for parrot?
11:48 Mowah joined #perl6
11:52 * muixirt writes 'awk' on moritz' todo list
11:52 pugssvn r31661 | moritz++ | [t/spec] fudge bool.t for rakudo, add tests for .Str
11:52 * moritz_ re-schedules it for after perl 6.2.0
12:04 dju joined #perl6
12:05 Trashlord joined #perl6
12:05 envi^home joined #perl6
12:11 Intensity joined #perl6
12:13 tadzik rakudo: my @a = <foo bar asd>; @a.kv.kv
12:14 p6eval rakudo 94d01f:  ( no output )
12:14 tadzik rakudo: my @a = <foo bar asd>; @a.kv.kv.say
12:14 p6eval rakudo 94d01f:  ( no output )
12:14 tadzik hrm
12:14 tadzik ===SORRY!=== Cannot resume dead coroutine. here
12:14 tadzik why so?
12:14 moritz_ rakudo bug
12:15 tadzik to file?
12:15 moritz_ if you execute the same gather/take twice (before the first one is exhausted), you get that error
12:15 moritz_ doesn't hurt to file it
12:16 tadzik there is gather/take here?
12:16 moritz_ seems like, yes
12:17 arnsholt Implemented as gather { $i = 0; take $_, $i++ for @arr } I guess
12:18 hatsefla1s joined #perl6
12:20 tadzik « and » operators are hell mysterious to me. Gosh, I thought Perl 5 was complex and complicated
12:22 arnsholt tadzik: They're sugar over loops, sort of
12:22 jnthn tadzik: They just mean "take this other operator and do it to everything in the list". They're meta-operators really. If you think of operators as functions, then meta-operators are just higher-order functions.
12:22 tadzik like [op]?
12:23 moritz_ except when used as quoting construct
12:23 jnthn Then they ain't being operators. :P
12:23 moritz_ tadzik: [op] is also a meta operator, yes
12:23 moritz_ also acting on lists
12:24 tadzik ah, but unlike [op] they take 2 lists as an arg?
12:24 skids joined #perl6
12:25 moritz_ >>+<< takes a list on either side
12:25 moritz_ >>+>> takes a list on one side, and a scalar on the other
12:27 Mowah joined #perl6
12:27 tadzik rakudo: (1, 2, 3, 4).list »+» 1
12:27 p6eval rakudo 94d01f:  ( no output )
12:28 tadzik rakudo: my @a = 1, 2, 3, 4; @a >>+>> 2; @a.perl.say
12:28 p6eval rakudo 94d01f: OUTPUT«[1, 2, 3, 4]␤»
12:28 moritz_ it doesn't modify in-place
12:28 tadzik oh, does not work locally
12:28 tadzik yeah, I see now
12:29 moritz_ rakudo: my @a = (1, 2, 3, 4) >>+>> 2; @a.perl.say
12:29 p6eval rakudo 94d01f: OUTPUT«[3, 4, 5, 6]␤»
12:29 tadzik I get "Could not find sub &infix:<>>+>>>" in REPL
12:29 tadzik latest monthly release
12:29 tadzik I guess I have to switch to git
12:29 moritz_ good choice :-)
12:30 tadzik more fun is fun :)
12:30 tadzik bah, I'll have to get parrot from svn
12:30 tadzik btw, moritz_, how is try.rakudo.org going?
12:31 frettled Hrm, I can't get the Unicode versions to work locally, weirdness.
12:31 moritz_ tadzik: ash_ and cygx have done impressive work; now somebody just needs to glue it together
12:36 [Coke] tadzik: there is a git mirror of parrot. but then you can't use rakudo's gen-parrot. pick your poison.
12:37 moritz_ rakudo: say <vermin poison toxin>.pick
12:37 p6eval rakudo 94d01f: OUTPUT«poison␤»
12:37 dju joined #perl6
12:38 ruoso joined #perl6
12:39 timbunce joined #perl6
12:41 dju_ joined #perl6
12:43 pmurias ruoso: hi
12:44 pmurias ruoso: if the mildew test suit (the p6 tests) takes a long time will we run it on installation?
12:46 moritz_ you can have a default 'test' and an additional 'fulltest' or 'stresstest' target
12:48 ruoso pmurias, I agree with moritz_... it's important to have a minimal set of sanity checking tests
12:49 SmokeMachine joined #perl6
12:52 arnsholt Rakudo recently moved to something like that, no?
12:53 moritz_ well, we've had 'make test' for ages
12:53 moritz_ but it's new that 'make spectest' doesn't run all the tests known to pass ('make stresstest' does that now)
12:53 pmurias ruoso: in which dist will we keep the tests?
12:54 moritz_ don't you have one dist which depends on all others?
12:54 pmurias Mildew-Setting-SMOP
12:54 moritz_ ie the one that can actually run the compiler?
12:54 moritz_ then keep the tests there
12:56 [particle] joined #perl6
12:56 SmokeMachine joined #perl6
12:56 Kodi joined #perl6
12:58 ruoso pmurias, yeah... keep the tests on the dist that provides what's needed for it... the p6 tests are probably going to Mildew-Setting-SMOP, yes
12:58 Kodi Any idea when http://rt.perl.org/rt3//Public/Bug/Display.html?id=76376 will be merged into master so I can submit my own Temporal patch?
12:59 moritz_ rakudo has a 'make release' that copies the tests into the tarball
13:00 moritz_ Kodi: I'll try to remember reviewing/applying it tonigh
13:00 Kodi moritz_: Cool.
13:05 Kodi left #perl6
13:07 [Coke] rakudo: <cheap fast right>.pick(2)>>.say
13:07 p6eval rakudo ae4538: OUTPUT«cheap␤fast␤»
13:08 hejki rakudo: <wait work home>.pick(1).say
13:08 p6eval rakudo ae4538: OUTPUT«wait␤»
13:11 PerlJam it would be interesting if you could supply pick() with a distribution function or a set of weights so that it could pick items in a non-evenly distributed fashion.
13:11 moritz_ isn't that specced already?
13:11 moritz_ I have something in the back of my mind, with hashes where the values denote the weight
13:12 PerlJam Dunno.  Just thought of it and didn't remember seeing it before.
13:12 moritz_ btw RT#76376 looks fine, I just can't apply it from $work
13:15 jnthn I seem to recall .pick on hashes did something like that too
13:16 moritz_ rakudo: my @a = 0, 0; for ^10 { @a[{0 => 1, a => 5}.pick]++ }; say @a.perl
13:16 PerlJam ah, yes S32-setting-library/Containers.pod:936
13:16 p6eval rakudo ae4538:  ( no output )
13:17 moritz_ PerlJam: you're my hero :-)
13:18 moritz_ PerlJam: guess what the next weekly challenge will be? :-)
13:18 PerlJam heh :-)
13:18 PerlJam moritz_++
13:18 plainhao joined #perl6
13:23 pugssvn r31662 | pmurias++ | [mildew] port over signatures
13:23 pugssvn r31663 | pmurias++ | [mildew-setting-smop] port over Exception
13:23 pugssvn r31664 | pmurias++ | [mildew-setting-smop] copy over the tests from mildew-old
13:23 pugssvn r31665 | pmurias++ | [mildew-setting-smop] ported over Failure and Multi
13:23 pugssvn r31666 | pmurias++ | [mildew-setting-smop] p5 and p6 tests are distinguished
13:37 pugssvn r31667 | pmurias++ | [mildew-setting-smop] hack so that True and False work correctly
13:41 am0c joined #perl6
13:48 FardadJalili joined #perl6
13:51 moritz_ http://github.com/moritz/perlgeek.de/blob/master/source/blog-source-en/perl-6/contribute-now-hash-pick.txt any feedback before I blog it?
13:52 * frettled has a look-see.
13:52 PerlJam line 28: s/implement/implemented/
13:53 * moritz_ fixes
13:53 PerlJam moritz_: looks good
13:54 frettled Yup.
13:58 moritz_ http://perlgeek.de/blog-en/perl-6/contribute-now-hash-pick.html lolihazblogged
13:59 frettled shock horror
13:59 moritz_ :-)
13:59 frettled I guess I forgot to mention that the upgraded local Rakudo performed as expected, regarding Bool.Str and Bool.perl.
14:00 moritz_ great
14:00 moritz_ but not regarding ~Bool :(
14:01 tylerni7 joined #perl6
14:01 tylerni7 joined #perl6
14:01 ruoso does anyone have a working link for the proposed amelia logo? the blog have its image references broken (at least behind proxies)
14:03 moritz_ ruoso: http://files.posterous.com/kraih/UeHAH1Jdbt99j9Wff8QY6sDCo6ormGQ0RFz2ld4A41NDjmrYGJS6DZxzFZ8o/perl6-amelia-sri.png?AWSAccessKeyId=1C9REJR1EMRZ83Q7QRG2&amp;Expires=1279030094&amp;Signature=zDnHGH2ytJr79YGNrkE%2BmJbJ2rM%3D for example... does that link for you?
14:04 _sri oh noes, link the good ones
14:05 _sri that one is an example for a failed attempt :S
14:05 moritz_ _sri: then provide a link to a good one :-)
14:05 _sri http://kraih.com/perl-clean-sri.png
14:06 FardadJalili moritz_: line 14: s/has method/has a method/
14:06 * PerlJam wonders if you could make a stylized butterfly out of the letters in Perl
14:07 moritz_ FardadJalili: thanks, fixing...
14:07 gbacon joined #perl6
14:07 pmurias sorear: re App::Persistent security i creates the sockect in a 700 dir
14:07 pmurias * socket
14:13 plobsing joined #perl6
14:17 ruoso the logo is cute... it's actually a dragonfly....
14:21 dalek book: eb4182a | util++ | Makefile:
14:21 dalek book: Changed `perl` into macro to allow command-line override to non-system perl
14:21 dalek book: review: http://github.com/perl6/book/commit/eb4182acb6e2f972a291935624270cc85d5871f1
14:21 tylercurtis joined #perl6
14:38 SmokeMachine joined #perl6
14:51 dalek book: ce34472 | util++ | Makefile:
14:51 dalek book: Normalize list of chapter files
14:51 dalek book: review: http://github.com/perl6/book/commit/ce344724c591b64a4aaedeb693ad6b44e53701b8
14:53 SmokeMachine joined #perl6
14:58 FardadJalili joined #perl6
15:10 dalek book: d24ec3e | util++ | README:
15:10 dalek book: Add to README info on TeX for other platforms
15:10 dalek book: review: http://github.com/perl6/book/commit/d24ec3e5f8b576af03aed011ff27291c4936be55
15:10 dalek book: 9c8a264 | util++ | README:
15:10 dalek book: Change Pod::PseudoPod::LaTeX version number in README to match what is actually
15:10 dalek book: required by bin/book-to-latex
15:10 dalek book: review: http://github.com/perl6/book/commit/9c8a2648f74e1a7a9c5506acae250c582160d586
15:10 IllvilJa joined #perl6
15:11 dolmen__ joined #perl6
15:12 dolmen__ Looks like the community has a good logo designer: http://blog.kraih.com/a-logo-for-perl
15:17 frettled dolmen__: oh, those are really nice!
15:22 Mowah joined #perl6
15:26 patspam joined #perl6
15:27 jnthn http://files.posterous.com/kraih/UeHAH1Jdbt99j9Wff8QY6sDCo6ormGQ0RFz2ld4A41NDjmrYGJS6DZxzFZ8o/perl6-amelia-sri.png?AWSAccessKeyId=1C9REJR1EMRZ83Q7QRG2&amp;Expires=1279035135&amp;Signature=ZryOSMha11JuFbg3CsNFx5cFdtg%3D # nice
15:28 _sri i consider that one the worst :)
15:33 macdaddy joined #perl6
15:36 * tylercurtis doesn't understand why some people seem to absolutely hate Camelia.
15:39 dolmen__ Perl 6 is not being designed by a 4 years old child, while Camelia looks like it is...
15:40 diakopter well
15:40 dalek book: 85e9e39 | util++ | README:
15:40 dalek book: Add more IRC contact info to README
15:40 dalek book: review: http://github.com/perl6/book/commit/85e9e395c6042e68477bd4a3f7050f3c248c07c7
15:40 dalek book: 7c9eae8 | util++ | README:
15:40 dalek book: Add Inkscape link to README
15:40 dalek book: review: http://github.com/perl6/book/commit/7c9eae8e82ab76b8ca42c32e4448620a64179e3d
15:44 rgrau` joined #perl6
15:47 justatheory joined #perl6
15:53 diakopter this one fixes my complaints: http://posterous.com/getfile/files.posterous.com/kraih/UeHAH1Jdbt99j9Wff8QY6sDCo6ormGQ0RFz2ld4A41NDjmrYGJS6DZxzFZ8o/perl6-amelia-sri.png
15:54 diakopter (too much blocky contrast, too much saturation)
16:02 pugssvn r31668 | pmurias++ | [mildew] no adhoc_signatures;
16:02 pugssvn r31669 | pmurias++ | [mildew] port over the integer multis
16:03 pmurias ruoso: regression from mildew are down from 5 to 4 failing tests (plus the 3 tests for the disabled p5 interop)
16:07 pmurias ruoso: what i'm considering is taking some time to determin why compiling the CORE is taking so long and restoring App::Persistent support
16:08 SmokeMachine joined #perl6
16:13 eternaleye joined #perl6
16:24 [Coke] I am sure there are better ways to stump for a new logo than calling larry a four year old. I'm not sure what they are, but there you go. =-)
16:25 hercynium joined #perl6
16:34 tadzik rakudo: (3/8).nude # what method is this?
16:34 p6eval rakudo ae4538:  ( no output )
16:38 ashleydev joined #perl6
16:38 jnthn tadzik: Returns the numerator and the denominator of the Rat
16:39 jnthn rakudo: (3/8).nude.perl.say
16:39 p6eval rakudo ae4538: OUTPUT«(3, 8)␤»
16:39 tadzik yep, read the source code
16:39 jnthn Nice name... :-)
16:39 tadzik It reminded me of some cpan module, "See your data in nude", and I wondered if anything else has this :)
16:43 zostay joined #perl6
16:52 ruoso pmurias, I'd suggest hunting down the regressions first so we can have a publish-grade package
16:56 pmichaud good morning, #perl6
16:56 jnthn morning, pmichaud
16:56 cdarroch joined #perl6
16:56 cdarroch joined #perl6
16:56 moritz_ hi pmichaud
16:56 moritz_ I hope you're enjoying your vacations
16:57 pmichaud very much so
16:57 pmichaud beautiful weather and scenery here
16:59 pugssvn r31670 | moritz++ | [t/spec] s/skip/todo/ a few tests
17:00 moritz_ std: class A { }; A.new(:x<a>, :Parent{:y<b> })
17:00 p6eval std 31669: OUTPUT«ok 00:01 114m␤»
17:00 moritz_ std: class A { }; A.new(:x<a>, Parent{:y<b> })
17:00 p6eval std 31669: OUTPUT«[31m===[0mSORRY![31m===[0m␤Undeclared name:␤ 'Parent' used at line 1␤Check failed␤FAILED 00:01 112m␤»
17:00 moritz_ std: class A { }; class Parent; A.new(:x<a>, Parent{:y<b> })
17:00 p6eval std 31669: OUTPUT«[31m===[0mSORRY![31m===[0m␤Too late for semicolon form of class definition at /tmp/O0yAiPC3Kb line 1:␤------> [32mclass A { }; class Parent[33m⏏[31m; A.new(:x<a>, Parent{:y<b> })[0m␤    expecting any of:␤   name␤   trait␤Parse failed␤FAILED 00:01 107m␤»
17:01 moritz_ std: class A { }; class Parent { }; A.new(:x<a>, Parent{:y<b> })
17:01 p6eval std 31669: OUTPUT«ok 00:01 112m␤»
17:01 moritz_ I know what it does, but what kind of construct is this syntactically?
17:02 moritz_ rakudo: say ~Str.^parents(:tree)
17:02 p6eval rakudo ae4538: OUTPUT«Cool() Any() Mu()␤»
17:02 moritz_ rakudo: say Str.^parents(:tree).perl
17:02 p6eval rakudo ae4538: OUTPUT«([Cool, [Any, [Mu]]], )␤»
17:07 SmokeMachine joined #perl6
17:12 bbkr awesome syntax! easiest metaobject access ever :)
17:13 constant joined #perl6
17:13 cognominal joined #perl6
17:14 bbkr rakudo: class A is Mu {}; say A.^parents(tree => True).perl
17:14 constant_ joined #perl6
17:14 p6eval rakudo ae4538: OUTPUT«([Mu], )␤»
17:27 Phar joined #perl6
17:33 Phar joined #perl6
17:34 tedv joined #perl6
17:34 SmokeMachine joined #perl6
17:36 Phar left #perl6
17:37 Phar joined #perl6
17:37 pugssvn r31671 | pmurias++ | [mildew] [smop] fix bug with wrong handling of unicode literals
17:37 pmichaud jnthn: ping
17:37 pmurias ruoso: fixed 1 regression, 3 to go
17:38 takadonet joined #perl6
17:39 Ross joined #perl6
17:39 mberends_ joined #perl6
17:40 lue goodtime #perl6 o/
17:41 jnthn pmichaud: pong
17:42 pmichaud jnthn: I'm a bit concerned about the fix for TT #1631
17:42 jnthn Adding the pop_eh?
17:42 pmichaud right.
17:42 jnthn I don't think a CATCH should catch stuff thrown within it.
17:42 pmichaud doing the pop_eh removes the handler.
17:42 ingy greetings
17:43 jnthn Right, that's what I intended.
17:43 ingy jnthn: I agree
17:43 pmichaud perhaps not, but triggering a CATCH shouldn't disable it for all subsequent exceptions, either.
17:43 jnthn huh?
17:43 jnthn It doesn't push_eh it next time around in the block?
17:43 pmichaud die "1";  die "2";  CATCH { resume }
17:43 jnthn Oh. :S
17:44 jnthn OTOH, I'd take getting basic exceptions and throws from within the block over resumable exceptions, if it's the choice between them.
17:44 jnthn (until we work out a way to do both)
17:44 pmichaud we have to be able to handle both, though.
17:44 pmichaud maybe just update the ticket to point out that it's not resolved?
17:45 jnthn Can do
17:45 pmichaud the lack of a pop_eh was intentional.
17:45 jnthn We have spectests running for the fixed case now, so a fix to re-instnate the resumability will get caught by that if it breaks things again.
17:46 pmichaud we need a way to throw exceptions such that they skip the current handler.
17:47 pmichaud (or the current handler otherwise ignores them)
17:48 jnthn ticket updated with this discussion
17:48 pmichaud thanks.
17:49 jnthn It seems that CATCH in general needs work though
17:49 pmichaud well, exceptions in Parrot still need work
17:49 jnthn Since at the moment we always mark an exception handled.
17:49 jnthn There is that :-)
17:52 ingy rakudo: class C { has $.h; has $!h }; say C.new.^attributes
17:52 p6eval rakudo ae4538: OUTPUT«===SORRY!===␤Can not re-declare attribute $!h at line 20, near " }; say C."␤»
17:53 ingy I think I'll make YAML dump object attributes without the $x
17:54 pmichaud I never could get Allison (or Whiteknight) to recognize that there are three paths out of an exception handler.
17:54 pmichaud And as such, Parrot's exception handling model is broken for Perl 6 purpose.
17:54 pmichaud *purposes.
17:54 ingy pmichaud: did you see http://gist.github.com/473265 ?
17:54 pmichaud although it may be better now with NotFound++'s resume patch.
17:55 pmichaud haven't looked recently.
17:55 pmichaud ingy: \o/
17:55 justatheory joined #perl6
17:56 ingy how do I prep modules for rakudo *?
17:56 pmichaud probably just make them available to proto and/or pls
17:57 Tene pmichaud: you could also have Perl6 exception handlers introspect the exception and determine whether it was thrown from within the EH, and rethrow it if so.
17:57 pyrimidine joined #perl6
17:57 pmichaud Tene: is there an easy way for "determine whether it was thrown from within the EH?", ooc?
17:57 * ingy update proto
17:58 Tene pmichaud: get the continuation and walk its contexts, oslt.
17:58 patspam joined #perl6
17:58 Tene My initial prototype of that worked in what seemed the obvious way at the time.
17:58 Tene I don't remmebr the details of what that was, though.
17:58 Tene afk; meeting
17:59 pmichaud yeah, seems like a method on the Exception object to ask its source would work.
18:00 cj joined #perl6
18:00 pmichaud At any rate, even with the additional text for TT #1631 I'm uncomfortable with where we sit now, because we're (1) changing a documented behavior without a deprecation cycle, and we're introducing a "fix" that we know we'll have to switch back (again without a deprecation cycle).
18:01 Ross joined #perl6
18:01 lue is TT different from the RT ?
18:01 pmichaud TT is Parrot's ticket system
18:01 pmichaud trac.parrot.org
18:03 lue ah, ok.
18:03 mberends_ cxreg: ping
18:04 hercynium joined #perl6
18:06 SmokeMachine joined #perl6
18:06 pmichaud moving discussion to #parrot; bottom line is that I'm thinking of reverting r48074.  It's wrong to have it there on several layers.
18:09 lue rakudo: subset Byte where 0..0xFF; my Byte $a; $a = 300; say "$a made it!"
18:09 p6eval rakudo ae4538:  ( no output )
18:09 lue rakudo: subset Byte of Int where 0..0xFF; my Byte $a; $a = 300; say "$a made it!"
18:10 p6eval rakudo ae4538:  ( no output )
18:10 tylercurtis akudo: subset Byte where 0..0xFF; my Byte $a; $a = 255; say "$a made it!"
18:10 tylercurtis rakudo: subset Byte of Int where 0..0xFF; my Byte $a; $a = 255; say "$a made it!"
18:10 p6eval rakudo ae4538: OUTPUT«255 made it!␤»
18:11 dakkar joined #perl6
18:11 tylercurtis rakudo: subset Byte where 0..0xFF; my Byte $a; $a = 255; say "$a made it!"
18:11 p6eval rakudo ae4538: OUTPUT«255 made it!␤»
18:11 tylercurtis rakudo: subset Byte where 0..0xFF; my Byte $a; $a = 253.4; say "$a made it!"
18:11 p6eval rakudo ae4538: OUTPUT«253.4 made it!␤»
18:11 Phar left #perl6
18:11 SmokeMachine joined #perl6
18:11 tylercurtis rakudo: subset Byte of Int where 0..0xFF; my Byte $a; $a = 253.4; say "$a made it!"
18:12 p6eval rakudo ae4538:  ( no output )
18:12 tylercurtis lue: I'd recommend subsetting Int.
18:13 lue Alright.
18:13 cxreg mberends_: hi there
18:14 cxreg mberends_: i was just working on my t/ stuff this morning, was on vacation last week
18:14 Mowah joined #perl6
18:15 Tene pmichaud: another option *should* be to subclass ExceptionHandler.
18:15 tylercurtis Otherwise, Nums and Rats within the 0..255 range would be considered Bytes, which I don't think you want.
18:15 mberends_ cxreg: :-) cool! If you would like to, it would be nice if you were the one to merge the MiniDBD::Pg stuff. It looks nicer in the logs )
18:15 cxreg yeah, will do
18:15 cxreg thanks for the ping
18:15 mberends_ :)
18:15 PerlJam Hmm.
18:16 Tene I don't remember if that worked in my exceptions branch.
18:16 Tene I should work on that again someday.
18:16 * moritz_ must resist to solve his own challenge
18:16 Tene I'm still so burned out... :(
18:16 PerlJam tylercurtis' mistype earlier "akudo" is interesting.  If I am correct, it means "way of evil"  Kind of an odd one character difference from rakudo
18:17 moritz_ a fittin one, if you ask me :-)
18:17 tylercurtis PerlJam: I'm sure there are lots of places where a one character difference in Rakudo could be plenty evil.
18:19 lue Rakudadō -> Rakudo -> Akudo # what will be next...
18:20 sbp kudos, hopefully
18:20 moritz_ sbp++
18:22 jnthn pmichaud: Being able to re-throw from an exception handler is kinda useful.
18:22 cosimo joined #perl6
18:22 jnthn pmichaud: I'm all for putting a proper fix in.
18:23 jnthn pmichaud: I just don't see how it'd look, and if we're going to have it broken one way or the other, I'd prefer this way.
18:23 alester joined #perl6
18:24 kensanata joined #perl6
18:25 pmichaud jnthn: I'm not sure I like violating Parrot's deprecation policy (twice) for the sake of Rakudo.  I think it sets very bad precedent.
18:26 SmokeMachine joined #perl6
18:26 jnthn pmichaud: I considered the patch a bug fix when I put it in.
18:27 jnthn pmichaud: I see now it's not
18:27 jnthn Go ahead and revert it
18:27 jnthn I'll stay away from hacking on exceptiony stuff.
18:28 pmurias what would a CONTROL {$_.handled = 1} block do?
18:29 pmurias ruoso: i'm not sure v6/Mildew-Setting-SMOP/t/p6/basic/control_exception.t is correct
18:32 moritz_ rakudo: say <a b c>.kv.kv.perl
18:33 p6eval rakudo ae4538:  ( no output )
18:33 moritz_ locally gives "Cannot resume dead coroutine."
18:33 moritz_ don't know if that's related to jnthn's patch
18:33 jnthn No
18:34 jnthn Highly unlikely anyway
18:34 jnthn Coroutines aren't exception based.
18:36 tylercurtis Someone mentioned a gather/take bug with the same result yesterday or a few days ago. Can't remember exactly what it was. Possibly related?
18:37 jnthn Certainly related.
18:37 jnthn gather/take is the only place that Rakudo uses co-routines, afaik.
18:38 colomon and .kv probably uses gather / take
18:38 jnthn I believe it does
18:38 tylercurtis rakudo: (1..10).grep({ $_ % 2  == 0 }) Z (1..10).grep({ $_ % 2 != 0 })
18:38 p6eval rakudo ae4538:  ( no output )
18:40 tylercurtis rakudo: say (1..10).grep({ $_ % 2  == 0 }) Z (1..10).grep({ $_ % 2 != 0 })
18:40 colomon rakudo: (1..10).grep({ $_ % 2  == 0 }).perl.eval Z (1..10).grep({ $_ % 2 != 0 }).perl.eval
18:40 p6eval rakudo ae4538: OUTPUT«1133557799␤»
18:40 p6eval rakudo ae4538:  ( no output )
18:40 tylercurtis Nevermind. That's the bug I was thinking of.
18:41 ruoso pmurias, /me looking
18:42 Ross joined #perl6
18:43 tylercurtis rakudo: say gather { gather { take $_ ** 2 for 1..10; }; take for 1..10 };
18:43 p6eval rakudo ae4538: OUTPUT«␤»
18:43 ruoso pmurias, the only thing that looks possibly wrong to me is the exception class name
18:44 ruoso rakudo: sub foo { { return "a"; CONTROL { say $_; $_.handled = 1 } }; say "hi" }; foo()
18:44 p6eval rakudo ae4538: OUTPUT«␤»
18:46 ruoso rakudo: sub foo { { return "a"; CONTROL { say "hi" $_; $_.handled = 1 } }; say "hi" }; foo()
18:46 p6eval rakudo ae4538: OUTPUT«===SORRY!===␤Unable to parse blockoid, couldn't find final '}' at line 20␤»
18:46 ruoso oops
18:46 tylercurtis rakudo: .print for gather { take for 1..10 } Z gather { take $_ ** 2 for 1..10; }
18:46 p6eval rakudo ae4538:  ( no output )
18:46 ruoso rakudo: sub foo { { return "a"; CONTROL { say "hi" ~ $_; $_.handled = 1 } }; say "hi" }; foo()
18:46 p6eval rakudo ae4538: OUTPUT«hi␤»
18:46 tylercurtis rakudo: .print for gather { take $_ for 1..10 } Z gather { take $_ ** 2 for 1..10; }
18:46 p6eval rakudo ae4538: OUTPUT«11243941652563674986498110100»
18:47 ruoso rakudo: sub foo { { return "a"; CONTROL { say "inside" ~ $_; $_.handled = 1 } }; say "outside" }; foo()
18:47 p6eval rakudo ae4538: OUTPUT«inside␤»
18:47 ruoso rakudo: sub foo { { return "a"; CONTROL { say "inside" ~ $_.WHICH; $_.handled = 1 } }; say "outside" }; foo()
18:47 tylercurtis rakudo: .print for (1..10).map({$_}) Z (1..10).map(* ** 2)
18:48 p6eval rakudo ae4538: OUTPUT«inside118357872␤»
18:48 p6eval rakudo ae4538: OUTPUT«11243941652563674986498110100»
18:48 sorear good * #perl6
18:48 ruoso rakudo: sub foo { { return "a"; CONTROL { say "inside" ~ $_.WHAT; $_.handled = 1 } }; say "outside" }; foo()
18:48 p6eval rakudo ae4538: OUTPUT«insideException()␤»
18:49 tylercurtis rakudo: .print for (1..10).grep({$_ % 2}) Z (1..10).grep({$_ ** 2 % 2})
18:49 p6eval rakudo ae4538: OUTPUT«1133557799»
18:49 ruoso I think that's a bug... it should've printed "outside" as well, shouldn't it?
18:49 Tene ruoso: that's right.
18:50 * ruoso submits rakudobug
18:51 ruoso pmurias, so the only thing that might be wrong there is the class name...
18:51 ruoso but I think that name (ControlExceptionReturn) was kinda informally approved by TimToady
18:51 pmurias i'm not that sure .handled will stop the rethrow
18:51 colomon tylercurtis: I think this is a quicker way of demonstrating it:
18:51 ruoso pmurias, TimToady's yesterday commit makes it clear
18:52 pmurias according to the spec there is a implicit die $! at the end of the CONTROL block
18:52 colomon rakudo: say (2, 4 ... 10) Z (1, 3 ... 10)
18:52 p6eval rakudo ae4538: OUTPUT«1133557799␤»
18:52 * pmurias looks at that
18:52 ruoso r31645
18:53 supernovus joined #perl6
18:56 pmurias what's an unsucceful block exit?
18:56 mberends_ #phasers in 4 mins?
18:57 pmurias ruoso: so according to r31645 our test is incorrect
18:57 colomon mberends++
18:58 pmurias ruoso: leave(Failure) is an unsuccesful block exit
18:58 pmurias so UNDO is ran
18:58 rlb3 joined #perl6
18:58 pmurias and UNDO rethrows our exception despite the fact that it was handled
18:59 jnthn mberends_: ooh, well remembered!
19:01 pmurias is my reasoning correct
19:02 pugssvn r31672 | colomon++ | [t/spec] Add a few more tests for hypers and ", *".
19:05 cono joined #perl6
19:06 pmurias TimToady: why is a new perl started for parsing a module?
19:08 sorear pmurias: because STD isn't reentrant
19:09 cxreg "cannot resume dead parrot"
19:10 pmurias sorear: what blocks reentrancy?
19:11 pmurias the globals are local'ised?
19:11 sorear about fifty globals are used without being properly localized
19:12 [Coke] pmichaud: Jealous!\
19:16 pmurias sorear: anything besides that, that could be easily solved with about fifty locals
19:16 pmichaud [Coke]: :-)
19:17 sorear pmurias: $STD::ALL scares me and I don't have a clue if compiling modules reentrantly would break it
19:17 allbery_b joined #perl6
19:18 pmurias sorear: as long as they have different names it shouldn't
19:19 pmurias calling eval from eval would break it
19:20 pmurias walk&
19:21 cdarroch joined #perl6
19:21 cdarroch joined #perl6
19:25 allbery_b joined #perl6
19:26 pmichaud rakudo:   say (1..*).list.infinite
19:26 p6eval rakudo ae4538: OUTPUT«Method 'infinite' not found for invocant of class 'List'␤  in main program body at line 20:/tmp/BVvWQEyac7␤»
19:30 Mowah joined #perl6
19:34 pmichaud hugme tweet rakudoperl  Rakudo now supports simple forms of := and ::= binding (lue++)
19:34 * hugme hugs pmichaud; tweet delivered
19:37 dalek niecza: 91d8b99 | sorear++ |  (3 files):
19:37 dalek niecza: Implement postfix method calls
19:37 dalek niecza: review: http://github.com/sorear/niecza/commit/91d8b996190f3b83eb7e5f53341633a00a7d8a2d
19:37 dalek niecza: d5a737e | sorear++ | setting:
19:37 dalek niecza: Implement Boolean context; Num is true if nonzero
19:37 dalek niecza: review: http://github.com/sorear/niecza/commit/d5a737e3dd0784adcb12fcbe309c186bf69c39d7
19:37 dalek niecza: acbdf8b | sorear++ | Op.pm:
19:37 dalek niecza: Control structures put the argument in boolean context
19:37 dalek niecza: review: http://github.com/sorear/niecza/commit/acbdf8b9ebab6f44a68e5c098c8154eccfd73aed
19:49 dalek niecza: 02783f9 | sorear++ | setting:
19:49 dalek niecza: Fix obvious bug in postfoocrement
19:49 dalek niecza: review: http://github.com/sorear/niecza/commit/02783f9b0433d94788f6e60fa0458335a8491f9e
19:49 dalek niecza: 332b344 | sorear++ | setting:
19:49 dalek niecza: Implement ~ and ? prefix ops
19:49 dalek niecza: review: http://github.com/sorear/niecza/commit/332b344cdadd25d413ea2630be302c4feaee6826
19:49 dalek niecza: 8c7971e | sorear++ |  (3 files):
19:49 dalek niecza: Implement binding
19:49 dalek niecza: review: http://github.com/sorear/niecza/commit/8c7971e30080d399ad3411a37c17ca12fd3bc8ff
19:49 frettled nice!
19:49 cdarroch joined #perl6
19:49 cdarroch joined #perl6
19:53 SmokeMachine joined #perl6
20:05 sorear I believe niecza can now do everything yapsi can, code-wise
20:06 dalek rakudo: f0dbe32 | moritz++ |  (3 files):
20:06 dalek rakudo: get rid of match-bool cheat
20:06 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/f0dbe322c42b796711435d601f096db0de5ecf56
20:06 dalek rakudo: b196d2d | moritz++ | src/core/Mu.pm:
20:06 dalek rakudo: A Mu.perl which dumps attributes of custom classes
20:06 dalek rakudo: This also includes code for descending into parent classes, but it's disabled
20:06 dalek rakudo: because it doesn't quite work, and because Rakudo doesn't understand
20:06 dalek rakudo: initialization of parent attributes anway.
20:06 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/b196d2de1c80f0ef8065148cf7a0e0e4be8a2eae
20:06 dalek rakudo: 66ca1a7 | moritz++ | docs/ChangeLog:
20:06 dalek rakudo: add some ChangeLog entries
20:06 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/66ca1a7c8d5f82796171f0a7ebca27aaa133d652
20:06 * ingy should make C'Dent be Perl 6 based
20:06 ingy maybe
20:06 pmurias sorear: who's your next target? ;)
20:07 sorear viv
20:07 moritz_ (me hopes for "rakudo" :-)
20:07 ingy hi moritz_
20:07 moritz_ hi ingy
20:07 ingy moritz_: I fixed ufo,btw
20:07 moritz_ \o/
20:07 sorear multi sub foo(Array[Int] $x where { (all(@$_) > 0) && (.[0] <= 2 || .[1] ** .[0] + .[2] ** .[0] != .[3] ** .[0]) } { ... }
20:08 sorear multi sub foo(Array[Int] $x where { all(@$_) > 0 } { ... }
20:08 sorear # longname collision?
20:08 ingy is proto/projects.list YAML on purpose?
20:09 ingy I should start writing a simple loader for yaml-pm6
20:10 ingy w/ p6rules
20:11 moritz_ ingy: in the 'pls' branch in proto it's JSON
20:11 moritz_ easier to parse, and a module for it is already written
20:11 ingy moritz_: oh. what is the right one to use? pls or proto?
20:11 ingy ah
20:11 ingy branch
20:12 ingy sorry
20:12 perigrin w28
20:12 jnthn sorear: No
20:13 moritz_ ingy: if you're adventorous, test 'pls' and report any failings to masak++
20:13 ingy moritz_: if?!
20:14 ingy ;)
20:14 moritz_ I meant... more than usual :-)
20:14 pmichaud afk for a while  # beach time
20:22 pyrimidine left #perl6
20:23 dalek rakudo: 97c91c6 | moritz++ |  (2 files):
20:23 dalek rakudo: remove Safe.pm. It was not working anyway, and screwed up innocent programs
20:23 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/97c91c6e0b2e55b931f6797389c629711c844a8f
20:25 ingy moritz_: what is the purpose of pls?
20:26 moritz_ ingy: a proper module installer. proto was... well, a prototype, evolving far beyond the original goals. It showed.
20:26 ingy but why is pls a branch of proto?
20:26 moritz_ dunno, ask masak :-)
20:27 moritz_ maybe hysterical reasons
20:27 ingy you mean raisins?
20:27 moritz_ right. Hysterical, dried grapes
20:29 ingy moritz_: how do I git the branch
20:29 ingy I forget
20:29 ingy *forgit
20:30 moritz_ git checkout -b pls origin/pls
20:30 ingy \o/
20:30 SmokeMachine joined #perl6
20:33 IllvilJa joined #perl6
20:33 sorear jnthn: what about $x where { 1} and $x where { 1 }?
20:33 lue afk
20:34 * ingy added yaml-pm6 to pls
20:34 eternaleye joined #perl6
20:35 jnthn sorear: May be an ambiguous dispatch at runtime
20:36 jnthn sorear: We don't know just from the signature.
20:36 jnthn sorear: What Perl 6 means by "name" is pretty liberal :-)
20:37 jnthn sorear: Not to mention that multis with the same signature plus .* is a convenient way to write event handlers. :-)
20:37 sorear How about: Int $x and Int $x
20:37 sorear jnthn: yes, I invented that trick, then discovered it was banned by rakudo and the spec
20:37 jnthn Uh
20:37 jnthn I wrote code in Rakudo that uses that trick and it worked.
20:38 jnthn Rakudo certainly should allow it.
20:38 sorear rakudo: role A { method x(Int $a) { say "A" }; }; role B { method x(Int $a) { say "B" }; }; class C does A does B { }; C.new.x;
20:38 jnthn rakudo: class Foo { multi x() { say 1 }; multi x() { say 2 } }; Foo.new.*x
20:38 p6eval rakudo ae4538: OUTPUT«===SORRY!===␤Method 'x' collides and a resolution must be provided by the class␤»
20:38 p6eval rakudo ae4538:  ( no output )
20:38 sorear rakudo: role A { multi method x(Int $a) { say "A" }; }; role B { multi method x(Int $a) { say "B" }; }; class C does A does B { }; C.new.*x;
20:38 p6eval rakudo ae4538:  ( no output )
20:38 jnthn oh grr
20:39 jnthn rakudo: class Foo { multi method x() { say 1 }; multi method x() { say 2 } }; Foo.new.*x
20:39 p6eval rakudo ae4538: OUTPUT«1␤2␤»
20:39 jnthn sorear: checking that locally
20:40 jnthn > role A { multi method x(Int $a) { "A".say }; }; role B { multi method x(Int $a
20:40 jnthn ) { "B".say }; }; class C does A does B  { }; C.new.*x(1);
20:40 jnthn A
20:40 jnthn B
20:40 jnthn (note, say in role bug)
20:41 jnthn (and it needs a parameter, otherwise it finds no candidates)
20:41 sorear It definitely didn't work when I tried it three months ago.
20:41 sorear :)
20:41 sorear progress++
20:41 jnthn Oh, I can believe that. :-)
20:42 * jnthn afk for a bit
20:45 ashleydev joined #perl6
20:46 moritz_ has anybody tested blizkost recently?
20:55 supernovus joined #perl6
20:57 supernovus How long does it generally take for an e-mailed reply to RT to show up?
20:57 [particle] that depends on how much spam perl.org's mail servers are handling
20:57 dju joined #perl6
20:57 [particle] and whether or not you're whitelisted or moderated
20:58 supernovus Ah. Well, I probably should have used the web interface.
20:58 moritz_ supernovus: nevermind, I applied the patch myself now
20:58 supernovus moritz_: Oh... I went and rebased it :-)
20:59 dalek rakudo: 615dfc9 | (Timothy Totten)++ |  (6 files):
20:59 dalek rakudo: Temporal/Date modifications and refactoring.
20:59 dalek rakudo: Changed how DateTime::strftime works.
20:59 dalek rakudo: Added DateTime::strftime to Makefile.in
20:59 dalek rakudo: Changed time-zone to timezone as per spec.
20:59 dalek rakudo: Changed DateTime.parse() to DateTime.new() as per spec.
20:59 dalek rakudo: Temporal => DateTime, and simplified changes.
20:59 dalek rakudo: Signed-Off-By: Moritz Lenz <moritz@faui2k3.org>
20:59 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/615dfc9a188bba6d6002b885ebcce1dbf539723b
20:59 dalek rakudo: 6ab7415 | moritz++ | build/Makefile.in:
20:59 dalek rakudo: build everything before we start testing
20:59 dalek rakudo: Behaves a bit weird otherwise: 'make spectest' seems to build Rakudo, but then
20:59 dalek rakudo: a 'make' or 'make install' builds modules.
20:59 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/6ab7415762a5bc6269ddd8d4dae023e6f357a429
20:59 moritz_ supernovus: sorry for having caused additional work
21:00 supernovus How does git handle renames? If Kodi's work has been done on Temporal.pm but now the file is called DateTime.pm will git move his changes over to the new filename? I haven't done that in git yet, I know bzr works that way, so I'm assuming git will too.
21:00 moritz_ supernovus: git generally has no problem with merging such changes - only applying patches with such changes cause problems
21:01 moritz_ supernovus++
21:01 supernovus Ah, damn. I hope Kodi is able to merge his changes easily since my changes were applied as a patch.
21:01 moritz_ supernovus: you should add yourself to CREDITS in your next patch
21:02 moritz_ that's not a problem
21:02 moritz_ only if he tries to apply *his* changes as a patch he has a problem
21:02 moritz_ so he needs to merge or rebase before submitting it to rt
21:02 cognominal joined #perl6
21:02 timbunce joined #perl6
21:03 * moritz_ -> sleep
21:03 supernovus Have a good night moritz_
21:06 dju joined #perl6
21:08 xabbu42 joined #perl6
21:10 christine joined #perl6
21:10 whiteknight joined #perl6
21:12 tylercurtis jnthn: was the notice you and pmichaud were discussing earlier that NQP's/P6object's implementation will change and that the API might a deprecation notice in Parrot's 2.6 release?
21:13 SmokeMachine joined #perl6
21:28 masak joined #perl6
21:28 masak ahoy!
21:28 phenny masak: 09:05Z <moritz_> tell masak reminder: today is #phasers, if you don't make it, you can pre-post a report :-)
21:28 supernovus Loving the new REPL with lexical variables!
21:28 jnthn masak: ahoj!
21:29 masak moritz_: thanks for the reminder. unfortunately, the whole day has been too disconnected for me to heed your advice. :/
21:29 masak best I can do is post-post.
21:29 jnthn tylercurtis: Yes, since PCT is in Parrot repo
21:29 jnthn tylercurtis: fwiw, I don't expect it will that much hit people who are "just" using PCT.
21:29 masak also, I do write progress blog posts for my GSoC work, and I hope people turn to these when they want to know the latest progress.
21:29 jnthn If at all.
21:30 * masak backlogs #phasers
21:30 masak jnthn: getting pls to work on Windows sounds nice.
21:34 jnthn masak: pls can haz?
21:34 jnthn Oh wait, I volunteered...
21:35 tylercurtis jnthn: I brought it up at #ps, allison thinks that it could work without a deprecation notice in 2.6. "right, but if they miss the deprecation notice in 2.6, that just means we leave the existing P6object in place, and they develop the new one with a different name"
21:35 masak jnthn: we'll make it happen somehow.
21:35 tylercurtis jnthn: Would that work?
21:37 jnthn tylercurtis: The issue would more be that PCT currently uses P6object to provide its underlying object model, and would switch to using The New Thing.
21:38 jnthn tylercurtis: I will do what is reasonable to make that painless. At present, I expect the impact to be relatively low to most users, especially since most people write stuff in nqp-rx.
21:38 jnthn tylercurtis: It'll mostly hit people who use p6object explicitly in conjunction with their use of PCT.
21:41 jnthn tylercurtis: So the deprecatin notice I was thinking of was more along those lines - that PCT could be sat atop a new meta-model implementation with a slightly different API (but not entirely different).
21:41 jnthn tylercurtis: I'll do my best to judge the balance between progress and not causing pain, anyways. :-)
21:41 tylercurtis jnthn: I'll bring that concern up once the discussion about Lorito dies down. :)
21:43 masak ingy: re http://github.com/masak/ufo/commit/fed8133efebfe8cc4e9785b0839ed4565e91f3bf -- I'm not yet convinced $cwd/t should be added to PERL6LIB. do convince me, please.
21:45 sorear Hello masak!
21:45 masak hi, sorear!
21:46 sftp joined #perl6
21:46 jnthn tylercurtis: I can drop into #ps at some point if that'd be helpful. :-)
21:47 tylercurtis jnthn: now would be the time. We're close to wrapping up.
21:48 jnthn tylercurtis: I'm there now if folks have questions :-)
21:51 sorear masak: got a few more things working in niecza.  I think I'm up to yapsi 2010.07 level now
21:51 masak sorear: I've been keeping half an eye on you. I think you are, too.
21:51 masak scary :)
21:56 masak sorear: in my mind, we never reached a resolution in our discussion about 'state' variables. in short, you never explained how your implementation of them would be able to do this: http://rt.perl.org/rt3/Ticket/Display.html?id=62184
22:09 sorear easy; my implementation of Sub doesn't have a .clone method
22:10 masak wow, that *was* easy. I see no flaws with that at all. :P
22:10 sorear closure cloning is not the same as Mu.clone
22:10 sorear closure cloning requires a frame to clone into
22:10 sorear I have .closure-clone(callframe)
22:10 masak is there a difference between a frame and a lexpad?
22:11 sorear a frame has-a lexpad
22:11 masak I suspected as much.
22:11 sorear a lexpad just holds the variables
22:11 masak what more does a frame has-a? :)
22:12 sorear a frame has a lexpad, but it also has a raw argument capture, an .outer, a .caller, some runtime foo to support CATCH/CONTROL
22:12 sorear in rakudoland a true frame is a CallContext PMC
22:12 sorear (Callframe is a P6object wrapper)
22:13 masak hm, so the frame has the .outer, not the lexpad?
22:13 sorear yes
22:14 masak could the lexpad have it, and it'd still work?
22:15 sorear Maybe
22:15 jnthn fwiw, Rakudo (well, Parrot) has it as frame has-a lexpad and the outer pointer is between frames, fwiw.
22:15 jnthn oh, sorear++ just said so :-)
22:15 sorear Perl 6 gives a lot of leeway with how you actually implement this stuff
22:15 sorear since you have to use methods to access it
22:16 sorear You just have to be able to present the illusion of callframe.my working as specced
22:16 sorear i.e. just returning the variables from the pad
22:17 sorear I need to talk with TimToady about $CALLER:: and inlining, though
22:18 sorear (note that $CALLER::x = callframe.caller.my.<$x>, not callframe.my.<$CALLER::x>)
22:27 timbunce joined #perl6
22:29 masak sorear: fwiw, I plan to do subs as soon as I have the new runtime integrated. I want to add enough infrastructure so that fibonacci be possible.
22:42 sorear what kind of infrastructure are you talking about?
22:43 supernovus rakudo: use DateTime::strftime; say strftime('%A',DateTime.now)
22:43 p6eval rakudo 97c91c: OUTPUT«Tuesday␤»
22:44 sorear > my $a = 0; my $b = 1; my $c = 0; while $c < 1000 { say $a; my $d = $a; $a = $b; $b = $b + $d; $c++ }
22:44 gbacon joined #perl6
22:49 sorear removing the say and increasing to 100k fibs generated, niecza takes 27s
22:49 masak nice.
22:49 masak sorear: re needed infrastructure: first, making 'sub fib' register as a &fib, variable. then, I'd need enough of positional signatures to make 'sub fib($n)' work. then, I'd need return values.
22:50 masak oh, and minor things, like infix:<< < >> and infix:<+>.
22:51 sorear oh, going to do it loopily?
22:51 sorear or recursive
22:51 masak recursive.
22:52 masak ooh, loopily'd almost work already :)
22:53 skids joined #perl6
22:53 masak *lol* 'Room "Never let others name your rooms!"' -- http://conferences.yapceurope.org/ye2010/schedule
22:54 jnthn omg the shcedule
22:54 jnthn this is where I find I have a slot first thing in the morning
22:54 sorear sounds like something you would do masak
22:54 wallberg joined #perl6
22:55 jnthn ooh...the talks start at 10!!
22:55 jnthn Somebody was sensible.
22:55 masak :)
22:56 * masak has one on Wed and one on Fri
22:56 jnthn masak: whoa, we're scheduled against each other!
22:56 jnthn That's...curious.
22:56 masak jnthn: this had to happen sooner or later... :P
22:57 jnthn Aww. I'll have to see the Prince of Parsia another time. :-)
22:58 masak jnthn: no towel for you! :)
22:58 jnthn :'(
22:58 wallberg joined #perl6
22:59 masak perl6.org triggers as gambling? wtf? http://blogs.perl.org/users/chisel/2010/07/gambling.html
23:01 TimToady I think someone can't tell the difference between perl6 and pick6
23:01 phenny TimToady: 08:45Z <sorear> tell TimToady I found a buglet in STD.pm6; after sub infix:<=>($x,$y) { ... }; $x = $x + 1 is parsed as ($x = $x) + 1
23:01 phenny TimToady: 08:46Z <sorear> tell TimToady i.o.w., within the setting standard operator precence is ignored, the sub{} makes STD forget its default precedence rules
23:01 jnthn Damm, I knew we shouldn't have use the slogan "Roll up and take a chance on Perl 6!"
23:01 TimToady someone searched for perl6 and found pmichaud's card picker, I suppose :)
23:02 masak *lol*
23:04 tylercurtis masak: looking at the list of attendees for jnthn's talk, http://conferences.yapceurope.org/ye2010/talk/2729 , I think you're lying about not having found something that can bend time.
23:04 arnsholt masak: How usable is your Buf stuff for other people?
23:05 takadonet hey everyone
23:05 masak tylercurtis: overlap? oy vey.
23:05 masak arnsholt: please be more specific.
23:05 arnsholt I was thinking of writing a Base64 decoder
23:06 sorear takadonet: hello!
23:06 takadonet sorear: how are u sir?
23:06 arnsholt Which requires buffers rather than strings, at least in the general case
23:06 sorear takadonet: good
23:06 masak arnsholt: that should work.
23:06 sorear it's far too hot
23:06 masak arnsholt: let me know if it doesn't.
23:06 masak or if there's something in general that can be improved.
23:06 arnsholt Excellent. I'll keep you informed
23:07 masak awesome.
23:16 sorear std: 1,
23:16 p6eval std 31672: OUTPUT«ok 00:01 112m␤»
23:19 ive joined #perl6
23:23 sorear std: 1,,,3
23:23 p6eval std 31672: OUTPUT«[31m===[0mSORRY![31m===[0m␤Preceding context expects a term, but found infix , instead at /tmp/8f4RL4hy5M line 1:␤------> [32m1,[33m⏏[31m,,3[0m␤Parse failed␤FAILED 00:01 109m␤»
23:25 masak zzz &
23:34 silug joined #perl6
23:34 TimToady sorear: re precedence, we need to move all the <O()> terms up into the protos in CORE eventually, but
23:34 TimToady STD doesn't yet have a way of sending parsing rules onward from CORE.setting
23:36 TimToady eventually most of those operators in STD reduce to <sym> and drop out of the standard grammar entirely, existing only as declarations in CORE
23:37 TimToady yes, $CALLER::x is misleading; I almost always write it CALLER::<$x> these days anyway
23:39 TimToady and as with any dynamic var, you can't really know the type of it in advance
23:40 f00li5h joined #perl6
23:40 ingy greetings
23:40 sorear How do magic initializers parse?  state $x = 5  means state $x; START { $x = 5 }; but state $x + 5 means state $x; $x + 5
23:40 TimToady o/
23:40 sorear same for has initializers
23:40 sorear and I have no clue about :=, .=, etc
23:40 sorear hello ingy
23:42 TimToady yes, basically certain assignish ops (which the spec does not yet nail down) recognize that their left side is a declarator and rewrite the assignment to happen at a different phase
23:42 f00li5h joined #perl6
23:43 TimToady I think :=, ::=, and .= certainly want to be in that category, and maybe just all assignops to make it simple
23:43 takadonet joined #perl6
23:43 TimToady one can always write (state $x) += 32 to force it the other way
23:44 f00li5h joined #perl6
23:44 TimToady alternately .= is the only assignop that really makes sense there
23:45 TimToady can argue it both ways
23:45 TimToady (and := and ::=, of course)
23:45 TimToady I still fall into the old C-ish usage of "assignops" to mean things like +=
23:46 TimToady but I should say meta in there somewhere
23:46 sorear (state $x) is not a declarator?
23:46 TimToady sure it is, but not parenthesized
23:46 sorear ah
23:47 TimToady parens on lvalues have always been a bit mystical in Perl
23:47 sorear what about has... slots don't even exist at class body run time, so what does 'has $x' return as a term?
23:47 TimToady $x =   vs  ($x) =\
23:48 sorear or is it an error to use has in non-void non-assigny context?
23:48 TimToady probably just an error, or erroneous
23:48 TimToady or Nil, or sump'n
23:48 sorear what's the difference?
23:49 TimToady erroneous is an old Ada spec term meaning "it's wrong, but the compiler is not obligated to tell you"
23:49 TimToady seems detectable though
23:49 sorear ah
23:50 sorear as a C woopersnapper I call that "undefined behavior"
23:50 TimToady it's possible that pugs is doing an idea that we had once, where the "class" object remember default values in its slots
23:50 TimToady erroneous puts a bit more blame on the user :)
23:51 TimToady but these days it seems better if the undefined type object just blows up on attr access
23:52 TimToady esp since default values are not guaranteed to be meaningful till BUILD time
23:52 TimToady that is, can depend on info that is not available till then
23:52 ingy rakudo: say "aaa".match(/a/)
23:52 TimToady like, er, self :)
23:52 p6eval rakudo 6ab741: OUTPUT«a␤»
23:52 f00li5h joined #perl6
23:52 ingy rakudo: say "aaa".match(/<alpha>/)
23:52 p6eval rakudo 6ab741: OUTPUT«a␤»
23:53 ingy rakudo: say "öaa".match(/<alpha>/)
23:53 TimToady so yeah, pugs is basically wrong there, even if it was right once :)
23:53 p6eval rakudo 6ab741: OUTPUT«ö␤»
23:53 ingy rakudo: say "茶aa".match(/<alpha>/)
23:53 sorear TimToady: so within a class body, self is the type object?
23:53 p6eval rakudo 6ab741: OUTPUT«茶␤»
23:53 TimToady no, only within methods
23:54 TimToady rakudo: class A { self }
23:54 p6eval rakudo 6ab741: OUTPUT«===SORRY!===␤Symbol 'self' not predeclared in <anonymous> (/tmp/XZ3q6HMUzw:20)␤»
23:54 ingy is there a named subrule for [a-zA-Z] ?
23:54 sorear No
23:54 sorear Well, sorta
23:54 TimToady that would be, like, culturally imperialistic
23:54 sorear rakudo: say 'A' ~~ /<alpha>/
23:54 p6eval rakudo 6ab741: OUTPUT«A␤»
23:55 sorear rakudo: say '楽' ~~ /<alpha>/
23:55 p6eval rakudo 6ab741: OUTPUT«楽␤»
23:55 ingy ETOOUNICODEAWARE
23:55 ingy TimToady: it's culturally acmeistic :\
23:56 Psyche^ joined #perl6
23:56 TimToady so write <[a..z A..Z]> if you want to embrace the cause of englishonlyisticicism
23:57 ingy If I want to use the same grammar in over a dozen programming languages, I can't be all highfallutin'
23:57 ingy TimToady: yeah I already do that
23:57 jnthn Well, you can always re-define <alpha> in your grammar :-)
23:58 ingy jnthn: true. I was actually using the predefined ones hoping for a speed op
23:58 ingy is that the case?
23:58 jnthn Not sure, off hand.
23:58 TimToady that would be highly implementation specific
23:58 * jnthn is not a grammar engine guru
23:59 ingy TimToady: I'm talking to the rakudo guy, not the p6 guy :)
23:59 jnthn ingy: My suspicion is that <alpha> checks a unicode property
23:59 TimToady *sniff* *sniff*
23:59 ingy jnthn: you are wearing your rakudo hat, right?
23:59 jnthn ingy: huh, it's hot and humid in here and you expect me to where a hat?!
23:59 ingy TimToady: I'll get around to you :)
23:59 TimToady *snuffle*

| Channels | #perl6 index | Today | | Search | Google Search | Plain-Text | summary

Perl 6 | Reference Documentation | Rakudo