»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'perl6: say 3;' or rakudo:, niecza:, std:, or /msg p6eval perl6: ... | irclog: irc.perl6.org/ | UTF-8 is our friend! Set by sorear on 4 February 2011. |
|||
00:11
donri left
|
|||
colomon | sorear: is there any easy / good way to define constants in C#? My code would be a lot cleaner if I had constants for pi and i | 00:31 | |
sorear | colomon: public static readonly Complex i = ...; | 00:35 | |
and Math.PI | |||
colomon | .PI, not .Pi? | ||
sorear | correct, PI | ||
colomon gives C# designers a dirty look | 00:36 | ||
sorear++ | |||
jnthn | Well, it's not mandated by the language. But the C# cultural convention is that CONSTANTS SHOULD BE SHOUTED OUT LOUD. | ||
:) | |||
sorear | yeah. I find int.MaxValue to be much wronger than Math.PI | 00:37 | |
jnthn | heh, what, you want consistency too? :) | ||
oh what, how's it this late...and I should actually get up to work in the morning... | 00:38 | ||
sleep & | 00:41 | ||
colomon | jnthn: o/ | ||
oooo, autopromotes Int to Double. handy | 00:45 | ||
sorear | yeah C-family languages do that as a rule | ||
colomon | I still don't quite have a feel for when C# is slick like that and when it is clunky. and I tend to expect clunky. | 00:47 | |
00:51
gbacon joined,
Chillance left
00:54
am0c joined,
whiteknight left
|
|||
colomon | btw, the other thing that keeps killing me is I don't want to use () after method calls with no arguments. :) | 01:11 | |
sorear | Heh | ||
01:23
am0c left
01:24
am0c joined
01:31
am0c left,
am0c joined
|
|||
[Coke] | tchrist-- # general (#&$ery on p5p. | 01:34 | |
dalek | ast: ca8ada6 | Coke++ | S (4 files): rakudo nom fudging. |
01:36 | |
kudo/nom: 35ec9c7 | Coke++ | t/spectest.data: track failures, run fudged tests. |
01:37 | ||
sorear | [Coke]: wah? | 01:41 | |
01:49
wamba left
|
|||
colomon | oh, shoot. C#'s Math doesn't have all the trig functions. | 01:49 | |
that makes the super-simple version I had in mind not work. | 01:50 | ||
01:58
orafu left,
orafu joined
02:00
abercrombie joined
|
|||
colomon does not enjoy hand correcting his autogenerated code. | 02:03 | ||
dalek | ecza/serialize: b62a6bb | sorear++ | / (5 files): checkpoint 1 of executable code in new model |
02:06 | |
02:10
bluescreen10 joined
02:12
miguet left
02:17
s_mosher joined
|
|||
colomon | sorear: got all the non-hyperbolic trig functions (except atan2) passing all spectests. but I need to reformulate the code generation a bit, and I want to check with the suggested implementation of the complex functions anyway. still, nice progress tonight. | 02:17 | |
s_mosher | hey sorear, I want to express appreciation for the CLR integration work you've been doing lately with Niecza | 02:19 | |
sorear | colomon++ # excellent | 02:24 | |
s_mosher: Thank you! I need to know that I'm doing useful things sometimes :) | |||
02:40
gbacon left
02:41
daniel-s joined
|
|||
s_mosher | sorear, for sure. I think it's a great strength for Niecza to have. | 02:55 | |
I tend to work with Rakudo mostly, but I'm planning something that will be better suited to Niecza. (It wouldn't be remotely practical with Rakudo today.) | 02:57 | ||
out for now | 03:05 | ||
03:05
s_mosher left
|
|||
colomon | afk # bed | 03:06 | |
03:06
wolfman2000 joined
03:24
Reaganomicon left
03:49
envi_laptop joined
03:59
masonkramer left
04:01
packetknife joined
04:03
packetknife left,
abercrombie left
04:10
[particle]1 left
04:14
birdwindupbird joined,
satyavvd joined
04:18
REPLeffect joined
04:21
tokuhiro_ left
04:24
jamtech left
04:29
tokuhiro_ joined,
woosley joined
04:31
araujo left
|
|||
moritz | good morning | 04:32 | |
woosley | good *, #perl6 | 04:49 | |
04:51
uasi joined
05:03
soh_cah_toa left
05:04
mberends left
05:05
kaleem joined
05:10
JimmyZ joined
|
|||
sorear | hello moritz | 05:20 | |
05:27
koban` joined,
koban` left
05:30
mberends joined
05:31
uasi left
|
|||
dalek | ast: e2676ba | jamesrom++ | README: Typo. |
05:33 | |
ast: f3dfe0e | moritz++ | README: Merge pull request #6 from jamesrom/patch-1 Typo. |
|||
05:45
am0c left,
_jaldhar left
05:52
JimmyZ left
05:53
wtw joined
05:55
mberends left
06:00
packetknife joined
06:08
orafu left
06:10
orafu joined
06:11
REPLeffect left
06:12
wamba joined
06:13
mberends joined
06:25
REPLeffect joined
06:27
SHODAN joined,
mberends left
06:45
static_perl left
06:47
agentzh joined
06:49
fridim_ left
|
|||
agentzh | hi, can nqp compile source files to pbc/pir files that can be run by parrot later directly? | 06:50 | |
sorear | yes | 06:52 | |
this is in fact how nqp works | |||
moritz | agentzh: yes, that's how the bootstrap works | ||
agentzh | moritz: any doc on the command line syntax? | ||
06:53
dayangkun joined,
mishin joined
|
|||
moritz | agentzh: dunno about docs, but --target=pir -o out.pir is what you need | 06:53 | |
agentzh | moritz: cool, thanks! i'll try it out :) | ||
moritz | and then parrot -o out.pbc out.pir | ||
there are plenty of examples in the Makefile | 06:54 | ||
agentzh | moritz: cool, it works, though not making things faster ;) | 06:55 | |
06:56
uasi joined
|
|||
agentzh | moritz: i'll read Makefile in detail, thanks :) | 06:57 | |
Woodi | do copy of rakudo/src/core/* to dir in PERL6LIB just work ? | ||
06:58
mj41 joined
|
|||
Woodi | hmm, or it is consider builtin ? | 06:58 | |
*considered | 06:59 | ||
06:59
drbean left
|
|||
sorear | bad idea | 07:00 | |
the stuff in src/core/* isn't Perl modules | |||
they're setting fragments | |||
subtly differen | |||
Woodi | problem is IO::Select::INET do not work for me and it is in core... | 07:01 | |
so how to use i-s-i ? | 07:02 | ||
debian-rakudo here | |||
sorear | don't use it | 07:04 | |
just access it | |||
b: say IO::Socket::INET.^methods | 07:05 | ||
p6eval | b 1b7dd1: OUTPUT«newexceptionperlmaybefailBooldefinedStrNumIntcanisadoeslistACCEPTSStrNumericSeqallanyonenonejoinelemsflatmapsortrotatefirstgrepreverseendminmaxminmaxpickrollclassifyreduceuniqkvkeysvaluespairspostcircumfix:<[ ]>at_pospostcircumfix:<{ }>at_keyclonedefineditemblessBUILDBU… | ||
sorear | and it's spelled Socket, not Select | ||
Woodi | ah :) | ||
right | |||
thanks sorear | |||
sorear sleep | 07:07 | ||
07:14
dayangkun_ joined
07:17
dayangkun left
07:19
lumi_ left
07:22
araujo joined,
araujo left,
araujo joined
07:32
woosley left,
woosley joined,
woosley left
|
|||
ingy | plobsing: a pegex parser applies a compiled pegex grammar to an input stream, and then calls a method in a "receiver" class for every matched subrule. the default receiver returns a hash that looks like {subrule_name => [terminals]} | 07:42 | |
plobsing: so... both :) | |||
plobsing: by having your action methods in a receiver class (instead of inside the grammar rules themselves) you can use the same grammar against many differnt receivers | 07:44 | ||
moritz | it's the same concept as the 'actions' in Perl 6 grammars | 07:45 | |
and so far I haven't seen a single grammar with more than one actions class/receiver | 07:46 | ||
ingy | moritz: well I can easily imagine it :) | ||
say you have a yaml grammar for instance | |||
moritz | ingy: it's not a problem of imagination :-) | 07:47 | |
ingy: I can think of many cases too, I just said that I've never encountered such a case in the wild | |||
ingy | then everyone who wants to work with yaml in any special way will simply define a receiving class | ||
moritz | since the structure of captures is a result of the implementation, it basically becomes part of the grammar's API | 07:48 | |
so it becomes hard to change a grammar later on, while retaining the structure of the captures | |||
07:48
wamba left
|
|||
ingy | noted | 07:49 | |
moritz | that's kinda obvious, but it's less obvious if there's a good solution to that | 07:51 | |
p6's capture aliasing makes it possible (but still hard) to maintain the structure | |||
ingy | i'm spending a lot of time trying to make my default structures as clean as possible, and adding a few simple syntax hints to pegex | 07:54 | |
i'm spending a lot of time trying to make my default structures as clean as possible, and adding a few simple syntax hints to pegex to make the structures cleaner | 07:55 | ||
so that the receiving classes can be minimal | |||
tadzik | good morning | ||
ingy | o/ | ||
07:56
daxim joined
|
|||
ingy | moritz: gist.github.com/1226129 | 07:56 | |
pester pester... :) | 07:57 | ||
moritz | ingy: I too find that I don't often use <a> ** <b> | 07:59 | |
ingy: it's occasionally useful though | 08:01 | ||
08:01
packetknife left
|
|||
ingy | moritz: I'll write up a list of variations of that that I would like to handle nicely and maybe you can help me find a reasonable syntax | 08:03 | |
moritz | ingy: ok | ||
ingy | moritz: I need a**b because that can return a list of [a+] whereas a [b a]* has to return a form of [a,[a*]] and that just cascades into complexity | 08:05 | |
moritz | ingy: why can't multiple captures of the same name simply return a list? | 08:06 | |
mishin | what is latest release racudo ro windows? | ||
08:06
uasi left
|
|||
ingy | a: b? c b+ | 08:07 | |
moritz | mishin: rakudo has source releases which you can compile on windows too | ||
ingy | I think combining the b's in that case is not what you want | ||
moritz | mishin: I think the last winidows binary was 2011.04 or so | 08:08 | |
ingy: hm, right. Perl 6 solves that by allowing you to write (b?) c b+ or (b)? c b+ | |||
ingy | I want pegex rules to follow very obvious, er, rules | ||
mishin | thanks is it planned to compile new release? | ||
moritz | somebody does that occasinally. | 08:09 | |
mishin: you could do it too | |||
and share the result with the community | |||
ingy | moritz: bbl | ||
08:14
dayangkun__ joined
|
|||
mishin | @motitz: Good idea, it is necessary to understand only how it to make and that to me it is necessary for this purpose | 08:14 | |
08:18
dayangkun_ left
08:21
lumi_ joined
|
|||
jnthn | monring o/ | 08:25 | |
moritz | \o jnthn | 08:26 | |
jnthn | +# S32-temporal/DateTime-Instant-Duration.t # err: Method 'eval' not found for invocant of class 'Str' | ||
Well, that looks like lhf. ;) | 08:27 | ||
[Coke]++ # tracking failure modes | |||
08:28
agentzh left
08:29
daniel-s left,
daniel-s joined
|
|||
ingy | moritz: one thing to mention is that pegex grammars always assume '^ ...grammar... $', (since Pegex is intended to be a parser, not a regex replacement) | 08:34 | |
I only thought of that because I was just considering adding a parser option to not enforce the $ to do a partial parse :) | 08:36 | ||
08:38
Trashlord joined
|
|||
moritz | ingy: makes sense | 08:40 | |
dalek | Heuristic branch merge: pushed 484 commits to rakudo/nom-exceptions by moritz | ||
moritz | oops, accidnetally pushed to the wrong branch :-) | ||
dalek | kudo: d7f45ff | moritz++ | src/core/Cool.pm: Cool.eval |
08:41 | |
08:46
odoacre_ joined
08:55
dayangkun__ left
08:56
dayangkun__ joined,
dayangkun__ left
08:58
replore left,
REPLeffect left,
REPLeffect joined
08:59
PZt left
09:04
woosley1 joined
09:06
am0c joined
09:07
kaleem left,
kaleem joined
09:08
replore joined
09:13
drbean joined
09:17
am0c left
09:18
am0c joined,
PZt joined
09:20
uasi joined
|
|||
moritz | nom: say now.perl.eval | 09:32 | |
p6eval | nom 35ec9c: OUTPUT«Method 'eval' not found for invocant of class 'Str' in <anon> at /tmp/seKsoO4hPv:1 in <anon> at /tmp/seKsoO4hPv:1» | ||
moritz | evalbot rebuild nom | ||
p6eval | OK (started asynchronously) | ||
09:32
tokuhiro_ left
09:39
wamba joined
09:46
am0c left
|
|||
Woodi | perl6: class A { has $.b = 10; }; sub foo() { say self.b }; my $b = A.new; $b.foo() | 09:46 | |
p6eval | niecza v9-32-g380d891: OUTPUT«===SORRY!==='self' used where no object is available at /tmp/FpMaFHP0Pk line 1:------> { has $.b = 10; }; sub foo() { say self⏏.b }; my $b = A.new; $b.foo()Potential difficulties: &foo is declared but not used a… | ||
..rakudo 35ec9c: OUTPUT«===SORRY!===Symbol 'self' not predeclared in foo (/tmp/F3btE1vtBR:1)» | |||
..pugs: OUTPUT«*** No compatible multi variant found: "&foo" at /tmp/cS5G0ZtE0I line 1, column 70 - line 2, column 1» | |||
Woodi | pls someone tell me how to call method in perl6 | 09:47 | |
imho DWIM is heavy broken in perl6 | |||
moritz | Woodi: well, it works just fine if you actually write a method, not a sub | 09:48 | |
arnsholt | nom: class A { hsa $.b = 10; method foo() { say self.b; }; }; my $a = A.new; $a.foo | ||
Woodi | perl6: class A { has $.b = 10; }; method foo() { say self.b }; my $b = A.new; $b.foo() | ||
p6eval | nom 35ec9c: OUTPUT«Null PMC access in find_method('b') in <anon> at /tmp/sCgQyi8yuW:1 in <anon> at /tmp/sCgQyi8yuW:1 in <anon> at /tmp/sCgQyi8yuW:1» | ||
rakudo 35ec9c: OUTPUT«Useless declaration of a has-scoped method in mainlineMethod 'foo' not found for invocant of class 'A' in <anon> at /tmp/FW3IOJlmdA:1 in <anon> at /tmp/FW3IOJlmdA:1» | |||
..niecza v9-32-g380d891: OUTPUT«===SORRY!===Methods must be used in some kind of package at /tmp/hyx7Uu5g5b line 1:------> class A { has $.b = 10; }; method foo⏏() { say self.b }; my $b = A.new; $b.foPotential difficulties: 'method' declaration… | |||
..pugs: OUTPUT«10» | |||
moritz | Woodi: you can't expect a programming language to do what you mean if it contradicts with what you tell it. | ||
arnsholt | Or something. My Perl 6 is a bit rusty | 09:49 | |
09:49
am0c joined
|
|||
arnsholt | At any rate, as moritz says, you need to place the method declaration inside the class | 09:49 | |
moritz | arnsholt: probably works if you spell 'has' correctly :-) | ||
arnsholt | Ooooooh, right. That might help =D | ||
Woodi | moritz: DWIM usually allow to say what i mean and language gueses right :) | ||
arnsholt | nom: class A { has $.b = 10; method foo() { say self.b; }; }; my $a = A.new; $a.foo # Once more, with feeling | ||
p6eval | nom 35ec9c: OUTPUT«10» | 09:50 | |
arnsholt | There we go. | ||
moritz | arnsholt++ # with feeling | ||
09:50
envi_|2 joined
|
|||
Woodi | ah | 09:50 | |
arnsholt | Woodi: But that'll explode messily when you have class A {}; class B {} | ||
09:51
envi_laptop left
|
|||
arnsholt | It's the kind of dwimmery that'll only come back and bite you because figuring it out properly is an AI-complete problem (or close enough) | 09:51 | |
moritz | DWIM must be applied con spirito, ma non troppo :-) | ||
Woodi | i just know how to write 'espresso' and 'cappucino' :) | ||
perl6: class A { has $.b = 10; }; method foo() { say self.b; }; my $b = A.new; $b.foo() | 09:53 | ||
p6eval | rakudo 35ec9c: OUTPUT«Useless declaration of a has-scoped method in mainlineMethod 'foo' not found for invocant of class 'A' in <anon> at /tmp/ar6dwzEOi9:1 in <anon> at /tmp/ar6dwzEOi9:1» | ||
..pugs: OUTPUT«10» | |||
..niecza v9-32-g380d891: OUTPUT«===SORRY!===Methods must be used in some kind of package at /tmp/rVGT1p0wCF line 1:------> class A { has $.b = 10; }; method foo⏏() { say self.b; }; my $b = A.new; $b.fPotential difficulties: 'method' declaration… | |||
09:53
JimmyZ joined
|
|||
Woodi | perl6: class A { has $.b = 10; }; sub foo($self) { say $self.b }; my $b = A.new; $b.&foo | 09:54 | |
p6eval | pugs, rakudo 35ec9c, niecza v9-32-g380d891: OUTPUT«10» | ||
moritz | Woodi: if the method is meant to go into the clas, write it inside the class | ||
Woodi | but why it working | ||
*is is *? | 09:55 | ||
goot that works but strange | |||
perl6: class A { has $.b = 10; }; method foo($self) { say $self.b }; }; my $b = A.new; $b.foo | 09:56 | ||
moritz | because methods and subs are really just the same thing, they are just being searched for in different ways | ||
p6eval | pugs: OUTPUT«***  Unexpected "};" expecting ";", identifier, Doc block, block declaration, declaration, construct or expression at /tmp/GjmwrntSVA line 1, column 64» | ||
..rakudo 35ec9c: OUTPUT«Useless declaration of a has-scoped method in mainline===SORRY!===Confused at line 1, near "}; my $b "» | |||
..niecza v9-32-g380d891: OUTPUT«===SORRY!===Methods must be used in some kind of package at /tmp/KpfJuDuNfV line 1:------> class A { has $.b = 10; }; method foo⏏($self) { say $self.b }; }; my $b = A.nUnexpected closing bracket at /tmp/KpfJuDuNfV… | |||
arnsholt | That's the monkey patching approach, essentially. Put the method declaration -inside- the braces of the class, and you can drop the .& syntax | ||
Woodi | perl6: class A { has $!b = 10; }; method foo() { say self.b }; }; my $b = A.new; $b.foo | ||
jnthn | The syntax you're looking for is "my method foo ..." then "$b.&foo" | ||
p6eval | rakudo 35ec9c: OUTPUT«Useless declaration of a has-scoped method in mainline===SORRY!===Confused at line 1, near "}; my $b "» | ||
..niecza v9-32-g380d891: OUTPUT«===SORRY!===Methods must be used in some kind of package at /tmp/9eKhcynh6Z line 1:------> class A { has $!b = 10; }; method foo⏏() { say self.b }; }; my $b = A.new; $bUnexpected closing bracket at /tmp/9eKhcynh6Z… | |||
..pugs: OUTPUT«***  Unexpected "};" expecting ";", identifier, Doc block, block declaration, declaration, construct or expression at /tmp/p8QqoC2JdS line 1, column 58» | |||
moritz | perl6: class A { has $.b = 10 }; my method foo() { self.b }; say A.new.&foo | 09:57 | |
p6eval | niecza v9-32-g380d891: OUTPUT«===SORRY!===Methods must be used in some kind of package at /tmp/2pLDg_kLPp line 1:------> class A { has $.b = 10 }; my method foo⏏() { self.b }; say A.new.&fooUnhandled exception: Check failed at /home/p6eval/ni… | ||
..pugs, rakudo 35ec9c: OUTPUT«10» | |||
JimmyZ | moritz: there are not same if /$.b/$!b/ | ||
Woodi | perl6: class A { has $!b = 10; method foo() { say self.b }; }; my $b = A.new; $b.foo | ||
p6eval | pugs: OUTPUT«*** No such method in class A: "&b" at /tmp/WtRi0z4m_h line 1, column 45-52» | ||
..niecza v9-32-g380d891: OUTPUT«Unhandled exception: Unable to resolve method b in class A at /tmp/Nf0AdwQpJj line 1 (MAIN A.foo @ 2)  at /tmp/Nf0AdwQpJj line 1 (MAIN mainline @ 3)  at /home/p6eval/niecza/lib/CORE.setting line 2060 (CORE C968_ANON @ 2)  at /home/p6eval/niecza/lib/… | |||
..rakudo 35ec9c: OUTPUT«Method 'b' not found for invocant of class 'A' in method foo at /tmp/XDwEmaEC3W:1 in <anon> at /tmp/XDwEmaEC3W:1 in <anon> at /tmp/XDwEmaEC3W:1» | |||
moritz | JimmyZ: right, but that's more of a difference in the compilation context than in the generated code object | ||
09:58
am0c left
|
|||
Woodi | perl6: class A { has $!b = 10; method foo() { say self!b }; } my $b = A.new; $b.foo | 09:58 | |
p6eval | niecza v9-32-g380d891: OUTPUT«===SORRY!===Strange text after block (missing comma, semicolon, comment marker?) at /tmp/7D5IP8Gk3q line 1:------> !b = 10; method foo() { say self!b }; }⏏ my $b = A.new; $b.fooParse failed» | ||
..rakudo 35ec9c: OUTPUT«===SORRY!===Confused at line 1, near "class A { "» | |||
..pugs: OUTPUT«10» | |||
moritz | need a ; after the } that closes the class | ||
or a newline | |||
Woodi | perl6: class A { has $!b = 10; method foo() { say self!b }; }; my $b = A.new; $b.foo | 09:59 | |
p6eval | rakudo 35ec9c: OUTPUT«Method 'postcircumfix:<( )>' not found for invocant of class 'Mu' in <anon> at src/gen/Metamodel.pm:3029 in method dispatch:<!> at src/gen/CORE.setting:644 in method dispatch:<!> at src/gen/CORE.setting:656 in method foo at /tmp/ak6_fPNeDy:1 in <anon> at … | ||
..pugs, niecza v9-32-g380d891: OUTPUT«10» | |||
Woodi | perl6: class A { has $!b = 10; method foo() { say self.b }; }; my $b = A.new; $b.foo; | ||
p6eval | rakudo 35ec9c: OUTPUT«Method 'b' not found for invocant of class 'A' in method foo at /tmp/Q7JQMfJEvA:1 in <anon> at /tmp/Q7JQMfJEvA:1 in <anon> at /tmp/Q7JQMfJEvA:1» | ||
..pugs: OUTPUT«*** No such method in class A: "&b" at /tmp/E2Bt12eIfM line 1, column 45-52» | |||
..niecza v9-32-g380d891: OUTPUT«Unhandled exception: Unable to resolve method b in class A at /tmp/UmTG8luWKq line 1 (MAIN A.foo @ 2)  at /tmp/UmTG8luWKq line 1 (MAIN mainline @ 3)  at /home/p6eval/niecza/lib/CORE.setting line 2060 (CORE C968_ANON @ 2)  at /home/p6eval/niecza/lib/… | |||
Woodi | perl6: class A { has $!b = 10; method foo() { say $b }; }; my $b = A.new; $b.foo; | ||
p6eval | pugs: OUTPUT«***  Unexpected " };" expecting "::" Variable "$b" requires predeclaration or explicit package name at /tmp/YEGH9P9njR line 1, column 47» | 10:00 | |
..niecza v9-32-g380d891: OUTPUT«===SORRY!===Variable $b is not predeclared at /tmp/TcEO80zcIS line 1:------> s A { has $!b = 10; method foo() { say ⏏$b }; }; my $b = A.new; $b.foo;Unhandled exception: Check failed at /home/p6eval/niecza/boot/… | |||
..rakudo 35ec9c: OUTPUT«A<70099768>» | |||
Woodi | i give up :) | ||
JimmyZ | rakudo: class A { has $!b = 10; method foo() { say self!b }; }; my $b = A.new; $b.foo # I think it's a bug | ||
p6eval | rakudo 35ec9c: OUTPUT«Method 'postcircumfix:<( )>' not found for invocant of class 'Mu' in <anon> at src/gen/Metamodel.pm:3029 in method dispatch:<!> at src/gen/CORE.setting:644 in method dispatch:<!> at src/gen/CORE.setting:656 in method foo at /tmp/FherJzZ4W9:1 in <anon> at … | ||
moritz | Woodi: I recommend reading the chapter on objects and classes in github.com/downloads/perl6/book/2011.07.a4.pdf | ||
Woodi: and perlcabal.org/syn/S12.html if you want the gory details :-) | |||
JimmyZ | LTA bug? | ||
10:01
wamba left
|
|||
Woodi | must be book, S12 not contain any use of class... | 10:01 | |
moritz | huh? | ||
Woodi | any small-complete-example | ||
10:01
woosley1 left
|
|||
moritz | JimmyZ: should probably read 'Cannot find private method b in class A' or so | 10:01 | |
JimmyZ | b: class A { has $.b = 10; method foo() { say self.b }; }; my $b = A.new; $b.foo | 10:02 | |
p6eval | b 1b7dd1: OUTPUT«10» | ||
JimmyZ | b: class A { has $!b = 10; method foo() { say self!b }; }; my $b = A.new; $b.foo | ||
p6eval | b 1b7dd1: OUTPUT«Method '!b' not found for invocant of class 'A' in 'A::foo' at line 22:/tmp/kH2gKWVHoK in main program body at line 22:/tmp/kH2gKWVHoK» | ||
JimmyZ | b++ ;) | ||
moritz | beijing++ indeed :-) | ||
JimmyZ submits LTA bug | 10:03 | ||
moritz | JimmyZ++ | ||
JimmyZ | speak of bug, rt didn't proctect email address | 10:06 | |
10:06
JimmyZ left
|
|||
moritz | JimmyZ: are you logged in? | 10:06 | |
10:06
JimmyZ joined
|
|||
JimmyZ | moritz: no | 10:07 | |
moritz | hm | ||
well, in the end a copy goes to [email@hidden.address] and that doesn't protect the email either | |||
or maybe not well | |||
but that's how mailing lists work | |||
JimmyZ would like to protect emails | 10:08 | ||
szabgab | hi, can anyone help me with the rakudo compilation on windows? | 10:09 | |
10:09
arthur-_ left
|
|||
szabgab | I sent the failure to perl6-users yesterday but no reaction so far | 10:09 | |
it starts by complaining that nqp.exe cannot be found and ends by a windows pop-up | 10:10 | ||
moritz | what does the windows popup say? | 10:11 | |
.\nqp.exe --target=pir --output=src\stage2\QRegex.pir src\stage2\QRegex.nqp | |||
gmake: *** [QRegex.pbc] Error -1073741515 | |||
that doesn't look good :( | |||
ah right, I see it in your email | 10:12 | ||
szabgab: is there a libparrot.dll somehwere in the install/ dir? | |||
szabgab | nope | 10:13 | |
arnsholt | szabgab: Win64 or win32? | ||
szabgab | 64 | ||
but I think strawberry is 32 bit | |||
arnsholt | Right. I think jnthn was wrangling some parrot-related problems on win64 the other day | ||
Might be something similar you're running into | |||
moritz | szabgab: or in the parrot/ folder maybe? | 10:14 | |
szabgab | yes I have parrot\libparrot.dll | ||
10:14
arthur-_ joined
|
|||
moritz | szabgab: maybe try copying that to install\bin\ | 10:15 | |
szabgab | www.nntp.perl.org/group/perl.perl6....g1540.html | ||
moritz | it seems that -shared | 10:16 | |
"C:\work\rakudo\install\bin\libparrot.dll" | |||
appears in the makefile | |||
so the build system expects it to be there | |||
JimmyZ | rm it | ||
szabgab | moritz: after copying libparrot.dll and running again perl Configure.pl --gen-parrot I get the same crash | 10:17 | |
10:17
wamba joined
|
|||
szabgab | oh in bin | 10:17 | |
jnthn | Note that for some reason we don't always end up with libparrot.dll getting copied into the right place... | 10:18 | |
szabgab | there is install\bin\libparrot.dll | ||
jnthn | I dunno why... | ||
szabgab | and still crashes | ||
JimmyZ | rm all libparrot.dll s | ||
jnthn | Yeah. If you run Rakudo from build directory it wants libparrot.dll in that directory too | ||
Not a problem after make install, afaik. | 10:19 | ||
I thougth the makefile had a line to copy it into the right place...will have to take a look and see what came of it. | |||
szabgab | I removed the whole install directory and started again | 10:21 | |
running perl Configure.pl --gen-parrot | |||
adn I get the crash, should I run some make install now? | 10:27 | ||
moritz | won't do any good until nqp is properly build and installed | 10:28 | |
szabgab: what you could try: copy libparrot.dll into the nqp/ folder | |||
jnthn | When is it failing | ||
? | |||
szabgab | www.nntp.perl.org/group/perl.perl6....g1540.html <- jnthn | ||
moritz | szabgab: and then in that folder, run 'gmake install' | 10:29 | |
jnthn | OK, try what moritz++ suggested | ||
ah, I think we never needed to do that in NQP before QRegex came along; it invokes nqp.exe. We didn't tend to invoke it during nqp build before. | |||
szabgab | so copy from install\bin\libparrot.dll to nqp\ ? | ||
jnthn | szabgab: yes | 10:30 | |
szabgab | cd nqp; gmake install | ||
moritz | right | ||
szabgab | done | ||
and now? | 10:31 | ||
moritz | did it work? | ||
szabgab | it seems so | ||
moritz | cd .. # back to rakudo | ||
perl Configure.pl # without options | |||
gmake | |||
# and wait.... | |||
szabgab | waiting :) | ||
same popup crash | 10:33 | ||
different output on console | |||
gmake: *** [CORE.setting.pbc] Error -1073741515 | |||
moritz | then also copy libparrot.dll into the rakudo dir | ||
szabgab | copy install\bin\libparrot.dll . | 10:34 | |
gmake | |||
jnthn suspects we should just get Configure.pl to do this copying. | |||
szabgab | let's see if the copying helps at all :) | 10:35 | |
jnthn | *nod* | 10:36 | |
I see you're building against Strawberry too, which I haven't tried. If it's got this far it's likely to work out though. | 10:37 | ||
szabgab | ok, gmake worked | ||
what now? | |||
gmake test | 10:38 | ||
t\02-embed\01-load.t failed | |||
ok, I have perl6.exe and it works when I am in the rakudo dir | 10:40 | ||
after running gmake install it also works outside | |||
thanks for your help | |||
now trying gmake spectest | 10:41 | ||
jnthn | Great. I'll try and patch the Configure.pls this evening. | ||
szabgab | I see some of the tests in the spec are failing | 10:43 | |
is there a way I can easily report them? | |||
10:44
odoacre_ left,
odoacre left
|
|||
szabgab | or should I wait with that till thing get stable | 10:44 | |
? | |||
10:45
odoacre joined
|
|||
jnthn | szabgab: I'd be interesting to know what fails. | 10:45 | |
I've been getting clean test runs here of late. | 10:46 | ||
(Win64/MSVC) | |||
szabgab | t\spec\S02-literals\radix.rakudo .......................... Failed 3/131 subtests | ||
t\spec\S02-magicals\args.t ................................ Failed 1/4 subtests | |||
so far | |||
jnthn | Are you on 32 bit or 64? | 10:47 | |
szabgab | 64 bit machine | ||
Win7 | |||
but strawberry is 32 I think | 10:48 | ||
10:50
wamba left
|
|||
jnthn | ah, then you've probably got a 32-bit build | 10:50 | |
We have some issues on 32 bit at the moment. | |||
szabgab | ok, I won't have much time to play with rakudo anyway, just wanted to make sure I can at least compile it :) | 10:54 | |
jnthn: it seems to be stuck on t\spec\S02-types\instants-and-durations.t ................. | 11:02 | ||
11:02
breinbaa1 left
|
|||
jnthn | szabgab: Yeah, that's one of the 32-bit issues ;( | 11:03 | |
:( | |||
szabgab | ok | ||
11:03
breinbaas joined
11:11
wamba joined
11:12
mishin left
|
|||
snarkyboojum | "stuck on an instant" - that's kinda deep | 11:13 | |
jnthn | It gets stuck in an instant, for a long duration :P | 11:15 | |
11:27
donri joined
11:37
Patterner left
11:39
wamba left
11:40
JimmyZ left
11:41
Psyche^ joined,
Psyche^ is now known as Patterner
11:44
geekosaur joined
11:47
jql joined
|
|||
Woodi | perl6: class A { has $!b = 10; method foo() { say $!b }; }; my $b = A.new; $b.foo; | 11:48 | |
p6eval | pugs, rakudo 35ec9c, niecza v9-32-g380d891: OUTPUT«10» | ||
Woodi | tada :) | ||
do IO::Socket::INET defaults to TCP ? | 11:51 | ||
moritz | I don't think anything else is implemented | 11:53 | |
Woodi | looks like it depends on parrot implementation | 11:55 | |
ingy | moritz: can action method return values change whether the match that invoked them is then considered a match? | 11:56 | |
moritz | ingy: no | 11:57 | |
that's what assertions are for. | |||
ingy | moritz: good :) | 11:58 | |
I don't want to do it, but I thought maybe I was missing something important | 11:59 | ||
and I already have assertions | |||
=<foo> !<bar> <foo> | |||
12:01
_jaldhar joined
|
|||
ingy | if an action return() the that branch is pruned, if return(undef) then the branch becomes the scalar (undef) | 12:02 | |
moritz | letting actions influence the parse goes against the whole concept of separating actions and parsing | ||
ingy | moritz: right | 12:03 | |
very good point | |||
jnthn | Plus the action methods never return anything of interest. | ||
They always "make". | |||
moritz | right, in p6 they make() stuff | ||
not sure I like that part | |||
ingy | jnthn: that's not the case in pegex | ||
tadzik | yeah, I got stuck on that a few times | 12:04 | |
it feels weird, it's a normal method, but it doesn't return | |||
ingy | they are allowed to make stuff, but actually returning stuff looks like the better way out | ||
moritz | hey, I just got a nice idea | 12:05 | |
12:05
satyavvd left
|
|||
moritz | one can use signature unpacking on $/ in action methods | 12:05 | |
jnthn | ooh! | ||
tadzik | woo | ||
ingy | each rule makes something by default, but an action method can change that | 12:06 | |
moritz | method foo( $/ (:$bar, :$baz) ) { no need for $<bar> or $<baz> here ... } | ||
tadzik | looks magic | ||
moritz | does signature unpacking work in nom already? | 12:07 | |
ingy | bbl :P | ||
Woodi | perl6: class A { has $!b = 10; method foo() { say $!b.perl }; }; my $b = A.new; $b.foo; | 12:10 | |
p6eval | pugs: OUTPUT«\10» | ||
..rakudo 35ec9c, niecza v9-32-g380d891: OUTPUT«10» | |||
12:10
mtk joined
|
|||
jnthn | moritz: yes | 12:14 | |
moritz | oh, but it doesn't do action methods yet :( | 12:16 | |
12:20
colomon left
12:31
packetknife joined
12:32
benabik left,
JimmyZ joined
|
|||
JimmyZ | nom: sub foo($/) { say "$<hi>, $<world>"; }; foo({ 'hi'=>'hello', 'world'=>'#perl6'}); #like this? | 12:34 | |
p6eval | nom 35ec9c: OUTPUT«hello, #perl6» | ||
moritz | no | 12:35 | |
12:35
bluescreen10 left
|
|||
moritz | nom: sub foo($/ (:$hi, :$world)) { say "$hi, $world" }; foo { hi => 'hello', world => '#perl6' } | 12:36 | |
p6eval | nom 35ec9c: OUTPUT«hello, #perl6» | ||
moritz | excpt that I'd pass in a Match object, not a hash | ||
JimmyZ | b: ( -> { say $^hi, $^world; } )('hello', '#perl6'); | 12:40 | |
p6eval | b 1b7dd1: OUTPUT«===SORRY!===Placeholder variable cannot override existing signature at line 22, near " )('hello'"» | ||
JimmyZ couldn''t understand | 12:42 | ||
12:43
woosley joined
|
|||
moritz | -> { is an empty signature | 12:43 | |
JimmyZ | thanks | 12:45 | |
12:48
bluescreen10 joined
12:52
pernatiy joined
12:54
packetknife left
12:56
[particle] joined
|
|||
felher | rakudo: enum Thing ( large => 'l', small => 's') | 12:58 | |
p6eval | rakudo 35ec9c: OUTPUT«===SORRY!===This type cannot unbox to a native integer» | ||
felher | Is that regression known? | ||
moritz didn't know about it | |||
felher++ | |||
jnthn did. | 12:59 | ||
Just not doing non-numeric enums yet. | |||
felher | jnthn: k :) | 13:00 | |
Another thing: | 13:02 | ||
rakudo: say (1 != 1 & 2); say ('a' !eq 'b' & 'c'); # where is the difference? | 13:03 | ||
p6eval | rakudo 35ec9c: OUTPUT«all(False, True)Bool::True» | ||
moritz | b: say (1 != 1 & 2); | 13:05 | |
p6eval | b 1b7dd1: OUTPUT«Bool::True» | ||
moritz | I think that's a nom bug | ||
rakudo: say (1 !== 1 & 2) | |||
p6eval | rakudo 35ec9c: OUTPUT«Bool::True» | ||
felher | moritz: They all should return junctions, shouldn't they? | 13:07 | |
moritz | felher: no, since they are negated operators | 13:08 | |
(which are special-cased) | |||
$a !op $b should be the same as not $a op $b | |||
13:09
kaleem left
|
|||
felher | moritz: oh, okay, i see. So all(1,2) !== 3 is the same as '!all(1,2) == 3'? | 13:09 | |
moritz | minus precedence issues, yes | 13:10 | |
!(all(1,2) == 3) | |||
felher | moritz: yeah, shold be 'not' instead of '!' :) | ||
moritz: thnx :) | |||
13:16
Holy_Cow joined,
packetknife joined,
Holy_Cow left
|
|||
cognominal | nom: eval qq"sub $_ (*\%_ ) \{ elt('$_', |\%_) \}" for < div >; | 13:17 | |
p6eval | nom 35ec9c: OUTPUT«Lexical '$!' not found in sub eval at src/gen/CORE.setting:421 in block <anon> at /tmp/K7bUV8kDof:1 in method reify at src/gen/CORE.setting:3660 in method reify at src/gen/CORE.setting:3565 in method reify at src/gen/CORE.setting:3565 in method gimme at sr… | ||
moritz | nom: say qq"sub $_ (*\%_ ) \{ elt('$_', |\%_) \}" for < div > | 13:18 | |
p6eval | nom 35ec9c: OUTPUT«sub div (*%_ ) { elt('div', |%_) }» | ||
13:18
lumi_ left
|
|||
moritz | nom: eval '1 2'; say $! | 13:18 | |
p6eval | nom 35ec9c: OUTPUT«Confused at line 1, near "1 2"» | ||
13:20
packetknife left
13:21
lumi_ joined
13:33
kaleem joined
13:37
jimmy1980 joined
13:48
jamtech joined
13:53
PacoLinux joined,
uasi left,
wamba joined,
SHODAN left
|
|||
[Coke] | phenny, tell jnthn I have a 32-bit windows 7 box that I've built nom on before using strawberry & visual studio. ping me if you need testing. | 14:00 | |
phenny | [Coke]: I'll pass that on when jnthn is around. | ||
14:02
SHODAN joined
14:06
SHODAN left
14:11
thou joined
14:16
wolfman2000 left
14:17
jimmy1980 left
|
|||
[Coke] yawns. | 14:20 | ||
14:26
skangas__ joined,
skangas left
14:27
wtw left
14:31
kaare_ joined
14:36
uasi joined
14:40
[particle] left
14:42
woosley left
14:45
[particle] joined
14:53
am0c joined
14:55
[particle]1 joined,
[particle] left,
sayu joined
|
|||
moritz hates error messages from pdflatex | 14:56 | ||
they are sometimes quite obscure, and point into completely wrong directions | |||
TimToady | phenny: tell ingy that if your grammar assumes ^ $ you can never use a grammar to parse a portion of a string, such as an embedded block in a different language | 14:57 | |
phenny | TimToady: I'll pass that on when ingy is around. | ||
felher | Whats the easiest way to check if $value is in @array? $value == @array.any? | 14:58 | |
14:58
sivoais joined
|
|||
moritz | yes | 14:59 | |
felher | moritz: thnx :) | ||
14:59
Holy_Cow joined
|
|||
moritz | if $value is a number, and you want to compare numerically, that is :-) | 14:59 | |
14:59
Holy_Cow left
|
|||
felher | moritz: yes, i do :) | 14:59 | |
TimToady | and if you don't want it fast :) | ||
mux | no more grep($value, @array) ? :) | ||
TimToady | you can do that too | 15:00 | |
moritz | well, if you want it fast, and @array is big, you're doing something wrong :-) | ||
TimToady thinks about content addressabe memories... | 15:01 | ||
*able | |||
moritz 's memory is also content addressable | 15:03 | ||
15:06
thou left
|
|||
cognominal | as you get older, you don't loose much content but addressability becomes erratic. | 15:08 | |
sorear | good * #perl6 | ||
cognominal: my addressability has always been erratic... | 15:09 | ||
15:10
pjcj left,
pjcj joined
|
|||
sorear needs a way to have irssi ignore p6eval's niecza-mentions | 15:11 | ||
15:11
daniel-s left
|
|||
moritz | sorear: should p6eval misspell niecza? :-) | 15:11 | |
(I'm not quite serious) | |||
sorear | moritz: hah. No, because then people I care about will start spelling it the same way. :) | 15:12 | |
moritz | perl6: sub digitize($x) { $x.substr(0, 1) ~ ($x.chars - 2) ~ $x.substr(*-1) }; say digitize('niecza') | 15:14 | |
p6eval | rakudo 35ec9c: OUTPUT«No applicable candidates found to dispatch to for 'Numeric'. Available candidates are::(Mu, Mu %_) in method Numeric at src/gen/CORE.setting:560 in sub infix:<<> at src/gen/CORE.setting:1929 in method substr at src/gen/CORE.setting:2636 in sub digitize at… | ||
..pugs: OUTPUT«n4niecza» | |||
..niecza v9-32-g380d891: OUTPUT«n4a» | |||
TimToady | /niecza.[^v]/ or so | 15:15 | |
highlighting goes wonky though | 15:16 | ||
someone needs to rewrite irssi into P6 :) | |||
doubtless there's some way to manage highlighting with a plugin, if you're devious enough | 15:17 | ||
and have nothing better to do... | 15:18 | ||
sorear | anyone here played with smuxi? | 15:23 | |
15:27
y3llow left,
y3llow_ joined,
y3llow_ is now known as y3llow
15:29
am0c left
15:31
am0c joined
15:34
static_perl joined
15:36
mtk left
15:37
am0c left
15:40
am0c joined
|
|||
TimToady | jnthn: the fix for .Bool on // seems to need more help; I get "Cannot assign to non-container" in method Bool, which I presume is trying to set $/ | 15:42 | |
perhaps the // is closing over the wrong $/ somehow | 15:43 | ||
also, some kind of similar fix is needed for //.ACCEPTS | 15:44 | ||
maybe this is pmichaud++ territory | |||
15:44
supernovus joined
|
|||
TimToady | more specifically, "when /(\d+)/ { $0 }" fails to set $0 | 15:45 | |
15:45
mkramer joined
|
|||
jnthn | TimToady: Yeah, I realized that somehow I'd never quite followed through with implementing current spec on $/ and $! :S | 15:48 | |
phenny | jnthn: 14:00Z <[Coke]> tell jnthn I have a 32-bit windows 7 box that I've built nom on before using strawberry & visual studio. ping me if you need testing. | ||
15:48
mykhal joined
|
|||
jnthn | TimToady: I need to re-read it and then twiddle. I somehow thought I'd done that already... | 15:48 | |
TimToady: And yes, having a pmichaud++ around to look at it would be nice, but when that does happen then getting protoregexes back in place and NFA stuff integrated into nom is kinda higher priority. That's something I'd struggle with knowing how to do, whereas the $/ handling I can most likely figger out. | 15:52 | ||
:) | |||
TimToady | just being a squeaky wheel... | ||
15:52
mtk joined,
uasi left
|
|||
supernovus | It seems the features chart is slightly out of date (last updated Aug 20th). I'm not sure how many of the items have been updated since, but I know Date/DateTime are supported in nom now. I can update that, but I'm sure there's other features that should be updated. I'm just not sure which ones. | 15:54 | |
15:54
Reaganomicon joined
|
|||
TimToady | feel free to fix the parts you know about, and ignore the rest, or bug other people to fix | 15:55 | |
supernovus | TimToady: okay, works for me :-) | ||
And since DateTime is working again, I'll get DateTime::Utils fixed up to work with nom. | 15:59 | ||
jnthn | I think we deserve a + on introspection in nom now. ng has one, and I consider nom at least as capable there, if not more so. | ||
Anyone want to explain to me what "Inheritance manipulation" means in the MOP section, so I can know if we do it? :) | |||
I mean, if you're constructing a class using the MOP, you can certainly .^add_parent | 16:00 | ||
That's how the compiler implements it. | |||
TimToady | maybe they mean at run time | ||
tadzik | supernovus: having DateTime fixed would be nice too :) | ||
TimToady | or maybe they mean picking MRO | 16:01 | |
or something WALKish | |||
jnthn | class MyMROClassHOW is Metamodel::ClassHOW { method mro($obj) { ... } } # :-) | 16:02 | |
TimToady | we could probably figger out who to blame for adding it | ||
jnthn | I'm quite sure you can implement your own MRO today, it's just diddling with the meta-object :) | ||
Yeah. I don't mind it being there, I'd just like to know whether I can give us a + or only a +/- :) | |||
supernovus | tadzik: is it still broken? I haven't done much testing over here yet. I noticed I can at least create DateTime and Date objects again, and was going to throw DateTime up against strftime() and see what sticks ;-) | 16:03 | |
tadzik | supernovus: there are like 2 failing tests in DateTime.t | ||
TimToady | looks like pmichaud++ added it | ||
or last edited the line :) | 16:04 | ||
probably just translated to json | 16:05 | ||
supernovus | tadzik: I'll look into it, I haven't run the spec tests in far too long. | 16:06 | |
tadzik: And since the spec tests aren't fully functional, I'll give nom the +- rating for DateTime for now. | |||
16:06
colomon joined
|
|||
TimToady | yeah, would need to trace back through features.txt | 16:07 | |
tadzik | sounds good | ||
16:07
janosik joined
|
|||
dalek | atures: f38194f | (Timothy Totten)++ | features.json: Changed DateTime/Date for nom to +-, changed Introspection for nom to +. |
16:08 | |
16:12
mberends joined
16:13
mj41 left
|
|||
sorear | o/ colomon, mberends | 16:17 | |
colomon | \o | ||
sorear | (janosik too if you want it) | ||
16:18
replore left,
pjcj left,
pjcj joined
16:19
im2ee joined
|
|||
im2ee | Hi! :) | 16:19 | |
sorear | Hello and welcome, im2ee. | ||
mberends | o/ sorear | 16:20 | |
16:23
replore_ joined
|
|||
moritz | nom: say (1 + *).WHAT | 16:23 | |
p6eval | nom 35ec9c: OUTPUT«WhateverCode()» | ||
16:24
am0c left
|
|||
dalek | atures: 1bc3ef4 | moritz++ | features.json: nom does Whatever currying also remove an entry where nobody else seems to know what it means |
16:25 | |
supernovus | well, there definitely is something weird with the current DateTime... DateTime.new(time) returns the proper UTC time. DateTime.now.utc is returning, err, okay, that's the problem, my current timezone is -0700 and DateTime.now is returning +0700... | 16:27 | |
pmichaud | good morning, #perl6 | 16:29 | |
mls_ | hi pmichaud! | ||
mberends | o/ pmichaud | ||
sorear | hi pmichaud | ||
16:31
kaleem left
|
|||
[Coke] | supernovus: checkout the recent todo'd spectests marked 'nom regression', that sounds familiar. | 16:32 | |
pmichaud | mainly stopping in to say "I'm still around" -- things have been a little hectic around here the past few days | 16:33 | |
(all is relatively well, though) | |||
sorear | how are we for #phasers in 3040? | ||
moritz | nom: say 3040 div 24, ' ', 3040 % 24 | 16:34 | |
p6eval | nom 35ec9c: OUTPUT«126 16» | ||
supernovus | it seems the internal local-timezone class is doing something wrong... it's returning 25200 as my timezone offset instead of -25200 ... | 16:35 | |
moritz | so, sign error? | ||
flussence | .oO( didn't we have a divmod function? ) |
||
phenny | flussence: 18 Sep 08:30Z <tadzik> tell flussence since nom is now default, please feel free to file every Pod-related issue you have to RT; external memory is better for me to remember about stuff | ||
flussence | tadzik: will do | ||
tadzik | flussence: thanks | 16:36 | |
16:36
static_perl left
|
|||
jnthn | pmichaud: o/ | 16:37 | |
[Coke] | pmichaud: o/ | 16:38 | |
mls_ | jnthn: here's an ugly patch for you to look at: gist.github.com/9be7df6c549eb2385b7e | ||
16:38
kaleem joined,
pjcj left
|
|||
jnthn | mls_: but...but...I like pretty things! :P | 16:39 | |
jnthn looks | |||
mls_: My word, it's ugly :P | |||
mls_ | I don't see any better way to fix the :outer problem for CATCH blocks | ||
jnthn | mls_: What's the problem it's solving? | ||
mls_: Well, I think (need to check the spec) we should be looking $/ up dynamically anyway | |||
er, $! | |||
16:40
pjcj joined
|
|||
mls_ | problem is, the CATCH block is already on the serialization queue | 16:40 | |
what about $_? | |||
same thing? | |||
jnthn | Why doesn't CATCH have its outer being the block it's in? | ||
That's what should happen really. | |||
If we're fudging in some other frame at the moment, that really wants to go away, I suspect. | 16:41 | ||
mls_ | Ok, we can also do that. | ||
(Currently there's a an extra block that creates the exception) | |||
(maybe for historic reasons) | |||
pmichaud | ...there is? that seems odd. | 16:42 | |
jnthn is looking at the code and can't quite tell | |||
But my brane is kind of a mess today, so :/ | |||
sorear | nom is doing serialization now? I am so behind the times | ||
jnthn | sorear: Not in that sense...though hopefully, soon. | ||
mls_ | the first $handler := line creates it | ||
pmichaud | ah yes, I see the extra block. | 16:43 | |
jnthn | *nod* | ||
I'd rather see if we can not have that. Or at most, it only contributes to the dynamic scope, not the lexical one. | 16:44 | ||
pmichaud | perhaps the handler should add code to the catch block instead of wrapping it in a new one | ||
jnthn | That sounds preferable. | ||
mls_ | maybe it was added so that the handler doesn't change $_/$/... | ||
pmichaud | I suspect it was simply "get something working" | 16:45 | |
since many aspects of exceptions were still fuzzy at the time | |||
mls_ | (Btw, jnthn, if you want a 10% speedup for mandelbrot, just change "$z.abs > 2" to "$z.abs > 2e0") | 16:47 | |
mberends | sorear: the Gtk text editor is beginning to work with plain text. Do you think we could get some syntax highlighting to work, and would you have time to help me when I get tuit (after next week's release)? Btw, I'll probably make that #phasers time on Wednesday via mobile connection during decommute. | ||
PerlJam | mls: that seems so backwards | ||
mls_ | yeah, that's something the optimizer should do ;) | 16:48 | |
16:48
birdwindupbird left
16:49
replore_ left
|
|||
jnthn | Hm...not sure if the optimizer can do that too easily. | 16:49 | |
It may be able to know that it's impossible for any of the same type candidates to match, mind. | |||
mls_ | Hmm, true, it can't assume that it's ok to promote a Int to Num in all cases | 16:51 | |
tadzik | mls_: why does it give such a speedup? | ||
jnthn | It avoids a re-dispatch. | ||
mls_ | No more calls to .Bridge | ||
tadzik | ah | 16:52 | |
jnthn | Num + Num ==> dispatch straight to the right candidate | ||
Num + Int ==> coercion, then re-dispatch. | |||
I suspect that kinda thing will only be made to look ever more ugly once we have an optimizer. | |||
sorear | mberends: ...why are you writing a text editor? | ||
my C text editor is slow enough already. | |||
pmichaud | My gut still tells me that .Bridge is the wrong answer to this problem. | 16:53 | |
sorear is not thrilled with Bridge either | |||
jnthn | pmichaud: That may be so. But even if it isn't, there's still probably going to be a double-dispatch (the multi candidate that coerces, then the one that does the work). | 16:54 | |
pmichaud | jnthn: I don't see a problem with special dispatch candidates for Int/Num variants. | ||
jnthn | pmichaud: Well, there's that option too :) | ||
pmichaud: They do blow up exponentially | |||
pmichaud | I did a little playing around with some of these cases and managed to reduce things by one or two dispatches | 16:55 | |
jnthn | But I guess a given program will probably only use to many variants. | ||
s/to/so/ | |||
pmichaud | part of the problem is that .Bridge only fixes one candidate at a time, when it should probably be done in pairs | ||
sorear | the blowup is only quadratic | ||
jnthn | sorear: ah, true. | ||
sorear: That's bad enough. | |||
16:56
supernovus left,
thou joined
|
|||
jnthn | Int, Num, Rat, Complex... :) | 16:56 | |
Guess it ain't so bad. | |||
pmichaud | Str | ||
unless we're willing to live with the redispatches there :) | |||
jnthn | pmichaud: I may be willing to live with those. :) | 16:57 | |
sorear | pmichaud: I think that "multiple dispatch" is only a sensible approach to the numeric ladder if the dispatcher itself knows about the Int->Rat->Num->Complex subtyping relationship | ||
jnthn | I guess Rat + Int is going to be commonish. | ||
sorear: Well, the problem is that it's not a subtyping relationship. | |||
16:57
mberends left,
pjcj left
|
|||
jnthn | nom: say Int ~~ Complex | 16:57 | |
p6eval | nom 35ec9c: OUTPUT«Bool::False» | ||
jnthn | niecza: say Int ~~ Complex | 16:58 | |
p6eval | niecza v9-32-g380d891: OUTPUT«Bool::False» | ||
pmichaud | I'm not certain about that relationship, fwiw. | ||
sorear | jnthn: exactly | ||
jnthn: as the types are currently defined, multiple dispatch on + doesn't make sense | |||
jnthn | Well, in a sense, if people are trying to write fast code, they'll write in types. And probably use native ones anyway. | 16:59 | |
pmichaud | well, we'd like it to be "fast" even if they don't. :-) | 17:00 | |
jnthn | Well, multi-dispatch in terms of the decision making process is pretty fast in nom now. :-) It's just that our only current backend is kinda slow on the invoke part, so re-dispatch is a pretty painful cost. | 17:01 | |
mls_ | hmm, let me run the profiler... | 17:02 | |
jnthn | mls_: ooc, what does one feed the output of your profiler too? Or is it meant for direct human consumption? | ||
mls_ | no, it's meant for kcachegrind | ||
jnthn | oh! | ||
OK :) | 17:03 | ||
mls_ | dunno if it exists for windows | ||
jnthn | I did manage to coerce it into running on Windows once before. | ||
17:06
pjcj joined
|
|||
mls_ | invoke() cost seems to be 1% | 17:06 | |
17:07
JimmyZ left
|
|||
moritz | that's... surprisingly little bad | 17:07 | |
jnthn | uh. | ||
pmichaud | ops or ticks? | ||
moritz | wait, is that PIR level invoke? | ||
jnthn | That's WAY off what you'll see if you look with a C profiler. | 17:08 | |
mls_ | I mean the invoke for the Bridge calls ;) | ||
jnthn | oh. | ||
mls_ | ticks | ||
jnthn | Where is mandelbrot spending a lot of time, ooc? | ||
mls_ | on a hll or opcode level? | 17:09 | |
jnthn | hll | ||
17:10
plobsing left
|
|||
mls_ | well, the most time is spent in that inner block comparing z against 2 | 17:11 | |
17:11
plobsing joined
|
|||
mls_ | but only 6.5% is spent with opcodes from that block, about 30% is infix<+>, infix<>>, infix<*>, abs | 17:13 | |
jnthn | *nod* | ||
PerlJam | so ... all we need is a single op to do all that and it'll be *much faster ;) | 17:14 | |
mls_ | ah, yes, a mandlebrot op! | ||
mandel | |||
jnthn | PerlJam: Well, or to implementing inlining ;) | 17:15 | |
17:17
mberends joined
|
|||
mls_ | mandelbrot also spends 10% in @color_map[$_]. I wonder why that's so expensive. | 17:17 | |
pmichaud | subscripting is generally expensive | 17:18 | |
it can likely be optimized, but there's a fair bit that happens there | |||
afk, lunch | |||
moritz | mls_: too many redispatches, probably | 17:19 | |
17:19
MayDaniel joined,
SHODAN joined
|
|||
mls_ | yes, many different functions involved | 17:19 | |
17:20
packetknife joined
|
|||
jnthn | food shop, bbiab | 17:20 | |
moritz | postcircumfix, at_pos, exists, gimme, | 17:21 | |
17:22
sayu left
|
|||
TimToady | well, the thing Bridge should probably be doing is allomorphic caching | 17:23 | |
not to the extend P5 mushes its scalars, but enough to not do the same work over and over | |||
*extent | |||
and constants like 2 should certainly be as allomorphic as possible | 17:24 | ||
well, within the bounds of Coolness | |||
17:25
packetknife left
|
|||
TimToady | in the absense of type inference, the fastest run-time strategy will probably be do assume memoizing is useful on conversions, and disable it on values that are written as often as they are converted | 17:26 | |
(once that trend is noted) | |||
P5 does some tricks like that | |||
though mostly on regex optimizations | 17:27 | ||
but since a constant can't be rewritten, memoization is a no-brainer | 17:28 | ||
esp if it can be done at compile-time, but then it starts looking like type inference :) | 17:29 | ||
sorear | the complicating factors here are 1. multithreading 2. memory usage | ||
TimToady | both good reasons to figure it out at compile time :) | ||
PerlJam | no threaded compiles? | ||
moritz | if I change the $z.abs > 2 to $z.abs > 2e0, mandelbrot goes down from 48.6s to 42.1s | 17:30 | |
TimToady | that's what I'm talking about | ||
moritz | nom: say (48.6-42.1) / 48.6 | ||
p6eval | nom 35ec9c: OUTPUT«0.133744855967078» | ||
im2ee | What is exactly a "nom"? | ||
PerlJam | im2ee: it's the sound one makes while eating :) | ||
17:30
mj41 joined
|
|||
TimToady | coincidentally, it stands for New Object Model | 17:30 | |
PerlJam | im2ee: or it's just the New Object Model branch of Rakudo | ||
im2ee | TimToady, PerlJam , thanks. :) | 17:31 | |
TimToady | sorear: the single-ownership model of mutables probably helps with memoization under threading | 17:32 | |
mls_ | afk -> home... | ||
TimToady | if you're not the owner, you don't do it | 17:33 | |
with immutables, it doesn't much matter who does it, as long as it's idempotent | |||
sorear | who understands the single-ownership-model? | ||
TimToady | beats me, but that never stopped me before | 17:34 | |
I'm that fool that rushes in, y'know... | |||
but I suppose you might think of it as a funny kind of monad | 17:35 | ||
colomon | as opposed to ingy, who is a funny kind of nomad? | 17:37 | |
TimToady | .oO(a 'mandelbrot op' is sorta what hotpath analyzers *do*, y'know...) |
17:41 | |
jnthn knows :) | |||
Just non-trivial (and fun ;-)) to build one :) | 17:42 | ||
PerlJam | As soon as M0 hits the streets, builing a mandelbrot op on-the-fly should be easier. | ||
s/builing/building/ | |||
TimToady | re subscript overhead, that's one of the reasons for the sigil policy, so that we can know that @a[$x] is a single subscript by definition, since $x can't flatten | ||
so it can hotpath around the whole slice processor | 17:46 | ||
P5 also had an optimization for literal subscripts, btw | |||
ingy is nowmad | 17:50 | ||
phenny | ingy: 14:57Z <TimToady> tell ingy that if your grammar assumes ^ $ you can never use a grammar to parse a portion of a string, such as an embedded block in a different language | ||
ingy | TimToady: I'm not certain of that | 17:51 | |
I can invoke a parse with any start rule | 17:52 | ||
which means that I can have actions that do launch entire new parses | 17:53 | ||
17:53
mj41 left
|
|||
ingy | and then put the result of the sub parse into the ast that triggered them | 17:53 | |
. | |||
17:56
mj41 joined
18:01
slavik1 left
18:04
slavik1 joined
18:07
molaf left
18:09
benabik joined
18:12
jamtech left
18:13
jamtech joined
18:14
packetknife joined
18:18
pernatiy left
18:22
PacoLinux left
|
|||
sorear out | 18:24 | ||
18:24
molaf joined
18:26
reokie joined
18:29
reokie left
18:30
envi_|2 left
18:38
packetknife left
18:40
PacoLinux joined
18:46
shinobicl_ joined
18:50
kaleem left
18:58
Caldrin joined
18:59
im2ee left,
im2ee joined
|
|||
moritz | pmichaud: ping | 18:59 | |
19:14
masak joined
|
|||
masak | OH HAI #perl6 | 19:14 | |
moritz | lol it's masak! | 19:15 | |
jnthn | o/ masak | 19:16 | |
mberends | oh hai masak | 19:18 | |
TimToady | o̐\ | 19:19 | |
(doffs hat) | |||
jnthn | :) | ||
TimToady: So, there should be a $/ and $! per sub, and the mainline is a "sub" for this too. Is the lookup of them still lexical? | 19:20 | ||
Something about the "gather and async must also define them" made me think there was a switch to a dynamic lookup, but I just realized that didn't really follow :) | 19:21 | ||
TimToady | last I heard :) | ||
jnthn | OK. | ||
TimToady | but it bears more thought... | 19:23 | |
jnthn | If you say that I'm gonna put off doing anything until you've thunk more :P | ||
19:26
daxim left
|
|||
TimToady | that's probably...wise... | 19:28 | |
ingy | hi TimToady | ||
PerlJam | But then if you don't do something, you can't twiddle his thinking (which is probably why he needs to think more) | ||
jnthn | TimToady: Is it safe to assume the "one $! and $/ per sub" thing is here to stay? | 19:29 | |
Or, more likely than not? | 19:30 | ||
Well, if I do it I guess I make some bugs go away...so provided it doesn't make more new ones on the way it's a win ;) | |||
TimToady | likely to stay, I think, but we do need to figure out how not to set $/ from things like grep: /pattern/ | 19:31 | |
jnthn | Hm | ||
yeah | |||
That's why I was wondering about dynamic. | |||
TimToady | and grep: sub { /pattern/ } is not the answer | ||
jnthn | ew, no :) | ||
It also fixes the subst case :) | 19:32 | ||
TimToady | well, even if we call it dynamically set, dynvars are still defined lexically | ||
moritz | grep could localize $CALLER::</> | ||
jnthn | ...wait, what? :) | ||
TimToady: I menat dynamically looked up. | |||
19:32
MayDaniel left
|
|||
ingy | TimToady: can you reexplain why I would not want to anchor grammars | 19:32 | |
19:32
REPLeffect left
|
|||
TimToady | jnthn: yes, but the setting of $/ from within a matcher doesn't have to use that mechanism | 19:33 | |
19:33
shinobicl_ left
|
|||
jnthn | $foo.subst(/blah/, { #`the $/ in here is the one set in subst` }); #`out here, $/ not touched` | 19:33 | |
TimToady | what if you have a string that contains leading and trailing garbage you want to ignore; how do you parse that without substr()? | 19:34 | |
jnthn: yes, that argues for dynamic reads too | 19:36 | ||
19:37
birdwindupbird joined,
birdwindupbird left
|
|||
jnthn | TimToady: Yeah. I'm curious what the counter-examples for dynamic reads look like :) | 19:37 | |
TimToady | I suppose something that wants to be transparent can do $/ := CALLER::<$/> or some such | ||
ingy | TimToady: well I feel like I'm creating an acmeist parsing language. it doesn't seem the job of a parsing language to write a json grammar that can pull json out of a garbage can. | 19:38 | |
but it I needed to do that I certainly could add garbage rules to the json-in-garbage grammar | 19:39 | ||
TimToady | the question is who's to be master, that's all... | ||
that seems inside out to me | 19:40 | ||
the P6 view is that there is no priviledged level of grammar, and every lexical scope can have its own language, as it were | 19:41 | ||
ingy | well I can certainly add a add-garbage-rules-to-my-grammar option in the parser | ||
but I can't imagine ever needing it | |||
unless I was wanted my grammars to also be general purpose regexen :D | 19:42 | ||
cognominal | nom: my ($a, $b) = "ab" ~~ /(a)(b)/; say "'$a' '$b'" | ||
p6eval | nom 35ec9c: OUTPUT«'ab' ''» | ||
TimToady | a parser at any level just starts at a point in the string, and ends at some other point; it's the outside of that that sets it going in the right starting spot, and verifies that the end spot is adequate | ||
cognominal | what am I doing wrong here? | ||
jnthn | nom: my ($a, $b) = ("ab" ~~ /(a)(b)/).list; say "'$a' '$b'" | 19:43 | |
p6eval | nom 35ec9c: OUTPUT«'a' 'b'» | ||
PerlJam | cognominal: you're not flattening or it's a bug | ||
jnthn | I think you gotta .list it yourself. | 19:44 | |
ingy | TimToady: sure but for json or any other dsl you always start at the start and end at the end, so if I publish 1000 grammars and they all have ^ ... $ obviously I mad a mistake | ||
TimToady | I suspect list assignment should do that for you | ||
ingy: it's the thing that applies the grammar that checks that, not the grammar itself | 19:45 | ||
or you just have alternate top rules, like the P6 grammar does | 19:46 | ||
TOP checks, and comp_unit doesn't | |||
TOP also also allows an alternate end to be specified from outside | 19:47 | ||
ingy | so if I define a rul called TOP I don't need ^ or $ in my grammar? | ||
pegex has a TOP special rule too... | |||
TimToady | well, just don't make it impossible to work as an embedded parser, I don't much care how you don't do it :) | 19:48 | |
19:48
MayDaniel joined
|
|||
cognominal | thx jnthn++, TimToady++ | 19:49 | |
TimToady | use inline python; python { ... } | ||
ingy | TimToady: did you see earlier: gist.github.com/1227402 | 19:50 | |
19:50
im2ee left
|
|||
ingy | TimToady: and you didn't answer: 15:47 < ingy> so if I define a rul called TOP I don't need ^ or $ in my grammar? | 19:51 | |
does TOP imply ^ $? | 19:52 | ||
the Pegex TOP is special in that if you start a parse with rule aaa the default ast is {aaa: ...} whereas if you start with TOP it is just ... | 19:54 | ||
jnthn | Well, switching to just one $! and $/ per routine, not per block, didn't break the build...let's see how spectest fares... | 19:55 | |
...oh dear. | 19:56 | ||
TimToady | ingy: no, TOP does not imply ^ $ | ||
ingy | anyway I think that when you use a grammar/parser the normal case is that you want to parse an entire text. but parsing a substr should be a (non-default) option | 19:57 | |
ashleydev | Couldn't you add something equivalent to Lisp macros to languages like Perl or Python?: www.paulgraham.com/raq.html | ||
phenny | ashleydev: 31 Aug 07:14Z <masak> tell ashleydev that yes, macros can be both AST-based and unhygienic. just defer all variable checks until macro-apply-time, and then have $x in the macro be the same as $x outside the macro. it's probably easier to implement than hygiene. | ||
ingy | but I'm not entirely sure of myself, so I show up on #perl6 to eat brains | 19:58 | |
ashleydev | "Not without turning them into dialects of Lisp." | ||
TimToady | parsers should not assume how they will be used | ||
arnsholt | ashleydev: I read that too yesterday. I was amused ^_^ | 19:59 | |
ingy | parser should assume how they will be used | ||
arnsholt | masak: Apparently you're going to turn Perl 6 into a dialect of Lisp =D | ||
ashleydev | haha | ||
TimToady | too late | ||
ingy | and provide alternatives when are needed :) | ||
donri | you can simulate macros with python's standard libs | ||
arnsholt | Simulate macros? | 20:00 | |
donri | well, in that they're not a language feature, but it does provide stuff like ast parser/compiler and import hooks | ||
ingy | TimToady: anyway, thanks for your input. I don't think I'm missing anything at this point. | ||
20:03
bluescreen10 left
20:04
packetknife joined,
localhost left
|
|||
cognominal | nom: my ($a, $b) = ( "a \n<-> b" ~~ / ^ (.*?) ^^ '<->' (.*) / ).list ; say "'$a' '$b'" | 20:05 | |
p6eval | nom 35ec9c: OUTPUT«'' ''» | ||
cognominal | it seems that there is no backtrack over ^^ | ||
20:06
localhost joined
20:07
mkramer left
|
|||
jnthn | OK, I fixed eval up and now the switch to $! and $/ being per sub doesn't look quite so disasterous for spectest. | 20:07 | |
cognominal | cool, jnthn++, it seems I run into it today. | 20:08 | |
masak | arnsholt: what TimToady said. you seem to be under the impression that Perl 6 isn't a Lisp. | 20:09 | |
20:10
Chillance joined,
BooK joined
|
|||
jnthn | gist.github.com/1227465 # fallout from $! and $/ per sub | 20:11 | |
arnsholt | masak: Well, I do agree that Perl is definitely very Lispy | ||
TimToady | 'course, it's also a Smalltalk, Java, Erlang, awk, sed, shell, C, C++, C#... | ||
arnsholt | But phrasing it as only languages that are "dialects of Lisp" can have macros sort of implies the whole parentheticalness to me | 20:12 | |
cognominal | nice potpourri | ||
TimToady | arnsholt: it's assuming that homiconicity can only be done with parens | 20:13 | |
masak | well, only *real* homoiconicity :P | ||
TimToady | or however you spell that | ||
well, the Perl philosophy is to fake everything so well you can't normally tell the difference | 20:14 | ||
masak | :) | ||
arnsholt | Quite, quite | ||
TimToady | we don't, however, define our lists using cons cells by default, though you can do cons using => | 20:15 | |
cognominal | that's a lapsus, when TimToady thinks Lisp, he thinks homicide :) | ||
jnthn | TimToady: Should eval bind its result to $!, or assign? | ||
TimToady | part of the reason for simplifying the scoping of $/ and $! is to make it not matter, as long as we're consistent | 20:16 | |
jnthn | TimToady: ah, well, it's consistency we lack it turns out, now I see what's happening | 20:17 | |
TimToady: try was binging, eval assigning. | |||
er, binding :) | |||
so try { ... }; eval '...' # epic fail :) | |||
jnthn switches eval to bind to see what happens | |||
TimToady | it might be better to switch everything to assignment, so we can do $/ := CALLER::<$/> tricks | 20:18 | |
jnthn | heh | ||
turns out Parrot defines a find_caller_lex but not store_caller_lex | |||
20:18
_jaldhar is now known as jaldhar
|
|||
jnthn | So if I switch to assignment I don't have to go and hack C to add an op | 20:18 | |
So, assign wins ;) | |||
TimToady | \o/ | ||
20:20
bluescreen10 joined,
janosik left
|
|||
BooK | TimToady: did you get my email? about a T-shirt | 20:21 | |
20:22
kshannon joined
|
|||
TimToady | ah, yes, I had overlooked it | 20:23 | |
jnthn | TimToady: Looks dramatically better after switching both to assign. | 20:25 | |
Well, making try assign too. | |||
Yay. Down to just two test files with regressions now, both in S05. | 20:27 | ||
20:32
kaare_ left
|
|||
TimToady | if $! and $/ become dynamic, we'd need some way of declaring control subs that don't declare $! and $/ | 20:33 | |
or force them to do $/ := CALLER::<$/> by convention | 20:34 | ||
jnthn | fwiw, Rakudo's setting doesn't declare control-y things as subs. | ||
TimToady | innersting | ||
that's anudda way | |||
jnthn | Well, depends what you mean by "controlly things" | 20:35 | |
my &redo := -> |$ { ... # for example | |||
Not quite sure what the rationale was for it; you'd hafta ask pmichaud++ | |||
TimToady | I'm thinking of things that take closures that used to close over OUTER::<$!> and such | ||
your ifs and whiles and such | |||
if we're going to look up CALLER::<$!> via their stack frames, they need to be transparent | 20:36 | ||
jnthn | ah, I see | ||
Yeah, that's the big downside of them becoming dynamic. | 20:37 | ||
How waterbedesque. | |||
TimToady | but control routines seem relatively rare, so can be de-huffmanized | ||
jnthn | True. Whereas .subst is quite common :) | ||
OK, I have only 1 test file with regressions left. | 20:38 | ||
TimToady | or such routines can copy out their final $! or $/ if they want | ||
.match would, .subst wouldn't, to the first approximation | |||
or it's in the // s/// macro logic | 20:39 | ||
jnthn | .subst not doing so would make masak happy :) | ||
ah, I think the failing test file is a victim of the changed semantics. | 20:40 | ||
TimToady | but then how does s/// set $/, if it's hidden down in .subst? | ||
20:40
packetknife left
|
|||
jnthn | Maybe either s/// doesn't desugar to .subst (though it probably should) or it passes along an adverb. | 20:41 | |
{ | |||
my $str = "abcabcabc"; | |||
ok($str ~~ m:p/abc/, 'Continued match'); | |||
TimToady | an optional rw param to .match and .subst seems messy | ||
masak | well, I hope you solve this ;) I'm going to bed. | ||
jnthn | Here, it expected a fresh $/. | ||
masak | g'nite, #perl6. | ||
jnthn | night, masak | ||
20:41
masak left
|
|||
tadzik | night | 20:41 | |
dang! | |||
jnthn | :) | 20:42 | |
tadzik | and he's talking about leaving too early! | ||
TimToady | tadzik: you need an autoresponder :) | 20:43 | |
jnthn: fix with a 'my $/' maybe | |||
tadzik | well, it's Sweden, the road to bed is probably snowy, freezing and full of Polarizzly bears. Better leave to soon than too early | 20:44 | |
dalek | ast: b68a710 | jnthn++ | S05-modifier/pos.t: Update a test for current $/-per-routine spec. |
20:45 | |
jnthn | TimToady: coulda done that too.. | ||
OK, final run through the spectests justin case, then I push. | 20:46 | ||
20:46
pmurias joined,
wallberg joined
|
|||
pmurias | ingy: if TOP implies ^ and $ how am i supposed to turn that off? | 20:47 | |
PerlJam | pmurias: matach a subrule? | 20:48 | |
dalek | kudo/nom: 7563146 | jnthn++ | src/ (3 files): Switch to having a $! and $/ per routine, not per block. Also consistently use assignment, not binding, for $! and $/. |
20:49 | |
BooK | TimToady: thanks | 20:50 | |
pmurias | PerlJam: and if TOP contains a lot of stuff? copy and paste it? | ||
jnthn | There we go...that wasn't so bad as I feared. Time for a beer. | ||
tadzik | what does it fix? | 20:51 | |
oh, I think I know | |||
jnthn | tadzik: The patch I just did? | 20:53 | |
tadzik: Our non-compliance with the spec ;) | |||
Though maybe some other bits too :) | |||
pmurias: No, TOP would just ^ <that_rule> $ I guess. | |||
20:55
SHODAN left
|
|||
TimToady | cognominal: yes, niecza and ng seem to agree it's a bug in nom | 20:56 | |
perl6: my ($a, $b) = ( "a \n<-> b" ~~ / ^ (.*?) ^^ '<->' (.*) / ).list ; say "'$a' '$b'" | |||
p6eval | niecza v9-32-g380d891: OUTPUT«'a ' ' b'» | ||
..pugs: OUTPUT«Error eval perl5: "if (!$INC{'Pugs/Runtime/Match/HsBridge.pm'}) { unshift @INC, '/home/p6eval/.cabal/share/Pugs-6.2.13.16/blib6/pugs/perl5/lib'; eval q[require 'Pugs/Runtime/Match/HsBridge.pm'] or die $@;}'Pugs::Runtime::Match::HsBridge'"*** '<HANDLE>' trapped b… | |||
..rakudo 35ec9c: OUTPUT«'' ''» | |||
jnthn | TimToady: I think nom still has general issues backtracking, fwiw. | 20:57 | |
TimToady | well, a pm thing, likely | ||
jnthn | very much so | ||
TimToady | whoa, Method 'postcircumfix:<[ ]>' not found for invocant of class 'CallContext' | 20:59 | |
jnthn | o.O | ||
That should really not happen. | |||
TimToady | the line in question: $s ~= @row[^20]».fmt("%3s ").join.subst(/^' '/,''); | 21:00 | |
which doesn't tell you much :) | |||
tadzik | hehe | 21:01 | |
that reminds me of something :> | |||
jnthn | tadzik: yes. :( | 21:02 | |
tadzik: Wasn't it something like that we were seeing in wherefore-gc? | |||
tadzik | jnthn: certainly | ||
jnthn | :'( | ||
TimToady | and if I take out the » it segfaults | ||
jnthn | That's bad news. | ||
tadzik | also when I tried to fix multi-line docs | ||
jnthn | TimToady: bt may help. | 21:03 | |
TimToady: But I doubt it. It's almost certainly very action-at-a-distance. | |||
(GC issue) | |||
tadzik | TimToady: try with parrot -G perl6.pbc 'file' maybe? | ||
TimToady | hope I have enough memory :) | 21:04 | |
tadzik | if you can build nom you surely have lots of it :P | ||
21:05
benabik left
|
|||
TimToady | well, it got a different error, after a great deal of thrashing on a 3gig system :) | 21:11 | |
tadzik | :P | ||
TimToady | so yeah, probably GC corruption | ||
21:11
MayDaniel left
21:16
wallberg left
21:27
sbp left,
nsh left
|
|||
sorear | good * #perl6 | 21:54 | |
jnthn: what's the last word on $/ and $!? | |||
diakopter | sorear: his last commit made them per-routine, afaik | 21:56 | |
jnthn | sorear: Latest is that they're per-routine (and mainline gets them) | ||
sorear: And whether lookup of them is dynamic or lexical is still up in the air | |||
sorear: nom has it as lexical | |||
(mostly because that was the current state) | |||
I think niecza has them per-routine anyway? If so, in that regard I think we just converged a bit :) | |||
Also, $/ and $! are now consistently assigned to, not bound. | 21:57 | ||
(We did a bit of each before...) | 21:58 | ||
(As in, nom did a bit of each) | |||
sorear | jnthn: I am tentatively -1 to assigning to $/ and $!. I have an optimization which saves two allocations per routine entry that requires $/ and $! to be bound, not assigned | 22:00 | |
jnthn | sorear: Well, it should be all assignment or all binding, not the accidental mixture we had. TimToady++ preferred assignment as it makes $/ := CALLER::<$/> style things possible. | 22:01 | |
sorear | jnthn: requiring allocating two containers in the prologue makes me :( | ||
jnthn | sorear: It'd in theory make me :( too but (1) it's per routine and (2) I allocate them lazily in nom. | 22:02 | |
sorear | jnthn: I wasn't aware that there was a mixture - I thought it was all binding | ||
jnthn: please elaborate on (2) | |||
jnthn | sorear: The mixture in nom was accidental, not intentional. | ||
sorear: I have a "trap" for if the lexpad lookup comes back as null (which should never happen). If it hits that trap, it checks if it's one of the magicals being looked up and creates the container then. | 22:03 | ||
So things that never need a $!, $_ and $/ never end up allocating a container. | |||
I figure a smart inliner would be able to further cheapen that by tossing the check in a lot of cases. But for now a null check per lexical access is vastly cheaper than all the allocations. | 22:04 | ||
22:05
bluescreen10 left
|
|||
dalek | kudo/nom: e062a4c | jnthn++ | src/Perl6/Metamodel/ (2 files): Make role Foo[::T] does Bar[T] { ... } work. |
22:05 | |
kudo/nom: 178ddf6 | jnthn++ | src/ (2 files): Refactor so that we create a BUILDPLAN at a per-class level as well as for the whole hierarchy. |
|||
22:15
mj41 left
22:20
bluescreen10 joined
|
|||
tadzik | gah, I don't get it | 22:26 | |
token comment:sym<#=> { [ '#=' {say('almost there')} \h+ $<attachment>=[\N*] ] } prints 'almost there' 6 times | 22:27 | ||
when I change that to [ ... ]+, it doesn't print it at all | |||
22:30
jamtech left
|
|||
jnthn | tadzik: Confuses me too, fwiw. | 22:34 | |
Not sure why it'd be doing that. | |||
tadzik | maybe it causes the regex to be pre-compiled in a wrong way, for some reason | ||
22:38
jamtech joined
|
|||
jnthn | mebb | 22:38 | |
*mebbe | |||
dalek | kudo/nom: d9b19d6 | jnthn++ | src/Perl6/Metamodel/MROBasedTypeChecking.pm: Add missing .^does. |
22:39 | |
kudo/nom: e97afdb | jnthn++ | src/core/ (2 files): Ensure that when we mix in a role, its attributes are initialized appropriately (for example, any defaults are applied). |
|||
kudo/nom: 9256ee2 | jnthn++ | t/spectest.data: We now pass S14-roles/parameterized-mixin.t. |
|||
kudo/nom: b10ef51 | jnthn++ | NOMMAP.markdown: Remove completed tasks from nommap. |
|||
jnthn | We can probably have a + on the parametric roles entry on features now too. :) | 22:41 | |
22:41
domm left
22:43
arnsholt left
|
|||
diakopter | jnthn: I'll update it | 22:45 | |
22:45
packetknife joined
|
|||
jnthn | diakopter: thanks! | 22:46 | |
Didn't get a clone of that on my new machine yet... | |||
dalek | atures: 8fae163 | diakopter++ | features.json: 17:41 < jnthn> We can probably have a + on the parametric roles entry on features now too. :) |
22:47 | |
22:47
packetknife left
|
|||
tadzik | jnthn: why does BUILD_LEAST_DERIVED take arguments, some future plans? | 22:53 | |
jnthn | yeah | ||
$foo does Answer(42) | |||
22:54
wamba left
22:55
pmurias left
|
|||
tadzik | mhm | 22:56 | |
sleepytime, g'night! | |||
jnthn | night, tadzik | 22:58 | |
23:01
jamtech left
23:02
jamtech joined
23:06
envi_|2 joined
23:08
buubot_backup left
23:11
molaf_ joined
23:16
molaf left
23:17
packetknife joined
23:18
bluescreen10 left
23:28
buubot_backup joined
23:30
bluescreen10 joined
|
|||
jnthn | sleep for me & | 23:32 | |
23:33
packetknife left
23:34
envi_|2 left
23:59
uasi joined
|