Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2010-11-27

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:07 Kovensky joined #perl6
00:14 buubot joined #perl6
00:19 Chillance left #perl6
00:21 Infinoid left #perl6
00:22 hercynium joined #perl6
00:24 Infinoid joined #perl6
00:31 orafu left #perl6
00:33 __david__ joined #perl6
00:34 orafu joined #perl6
00:41 jnthn sleep &
01:01 mavrc left #perl6
01:15 risou joined #perl6
01:18 risou__ left #perl6
01:20 TypeNameHere_ is now known as TypeNameHere____
01:26 ch3ck3r joined #perl6
01:29 ch3ck left #perl6
01:46 saaki left #perl6
01:53 kthakore jnthn: NOOoooOooOOoOooOOooooo
01:58 kanishka joined #perl6
02:25 TypeNameHere____ left #perl6
02:30 jferrero left #perl6
02:45 alc joined #perl6
02:45 sorear kthakore: ?
02:47 allbery_b silliness, I'm pretty sure
02:55 dalek niecza: b312ffc | sorear++ | v6/tryfile:
02:55 dalek niecza: [v6] Optimize regex use in getsig a bit
02:55 dalek niecza: review: https://github.com/sorear/niecza/commit/b312ffc9e8
02:55 dalek niecza: af5fde9 | sorear++ | / (2 files):
02:55 dalek niecza: Use a slightly faster Hash.at_key
02:55 dalek niecza: review: https://github.com/sorear/niecza/commit/af5fde9833
02:55 dalek niecza: cb623ff | sorear++ | / (3 files):
02:55 dalek niecza: Abstract vivification away from simply subs
02:55 dalek niecza: review: https://github.com/sorear/niecza/commit/cb623ff9ba
02:55 dalek niecza: 115676a | sorear++ | / (4 files):
02:55 dalek niecza: Use specialized WHENCE for Hash.at-key
02:55 dalek niecza: review: https://github.com/sorear/niecza/commit/115676a6c1
02:55 cdarroch joined #perl6
02:55 cdarroch left #perl6
02:55 cdarroch joined #perl6
03:21 dalek niecza: 78f0696 | sorear++ | / (4 files):
03:21 dalek niecza: Implement explicit invocant syntax
03:21 dalek niecza: review: https://github.com/sorear/niecza/commit/78f0696861
03:24 alc left #perl6
03:30 dalek 6model: 06a55fd | diakopter++ | dotnet/compiler/PAST2DNSTCompiler.pm:
03:30 dalek 6model: [dotnet] finish/enable failure path for pasttype literal
03:30 dalek 6model: review: https://github.com/jnthn/6model/commit/06a55fdc03
03:30 dalek 6model: 2e8b472 | diakopter++ | dotnet/compiler/DNST (2 files):
03:30 dalek 6model: [dotnet] implement DNST::JumpTable, a syntax tree of switch/case Computed Goto (uses an Assigned Goto jumptable in the C# emitter) control structures.
03:30 dalek 6model: review: https://github.com/jnthn/6model/commit/2e8b472d5d
03:33 sorear diakopter: assigned goto?
03:33 diakopter I dunno; that's what the wikipedia article said
03:33 diakopter http://en.wikipedia.org/wiki/Goto#Assigned_GOTO
03:34 diakopter at compile-time, the labels in pmichaud's regex compiler are strings, and I wanted to preserve that representation
03:35 sorear that looks more like a switch statement than a real assigned GOTO
03:35 sorear I would *love* an assigned goto in C#
03:35 diakopter in the code generated from his compiler (PIR) it's an assigned goto.
03:35 sorear if it wasn't horribly inefficient
03:37 diakopter ok ok, you caught me being handwavy with the terminology; it's assigned-goto at JnthnNQP compile-time. and a zero-indexed int switch/case in C#, which should be JIT to machine code as a jumptable
03:38 diakopter so, at compile-time in nqp:
03:42 * diakopter pauses that last sentence indefinitely
03:43 diakopter $statements.push($jumptable.mark("some marker_34xxxx"));  more code here  $statements.push($jumptable.jump(ZZZ));
03:44 diakopter where ZZZ is some expression returning an int, and code that's generated to make that expression hold different int values (an array lookup/pop usually) knows to use that jumptable to convert the names to integers.
03:44 diakopter (unpaused)
03:46 diakopter then of course  $statements.push($jumptable);  at some point into the same CLR method.
03:55 TypeNameHere____ joined #perl6
03:56 envi joined #perl6
04:25 nymacro joined #perl6
04:32 joyer joined #perl6
04:32 joyer play the latest rakudo.. help, plz. How to do pack/unpack in perl6??
04:34 sorear I do not understand that sentence.
04:34 kthakore sorear: you did seen kthakore ... I thought you wanted to talk to msimple old me
04:35 alc joined #perl6
04:35 alc left #perl6
04:37 sorear kthakore: I think masak wanted us to talk
04:37 sorear joyer: Sorry, I don't understand you.
04:38 sorear joyer: Are you talking about 'perldoc -f pack'?
04:38 kthakore sorear: I was telling him about the memory proplem of the current perl6, for writing game. So he suggested to talk to you about memory stuff in perl6 (for slimming it down)
04:41 joyer sorear: no, I mean -- perl6 -e 'my $m = "abc"; unpack("A2")' get an error
04:42 joyer I want to do binary pack/unpack in perl6
04:42 sorear rakudo: say unpack("i", "abcd")
04:42 p6eval rakudo : OUTPUT«Could not find sub &unpack␤  in main program body at line 22:/tmp/XPQoIXArt7␤»
04:42 dd-sphere joined #perl6
04:42 sorear unpack isn't implemented yet
04:42 sorear I think masak was working on it
04:43 joyer is there any workaround?
04:45 joyer here : http://rakudo.org/announce/rakudo-star/2010.08 it says `* Initial implementations of .pack and .unpack`
04:45 joyer I thought it may be done after 3m.
04:46 ch3ck3r left #perl6
04:49 sorear oh
04:49 sorear "." pack
04:49 justatheory left #perl6
04:49 sorear rakudo: say "abcd".unpack("i")
04:49 p6eval rakudo : OUTPUT«Method 'unpack' not found for invocant of class 'Str'␤  in main program body at line 22:/tmp/42eLOSSx6C␤»
04:50 sorear rakudo: say "abcd".Buf.unpack("i")
04:50 p6eval rakudo : OUTPUT«Method 'Buf' not found for invocant of class 'Str'␤  in main program body at line 22:/tmp/9uifT41ET1␤»
04:50 sorear rakudo: say "abcd".encode.unpack("i")
04:50 p6eval rakudo : OUTPUT«Unrecognized directive i␤  in <anon> at line 4495:CORE.setting␤  in 'unpack' at line 1␤  in main program body at line 22:/tmp/Elq7lbrSBN␤»
04:50 sorear rakudo: say "abcd".encode.unpack("c")
04:50 p6eval rakudo : OUTPUT«Unrecognized directive c␤  in <anon> at line 4495:CORE.setting␤  in 'unpack' at line 1␤  in main program body at line 22:/tmp/s3TF32Yn1A␤»
04:50 sorear rakudo: say "abcd".encode.unpack("n")
04:50 p6eval rakudo : OUTPUT«24930␤»
04:50 sorear so that's how you make it work
04:52 TimToady rakudo: say 97*256 + 98
04:52 p6eval rakudo : OUTPUT«24930␤»
04:52 saaki joined #perl6
04:55 sorear joyer: still here?
04:56 joyer yes
04:56 joyer trying to get the idea.
04:57 joyer rakudo: say "abc".encode.unpack("A2")
04:57 p6eval rakudo : OUTPUT«ab␤»
04:58 sorear any questions?
04:58 joyer how about pack?
05:04 sorear rakudo: say "n".pack(123456)
05:04 p6eval rakudo : OUTPUT«Method 'pack' not found for invocant of class 'Str'␤  in main program body at line 22:/tmp/CNpFkvYMn8␤»
05:04 sorear rakudo: say 123456.pack("n")
05:04 p6eval rakudo : OUTPUT«Method 'pack' not found for invocant of class 'Int'␤  in main program body at line 22:/tmp/EXYMF2Jml2␤»
05:05 sorear rakudo: say pack("N", 123456)
05:05 p6eval rakudo : OUTPUT«Buf()<0x71b43f0>␤»
05:05 joyer .encode.unpack vs pack ? a bit odd.
05:05 sorear rakudo: say pack("N", 123456).decode("ISO-8859-1")
05:05 p6eval rakudo : OUTPUT«Malformed UTF-8 string␤␤  in 'decode' at line 4412:CORE.setting␤  in main program body at line 22:/tmp/L3mwCZfyHf␤»
05:06 sorear rakudo: say pack("N", 123456).contents
05:06 p6eval rakudo : OUTPUT«0122664␤»
05:06 sorear rakudo: say pack("N", 123456).contents.perl
05:06 p6eval rakudo : OUTPUT«[0, 1, 226, 64]␤»
05:09 joyer I see. Thanks a lot.
05:16 cdarroch left #perl6
05:25 ch3ck3r joined #perl6
05:25 sorear std: True ?? die "Foo" !! 2
05:25 p6eval std a194beb: OUTPUT«[31m===[0mSORRY![31m===[0m␤Ternary !! seems to be missing its ?? at /tmp/80cGbPuxh4 line 1:␤------> [32mTrue ?? die "Foo" !![33m⏏[31m 2[0m␤Parse failed␤FAILED 00:01 120m␤»
05:29 dd-sphere left #perl6
05:34 lopnor joined #perl6
05:36 joyer std: my Str @s = <a b c>; @s.sort;
05:36 p6eval std a194beb: OUTPUT«ok 00:01 121m␤»
05:36 joyer rakudo: my Str @s = <a b c>; say @s.sort;
05:36 p6eval rakudo : OUTPUT«maximum recursion depth exceeded␤  in 'at_pos' at line 5:CORE.setting␤  in 'at_pos' at line 5:CORE.setting␤  in 'Any::postcircumfix:<[ ]>' at line 1742:CORE.setting␤  in 'at_pos' at line 5:CORE.setting␤  in 'at_pos' at line 5:CORE.setting␤  in 'Any::postcircumfix:<[ ]>' at line 174…
05:36 joyer Why does the last input die?
05:37 joyer std: my Str @s = <a b c>; say @s.sort;
05:37 p6eval std a194beb: OUTPUT«ok 00:01 122m␤»
05:39 sorear joyer: because you're using a type on an array
05:40 sorear there's a bug of some kind that makes my Type @array die
05:40 sorear my @array works fine
05:40 joyer so, .sort can't be use on a typed array?
05:41 joyer ok, so this is a wellknown bug.
05:41 sorear .sort isn't the problem, typed arrays are
05:44 joyer In python's interactive shell. One can inspect an object with "dir(obj)" or "help(obj)". What is the perl6 way of doing that thing?
05:45 redicaps1 joined #perl6
05:47 sorear rakudo: Sub.^methods.say
05:47 p6eval rakudo : OUTPUT«assumingwrapunwrapcandocandidatesaritycountACCEPTSnewassumingcallwithmultinameperlsignaturedoStrofreturnsNumericRealIntRatNumabsexploglog10sqrtrootsto-radiansfrom-radiansfloorceilingroundtruncatesigncisunpolarchrrandsincostanseccoseccotansinhcoshtanhsechcosechcotanhasinacosatanatan…
05:47 sorear rakudo: say [Sub.^methods]
05:47 p6eval rakudo : OUTPUT«assuming wrap unwrap cando candidates arity count ACCEPTS new assuming callwith multi name perl signature do Str of returns Numeric Real Int Rat Num abs exp log log10 sqrt roots to-radians from-radians floor ceiling round truncate sign cis unpolar chr rand sin cos tan sec cosec cot…
05:48 sorear rakudo: say [Sub.^methods(:local)]
05:48 p6eval rakudo : OUTPUT«␤»
05:48 sorear rakudo: say [Sub.^parents(:all)]
05:48 p6eval rakudo : OUTPUT«Routine() Block() Code() Cool() Any() Mu()␤»
05:48 joyer what is the semantic of the magical []
05:48 sorear it's the same [] you know from Perl 5
05:48 sorear changes a raw list of values into an anonymous array
05:49 sorear say prints arrays with spaces, but doesn't for raw lists
05:49 joyer that is wonderful
05:57 sorear TimToady: How do I predeclare a constant?  I'd like to return False from a method in Any
06:01 lopnor is now known as lopaway
06:04 __david__ left #perl6
06:07 Woodi left #perl6
06:09 Woodi joined #perl6
06:13 jhuni joined #perl6
06:16 risou left #perl6
06:16 risou joined #perl6
06:17 bjarneh joined #perl6
06:18 bjarneh left #perl6
06:26 dalek 6model: 3307a45 | diakopter++ | dotnet/compiler/ (3 files):
06:26 dalek 6model: [dotnet] fix bugs in the last commit
06:26 dalek 6model: use the jumptable API (and it works) in the regex prologue/epilogue compiler
06:26 dalek 6model: review: https://github.com/jnthn/6model/commit/3307a45fa4
06:52 Woodi left #perl6
06:54 __david__ joined #perl6
06:56 joyer pugs: say "are you there";
06:56 p6eval pugs: OUTPUT«are you there␤»
06:59 Axius joined #perl6
06:59 Woodi joined #perl6
07:09 _twitch joined #perl6
07:10 satyavvd joined #perl6
07:12 satyavvd_ joined #perl6
07:14 satyavvd left #perl6
07:14 satyavvd_ is now known as satyavvd
07:16 risou left #perl6
07:17 risou joined #perl6
07:19 dalek niecza: 6250090 | sorear++ | / (3 files):
07:19 dalek niecza: Give responsibility for vivifying the container to at-key
07:19 dalek niecza: review: https://github.com/sorear/niecza/commit/6250090509
07:20 redicaps1 left #perl6
07:25 ch3ck3r !seen masak
07:25 ch3ck3r !seen ch3ck
07:25 ch3ck3r !seen dalek
07:26 ch3ck3r !seen ch3ck3r
07:26 Woodi left #perl6
07:26 sorear aloha, seen ch3ck3r
07:26 aloha sorear: ch3ck3r was last seen in #perl6 25 seconds ago saying "!seen ch3ck3r".
07:26 sorear what made you think !seen would work?
07:27 ch3ck3r it does work
07:28 ch3ck3r !seen sorear
07:28 ch3ck3r -dalek- ch3ck3r: sorear (~root@209.9.237.164) was last seen saying "what made you think ..." on #perl6 on freenode on Sat Nov 27 07:26:49 2010, that was 1m 26s ago
07:29 ch3ck3r chatting as root, hm
07:35 Axius left #perl6
07:36 Axius joined #perl6
07:41 alc joined #perl6
07:45 dd-sphere joined #perl6
07:45 dd-sphere is now known as ch3ck
07:48 ch3ck3r left #perl6
07:50 Woodi joined #perl6
08:06 wallberg joined #perl6
08:08 sorear $ary[$i] = $i until ($i++) == 1_000_000;  # 0.66 us Perl 5
08:13 _kaare joined #perl6
08:15 sorear 22637 us Rakudo.  I wonder if I should file a bug for this, it's by far the largest perl 5 / rakudo speed difference I've seen
08:16 sorear er, 2637
08:16 sorear 2263
08:16 sorear messed up my division there
08:16 sorear factor of 3000 is much more reasonable
08:17 risou_ joined #perl6
08:19 risou left #perl6
08:20 ch3ck3r joined #perl6
08:22 ch3ck left #perl6
08:31 Chillance joined #perl6
08:32 kanishka left #perl6
08:36 kanishka joined #perl6
08:38 kanishka left #perl6
08:45 nymacro_ joined #perl6
08:51 ch3ck3r left #perl6
08:56 Axius left #perl6
09:17 dalek niecza: a7608c4 | sorear++ | / (2 files):
09:17 dalek niecza: Move Array, Hash, List into bootstrap class list
09:17 dalek niecza: review: https://github.com/sorear/niecza/commit/a7608c4ea7
09:17 dalek niecza: 009826c | sorear++ | / (3 files):
09:17 dalek niecza: Extend hash optimizations to arrays
09:17 dalek niecza: review: https://github.com/sorear/niecza/commit/009826c5c6
09:19 nymacro_ left #perl6
09:28 mavrc joined #perl6
09:52 dalek niecza: cafc254 | sorear++ | v6/tryfile:
09:52 dalek niecza: [v6] Remove conflicting code
09:52 dalek niecza: review: https://github.com/sorear/niecza/commit/cafc254943
10:02 lichtkind joined #perl6
10:04 lichtkind hai
10:05 jferrero joined #perl6
10:07 mj41 joined #perl6
10:10 wallberg left #perl6
10:10 sorear hi
10:17 lichtkind sorear: thanks now i can better show the grantmanager that iv done something :)
10:20 lichtkind karma HerbertBreunung
10:20 aloha HerbertBreunung has karma of 0.
10:20 lichtkind karma Herbert Breunung
10:20 aloha Herbert Breunung has karma of 93.
10:26 jferrero left #perl6
10:31 MayDaniel joined #perl6
10:43 pjcj left #perl6
10:44 jhuni left #perl6
10:54 MayDaniel left #perl6
10:58 dalek niecza: 80a8307 | sorear++ | lib/ (2 files):
10:58 dalek niecza: Use a Bloom filter to speed up contextual processing
10:58 dalek niecza: review: https://github.com/sorear/niecza/commit/80a8307ba0
11:00 araujo left #perl6
11:13 rurban joined #perl6
11:25 rurban left #perl6
11:32 pjcj joined #perl6
11:44 pjcj left #perl6
11:45 pjcj joined #perl6
11:50 PacoLinux left #perl6
11:57 newbie joined #perl6
11:59 alc left #perl6
12:00 alc joined #perl6
12:01 MayDaniel joined #perl6
12:12 thelazydeveloper joined #perl6
12:18 risou joined #perl6
12:19 risou_ left #perl6
12:24 satyavvd left #perl6
12:29 newbie left #perl6
12:36 ingy sorear++ # niecza build so easy
12:36 lichtkind left #perl6
12:37 satyavvd joined #perl6
12:39 PacoLinux joined #perl6
12:39 MayDaniel left #perl6
12:46 pmurias_ joined #perl6
12:47 pmurias_ left #perl6
12:48 pmurias joined #perl6
12:48 araujo joined #perl6
12:48 araujo left #perl6
12:48 araujo joined #perl6
12:49 satyavvd left #perl6
12:49 satyavvd joined #perl6
13:13 wamba joined #perl6
13:16 kanishka joined #perl6
13:24 Patterner left #perl6
13:32 araujo left #perl6
13:32 araujo joined #perl6
13:32 araujo left #perl6
13:32 araujo joined #perl6
13:34 satyavvd_ joined #perl6
13:34 satyavvd left #perl6
13:34 satyavvd_ is now known as satyavvd
13:36 Psyche^ joined #perl6
13:36 Psyche^ is now known as Patterner
13:37 nymacro left #perl6
13:53 lichtkind joined #perl6
13:59 nymacro joined #perl6
14:06 drake1 joined #perl6
14:06 drake1 dynamic evaluation in perl6, how does that work?
14:07 drake1 and what about local globals?
14:08 jnthn rakudo: my $x = 'say(42)'; eval($x) # you mean this?
14:08 p6eval rakudo : OUTPUT«42␤»
14:08 drake1 yes
14:08 jnthn rakudo: my $x = 'say($y)'; my $y = 69; eval($x)
14:08 p6eval rakudo : OUTPUT«69␤»
14:08 jnthn It can see the outer lexical scope where eval was called.
14:08 jnthn *scopes
14:08 jnthn And $*foo vars too.
14:10 drake1 ok
14:17 drake1 perl6 doesn't have global variables like $/ and $. ?
14:21 nymacro left #perl6
14:22 jnthn $/, $! and $_ remain but are now lexical, not global.
14:23 drake1 ok. thats pretty clean
14:24 jnthn Yeah. There is a way to put stuff in to a global scope, but afaik Perl 6 puts nothing of its own there.
14:25 drake1 then it's faster to learn
14:28 maluco_ left #perl6
14:28 drake1 like in C where a block can have local objects that hide away the globals
14:29 drake1 simply be redeclaration
14:29 gabiruh left #perl6
14:33 drake1 (not to mention implicit / restrict pointers to temporary objects)
14:35 frew left #perl6
14:36 [hudnix] left #perl6
14:36 ashleydev left #perl6
14:36 ashleydev joined #perl6
14:36 frew joined #perl6
14:39 alc left #perl6
14:40 [hudnix] joined #perl6
14:42 MayDaniel joined #perl6
14:51 drake1 does perl6 use getc, putc, fread and fwrite from the local C library?
14:51 maluco joined #perl6
14:53 gabiruh joined #perl6
14:53 drake1 C library / stdio object. sry
14:56 frew left #perl6
14:56 frew joined #perl6
14:59 alc joined #perl6
14:59 tadzik drake1: it uses Parrot opcodes, not the C library itself
14:59 tadzik Parrot may use C under the hood
15:00 tadzik drake1: if by Perl 6 you mean Rakudo
15:00 drake1 fine heheh
15:00 tadzik Niecza for example uses .NET stuff, IIRC
15:00 drake1 up to the Parrot then
15:04 drake1 sometimes I have to ponder whether regular ascii strings are a slower base encoding than binary
15:05 drake1 of course with a optimized type system, things have to turn a bit faster
15:08 toebu joined #perl6
15:08 drake1 depends the amount of evaluation
15:14 nymacro joined #perl6
15:15 drake1 not for rapid meta-programming, probably
15:16 nymacro left #perl6
15:18 drake1 can perl5 modules be used in perl6?
15:19 risou_ joined #perl6
15:20 risou left #perl6
15:20 whiteknight joined #perl6
15:21 drake1 for example, I just updated a PSF module for console fonts in perl5. could that be used directly in perl6?
15:23 tadzik you cantry. Blizkost runs some of the modules
15:23 drake1 good idea
15:25 jferrero joined #perl6
15:29 simon left #perl6
15:31 colomon left #perl6
15:36 drake1 maybe a few include(``'')'s could ease the pain. heh
15:36 wamba left #perl6
15:37 tadzik hm?
15:37 drake1 in a build system for both perl5 and 6
15:40 tadzik that's exactly what's wrong with the build system
15:41 drake1 this one has: cat common $(version_specific) common ... alike rules
15:43 drake1 without a proper viewer, the include(`') style is probably the most comprehensive
15:46 tadzik I don't think I understand your poing
15:46 tadzik s/poing/point/
15:47 drake1 when the cat concatenates the individual version according to macro options, some kind of viewer is needed to be able to see the whole thing
15:48 drake1 since the source is fragmented into version specific and common files
15:51 drake1 (that comprise the individual sections)
15:53 bluescreen joined #perl6
15:53 wamba joined #perl6
15:53 bluescreen is now known as Guest54855
16:01 whiteknight left #perl6
16:01 drake1 although # file_name headers could provide for the achor points, from a preprocessed version specific source
16:02 drake1 s/preprocessed/concatenated
16:06 toebu left #perl6
16:10 drake1 does perl6 use the source files in the library files?
16:10 drake1 or Parrot bytecode?
16:10 TimToady define "use"
16:11 jnthn In general, source files are authoratitive and any compiled versions are "cash"
16:11 jnthn er
16:11 jnthn cache
16:11 TimToady source files are treated hygienically though, not like includes
16:12 jnthn aye
16:12 drake1 when a program is going to use / load a library in the beginning, are the library files taken from their source stage or parrot byutecode?
16:12 TimToady perl6 officially doesn't care
16:12 jnthn drake1: Implementation dependent.
16:12 cognominal left #perl6
16:13 drake1 ok
16:14 joyer` joined #perl6
16:15 drake1 jnthn: sounds close to perl5 with a boost
16:16 joyer left #perl6
16:19 drake1 just what if someone wanted to make cach on a library, would that someone have to provide the source to authorize the cache
16:20 satyavvd left #perl6
16:20 drake1 cash
16:24 drake1 hopefully, the parrot bytecode stage wont require an authoritative parent source
16:26 TimToady for official modules Perl 6 requires only an unspoofable and immutable identity
16:27 drake1 does that even exist?
16:27 TimToady it will
16:27 drake1 maybe so
16:27 TimToady once you have a universal naming scheme for immutable objects, you can get copies of those objects from anywhere
16:28 TimToady this solves most of the module scaling issues
16:28 drake1 good point
16:28 TimToady essentially the same approach as git and .NET
16:28 drake1 for all the hosts that are your friends
16:29 TimToady the cryptochecksum can be recalculated against the source, if you're paranoid
16:29 drake1 some hosts should be allowed to provide a variety of compositions imo
16:29 TimToady dunno what you mean
16:30 drake1 like with individual contents and hashes
16:30 TimToady dunno what you mean
16:30 drake1 or else the identity scheme won't allow decentralized dynamic distributions
16:31 drake1 only in the master / slave sense
16:31 * TimToady thinks that's someone else's problem :)
16:32 TimToady Perl 6's responsibility stops at identifying the desired module uniquely.
16:32 drake1 like everyone should trust the same authority
16:33 drake1 as long as it's just the path name, then you're right. completely left to the package manager
16:34 cognominal joined #perl6
16:35 TimToady sure, except maybe there's no path
16:36 drake1 yeah
16:37 drake1 /usr/perl is a fine authority
16:38 TimToady but to the abstract database lookup to find the actual module contents, it's just a stringy part of the universal module indicator.
16:39 TimToady in fact, we might as well call them UMIs
16:39 drake1 whatever they like
16:39 drake1 might work with the HAT hash
16:40 TimToady as long as a given module longname (UMI) always maps to the same immutable chunk of code (or its derivatives), P6 is happy
16:40 flussence module name + version + sha256 would be a good start...
16:40 drake1 fine
16:41 TimToady wildcard "use" is a step before that to translate a short name to a long name
16:41 TimToady + auth
16:41 drake1 no need for sha
16:41 drake1 maybe in the package manager
16:41 flussence yeah, that sounds about right
16:41 TimToady yes, at least there
16:41 drake1 the HAT is only to look them up fater
16:42 drake1 faster*
16:42 TimToady ENOCARE
16:42 flussence doesn't the Encode module in p5 work a bit like this already?
16:42 flussence with encoding alias lookups and stuff
16:43 TimToady EDUNNO
16:43 drake1 I used it for file handle ties, so characters written were local to the mode of interpretation
16:43 flussence that was the first thing that came to mind, I had to do charset translation for some horrible embedded hardware a while back :)
16:45 TimToady any number of shortname schemes can be layered on top of a longname scheme, but the converse is not true
16:45 drake1 with the utf8 flag or not, basically
16:46 moritz_ there is not UTF8 flag, and Juerd is its prophet.
16:48 TimToady so the best approach is if there is a good 1::1 correspondence between longnames ("URI") and immutable identity, and all shortname schemes are considered customizations or intentionally declared generic code
16:49 TimToady accidentally generic (underspecified) code is what tends to break as we go forward
16:51 TimToady to the extent that the entire system (including runtime support) is specified using immutable code, it tends to be unbreakable
16:52 TimToady breakages happen if the code is not immutable
16:52 TimToady they also happen if you don't actually have the code anymore, but borken proxy links to it
16:52 TimToady so the source code is important in that respect
16:53 mila__ joined #perl6
16:54 TimToady if the entire semantics of a program can be expressed bootstrappishly in Perl 6 (modulo a few primitives), then a snapshot of that entire code set is quite stable
16:55 TimToady of course, that will run very slowly, and optimizers also break code regularly  :)
16:55 Juerd moritz_: Prophet of the UTF8 flag?! :)
16:56 mila_ left #perl6
16:57 TimToady so which newspaper will be the first to publish cartoons of Juerd?
16:58 MayDaniel left #perl6
16:58 Juerd It's best to pretend the flag doesn't exist. Something that doesn't exist may very well have prophets, but I'm certainly not one of them.
16:59 drake1 piston coffee is quite a bit more instant than made by regular machines
17:00 alc left #perl6
17:00 jnthn Doesn't it taste bad if it's been piston?
17:01 * jnthn duck
17:01 jnthn s
17:01 TimToady Juerd: so from that I can deduce that you don't care to differentiate between something not existing and you pretending it doesn't exist :)
17:01 drake1 quite the same
17:01 Juerd TimToady: Entirely correct
17:02 dalek 6model: 5c00aa5 | jonathan++ | dotnet/compiler/ (2 files):
17:02 dalek 6model: [dotnet] Make DNST::Local behave a little more like other nodes. Also, now we have it, use it in a couple of places that I shoulda before.
17:02 dalek 6model: review: https://github.com/jnthn/6model/commit/5c00aa5912
17:02 TimToady must be convenient...
17:03 drake1 perl5 wouldn't work with the CTYPE environment afaik
17:03 jferrero left #perl6
17:05 drake1 equivalence classes and sh** would need explicit `use ..' statements etc.
17:08 jferrero joined #perl6
17:16 drake1 no great wonder since glibc uses wicked locale files
17:18 allbery_b l10n is hard, let's go shopping
17:18 drake1 perl wouldn't easily be able to compile the pattern engine nor specify something sane
17:19 drake1 yeah, thats my own conclusion, allbery
17:22 TimToady it should be possible to ask for braindamaged semantics, but it shouldn't be the default
17:23 allbery_b sadly, I think that while that's a nice idea in principle, it limits interoperability with pretty much everything
17:25 colomon joined #perl6
17:25 drake1 until they turn straight, local compensations might be the best
17:26 joyer` left #perl6
17:26 joyer` joined #perl6
17:31 lichtkind left #perl6
17:32 drake1 when you can't change the whole world; then at least show a good example
17:33 TimToady all is fair if you predeclare, including "use StupidStuff;"
17:34 drake1 only a little bit cumbersome
17:35 mikehh joined #perl6
17:36 drake1 like the read ends of the `tee' needs duplication
17:37 MayDaniel joined #perl6
17:38 envi left #perl6
17:40 mila_ joined #perl6
17:42 maluco_ joined #perl6
17:43 mavrc left #perl6
17:44 colomon_ joined #perl6
17:45 thelazydeveloper left #perl6
17:46 colomon left #perl6
17:46 mila__ left #perl6
17:46 maluco left #perl6
17:46 colomon_ is now known as colomon
17:50 drake1 Im off to add a todo to a PSF module. bye
17:50 drake1 left #perl6
17:51 ch3ck joined #perl6
17:59 tadzik seen mberends?
17:59 aloha mberends was last seen in #perl6 3 days 11 hours ago saying "masak: o/".
18:08 nadim left #perl6
18:15 mavrc joined #perl6
18:15 dalek 6model: d253bff | jonathan++ | dotnet/compiler/DNST.pm:
18:15 dalek 6model: [dotnet] Oops, :name for DNST::Local is required.
18:15 dalek 6model: review: https://github.com/jnthn/6model/commit/d253bffb78
18:15 dalek 6model: 7f69a02 | jonathan++ | dotnet/compiler/PAST2DNSTCompiler.pm:
18:15 dalek 6model: [dotnet] Refactor emit_op that diakopter++ added, and then use it in various places in PAST2DNST.pm, which makes things neater/shorter.
18:15 dalek 6model: review: https://github.com/jnthn/6model/commit/7f69a02f1e
18:17 justatheory joined #perl6
18:19 lamstyle left #perl6
18:19 dalek 6model: f1d5648 | jonathan++ | dotnet/compiler/PAST2DNSTCompiler.pm:
18:19 dalek 6model: [dotnet] A similar refactor for emit_call.
18:19 dalek 6model: review: https://github.com/jnthn/6model/commit/f1d56487bb
18:22 jnthn afk, noms
18:24 tadzik rakudo: class A { has $.method; }; say A.can('method')
18:24 p6eval rakudo :  ( no output )
18:24 tadzik rakudo: class A { has $.method; }; say A.can('method'); say 'alive'
18:24 p6eval rakudo : OUTPUT«alive␤»
18:38 knewt2 left #perl6
18:38 ch3ck left #perl6
18:38 Chillance left #perl6
18:38 clkao left #perl6
18:38 shabble left #perl6
18:38 cotto left #perl6
18:38 simcop2387 left #perl6
18:38 f00li5h left #perl6
18:38 pothos left #perl6
18:38 sunnavy left #perl6
18:38 robinsmidsrod left #perl6
18:38 florz left #perl6
18:39 nperez left #perl6
18:39 szbalint_ joined #perl6
18:39 _jaldhar joined #perl6
18:39 sbp left #perl6
18:39 joyer`` joined #perl6
18:39 jql_ joined #perl6
18:39 moritz__ joined #perl6
18:39 Infinoid_ joined #perl6
18:39 sftp_ joined #perl6
18:39 Sarten-X2 joined #perl6
18:39 PacoLinux_ joined #perl6
18:39 kanishka left #perl6
18:39 sbp joined #perl6
18:39 kfo left #perl6
18:39 PacoLinux left #perl6
18:39 mila_ left #perl6
18:39 zby left #perl6
18:39 PacoLinux_ is now known as PacoLinux
18:39 nperez_ joined #perl6
18:39 kfo joined #perl6
18:39 drbean_ joined #perl6
18:39 kst` joined #perl6
18:40 Sarten-X left #perl6
18:40 `26 left #perl6
18:40 nsh left #perl6
18:40 solarion left #perl6
18:40 tylerni7 left #perl6
18:40 allbery_b left #perl6
18:40 szbalint left #perl6
18:40 drbean left #perl6
18:40 mj41_ joined #perl6
18:40 Helios- joined #perl6
18:40 jql left #perl6
18:40 nsh_ left #perl6
18:40 Helios left #perl6
18:40 moritz_ left #perl6
18:40 Infinoid left #perl6
18:40 cookys left #perl6
18:40 kst left #perl6
18:40 sjn left #perl6
18:40 kolibrie_ left #perl6
18:40 diakopter left #perl6
18:40 jasonmay left #perl6
18:40 diakopter joined #perl6
18:40 cookys_ joined #perl6
18:40 dalek left #perl6
18:40 jferrero left #perl6
18:40 __david__ left #perl6
18:40 colomon left #perl6
18:40 MayDaniel left #perl6
18:40 jaldhar left #perl6
18:40 slavik left #perl6
18:40 spacebat left #perl6
18:40 mavrc left #perl6
18:40 sftp left #perl6
18:40 chitragupt left #perl6
18:40 mikehh left #perl6
18:40 hercynium left #perl6
18:40 tadzik hmm, any PSGI-familiar person?
18:40 zby_ joined #perl6
18:40 joyer` left #perl6
18:40 __david__ joined #perl6
18:40 explorer__ joined #perl6
18:40 y3llow left #perl6
18:40 frettled left #perl6
18:40 BinGOs left #perl6
18:40 mikehh_ joined #perl6
18:40 mila__ joined #perl6
18:40 slavik2 joined #perl6
18:40 TypeNameHere____ left #perl6
18:40 cosimo left #perl6
18:40 BinGOs joined #perl6
18:40 BinGOs left #perl6
18:40 BinGOs joined #perl6
18:40 dalek joined #perl6
18:40 jedai_ left #perl6
18:40 ch3ck joined #perl6
18:40 Chillance joined #perl6
18:40 clkao joined #perl6
18:40 shabble joined #perl6
18:40 cotto joined #perl6
18:40 simcop2387 joined #perl6
18:40 f00li5h joined #perl6
18:40 pothos joined #perl6
18:40 sunnavy joined #perl6
18:40 cosimo joined #perl6
18:40 nsh- joined #perl6
18:40 y3llow joined #perl6
18:40 allbery_b joined #perl6
18:40 PZt left #perl6
18:40 tylerni7 joined #perl6
18:40 tylerni7 left #perl6
18:40 tylerni7 joined #perl6
18:40 bbkr left #perl6
18:41 lamstyle joined #perl6
18:41 jedai joined #perl6
18:41 TimToady tadzik: try again not in the middle of a major netsplit :)
18:41 mj41 left #perl6
18:42 dual left #perl6
18:42 mj41_ is now known as mj41
18:43 florz joined #perl6
18:43 robins joined #perl6
18:43 hercynium joined #perl6
18:43 kolibrie joined #perl6
18:44 nsh joined #perl6
18:44 bbkr joined #perl6
18:44 knewt2 joined #perl6
18:44 ch3ck3r joined #perl6
18:44 solarion joined #perl6
18:44 hercynium left #perl6
18:44 hercynium joined #perl6
18:44 lamstyle left #perl6
18:44 lamstyle joined #perl6
18:44 jasonmay joined #perl6
18:45 spacebat joined #perl6
18:45 sjn_ joined #perl6
18:46 ch3ck left #perl6
18:47 frettled joined #perl6
18:47 d4l3k_ joined #perl6
18:48 breinbaa1 joined #perl6
18:48 dual joined #perl6
18:48 tadzik1 joined #perl6
18:48 breinbaa1 left #perl6
18:48 solarion left #perl6
18:48 solarion joined #perl6
18:49 zby joined #perl6
18:49 ironcame1 joined #perl6
18:50 betterwo1ld joined #perl6
18:50 tadzik left #perl6
18:50 __david__ left #perl6
18:50 zby_ left #perl6
18:50 breinbaas left #perl6
18:50 ironcamel left #perl6
18:50 dalek left #perl6
18:50 betterworld left #perl6
18:50 __david__ joined #perl6
18:50 chitragupt joined #perl6
18:51 d4l3k_ is now known as dalek
18:52 pmeursault joined #perl6
18:52 tadzik1 is now known as tadzik
18:55 breinbaas joined #perl6
18:56 `26 joined #perl6
18:58 mavrc joined #perl6
19:01 dd-sphere joined #perl6
19:02 BooK_ joined #perl6
19:02 Koven joined #perl6
19:03 tadzik loliblogged! http://ttjjss.wordpress.com/2010/11/27/grammar-dispatching-%E2%80%93-a-step-further/
19:03 jedai_ joined #perl6
19:04 exodist_ joined #perl6
19:04 cognominal_ joined #perl6
19:05 jedai left #perl6
19:05 cognominal left #perl6
19:05 Kovensky left #perl6
19:05 Exodist left #perl6
19:05 BooK left #perl6
19:06 moritz__ Juerd: more like "prophet of ignoring the UTF8 flag"
19:06 ch3ck3r left #perl6
19:06 Juerd :)
19:07 PZt joined #perl6
19:08 moritz__ is now known as moritz_
19:13 nadim joined #perl6
19:17 sftp_ left #perl6
19:17 sftp_ joined #perl6
19:20 tadzik oh, the advent calendar is close
19:22 jnthn_ joined #perl6
19:23 Eevee_ joined #perl6
19:23 Eevee left #perl6
19:23 jnthn left #perl6
19:25 mavrc left #perl6
19:27 jnthn_ left #perl6
19:28 jnthn joined #perl6
19:28 drake1 joined #perl6
19:28 drake1 look www.gangsterfreak.com/vcfed - Now with Perl6 / Rakudo directions
19:31 Gruber joined #perl6
19:31 d4l3k_ joined #perl6
19:31 Maddingue left #perl6
19:31 kst`` joined #perl6
19:31 jferrero joined #perl6
19:32 sjn_ left #perl6
19:32 sjn joined #perl6
19:32 MayDaniel joined #perl6
19:32 `26 left #perl6
19:36 xinming left #perl6
19:36 zb left #perl6
19:36 mikehh__ joined #perl6
19:36 exodist_ left #perl6
19:36 shelling_lab left #perl6
19:36 zby_ joined #perl6
19:36 risou joined #perl6
19:36 shelling_lab joined #perl6
19:36 wolveria1 joined #perl6
19:36 hercynium_ joined #perl6
19:36 y3llow_ joined #perl6
19:36 rokoteko_ joined #perl6
19:36 mila_ joined #perl6
19:36 risou_ left #perl6
19:36 Kovensky joined #perl6
19:36 exodist joined #perl6
19:36 tadzik nice
19:36 pmeursault left #perl6
19:36 mikehh_ left #perl6
19:36 hercynium left #perl6
19:36 Trashlord left #perl6
19:36 Koven left #perl6
19:36 rokoteko left #perl6
19:36 mila__ left #perl6
19:36 allbery_b left #perl6
19:36 slavik2 left #perl6
19:36 drake1 left #perl6
19:36 BinGOs left #perl6
19:36 Trashlord joined #perl6
19:36 BinGOs joined #perl6
19:36 kolibrie left #perl6
19:36 cosimo left #perl6
19:36 allbery_b joined #perl6
19:37 slavik1 joined #perl6
19:37 tadzik left #perl6
19:37 dalek left #perl6
19:37 phenny left #perl6
19:37 kst` left #perl6
19:37 jdv79 left #perl6
19:37 wolverian left #perl6
19:37 phenny joined #perl6
19:37 kolibrie_ joined #perl6
19:37 Maddingu1 joined #perl6
19:37 y3llow left #perl6
19:37 cosimo_ joined #perl6
19:37 orafu left #perl6
19:37 explorer__ left #perl6
19:37 Grrrr left #perl6
19:37 zby left #perl6
19:37 diakopter left #perl6
19:37 diakopter joined #perl6
19:37 lue left #perl6
19:37 Juerd left #perl6
19:37 y3llow_ is now known as y3llow
19:37 Juerd_ joined #perl6
19:37 tadzik joined #perl6
19:37 Juerd_ is now known as Juerd
19:37 lue joined #perl6
19:38 zb joined #perl6
19:38 OuLouFu joined #perl6
19:38 d4l3k_ is now known as dalek
19:38 OuLouFu is now known as orafu
19:38 xinming joined #perl6
19:38 `26 joined #perl6
19:38 `26 left #perl6
19:38 `26 joined #perl6
19:39 jdv79 joined #perl6
19:53 sorear good * #perl6
19:55 tadzik hello sorear
19:57 szbalint_ is now known as szbalint
19:59 sorear TimToady: How do I go from STD:auth<http://perl.org>:ver<6.0.0> to <xdigit>**64 ?
20:04 TimToady don't much care, as long as STD:auth<http://perl.org>:ver<6.0.0> always means the same thing everywhere
20:05 TimToady I've excapsulated library issues :)
20:05 `26 I've mental issues :)
20:14 rindolf joined #perl6
20:14 rindolf Hi all.
20:14 MayDaniel left #perl6
20:14 tadzik hi rindolf
20:14 ch3ck3r joined #perl6
20:14 sorear Hello rindolf
20:14 tadzik while the netsplit is gone, and everyone's up again:
20:15 tadzik loliblogged! http://ttjjss.wordpress.com/2010/11/27/grammar-dispatching-%E2%80%93-a-step-further/
20:15 rindolf tadzik: , sorear : What's up?
20:16 tadzik rindolf: fun :)
20:18 dd-sphere left #perl6
20:19 hillu left #perl6
20:20 hillu joined #perl6
20:21 oha is it possible to declare a Q:FOO{foo $bar cuz} so that the user defined function is called with ("foo ", \$bar, " cuz") or something similar? are there plans for?
20:21 moritz_ oha: I'm sure you can do that with macros... eventually
20:22 oha are macros available on rakudo?
20:22 moritz_ no
20:23 moritz_ that's why I said "eventually" :-)
20:23 sorear niecza: my $bar = 123; my @foo = do { sub infix:<~>(*@x) { @x }; "foo $bar cuz" }; say @foo.dump
20:23 p6eval niecza 80a8307: OUTPUT«["foo ", 123, " cuz"]␤»
20:23 sorear I'm not sure if this counts as a bug
20:23 sorear but it's possibly relevant
20:24 moritz_ that's... evil. And cute.
20:25 oha sorear: i've tried with rakudo, but was not able to.
20:25 moritz_ rkaudo probably uses a lower-level concatenation for string interpolation
20:26 oha moritz_: yep, i've checked the grammar and it seems so to me.
20:28 moritz_ I think the specification is silent about that aspect.
20:28 oha moritz_: but i get lost and i was not sure
20:28 oha would be nice to have a Q:SOMETHING{ ... }
20:29 moritz_ rakudo: my $bar = 123; my @foo = do { our sub infix:<~>(*@x) { @x  }; "foo $bar cuz" }; say @foo.perl
20:29 p6eval rakudo : OUTPUT«["foo 123  cuz"]␤»
20:29 sorear where did the space after 123 come from
20:30 moritz_ rakudo: my $bar = 123; say (do { our sub infix:<~>(*@x) { @x  }; "foo $bar cuz" }).split(/\s+/).perl
20:30 p6eval rakudo : OUTPUT«("foo", "123", "cuz")␤»
20:30 moritz_ :-)
20:30 oha moritz_: but sorear is right, isn't there an unwanted space?
20:32 moritz_ oha: maybe the returned array is stringified, and that adds a space between the elements
20:34 oha rakudo: my $bar = 123; my @foo = do { our sub infix:<~>(*@x) { say "dbg> "~@x.perl; @x }; "foo $bar cuz" }; say @foo.perl
20:34 sorear but there's only the one space in foo $bar
20:34 p6eval rakudo : OUTPUT«(timeout)»
20:34 oha emh... i'm stupid :)
20:35 oha rakudo: my $bar = 123; { our sub infix:<~>(*@x) { say @x.perl; @x }; "foo $bar cuz" }
20:35 p6eval rakudo : OUTPUT«["123", " "]␤»
20:35 oha the trick which put back the space captured after $bar?
20:35 oha i've read it in the grammar
20:36 oha rakudo: my $bar = 123; { our sub infix:<~>(*@x) { say @x.perl; @x }; "foo[$bar]cuz" }
20:36 p6eval rakudo :  ( no output )
20:37 oha interesting...
20:38 Gruber is now known as Grrrr
20:39 pmeursault joined #perl6
20:39 oha my @v; my $x=12; my $y='ab'; { our sub infix:<~>($a,$b) { push @v, $a; '?' }; say "select * from table where x = $x and y = $y ;", @v }
20:39 sorear .perl uses ~
20:40 oha (i'm sorry for the CPU which host p6eval :)
20:40 sorear you're not using any CPU now
20:40 oha rakudo: my @v; my $x=12; my $y='ab'; { our sub infix:<~>($a,$b) { push @v, $a; '?' }; say "select * from table where x = $x and y = $y ;", @v }
20:40 p6eval rakudo : OUTPUT«select * from table where x = ?and y = ?;12ab␤»
20:40 oha (forgot rakudo)
20:41 oha nice!
20:41 y3llow_ joined #perl6
20:41 pothos_ joined #perl6
20:41 oha rakudo: my @v; my $x=12; my $y='ab'; { our sub infix:<~>($a,$b) { push @v, $a; '? ' }; say "select * from table where x = $x and y = $y ;", [@v] }
20:41 p6eval rakudo : OUTPUT«select * from table where x = ? and y = ? ;12 ab␤»
20:42 rindolf left #perl6
20:42 pothos left #perl6
20:43 pothos_ is now known as pothos
20:43 y3llow left #perl6
20:44 y3llow_ is now known as y3llow
20:49 misterme joined #perl6
20:54 misterme left #perl6
21:03 pmurias left #perl6
21:16 jferrero left #perl6
21:25 masak joined #perl6
21:26 masak ahoj!
21:26 phenny masak: 26 Nov 23:07Z <eternaleye> tell masak Hey! I read HP & the methods of rationality too! I prticularly like how Draco was absolutely floored by muggles being the first humans on the moon.
21:26 masak eternaleye: :)
21:27 jnthn o/ masak
21:27 masak \o
21:29 tadzik ahoj masak!
21:32 masak if you haven't seen this, you probably should. interview with Grace Hopper. http://www.youtube.com/watch?v=57bfxsiVTd4
21:34 jql_ is now known as jql
21:42 dd-sphere joined #perl6
21:45 tadzik lovely lady
21:46 ch3ck3r left #perl6
21:48 sorear hello masak!
21:49 masak good evening.
21:52 masak rakudo: say 4.roots.perl
21:52 p6eval rakudo : OUTPUT«Not enough positional parameters passed; got 1 but expected 2␤  in 'roots' at line 3414:CORE.setting␤  in main program body at line 22:/tmp/1G2Mb1llu_␤»
21:53 masak oh, right.
21:53 masak rakudo: say 4.roots(2).perl
21:53 p6eval rakudo : OUTPUT«(Complex.new(2, 0), Complex.new(-2, 2.44929359829471e-16))␤»
21:53 * masak submits rakudobug
21:53 masak thanks to VienosNotes++ on twitter. http://twitter.com/VienosNotes/status/8632485453766656
21:57 tadzik masak: seen my blog toast?
21:57 gbacon joined #perl6
21:57 masak tadzik: no; haven't backlogged yet.
21:57 masak is it about .roots?
21:57 tadzik no, about PSGI and grammars
21:58 masak ah; looks promising :)
21:58 masak I'll get to it. right now I need to focus on Web.pm
22:05 tadzik I thought about writing a dispatcher for Web in grammars, if that's possible
22:06 masak might well be.
22:06 wamba left #perl6
22:12 sorear perl 6 PSGI ?
22:14 lue ohai o/
22:14 masak hilue.
22:14 dd-sphere godkväll masak \o
22:14 masak god afton dd-sphere.
22:14 dd-sphere is now known as ch3ck
22:14 masak thought so :)
22:14 ch3ck :D
22:15 tadzik sorear: ttjjss.wordpress.com
22:18 masak rakudo: my $answer = [] but role { method postcircumfix:<( )>( ($arg) ) { say "You called me with argument $arg" } }; $answer(5)
22:18 p6eval rakudo : OUTPUT«You called me with argument 5␤»
22:18 masak rakudo: my $answer = 42 but role { method postcircumfix:<( )>( ($arg) ) { say "You called me with argument $arg" } }; $answer(5)
22:18 p6eval rakudo : OUTPUT«invoke() not implemented in class 'Integer'␤  in main program body at line 22:/tmp/4wO4WdYY7v␤»
22:18 * masak submits rakudobug
22:19 ch3ck3r joined #perl6
22:19 masak rakudo: my $x = [] but role {}; say "alive"
22:19 p6eval rakudo : OUTPUT«alive␤»
22:19 masak rakudo: my $x = class {} but role {}; say "alive"
22:19 p6eval rakudo : OUTPUT«Attempt to use rebless_subclass where the new class was not a subclass␤  in 'infix:<does>' at line 7294:CORE.setting␤  in 'infix:<does>' at line 582:CORE.setting␤  in 'infix:<but>' at line 609:CORE.setting␤  in main program body at line 22:/tmp/i4TLL1ncR2␤»
22:19 * masak submits rakudobug
22:20 jnthn Two bugs that couldn't happen in 6model...
22:20 masak :)
22:20 masak talk is cheap :P
22:20 * masak hides
22:21 diakopter :P
22:21 * jnthn calls up an Uppsala polar bear to go chase masak a bit
22:22 masak I think I may have deserved that.
22:22 masak the sad thing? I was just toying around trying to recall what to put in the parameter list of postcircumfix:<( )>
22:22 jnthn a capture
22:23 jnthn I'm a bit surprised that doesn't work...
22:23 ch3ck left #perl6
22:23 jnthn OTOH I fear the way we handle overriding v-table invoke in Parrot is...weird.
22:23 masak I was surprised too.
22:23 jnthn I don't know that it shoudl matter though.
22:23 jnthn Hm
22:23 masak I've mixed other stuff into integers, and it worked fine.
22:24 masak rakudo: role R {}; my $x = class {} but R; say "alive"
22:24 p6eval rakudo : OUTPUT«Attempt to use rebless_subclass where the new class was not a subclass␤  in 'infix:<does>' at line 7294:CORE.setting␤  in 'infix:<does>' at line 582:CORE.setting␤  in 'infix:<but>' at line 609:CORE.setting␤  in main program body at line 22:/tmp/Q5q96Y3ZP0␤»
22:25 jnthn masak: That one is because of the way type objects are done.
22:25 masak rakudo: role R {}; my $x = (class {}).new but R; say "alive"
22:25 p6eval rakudo : OUTPUT«alive␤»
22:25 masak ah.
22:25 jnthn Yeah.
22:25 jnthn Trying to fix that was one of the things that told me, "OK, we need type objects to REALLY be the same type"
22:25 masak rakudo: my $x = (role {}) but role {}; say "alive"
22:26 p6eval rakudo : OUTPUT«Attempt to use rebless_subclass where the new class was not a subclass␤  in 'infix:<does>' at line 7294:CORE.setting␤  in 'infix:<does>' at line 582:CORE.setting␤  in 'infix:<but>' at line 609:CORE.setting␤  in main program body at line 22:/tmp/hhrZMRYBT_␤»
22:26 ch3ck joined #perl6
22:26 masak jnthn: same as what?
22:26 masak ah.
22:26 masak as their instantiated cousins.
22:26 masak yeah, that sounds like a good idea.
22:26 Guest54855 left #perl6
22:28 jnthn Right :)
22:28 sorear jnthn: care to elaborate?  I was about to do the opposite
22:28 ch3ck3r left #perl6
22:28 * masak like how his demolishing things can contribute to developer discussion :)
22:28 jnthn sorear: Mixing a role into something means that it's had an in-place change of type.
22:28 diakopter rakudo: say (role role { say (role role { }).WHAT }).WHAT.perl.eval
22:28 p6eval rakudo :  ( no output )
22:29 jnthn sorear: Which it turns out gets awkward at times.
22:29 masak and diakopter is his same old evil self, I see :P
22:29 jnthn sorear: er, I mean...
22:29 jnthn sorear: It gets awkward if you make the type object an instance with a role mixed in.
22:30 jnthn I argued it was OK for a while too, then saw myself having to put in a bunch of special cases.
22:31 jnthn SMOP called that one right.
22:34 lue Is there a nifty way to see if a string is valid pair notation? [writing a looong regex would be fine with me, but it doesn't seem like the smart way]
22:36 mila_ left #perl6
22:38 TimToady rakudo: say eval(':foo<bar>') ~~ Pair
22:38 p6eval rakudo : OUTPUT«1␤»
22:38 TimToady for some definition of "nifty" that isn't very
22:39 masak alternatively, run it through the built-in Perl 6 grammar and see what AST node pops out :)
22:39 TimToady rakudo: use STD;
22:39 p6eval rakudo : OUTPUT«===SORRY!===␤Unable to find module 'STD' in the @*INC directories.␤(@*INC contains:␤  lib␤  /home/p6eval/.perl6/lib␤  /home/p6eval/p1/lib/parrot/2.10.0-devel/languages/perl6/lib␤  .)␤»
22:40 lue that's pretty nifty.
22:40 jnthn rakudo: if Perl6::Grammar.parse(':foo<bar>', rule => 'colonpair') { say "yes" }
22:40 p6eval rakudo : OUTPUT«===SORRY!===␤Malformed regex at line 22, near "=> 'colonp"␤»
22:40 jnthn ffs
22:40 masak huh?
22:40 jnthn rakudo: if Perl6::Grammar.parse(':foo<bar>', :rule<colonpair>) { say "yes" }
22:40 masak ah!
22:40 p6eval rakudo : OUTPUT«yes␤»
22:40 masak 'rule'
22:40 jnthn rakudo: if Perl6::Grammar.parse(':foo<bar', :rule<colonpair>) { say "yes" }
22:40 p6eval rakudo : OUTPUT«yes␤»
22:40 jnthn Oh.
22:40 jnthn oh yeah
22:41 jnthn :foo *is* a colonpair.. :)
22:41 masak std: rule => 'colonpair'
22:41 p6eval std a194beb: OUTPUT«ok 00:01 119m␤»
22:41 jnthn rakudo: if Perl6::Grammar.parse('foo<bar', :rule<colonpair>) { say "yes" }
22:41 p6eval rakudo :  ( no output )
22:41 jnthn Yeah, works.
22:41 masak we already have a similar RT ticket about things that don't autoquote correctly in pairs.
22:41 jnthn yeah
22:42 bluescreen joined #perl6
22:42 lue rakudo: say eval('foo => 1') ~~ Pair
22:42 p6eval rakudo : OUTPUT«1␤»
22:42 bluescreen is now known as Guest24421
22:42 lue rakudo: say eval('Pear') ~~ Pair
22:42 p6eval rakudo : OUTPUT«0␤»
22:43 TimToady rakudo: say eval(':foo<bar') ~~ Pair
22:43 p6eval rakudo : OUTPUT«0␤»
22:43 TimToady we oughta have a parse primitive that uses the current language
22:43 jnthn $*LANG.parse ...?
22:43 TimToady $?LANG maybe
22:44 jnthn ah, yeah
22:44 jnthn compy time.
22:44 TimToady but it would be nice to have access to the various bits of eval
22:44 lue if only I could get that in a regex...
22:47 sorear %*LANG surely
22:47 sorear sigil invariance
22:47 TimToady %?LANG then
22:47 sorear $~MAIN anyway
22:47 sorear when are constants run?
22:48 TimToady but sub parse wants to be able to get at CALLER::<$~MAIN>
22:48 TimToady constant definitions always run at compile time
22:48 TimToady an enum is their prophet
22:49 TimToady all declarations are funny constant declarations, really
22:50 jhuni joined #perl6
22:52 sorear what should I do about constant FOO = ... if my compiler doesn't have a Perl 6 interpreter available
22:53 nrr left #perl6
22:53 TimToady re type objects, I've always thought of them as a kind of photon/gluon that carries a "type charge" on a massless object
22:53 TimToady sorear: write one
22:53 TimToady it is a requirement of Perl 6 compilers to be able to run code at compile time
22:54 TimToady constants are just a way to name a constant folding
22:55 TimToady in any case, it is required that BEGIN run as soon as parsed
22:56 masak due to BEGIN, a compiler needs to have a runtime. due to eval, a runtime needs to have a compiler.
22:58 TimToady yes, they are both extreme safety valves that we use to discover places where we haven't designed other, safer ways to do it
22:58 dalek 6model: 40db931 | jonathan++ | dotnet/compiler/PAST2DNSTCompiler.pm:
22:58 dalek 6model: [dotnet] Implement viviself for PAST::Var scope attribute.
22:58 dalek 6model: review: https://github.com/jnthn/6model/commit/40db9314bd
22:58 TimToady so we see that, in theory, we can avoid the eval above with a sufficiently advanced parser interface
22:59 * sorear hasn't figured out how to make BEGIN work sanely with a precompiler
22:59 TimToady likewise, suffiently advanced declarative magic prevents the need for most BEGINs
22:59 masak any sufficiently advanced parser interface is indistinguishable from Perl 6 :)
22:59 sorear if I'm running user code at compile time, I need to account for the possibility of module B changing module A's serialized data
22:59 TimToady just so
23:00 TimToady well, I've gotta decommute from SoCal now
23:00 jnthn sorear: That one worries me a lot too.
23:00 jnthn sorear: Before long, we've had to write an object version control system. :)
23:00 sorear or what if I load module B at runtime, but the main program has made significant changes to module A's serialized data and it no longer matches what B was linked against?
23:01 TimToady you mean you used MONKEY_TYPING on B?
23:01 TimToady then you get what you deserve
23:01 nrr joined #perl6
23:02 TimToady somewhere it's specced that the meaning of B should not depend on the main program
23:02 sorear more like
23:02 lue can you match pair notation inside a regex?
23:02 sorear module A { our $x = 1; }; module B { $A::x = 2 };
23:02 sorear the precompiler runs the assignments
23:03 sorear now use A; use B; say $A::x;
23:03 TimToady you used globals.  you lose.
23:03 masak lue: you should be able to call the <colonpair> rule from inside a regex, yes.
23:04 jnthn The module body doesn't run at BEGIN time?
23:04 jnthn So that one ain't an issue...
23:04 dalek niecza: 670df6e | sorear++ | / (5 files):
23:04 dalek niecza: Extend primitivization to most scalar operators
23:04 dalek niecza: review: https://github.com/sorear/niecza/commit/670df6e4e9
23:04 TimToady anyway, BEGIN is what it is, and I gotta run
23:04 TimToady well, drive...
23:05 sorear aww I missed you
23:05 TimToady bbl &  # ~7 hours
23:05 sorear oh
23:05 sorear if it's only 7 hours you weren't quite So enough, nm
23:06 sorear \o/ parsed STD.pm6 in 59 seconds
23:07 diakopter wow
23:12 starcoder left #perl6
23:13 Eevee_ is now known as Eevee
23:13 _kaare left #perl6
23:19 starcoder joined #perl6
23:31 masak starcoder: where were you when we released Rakudo Star? :)
23:32 starcoder hehe
23:33 masak blog post! http://strangelyconsistent.org/blog/november-27-2010-urban-planning
23:35 cotto left #perl6
23:38 * masak goes home
23:38 masak left #perl6
23:38 pmeursault left #perl6
23:39 dalek 6model: e3468dd | diakopter++ | common/NQP/P6Objects.pm:
23:39 dalek 6model: [common] fix regression due to jnthn++ 's real fix in Op.repr_defined
23:39 dalek 6model: review: https://github.com/jnthn/6model/commit/e3468ddceb
23:42 robins left #perl6
23:44 robinsmidsrod joined #perl6
23:47 robinsmidsrod left #perl6
23:48 robinsmidsrod joined #perl6
23:52 diakopter jnthn++ writing the tests that make my brain boil to think about writing
23:52 TypeNameHere____ joined #perl6
23:53 dalek 6model: b2c6bf9 | jonathan++ | dotnet/runtime/Runtime/Ops/Metamodel.cs:
23:53 dalek 6model: [dotnet] Simply repr_defined now that we have attr viviself and needn't work around NREs.
23:53 dalek 6model: review: https://github.com/jnthn/6model/commit/b2c6bf9b2b
23:53 dalek 6model: 0094141 | jonathan++ | t/nqp/57-attributes.t:
23:53 dalek 6model: [t] Add test to cover attribute auto-viv.
23:53 dalek 6model: review: https://github.com/jnthn/6model/commit/0094141445
23:53 dalek 6model: 7bbf3f8 | jonathan++ | t/nqp/45-smartmatch.t:
23:53 dalek 6model: [t] Add a muchly simplified version of 45-smartmatch.t. It's enough to make sure that I don't break the regex impl as it stands so far again, hopefully. :)
23:53 dalek 6model: review: https://github.com/jnthn/6model/commit/7bbf3f808d
23:55 sorear what exactly is viviself?
23:56 jnthn sorear: It's an attribute on PAST::Var nodes that says what to do if the thing the lookup produces is null
23:56 diakopter while compiling, a way to track what sigil...yeah
23:58 sorear you can't use defined-or for that/
23:58 diakopter but that's what it's compiling.. the way to test definedness
23:58 jnthn null = should never leak into userland
23:59 jnthn defined-or tests .defined
23:59 jnthn Well
23:59 jnthn sometimes we use repr_defiend directly but...
23:59 jnthn ...that unless overridden boils down to repr_defined

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

Perl 6 | Reference Documentation | Rakudo