»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:, std:, or /msg camelia p6: ... | irclog: irc.perl6.org | UTF-8 is our friend! | feather will shut down permanently on 2015-03-31 Set by jnthn on 28 February 2015. |
|||
dalek | ast: 6f1e2f1 | coke++ | S03-operators/assign-is-not-binding.t: Remove hard skip for test that is passing |
00:04 | |
00:05
vendethiel joined
|
|||
[Coke] | I thought we removed all the parrot fudges. Do we want those gone? | 00:09 | |
00:09
erdic joined
|
|||
[Coke] | there are 98 instances left. | 00:10 | |
00:11
raiph left
00:13
raiph joined
|
|||
[Coke] | I'll get a patch ready if the concensus is to get rid of them | 00:14 | |
00:14
tinyblak joined
00:19
atweiden joined,
tinyblak left
00:22
cognominal left
00:28
vendethiel left
00:34
airdisa left
|
|||
[Coke] finds AnyChar in the spec. | 00:50 | ||
sorry, the syn | |||
jnthn: Is this still a thing to be implemented or does this predate NFG? the spec test for this (S29-type/declarations.t) dates from 2008. | 00:52 | ||
t/spec/S12-construction/destruction.t seems like a flawed test. | 01:02 | ||
01:02
BenGoldberg left,
BenGoldberg joined
|
|||
[Coke] | m: say $*OS | 01:06 | |
camelia | rakudo-moar 56cae1: OUTPUT«opensuseSaw 1 call to deprecated code during execution.================================================================================$*OS called at: /tmp/sPM0lwLhez, line 1Deprecated since v2014.9, will be removed with release v2015.9!…» | ||
[Coke] | m: say $*OSVER | 01:07 | |
camelia | rakudo-moar 56cae1: OUTPUT«13.2.HarlequinSaw 1 call to deprecated code during execution.================================================================================$*OSVER called at: /tmp/MI4Mrn9Rf7, line 1Deprecated since v2014.9, will be removed with release v2…» | ||
[Coke] | I'm pulling the trigger on the rakudo.parrot removal; won't mind if someone reverts it. | 01:09 | |
dalek | ast: 506ffcd | coke++ | / (44 files): Remove rakudo.parrot fudges Will have to refudge once parrot support returns regardless. |
||
ast: 4f132bf | coke++ | S02-magicals/perlver.t: Remove file with gone or going vars. Rakudo wasn't running this file anyway |
|||
[Coke] | m: say %=pod | 01:12 | |
camelia | rakudo-moar 56cae1: OUTPUT«5===SORRY!5=== Error while compiling /tmp/T8o3SZ6YeXVariable '%=pod' is not declared. Did you mean '$=pod'?at /tmp/T8o3SZ6YeX:1------> 3say %=pod7⏏5<EOL> expecting any of: postfix» | ||
[Coke] | m: say $=pod | ||
camelia | rakudo-moar 56cae1: OUTPUT«» | ||
tadzik | ruoso: I see you're solving some of the problems I did; if I were to build a module to help generate grammars from code, would you be interested in that? | 01:14 | |
yoleaux | 1 May 2015 05:09Z <skids> tadzik: I sent you a pull request to Grammar::BNF that adds ABNF (popular in modern RFCs) | ||
tadzik | oh! Awesome! | ||
xBNF looks like a trendy thing these days :) | |||
skids | Also I am currently adapting ruoso++'s slang code to Grammar::BNF | 01:15 | |
Almost done. | |||
tadzik | cool :) | ||
dalek | ecs: 13f1284 | coke++ | S28-special-names.pod: Track an old change to this var name. |
01:16 | |
tadzik | I promise to look at your PR tomorrow, now I'm between drunk and sleepy :) | ||
skids | Never a good place to be when attempting to code, but otherwise a fine state of mind :-) | 01:17 | |
tadzik | well, one of my milestones on GSoC few years back was done under such circumstances | 01:18 | |
dalek | ast: c3083de | coke++ | S02-literals/pod.t: Track %=pod -> $=pod change... ... but rakudo still can't run this test |
||
tadzik | a comfy chair, a fireplace and a few cans of Żubr beer | ||
woke up next morning with code working and tests passing | |||
*shrug*, commit, push, I still don't know how I solved it | |||
skids | :-) | 01:19 | |
It will be interesting to bench some generated RFC grammars against ugexe++'s pure-perl versions. | 01:20 | ||
[Coke] | jnthn: you just added S04-statements/when.t a little while ago; that exception doesn't exist yet. Do we need a ticket to track ? | ||
tadzik | skids: I glanced over your PR, do you have some tuits to put some sort of real-world grammar into the test suite? | 01:21 | |
one thing that amused me a lot is when I put the BNF grammar from wikipedia into my tests and thus proved it incorrect :) | 01:22 | ||
01:22
Ven joined
|
|||
[Coke] adds some train-based commits. | 01:22 | ||
tadzik | . o O ( TRAIN RAIN ) | 01:23 | |
skids | tadzik: probably tomorrow or over the course of the next week. I do want to eventually get to doing HTTP header parsing. | ||
01:35
Ven left
|
|||
skids | tadzik: I PRd the slang support just now. | 01:36 | |
01:37
tinyblak joined
|
|||
skids | tadzik: RFC grammars are often full of "here's the BNF/ABNF but SHOULD tolerate this on input and MAY tolerate this but only when you are acting in the proxy role" so yeah, fun stuff. There will definitely need to be subgrammars wrapped around for such things. Good thing grammars are subclassable. | 01:40 | |
01:45
ilbot3 left
01:47
ilbot3 joined
01:58
bjz joined
02:01
xinyuan_ joined
02:02
Ven joined,
BenGoldberg left
02:06
vendethiel joined
02:10
Ven left
02:19
BenGoldberg joined
02:20
noganex_ joined
02:23
noganex left
02:24
rmgk_ joined,
rmgk left,
rmgk_ is now known as rmgk
02:27
vendethiel left
02:29
gfldex left
02:32
alini left
02:45
mattp|spurs is now known as mattp
03:08
vendethiel joined
03:10
konsolebox left,
konsolebox joined
03:12
konsolebox left
03:13
konsolebox joined
03:22
mr-foobar left
03:34
ssqq joined
|
|||
ssqq | p6: grammar A { token sym { <.ident> }; token id { <sym> }; } | 03:35 | |
camelia | rakudo-moar 56cae1: OUTPUT«===SORRY!===Substring length (-3) cannot be negative» | ||
geekosaur | o.O | ||
ssqq | p6: grammar B { token add-char { < $ @ % > }; token id { <+ alpha add-char> }; } | 03:37 | |
camelia | ( no output ) | ||
ssqq | p6: grammar B { token add-char { < $ @ % > }; token TOP { <+ alpha add-char> }; }; B.subparse('$'); | 03:39 | |
camelia | rakudo-moar 56cae1: OUTPUT«Method 'char' not found for invocant of class 'B' in regex TOP at /tmp/tmpfile:1 in block <unit> at /tmp/tmpfile:1» | ||
ShimmerFairy | IIRC <sym> is for rule names like token id:sym<stuff> , and then <sym> would match stuff . | ||
ssqq | ShimmerFairy: I see, name conflict. | 03:40 | |
token name like 'a-b' could not use `<+ token-name>` | 03:45 | ||
03:45
fhelmberger joined
03:46
Sqirrel left
03:49
raiph left
03:50
tinyblak left,
fhelmberger left,
tinyblak joined
03:51
ssqq left
03:54
tinyblak left
04:04
xinyuan_ left
04:12
BenGoldberg left,
tinyblak joined,
Sqirrel joined
04:14
vendethiel left
04:29
larks_ left
04:39
atweiden left
|
|||
TimToady | greetings from Furnace Creek, Death Valley, where today it only got up to 108℉ | 04:40 | |
m: say (108-32) * 5/9 | 04:41 | ||
camelia | rakudo-moar 56cae1: OUTPUT«42.222222» | ||
TimToady | so 42℃ or so | ||
timotimo | i wouldn't mind if camelia learned to reduce the number of ============= in a deprecation note so that we'll see what should be used instead right here in the channel | 04:49 | |
timotimo heads back to bed | |||
Timbus_ | 42C.. yeesh. i hope you found shade.. | ||
always walk through the shadows in the valley of death. | |||
04:51
ggoebel left
|
|||
flussence | it's 6°C here! Colder than it's been for any day all winter. | 05:01 | |
jdv79 | of course i get home and no wifi issues - only at the hackathon. figures. | 05:26 | |
05:38
jack_rabbit joined
05:39
rindolf joined
05:40
alini joined
05:45
Patterner joined
05:47
jack_rabbit left
05:50
Psyche^ left
05:52
laouji joined
|
|||
moritz | timotimo: or pastebin the untruncated output, and supply a short URL to the pastebin | 06:09 | |
06:16
konsolebox left
06:25
domidumont joined
06:27
skids left
06:30
domidumont left
06:31
domidumont joined
06:37
camel___________ joined
06:40
laouji left
06:41
laouji joined
06:42
risou is now known as risou_awy,
risou_awy is now known as risou
06:45
laouji left
07:01
konsolebox joined
07:04
rindolf left
07:09
konsolebox left,
araujo left
07:15
araujo joined
07:16
diana_olhovik_ joined
07:23
rindolf joined
07:24
laouji joined
07:26
[TuxCM] left
07:27
espadrine joined
07:42
mr-foobar joined
07:44
Alina-malina left
07:46
fhelmberger joined
07:47
darutoko joined
|
|||
lizmat | good *, #perl6! | 07:48 | |
m: say gethostname() | |||
camelia | rakudo-moar 56cae1: OUTPUT«ns1» | ||
07:50
fhelmberger left
07:51
Foxcool_ joined,
camel___________ left
07:54
domidumont left
08:04
konsolebox joined
08:07
rindolf left
08:15
Alina-malina joined
08:19
telex left
08:20
telex joined
08:21
Ven joined
08:22
Ven left
08:26
baest_ joined
08:28
baest left
08:36
diana_olhovik_ left
|
|||
dalek | kudo/nom: 065219c | lizmat++ | src/core/Deprecations.pm: Make deprecation more camelia friendly, timotimo++ Also mention RC-0 as a cutoff time for deprecations. |
08:38 | |
08:39
virtualsue joined
08:43
mj41 joined
08:45
diana_olhovik_ joined
|
|||
lizmat | m: say $*OS | 08:49 | |
camelia | rakudo-moar 56cae1: OUTPUT«opensuseSaw 1 call to deprecated code during execution.================================================================================$*OS called at: /tmp/zdwQ_nB72L, line 1Deprecated since v2014.9, will be removed with release v2015.9!…» | ||
08:53
cygx joined
|
|||
cygx | o/ | 08:54 | |
found a precompilation bug: gist.github.com/cygx/73df9343bb97208b0534 | 08:55 | ||
BEGIN $*KERNEL in a module closes $*OUT oO | |||
same with $*DISTRO, but eg not $*VM | 08:56 | ||
lizmat | cygx: please rakudobug | ||
that seems like something jnthn can sink his teeth into :-) | 08:57 | ||
excellent golf! | |||
09:13
Rounin joined
09:34
Ven joined
|
|||
lizmat | m: say $*OS | 09:35 | |
camelia | rakudo-moar 065219: OUTPUT«opensuseSaw 1 call to deprecated code during execution.$*OS called at: /tmp/SyplJEvmNi, line 1Deprecated since v2014.9, will be removed with release v2015.9!Please use $*DISTRO.name instead.» | ||
lizmat | timotimo: ^^ | 09:36 | |
09:36
Ven left
09:48
Akagi201_ left
09:49
Akagi201 joined,
RabidGravy joined
09:50
Akagi201_ joined
09:53
Akagi201 left
|
|||
[Tux] | m: say $*OS.VERSION | 10:03 | |
camelia | rakudo-moar 065219: OUTPUT«Method 'VERSION' not found for invocant of class 'Obsolete' in block <unit> at /tmp/HVhLQhUiyw:1» | ||
[Tux] | m: say $*OS.version | ||
camelia | rakudo-moar 065219: OUTPUT«Method 'version' not found for invocant of class 'Obsolete' in block <unit> at /tmp/D6bRPvTsQT:1» | ||
lizmat | m: say $*DISTRO.name.version | 10:05 | |
camelia | rakudo-moar 065219: OUTPUT«Method 'version' not found for invocant of class 'Str' in block <unit> at /tmp/uf4Thvy8bP:1» | ||
lizmat | m: say $*DISTRO.version | ||
camelia | rakudo-moar 065219: OUTPUT«v13.2.Harlequin» | ||
lizmat | m: say $*OSVER | ||
camelia | rakudo-moar 065219: OUTPUT«13.2.HarlequinSaw 1 call to deprecated code during execution.$*OSVER called at: /tmp/3OBGsMVa8m, line 1Deprecated since v2014.9, will be removed with release v2015.9!Please use $*DISTRO.version instead.» | ||
[Tux] | m: $*DISTRO.^methods».name.say | ||
camelia | rakudo-moar 065219: OUTPUT«BUILD Str gist <anon> <anon> <anon> <anon> <anon> <anon> <anon> <anon>» | ||
10:06
laouji left
|
|||
[Tux] | m: $*DISTRO.perl.say | 10:08 | |
camelia | rakudo-moar 065219: OUTPUT«Distro.new(release => "13.2", is-win => Bool::False, path-sep => ":", name => "opensuse", auth => "opensuse.org/", version => Version.new('13.2.Harlequin'), signature => Blob, desc => "2015-05-03T12:08:11+0200")» | ||
[Tux] thinks release and version are swapped | |||
Harlequin is a nickname for this release, not for the version | |||
lizmat | m: say $*DISTRO.release | ||
camelia | rakudo-moar 065219: OUTPUT«13.2» | 10:09 | |
[Tux] | the version is 13.2, the release is 13.2 (Harlequin) | ||
10:09
gfldex joined
|
|||
lizmat | m: say /etc/os-release'.IO.lines | 10:10 | |
camelia | rakudo-moar 065219: OUTPUT«5===SORRY!5=== Error while compiling /tmp/bp_qoAICPgTwo terms in a rowat /tmp/bp_qoAICPg:1------> 3say /etc/7⏏5os-release'.IO.lines expecting any of: infix infix stopper postfix statement end…» | ||
lizmat | m: say '/etc/os-release'.IO.lines | ||
camelia | rakudo-moar 065219: OUTPUT«NAME=openSUSE VERSION="13.2 (Harlequin)" VERSION_ID="13.2" PRETTY_NAME="openSUSE 13.2 (Harlequin) (x86_64)" ID=opensuse ANSI_COLOR="0;32" CPE_NAME="cpe:/o:opensuse:opensuse:13.2" BUG_REPORT_URL="bugs.opensuse.org" HOME_URL="opensuse.org/" I…» | ||
lizmat | [Tux]: so what should be where in your opinion | ||
[Tux] | VERSION_ID => version | ||
PRETTY_NAME => release | 10:11 | ||
lizmat | is PRETTY_NAME portable ? | ||
[Tux] | one sec | ||
github.com/abeltje/Test-Smoke/tree...ke/SysInfo and below | 10:12 | ||
test cases are in t/etc | |||
that is what we use for Test::Smoke identification | |||
github.com/abeltje/Test-Smoke/tree/master/t/etc <= a collection of what OS's gather in dist-info related files | 10:13 | ||
For Linux, even (very) old versions, use this code in perl5: github.com/abeltje/Test-Smoke/blob...nux.pm#L62 | 10:14 | ||
lizmat | ok, that seems like some nice LHF for someone else :) | 10:15 | |
lizmat working on is lazy | |||
[Tux] | github.com/abeltje/Test-Smoke/blob...nux.pm#L62 <= that one is more up-to-date | 10:16 | |
(some distro's have levels of os-release files) | |||
lizmat | Belin2015 ? not Berlin2015 ? | 10:17 | |
[Tux] | github.com/abeltje/Test-Smoke/comm...e520867f4a | ||
10:17
bjz left
|
|||
[Tux] | I did not create that branch name :) | 10:17 | |
10:18
bjz joined
|
|||
[Tux] | lizmat, /me is willing to help out there if someone would want me to | 10:19 | |
lizmat | PR's welcome! | ||
[Tux] | I think that t/etc folder will give you a whealth of info | ||
jnthn | o/ | ||
lizmat | jnthn /o | 10:20 | |
[Tux] | and if anyone has an OS that is not yet listed, I'd be very interested in getting the required info files | ||
lizmat | jnthn: work on "is lazy" so far | 10:21 | |
[Tux] | just execute t/etc/get-lsb.pl | ||
lizmat | gist.github.com/lizmat/11ac7b63a2faa074d20e | ||
jnthn | wtf, we suddenly have 1,300 tickets in RT?! | ||
lizmat | jnthn: trying to adapt the buildplan to shove an empty initiializer in there, however I can't get it empty enough | 10:22 | |
my $default := nqp::can($_,'lazy') | |||
?? -> $self, $attr { $type } | |||
!! $_.build; | |||
jnthn: I'm out of ideas atm | 10:23 | ||
Cannot invoke this object (REPR: Null, cs = 0) :-( | |||
seems it lost !build_closure :-( | 10:25 | ||
jnthn: wrt to #RT tickets, they weren't added last night, something else changed ? | 10:27 | ||
jnthn | lizmat: Maybe this is a better way: gist.github.com/anonymous/08896f0615a976d6caa1 | 10:29 | |
lizmat | ok, testing that | 10:30 | |
jnthn | It looks different from setting a default, which is probably good :) | ||
lizmat | hehe... | 10:32 | |
10:32
game0 joined
|
|||
lizmat | I just found there's a "will build" trait ? | 10:32 | |
10:32
game0 left
|
|||
jnthn | That may we what has $.foo = ... desugars to... | 10:33 | |
*may be | |||
lizmat | ah, ok | ||
yeah, that works and *is* much simpler | 10:36 | ||
jnthn | :) | ||
lizmat | althought the: | 10:37 | |
$attr.package.^method_table{$attr.name.substr(2)}.wrap(-> \self { | |||
callsame() // $attr.set_value(self, $block()) | |||
}); | |||
feels a bit like a rabbit out of a hat :-) | |||
[Tux] | lizmat, where is the code for DISTRO (in case I would find tuits to come up with suggestions) | ||
lizmat | src/core/Distro.pm | ||
[Tux] | takk | ||
jnthn | lizmat: If you take it apart it's not so bad. | ||
lizmat | $attr.name.substr(2) # pretty magic to me | ||
jnthn | m: class A { has $.foo }; say A.^attributes[0].name | 10:38 | |
camelia | rakudo-moar 065219: OUTPUT«$!foo» | ||
jnthn | m: class A { has $.foo }; say A.^attributes[0].name.substr(2) | ||
camelia | rakudo-moar 065219: OUTPUT«foo» | ||
jnthn | :) | ||
Basically, given the variable name, compute the accessor name | |||
lizmat | m: m: class A { has $.foo }; say A.^attributes[0].name.substr(0,2) | ||
camelia | rakudo-moar 065219: OUTPUT«$!» | ||
lizmat | ah, ok | ||
duh | 10:39 | ||
well, I learned a lot about buildplans and such :-) | 10:40 | ||
jnthn | All the RTs are 'cus somebody but all the Rakudo fudge'd spectests into RT tickets | 10:43 | |
lizmat | wow | ||
didn't see anything on the ml | |||
jnthn | Once I get over the initial shock, it's probably worth it, in so far as having 1,300 RTs will piss me off enough to start processing them. :P | ||
Which we really should do ahead of 6.0 | 10:44 | ||
10:45
mj41 left
|
|||
RabidGravy | having looked at a few bits of that however, the associated PR to roast may have been based on an out of date clone | 10:45 | |
10:53
virtualsue left
|
|||
RabidGravy | also, it would appear that there is stuff in S03-magicals/ that would probably be better in S28-named-variables/ as KERNEL DISTRO etc aren't mentioned in S03 | 10:55 | |
lizmat | RabidGravy: it's probably for hysterical raisins that they're in there | ||
RabidGravy | er S02 | 10:56 | |
dalek | kudo/nom: bdc66e7 | lizmat++ | src/core/traits.pm: Introduce Attribute will lazy initializer, jnthn++ Inspired by rjbs++, this will actually first wrap the Attribute composer, and in there, wrap the accessor with code that will call the indicated block once to set the value, then call the original accessor again. |
10:57 | |
lizmat | jnthn: I replaced the // with a once block, otherwise if the block returned a type object, it would be called again and again | ||
.tell rjbs "has $.fh will lazy { $file.IO.open }" at your service :-) | 10:59 | ||
yoleaux | lizmat: I'll pass your message to rjbs. | ||
11:00
ggoebel joined
|
|||
jnthn | lizmat: That's...screw it up over instances, no? | 11:00 | |
lizmat | ah, hmmm... lemme check | ||
grrrr | 11:01 | ||
you're right | |||
(sorry Grrrr) | |||
11:07
laouji joined
11:12
laouji left
|
|||
cygx | another precompilation bug, this time not golfed: gist.github.com/cygx/5dbbea302e0f536615c5 | 11:13 | |
11:17
Foxcool_ left
11:19
Foxcool joined
|
|||
dalek | kudo/nom: fd90eb6 | lizmat++ | src/core/traits.pm: Call lazy code until we have a defined value Tried to fix this by introducing an "$!initialized" attribute in the role, but couldn't get that to work, some weird scoping / capturing issues. |
11:30 | |
11:37
airdisa joined
11:42
alini left
11:47
cognominal joined
|
|||
dalek | kudo/nom: c72d670 | lizmat++ | src/core/traits.pm: Fix message on Attribute will foo |
11:52 | |
ab5tract_ | lizmat: cool patches :D | 11:53 | |
dalek | ast: 1f384ba | lizmat++ | S12-attributes/instance.t: Add some "will lazy" and "is/will foo" tests |
||
lizmat | ab5tract_: those were really jnthn++'s work, /me is just a minion :-) | 11:54 | |
11:57
spider-mario joined
12:04
RabidGravy left
12:07
kaare_ left
|
|||
rjbs | lizmat: I look forward to seeing how it got implemented. | 12:10 | |
yoleaux | 10:59Z <lizmat> rjbs: "has $.fh will lazy { $file.IO.open }" at your service :-) | ||
rjbs | lizmat++ jnthn++ # thanks, I think this i a big deal | 12:11 | |
lizmat | rjbs: github.com/rakudo/rakudo/commit/bdc66e79da and github.com/rakudo/rakudo/commit/fd90eb68fa | ||
rjbs | vielen Dank, I'll read this after breakfast; the women of the house have declared we will go get crêpes now | ||
lizmat | hmmm.... crêpes .... good choice | 12:12 | |
12:15
eli-se joined
12:16
eli-se left
|
|||
lizmat hopes FROGGS is doing ok | 12:16 | ||
12:22
tinyblak_ joined
12:23
eli-se joined
12:24
laouji joined,
tinyblak left
|
|||
cygx | jnthn: I'm unable to figure out gist.github.com/cygx/5dbbea302e0f536615c5 | 12:26 | |
jnthn: after compilation, Pointer[type] dies (where type is a CStruct) | 12:27 | ||
12:28
vendethiel joined
12:32
eli-se left
|
|||
[Coke] begins to backlog... | 12:33 | ||
12:33
szabgab joined
|
|||
dalek | ast: 71ea556 | lizmat++ | S02-lexical-conventions/begin_end_pod.t: Actually test what we say we're testing |
12:33 | |
szabgab | hello there | 12:36 | |
this might not be a good time to chat here, but at least I leave this info here | |||
[Coke] | so, the person who opened all the tickets took something I said at the hackathon and ran as far as they could with it without actually checking with me before they pulled the trigger on anything. I expected maybe ONE more ticket when I woke up this morning. Looks like there is a lot of cleanup to do, I think he opened a ticket for each fudge directive, not for each bug. | ||
so, I'm going to apply his fudge patch (if not already done) and then start consolidating tickets and fudge markers. | 12:37 | ||
szabgab | I am helping the YAPC::EU organizers with some PR (not Pull Request) and I've noticed there are only 3 talks about Perl 6 act.yapc.eu/ye2015/talks/tag/perl6 | 12:38 | |
(though I only see the accepted talks) It would be great to see some more Perl 6 talks submitted | 12:39 | ||
jnthn | szabgab: I plan to be there, just didn't submit yet. | ||
(It's on my todo list.) | |||
szabgab | Also the organizer would like to know if you would like to organize a Hackathon | ||
lizmat | I'm also planning to be there, just not planning to do a presentation | ||
szabgab | jnthn: great, push it please | 12:40 | |
12:40
araujo left
|
|||
[Coke] | is dnmfarrell on IRC? | 12:41 | |
12:43
araujo joined
12:45
araujo left
12:46
araujo joined
|
|||
[Tux] | class A { has B $.b is rw; has Str $.s is rw; }; class B { has A @.a; } | 12:46 | |
szabgab | oh and as I am usually not on IRC, could you just encourage each other to submit talks, please? | ||
[Tux] | that is impossible, as B is not defined by the time A is compiled and vice versa | 12:47 | |
moritz | [Coke]: irclog.perlgeek.de/perl6/search/?ni...ell&q= yes | ||
[Tux] | can I force A.b to be of type B later? | ||
12:47
araujo left
|
|||
[Tux] | or in another way | 12:47 | |
szabgab | Oh and if someone would like to run a Perl 6 course, there are still rooms for that too | ||
12:48
araujo joined,
szabgab left
|
|||
jnthn | [Tux]: Stub B first | 12:48 | |
class B { ... } | |||
12:48
araujo left
|
|||
lizmat | m: class B { ... }; class A { has B $.b is rw; has Str $.s is rw; }; class B { has A @.a; } | 12:48 | |
camelia | ( no output ) | ||
12:49
araujo joined
|
|||
lizmat | m: cclass A { has B $.b is rw; has Str $.s is rw; }; class B { has A @.a; } | 12:49 | |
camelia | rakudo-moar c72d67: OUTPUT«5===SORRY!5===Type 'B' is not declaredat /tmp/ZWPzlD_g0v:1------> 3cclass A { has B7⏏5 $.b is rw; has Str $.s is rw; }; class Malformed hasat /tmp/ZWPzlD_g0v:1------> 3cclass A { has7⏏5 B $.b is rw; has Str $.s is rw; }; cl…» | ||
lizmat | m: class A { has B $.b is rw; has Str $.s is rw; }; class B { has A @.a; } | ||
camelia | rakudo-moar c72d67: OUTPUT«5===SORRY!5===Type 'B' is not declaredat /tmp/x4sT0uG0ji:1------> 3class A { has B7⏏5 $.b is rw; has Str $.s is rw; }; class Malformed hasat /tmp/x4sT0uG0ji:1------> 3class A { has7⏏5 B $.b is rw; has Str $.s is rw; }; clas…» | ||
[Tux] | jnthn, that works. thanks | ||
[Tux] has entangled himself into the swamp of callbacks | 12:50 | ||
[Coke] | anyway, thanks everyone for not freaking out. I'll get RT cleaned up as soon as possible so that we get the benefit of the new tickets, but not the duplication. | 12:53 | |
jnthn | [Coke]++ | ||
12:54
domidumont joined
|
|||
jnthn | [Coke]: Just looking at some of the titles, I can see that some of them rely on out-dated spec. | 12:54 | |
[Coke]: Or possibly the design docs need changes :) | |||
Like the AnyChar thing you mentioned before. | |||
[Coke] | there's so much stuff that needs review, yes. | 12:55 | |
I wish we had a branch of RT we could have done this in. :) | |||
jnthn | I suspect some merging will help | ||
e.g. there's a load of ':: NYI' | |||
[Coke] | Aye. I just saw "int NYI", even. | 12:56 | |
jnthn | int is I :) | ||
[Coke] | and it's clearly one ticket per fudge, so the total will probably drop by a hundred or so just there. | ||
[Coke] creates an RT view that shows just tickets opened by our new ticketmaniac. :) | 12:57 | ||
12:58
rurban joined,
diana_olhovik_ left
|
|||
dalek | ast: d5c53cf | jnthn++ | S32-hash/delete-adverb.t: Fix tests sensitive to hash ordering. |
13:00 | |
13:03
alini joined,
RabidGravy joined
|
|||
RabidGravy | afternoon | 13:04 | |
dalek | ast: c8953f2 | jnthn++ | S05-capture/caps.t: Fix another test sensitive to hash ordering. Also these are fudged on JVM; maybe they will work now they aren't so sensitive? |
||
lizmat | jnthn: confirmed that S05-capture/caps.t: can be unfudged for jvm | 13:07 | |
jnthn | lizmat: Cool; wanna do it, or shall I? | ||
lizmat | I'll do it | ||
jnthn | I *think* that we now have clean spectest with MoarVM HEAD | ||
As in, those two were all that needed fixing. | |||
I get one other fail but I think it's 'cus I don't have your lazy patch. | 13:08 | ||
yes, it was :) | |||
dalek | ast: 4099cad | lizmat++ | S05-capture/caps.t: Unfudge passing tests on JVM Turns out the testing was relying on hash key order, jnthn++ for noticing |
13:09 | |
lizmat | yeah, tests for the will lazy patch are already in roast | ||
jnthn | I wasn't expecting it to go into CORE.setting, but I guess we're a good way from a relesae if anybody comes up with a reason not to do it like that. | 13:10 | |
dalek | ast: a219848 | moritz++ | / (82 files): Remove # chars from fudge messages they do not play too well with TODO messages in TAP |
13:11 | |
lizmat | fwiw, I think it's a *very* usefult faeature | ||
moritz o/ | |||
[Coke] | gah. | 13:18 | |
moritz: I think the right answer there is to fix the tap output. | |||
esp. given the effort I had put into having a standard way of writing RT #... | 13:19 | ||
13:19
araujo left
|
|||
arnsholt | Doesn't TAP let you say \# for hashes in the output? | 13:20 | |
13:21
Gothmog_ left
13:22
Gothmog_ joined
|
|||
moritz | arnsholt: no idea | 13:22 | |
[Coke]: that's unfortunate | |||
[Coke]: how would you fix the TAP output? | |||
[Coke] | Digging now. I swear I've already solved this for partcl. | 13:23 | |
yes, looks like \# is what I did there. | 13:25 | ||
Trying to find a spec of some kind to back it up. I'm curious what was breaking with things the way they were, though. | |||
13:26
rurban left
|
|||
[Coke] | we could s/#/SOMETHING ELSE/g, also | 13:26 | |
dalek | ast: 8b6048b | moritz++ | / (82 files): Revert "Remove # chars from fudge messages" This reverts commit a21984810bb4f073291818e6526d9d024c339b98. I'll try to fix the todo and todo functions in rakudo's Test.pm instead. |
13:27 | |
13:33
rurban joined,
rindolf joined
13:34
tinyblak_ left,
nbdsp joined
|
|||
[Tux] | What is a more perl6 way to write "for ($r.fields) -> $f { @!fields.push: $f; }" | 13:34 | |
$r.fields>> ... | 13:35 | ||
lizmat | @!fields.push: @$r.fields | 13:36 | |
?? | |||
[Tux] | Brrr: | 13:37 | |
# expected: (Failure) | |||
# got: (Failure) | |||
lizmat | .oO( not all Failures are alike :-) |
13:38 | |
[Tux] | Cannot understand @!fields in this context | ||
on your suggestion | |||
13:39
kaare_ joined
|
|||
lizmat | that's what you were pushing on in your example ? | 13:39 | |
[Tux] | gist.github.com/Tux/12387de2febd2eda1efc | ||
the commented-out line works as expected | 13:40 | ||
13:40
mj41 joined
|
|||
[Coke] | I'm trying to keep the giant list of new tickets managed so we can coordinate with the incoming pull request. Please ping me before closing/merging whatever those new tickets. | 13:41 | |
lizmat | [Tux]: perhaps a Slang::Tuxic artefact ? | 13:42 | |
[Tux] | ENOFROGGS | ||
13:43
hobbs left
|
|||
lizmat | yeah, I noticed as well... offline for ~ 3 days already :-) | 13:43 | |
13:45
hobbs joined
|
|||
[Tux] | so, "is(something-returning-failure, Failure, "Fail");" won't fly, but neither does "like(failing-thing, Failure, "FAIL");" | 13:45 | |
what to use there? | |||
moritz | isa_ok | 13:46 | |
[Tux] | \o/ :) thanks | ||
moritz | m: sub f { fail 'foo' }; use Test; plan 1; isa_ok f(), Failure, 'stuff' | ||
camelia | rakudo-moar c72d67: OUTPUT«1..1ok 1 - stuff» | ||
moritz | or do a throws_ok { use fatal; your test here }, X::The::Exception::Type::You::Except | 13:47 | |
*Expect | |||
13:47
rurban left
|
|||
[Coke] | m: my int $a = 2; use Test; isa-ok(2,int); | 13:49 | |
camelia | rakudo-moar c72d67: OUTPUT«not ok 1 - The object is-a 'int'# Failed test 'The object is-a 'int''# at /tmp/Ir5MYciBud line 1# Actual type: Int» | ||
lizmat | yeah, known issue | 13:50 | |
[Coke] | is there an RT? | ||
lizmat | natives int pretends to be an Int | ||
not sure | |||
[Coke] | ok. 124461 for now. let me know if you find another one, I'll merge it. | 13:51 | |
ab5tract_ | [Tux]: does it work when you explicitly do @($r.fields) | 13:52 | |
moritz | m: sub f(Mu $a, Mu $b) { say $a.isa($b) }; f 1, int | ||
camelia | rakudo-moar c72d67: OUTPUT«False» | ||
lizmat | moritz: you mean throws_like ? | ||
moritz | m: say 4.isa(int) | ||
camelia | rakudo-moar c72d67: OUTPUT«False» | ||
moritz | lizmat: erm, yes | ||
m: say 4.^isa(int) | |||
camelia | rakudo-moar c72d67: OUTPUT«0» | ||
moritz | m: say 4 ~~ int | ||
camelia | rakudo-moar c72d67: OUTPUT«False» | ||
moritz | m: say nqp::istype(4, int) | ||
camelia | rakudo-moar c72d67: OUTPUT«===============================================================================The use of nqp::operations has been deprecated for non-CORE code. Pleasechange your code to not use these non-portable functions. If you really wantto keep using nqp:…» | ||
moritz | m: use nqp; say nqp::istype(4, int) | ||
camelia | rakudo-moar c72d67: OUTPUT«0» | 13:53 | |
jnthn | isa-ok(2,int) won't ever work out | ||
[Tux] | m: class C { method hash { { :A(1), :B(2) }}}; my $c = C.new;$c<A>.say | ||
camelia | rakudo-moar c72d67: OUTPUT«postcircumfix:<{ }> not defined for type C in block <unit> at /tmp/aVQDg9Dhni:1» | ||
[Tux] | why? | ||
jnthn | .isa is an object operation | ||
13:53
rurban joined
|
|||
jnthn | And so by the time it sees the thing it's been boxed to an Int object | 13:53 | |
[Coke] | m: my num $a = 2; use Test; isa-ok(2,num); | 13:54 | |
camelia | rakudo-moar c72d67: OUTPUT«This type cannot unbox to a native number in block <unit> at /tmp/skYIovXdgi:1» | ||
[Tux] | ab5tract_, no, :( | ||
[Coke] | would you say that's the same issue? | ||
jnthn | [Coke]: ok(2, num) ain't going to work either | 13:55 | |
[Coke] | jnthn: ah. Excellent. I can rewrite the test file to do> | ||
jnthn | [Coke]: 2 isn't a Num though, so you can't assign it to a num native | ||
moritz | [Coke]: no | ||
[Coke]: that's correct, though the error message coudl be better | |||
jnthn | m: my num $a = 2e0; | ||
camelia | ( no output ) | ||
[Coke] | m: my int $a = 3; is($a.WHAT, int); use Test; | ||
camelia | rakudo-moar c72d67: OUTPUT«not ok 1 - # Failed test at /tmp/zDqr2pyog4 line 1# expected: (int)# got: (Int)» | ||
13:55
vendethiel left
|
|||
jnthn | .WHAT is *also* an object-y operation... | 13:56 | |
dalek | kudo/nom: 6a20f05 | moritz++ | lib/Test.pm: Test.pm: Escape # in todo() output |
||
[Coke] | m: my int $a = 3; say $a ~~int; | ||
camelia | rakudo-moar c72d67: OUTPUT«False» | ||
[Coke] | ok. How can we write the test? ;) | ||
jnthn | What is the goal of the test? | 13:57 | |
13:57
vendethiel joined
13:58
tinyblak joined
|
|||
[Tux] | I thought giving a class a hash method implicitly gave it postcircumfix:<{ }> | 13:58 | |
lizmat | no, you need to add AT-KEY and friends | ||
13:59
diana_olhovik_ joined
|
|||
lizmat | m: class A { method AT-KEY($a) { say "foo for $a" } }; A.new<zip> | 13:59 | |
camelia | rakudo-moar c72d67: OUTPUT«foo for zip» | ||
jnthn | [Coke]: If it's to check a variable declared is int is really native, you could try sticking a huge value (only storable as a big Int) into an int, and seeing it doesn't round-trip... | ||
dalek | p: 8437c84 | jnthn++ | tools/build/MOAR_REVISION: Get a MoarVM with hash size reduction, opts. |
14:00 | |
kudo/nom: 20e3646 | jnthn++ | tools/build/NQP_REVISION: Get MoarVM with hash improvements. Hashes on r-m now uses (on 64-bit platforms) 8 bytes less per hash, plus 16 bytes less per hash entry. |
14:02 | ||
14:03
mohij joined,
konsolebox left
|
|||
dalek | kudo/nom: 86b1b2b | lizmat++ | src/Perl6/Actions.nqp: Make nqp::ops warning a bit more camelia friendly |
14:04 | |
14:06
konsolebox joined
14:08
rindolf left
|
|||
jnthn away for a bit | 14:13 | ||
lizmat | jnthn: spectest clean for me, not noticing any speadup just yet though | 14:16 | |
[Tux] | AAAAHRG! after these commits, no more panda. no more panda => no more Slang::Tucic, not Slang::Tuxic no development :( | 14:17 | |
$ panda install Slang::Tuxic | |||
===SORRY!=== | |||
No candidate found for 'panda'. | |||
14:18
rindolf joined
14:21
rurban left
|
|||
lizmat | hmmm... I'm getting Missing or wrong version of dependency 'src/gen/m-CORE.setting' (from 'lib/File/Find.pm') on bootstrap | 14:22 | |
even on a fresh panda clone | |||
[Tux] so the rebootstrap.pl worked for you? | 14:23 | ||
14:23
nbdsp left
14:24
ir2ivps4 joined
14:25
pmqs joined
|
|||
[Tux] | no idea. I typed "make" :) | 14:32 | |
14:33
rurban joined
14:41
laouji left
14:45
airdisa left,
cygx left
14:49
airdisa joined
14:52
airdisa left,
cognominal left,
diana_olhovik_ left
|
|||
[Tux] | t/common.t ..... ok | 15:00 | |
# Failed test 'dependencies 1' | |||
# at t/ecosystem.t line 32 | |||
# expected: 'some' | |||
# got: 'else' | |||
15:01
rurban left,
BenGoldberg joined,
rurban joined
15:02
BenGoldberg left
15:04
BenGoldberg joined
15:07
domidumont left,
konsolebox left
|
|||
lizmat | down to 2 failing spectest files for my new lazy @*INC work *phew* | 15:12 | |
[Tux] | without panda I am lost :( | 15:21 | |
15:24
skids joined
|
|||
jepeway | m: use Test; my Int $i = 0; isa-ok $i, Str, 'crazy, magic stringification works in my slang'; # not that I can author such a slang, mind you | 15:30 | |
camelia | rakudo-moar 86b1b2: OUTPUT«not ok 1 - crazy, magic stringification works in my slang# Failed test 'crazy, magic stringification works in my slang'# at /tmp/Ri1kRfnK9S line 1# Actual type: Int» | ||
jepeway | (& greets, #perl6, btb) | 15:31 | |
nine waves from his new home | |||
yoleaux | 1 May 2015 10:46Z <lizmat> nine: would it be possible for me to get an Inline::Perl5 commit bit ? | ||
lizmat waves back | |||
nine | lizmat: if you tell me how I can give you one | ||
lizmat | I have *no* idea :-) | 15:32 | |
jepeway | o/ | ||
lizmat | moritz might be able to explain? | ||
nine | lizmat: you're lizmat on github? | ||
lizmat: I think I found it | |||
jepeway | I'm a tad disappointed that diag output doesn't mention the expected type. | ||
lizmat | yeah, that's me :-) | 15:33 | |
nine | lizmat: then you have one now :) | ||
lizmat | cool lemme check | ||
skids | (backlogging) So... does masak still hold the record for opening RT tickets? :-) | ||
jepeway | Seems like it should, whenever the default is overridden. | ||
dalek | line-Perl5: a52fd1b | lizmat++ | lib/Inline/Perl5.pm6: Workaround for "is nodal" breakage, quester++ |
||
lizmat | now we only need panda to work again | 15:34 | |
nine | I think I won't backlog this time. Was offline for almost three days. I hope there'll be a weekly tomorrow :) | 15:35 | |
jepeway | 'cause the default method mentions the expected type, y'see. | 15:36 | |
lizmat | nine: I hope so too | ||
jepeway | s/method/message/ | ||
lizmat | nine: we just got a new and shiny Moar with many optimisations | 15:37 | |
something you probably want to check Inliine::Perl5 against :-) | |||
nine | lizmat: on it :) | 15:40 | |
15:42
jack_rabbit joined
15:43
zakharyas joined
15:47
hobbs left,
fhelmberger joined,
rurban left
|
|||
timotimo | could panda rely on hash ordering in that test? | 15:50 | |
welcome back, nine | |||
glad to hear your move has succeeded | 15:51 | ||
15:51
hobbs joined
15:52
fhelmberger left
16:01
diana_olhovik_ joined
16:05
jack_rabbit left
|
|||
[Coke] | m: my bit $a; | 16:06 | |
camelia | rakudo-moar 86b1b2: OUTPUT«===SORRY!===Invalid int size for local/lexical» | ||
16:07
jack_rabbit joined
16:09
rurban joined
|
|||
[Coke] | is lowercase junction ever going to be a thing? | 16:09 | |
lizmat | [Coke] my bit $a is really NYI afaik | ||
[Coke] | yah, just a weird error messages. leaving that ticket alone. | 16:10 | |
lizmat | afk for some dinner& | 16:11 | |
[Coke] | m: my int $a; $a = 2**100; | 16:14 | |
camelia | ( no output ) | ||
[Coke] | in the repl that dies with qast not found. | ||
m: my int $a; $a = 2**100.say; | |||
camelia | rakudo-moar 86b1b2: OUTPUT«100» | ||
[Coke] | m: my int $a; $a = 2**100; $a.say; | ||
camelia | rakudo-moar 86b1b2: OUTPUT«0» | ||
[Coke] | is that the right overflow check? that it's still 0? | 16:15 | |
TimToady | .oO(native junctions are, like, diodes and transistors, right?) |
||
moritz | m: my int $a; $a = 1 + 2**100; $a.say | ||
camelia | rakudo-moar 86b1b2: OUTPUT«1» | ||
moritz | [Coke]: it's simply that powers of two tend to overflow to 0 | 16:16 | |
[Coke] | TimToady: yah, it didn't make any sense to me either; but there's a test for it. | ||
moritz: well, it's a more valid test than what we have, I guess. | |||
16:23
pmqs left
|
|||
jnthn | I think the lowercase junction thingy can go away. | 16:23 | |
As for bit: I added it recently-ish, initially for my bit @vector | 16:24 | ||
(Which ain't done yet, but at least in progress...) | |||
TimToady | "will lazy" ain't Engrish | ||
jnthn | hah, I knew you'd have some comment :P | 16:25 | |
"will lazily" maybe :P | |||
16:26
baest_ is now known as baest
|
|||
TimToady | most of the other 'wills' are designed to be verbs, but what's a good verb for doing something later? | 16:26 | |
sjn | postpone? | 16:27 | |
geekosaur | defer? | ||
...suppose not. hm | |||
procrastinate :p | |||
TimToady | otoh, the "later" is already implicit in 'will' | 16:28 | |
so 'will init' or so isn't so bad | |||
jnthn | 'will be' :) | ||
TimToady | * will be, will be... | ||
will get, will start | 16:29 | ||
don't want init | |||
sjn | will do :-P | ||
TimToady | start is available again these days, since START went away | ||
nwc10 | were weeklies running at the time START went away - I forget why START was able to go away - is there a summary online I can read? | 16:31 | |
(I realise that the direct answer to "why did START go away?" might be quite a few lines of repeated typing) | |||
jnthn | It didn't really fit the phaser "happens at a weird time" thing, since it happened at that point in the code, just once. So we called it "once" instead. | 16:32 | |
nwc10 | aha. | 16:33 | |
that answer was shorter than I expected. | |||
so, a "once" phaser fires once, at the first time execution reaches that point? | |||
jnthn | Well, it's not really a phaser, just sugar for something involving a state variable | 16:36 | |
masak | good evening, #perl6 | ||
vendethiel | \o, masak! | ||
jnthn | a wild masak appears! | ||
masak <-- actually quite tame | 16:37 | ||
vendethiel | .oO( that's what all the wild ones say! ) |
16:38 | |
masak | well, at least the articulate ones. | ||
tadzik: so excited to see what you'll do with github.com/tadzik/synopsebot/pull/6 ! :D | 16:39 | ||
masak backlogs, wildly | 16:40 | ||
I just want to say that it's heartening to see so much activity on the channel lately. | 16:42 | ||
it feels to me that with all the work being applied on rakudo itself, on the test suites, and on the docs, we might actually end up somewhere nice for Christmas. | |||
<3 | |||
vendethiel | it's not friday, but /hug to everyone indeed :-) | 16:43 | |
masak | m: say Date.new # and it's *this* Christmas! :D | ||
camelia | rakudo-moar 86b1b2: OUTPUT«2015-12-24» | ||
16:43
risou is now known as risou_awy,
risou_awy is now known as risou
16:44
risou is now known as risou_awy,
risou_awy is now known as risou
|
|||
arnsholt | masak: Regarding PARSING_IGNORED in your patch up there, wouldn't something like "regex piece { <info> | . }" do the trick? | 16:46 | |
masak | hmm :) | 16:47 | |
masak tries | |||
arnsholt | I think LTM should DTRT in that case | ||
masak | let's say that works -- what's the easiest way to "amend" a pull request? | ||
vendethiel | git push :P | 16:48 | |
RabidGravy | :) | ||
masak | ah -- to the source branch of the PR? | ||
moritz | yes | ||
vendethiel | yes | ||
moritz | you can even force-push there | ||
masak | and does Github DTRT with `git push -f`? | ||
:) | 16:49 | ||
vendethiel | yes | ||
masak | goodie. | ||
vendethiel++ moritz++ | |||
moritz | masak: it even shows comments on replaced patches as such | ||
masak | it works \o/ | 16:50 | |
masak pushes --force | |||
timotimo | jnthn: do we already have an idea why Proc::Async is racy? is that a mvm-level problem or an nqp/rakudo-level one? if you can point me at something, i could probably try to figure it out | ||
TimToady | gist.github.com/anonymous/16e85e7c3e1b95ce1577 is a test for Proc::Async written by a craigslist cohort | 16:54 | |
discusson at irclog.perlgeek.de/perl6/2015-03-31#i_10370872 | 16:55 | ||
masak | tadzik: new and improved! github.com/tadzik/synopsebot/pull/6 :) | ||
(pro tip: a `git push --force` *will* update the pull request. it does not update the OP comment, so if you're expecting that to change, you will be momentarily confused, at least until you start comparing SHA-1s.) | 16:56 | ||
timotimo | i'll have a look with that valgrind tool that checks for race conditions and stuff | ||
jnthn | timotimo: I suspect there's problems at a couple of levels; I was pondering spending some time tomorrow on that. | ||
timotimo | helgrind* | ||
i bet you wouldn't mind if i fixed it before you :P | 16:57 | ||
jnthn | timotimo: Helgrind is rather noisy :) | ||
True, but I think it's "them" not "it" | |||
timotimo | but if it's hard, i may not want to spend any time on it :P | ||
oh my | |||
jnthn | And at least some of it is our code-gen, I fear. | ||
timotimo | oh? | ||
jnthn | For example, our phaser handling isn't thread safe. | ||
timotimo | that surprises me a bit | ||
oh, this is about helgrind noise, not proc::async problems? | |||
jnthn | In fact, it's not really recursion safe. | ||
timotimo: Until a few days ago we had a bug related to the way we compile blocks inside thunks, which also could have caused thready issues. | 16:59 | ||
timotimo | mhm | ||
well, i'll have a look | |||
jnthn | *nod* | ||
There's two tools in valgrind; helgrind and drd | |||
timotimo | i may want to try "porting" Proc::Async to nqp so that i'll get much less output? | ||
jnthn | Not sure how much that'll help | 17:00 | |
I mean, it's not until you kick off a process or two that threads get created | |||
masak .oO( the brave warriors go to valgrind; the craven ones get sent to helgrind ) | |||
timotimo | i suppose that's fair, but in nqp land the code gen is much simpler and there's much less stuff actually running all in all | ||
jnthn | .oO( callgrind me maybe ) |
17:01 | |
TimToady wonders if 'nodal' needs to be split into array nodal vs hash nodal, such that AT-POS gets one, and AT-KEY gets the other | 17:02 | ||
shower & | |||
masak | jnthn: I challenge you to use that as aslide title at some point :P | 17:03 | |
nine | This is the reason for panda's test failure: | 17:05 | |
m: my @a = 1, 2, 3; my @b; say @a; say [(@a (|) @b).list.flat] | |||
camelia | rakudo-moar 86b1b2: OUTPUT«1 2 33 1 2» | ||
nine | github.com/tadzik/panda/blob/maste...tem.pm#L50 | 17:06 | |
jnthn | Sets are unordered, so relying on ordering would be a badass umption. | 17:07 | |
m: my @a = 1, 2, 3; my @b; say @a; say (@a (|) @b).WHAT | |||
camelia | rakudo-moar 86b1b2: OUTPUT«1 2 3(Set)» | ||
timotimo | food time first :) | ||
jnthn | However, our hashes until recently maintained insertion order. | ||
But only on Moar | 17:08 | ||
timotimo | is someone looking at the panda problem already, btw? | ||
jnthn | So this may also explain the panda bustage on JVM too... | ||
Which has never had the "oops we keep order" issue | |||
17:09
mj41 left
|
|||
masak | TimToady: my immediate reaction is -- if there's no overwhelming reason to distinguish those, then the API will be a lot simpler with them undistinguished. | 17:11 | |
jnthn | nine: Do you know if it's a bad test, or wrong code? | ||
nine | timotimo: github.com/tadzik/panda/blob/maste...tem.pm#L50 | ||
jnthn: unfortunately, I don't know if the order of dependencies is meaningful | |||
masak | not dependencies of a given module, no. | ||
at least not as far as I know. | 17:12 | ||
jnthn | yeah | ||
Taht'd be my guess too but I don't know for sure | |||
17:15
liztormato joined
|
|||
jnthn | Hm, on Windows testing File::Find fails, alas | 17:15 | |
liztormato | has $.a will do { ... }. # like it for the similarity with do { ... } | 17:16 | |
masak | liztormato: hm, what's the semantics of that? | 17:18 | |
liztormato: ISTR `will do` is the way to attach a routine body to a routine, or sump'n. | |||
liztormato | Alternate name for "will lazy" | 17:19 | |
masak continues backlogging, confused | 17:22 | ||
jnthn | masak: See my gist from earlier today where I sketched a "will lazy" trait in response to a question on channel | 17:23 | |
17:23
liztormato left,
domidumont joined
17:24
liztormato joined
|
|||
masak | nodnod | 17:24 | |
it will all make sense at the end of the rainb^Wbacklog | 17:25 | ||
liztormato: does the fix at irclog.perlgeek.de/perl6/2015-05-02#i_10537026 suggest that we have insufficient spectest coverage for the List.roll(Inf) case? | 17:26 | ||
liztormato | Yes | ||
masak .oO( make sure this call does not run forever ) | |||
jnthn | .oO( They see me .roll-in', they failin' ) |
17:27 | |
masak | [backlog] should lazy default attributes be part of doc.perl6.org/language/classtut ? did someone file an issue about this? | 17:32 | |
s/default attributes/attribute defaults/ | |||
jnthn | masak: Once we decide what we're callin' the trait | ||
TimToady | I guess they can always use .duckmap if they wish to distinguish .[] from .{} | ||
masak | I think it's orthogonal to that, no? lazy attribute defaults already exist in Perl 6 and work in Rakudo. | 17:33 | |
m: class C { has $.x = "OH HAI" }; say C.new(:x(42)).x; say C.new.x | |||
camelia | rakudo-moar 86b1b2: OUTPUT«42OH HAI» | ||
masak | jnthn: that ^ | ||
jnthn | Oh... | ||
liztormato | Thats at object build time | 17:34 | |
17:35
virtualsue joined
|
|||
TimToady | anyway, if we're going to encourage people to write 'method AT-KEY' and such, they also need 'is nodal' | 17:35 | |
TimToady needs to commute to the city of Lost Wages... | 17:36 | ||
afk till evening & | |||
masak | liztormato: yes. rjbs was asking about that, and didn't find the answer in doc.perl6.org/language/classtut | 17:37 | |
masak submits an issue | |||
liztormato | To be clear: has $.a = 42 is not lazy but run at build time | 17:38 | |
masak | oh! yes, you are right. those two are not the same. | ||
which totally motivates having a way to do the lazy thing, too. | 17:39 | ||
tbh, I'd be fine with `has $.x is lazy = "OH HAI";` | |||
liztormato | Otoh, why isn't lazy the default? | ||
masak | because that'd be surprising. | 17:40 | |
17:42
virtualsue left
|
|||
masak | oh, now I hit the point irclog.perlgeek.de/perl6/2015-05-02#i_10537636 where jnthn++ suggest doing `is lazy` as a module. | 17:45 | |
+1 | |||
if people want it badly enough, that's the way to prototype it and then eventually core it :) | |||
17:45
virtualsue joined
|
|||
masak | [backlog] by the way, speaking of irclog.perlgeek.de/perl6/2015-05-02#i_10537654 -- is it reasonable to expect `has $.x = !!!` to actually end up emitting a "nice" error message saying something about $.x not being supplied? | 17:46 | |
because that... would be... *swoon* | 17:47 | ||
liztormato | Let's prototype it in a module ;-) | ||
17:48
diana_olhovik_ left
|
|||
jnthn | Probably do-able with a little cunning ;) | 17:49 | |
dinner & | |||
liztormato | masak: what made me put will lazy in the core, is that it is apperemtly a standard feature of Moose | 17:51 | |
RabidGravy | it is | ||
mst | it isn't | 17:52 | |
Moose has lazy_build, which is not simple lazy | |||
well, 'lazy => 1' exists | |||
which I guess is equivalent to a trait | |||
the Moo/MooseX::AttributeShortcuts version is much nicer | |||
RabidGravy | didn't lazy_build go away? | ||
mst | has thing => (is => 'lazy', builder => sub { ... }); | ||
no, it's still there, just not really recommended | 17:53 | ||
largely because I designed it for a very specific case in a web metaframework and then somebody added it to Moose core without thinking about it | |||
hence when I did Moo, I designed a sensible version and supported that | |||
liztormato: I would prototype outside but want it to be cored later | 17:56 | ||
pretty much all of my attributes these days are either ro+required or lazy w/a builder method | |||
because, well, mutable state is the enemy :) | 17:57 | ||
masak | liztormato: putting `will lazy` in core might be a nice thing -- but it doesn't stand out as obviously so. | ||
liztormato: I would be more convinced if there was a known second use case besides lazy attributes :) | |||
17:57
Isp-sec joined
|
|||
timotimo | hey, hold on, this only just started existing today! ;) | 17:58 | |
oh | |||
(backlogged) | |||
liztormato | Can't think about another use case just yet | 17:59 | |
But the current implementation uses rakudo internals specific code, so it's tied pretty tightly to the core | 18:00 | ||
Specifically Attribute.compose | 18:01 | ||
18:02
vendethiel left
|
|||
liztormato | Cycling again& | 18:04 | |
18:04
liztormato left,
vendethiel joined
18:08
diana_olhovik_ joined
|
|||
RabidGravy | lazy might concievably enable initializing with the result of a method (i.e. no "may not be used on partially constructed objects" if tryin that now) | 18:09 | |
(of course you can do that right now with a similarly named method as the attribute) | 18:12 | ||
18:14
mohij left
18:18
iv left
|
|||
moritz | since the RHS of an attribute initializer is already a thunk (code object), it would make sense to use it as initializer for lazy attributes too | 18:19 | |
18:29
zakharyas left
|
|||
mst | one thing that Moo does that's a very useful affordance is that | 18:29 | |
has foo => (is => 'lazy', builder => sub { ... }); | |||
installs that sub as _build_foo and then calls it by name | 18:30 | ||
so you can method modifier or replace it in subclasses, roles etc. | |||
18:38
alini left
|
|||
RabidGravy | which is nice | 18:39 | |
always a pain having to manually install the builders if you are creating them in e.g. an attribute trait | 18:41 | ||
18:41
aindilis left
18:46
aindilis joined
|
|||
masak | RabidGravy: sounds a lot like the `builder` thing mst++ just metnioned. | 18:48 | |
RabidGravy | yes | ||
masak | RabidGravy: with the little I've used Moose, I feel there's good use for both `lazy` and `builder`. | 18:49 | |
18:49
spider-mario left
|
|||
RabidGravy | but if you had lazy you could do: | 18:49 | |
$.a is lazy = $.get_a; | 18:50 | ||
for instance | |||
or is it | |||
has $.a is lazy with bulder { ..... } | 18:51 | ||
18:52
telex left
18:54
telex joined
|
|||
RabidGravy | which would be quite good fun | 18:54 | |
jdv79 | p6 is now taking from Moose? dizzying. | ||
seems kind of warped and/or incestuous | 18:55 | ||
RabidGravy | it's more that it's quite a common pattern and Moose has a good extent example | 18:56 | |
extant rather | |||
18:57
mohij joined
|
|||
jdv79 | i'm all for it except i find the p6 stuff tends to be more well thought out than the likes of Moose in terms of holistics. | 18:58 | |
masak | that's what I'm after here too. | 18:59 | |
TimToady++ has said that a feature is seldom there for just one reason. | |||
jdv79 is a heavy Moose user - disclaimer | |||
19:00
vendethiel- joined
19:01
vendethiel left
|
|||
masak | TimToady: dangit, now I see anapests everywhere! :P www.salon.com/2015/04/30/i_secretly..._500_days/ | 19:03 | |
19:10
rindolf left
19:11
spider-mario joined
19:14
FROGGS[mobile] joined
|
|||
FROGGS[mobile] | Hi #perl6 | 19:14 | |
lizmat | FROGGS[mobile] o/ | 19:15 | |
FROGGS[mobile] | lizmat: I'm fine :o) | ||
masak | \o | ||
lizmat | good to hear! | ||
FROGGS[mobile] | just had to build a fence and doors for a friend, and today was birthday party for $son | 19:17 | |
and now every bit of my body is acking, and tomorrow is train ride to the GPW in Dresden | 19:18 | ||
lizmat | ah, they come in groups, those birthdays :-) | ||
won't be at the GPW :-( | 19:19 | ||
FROGGS[mobile] | no, it is a belated Party :o) | ||
yeah :/ | |||
lizmat | are you aware at least some train drivers in Germany will be on strike soon ? | ||
FROGGS[mobile] | it will be just lichtkind and me afaik | ||
19:19
zeleiadi joined
|
|||
FROGGS[mobile] | yes, from Tue to Mon | 19:20 | |
lizmat | hence your travel tomorrow :-) | ||
FROGGS[mobile] | and we attempt to get back on Sat ó.ò | ||
nwc10 is not aware of this. | |||
but is now | |||
bother? | |||
FROGGS[mobile] | there will be some trains, so I dont care much | 19:21 | |
there is always some sort of SCHIENENERSATZVERKEHRRR!!! | 19:22 | ||
:o) | |||
rurban | there's a big car from frankfurt | ||
19:22
zakharyas joined
|
|||
rurban | do you need to come from Berlin? | 19:23 | |
What I heard they'll start their strike on Tuesday - Wednesday | 19:24 | ||
masak | 1.3k tickets in RT!? irclog.perlgeek.de/perl6/2015-05-03#i_10538762 -- wow, that snuck up on me as well! | ||
but having a lot of tickets filed on you just means that you're popular. | |||
(and buggy) :P | |||
jnthn | .tell lizmat Attribute isn't Rakudo-specific; think S12 mentions it | 19:26 | |
yoleaux | jnthn: I'll pass your message to lizmat. | ||
masak | was gonna say. | ||
lizmat | jnthn: true, but Attribute.compose *is*, afaik | ||
yoleaux | 19:26Z <jnthn> lizmat: Attribute isn't Rakudo-specific; think S12 mentions it | ||
masak | that's probably more an oversight than anything... | ||
lizmat | at least until we have a COMPOSE phaser | ||
masak | anyway, what feels weird to me is coupling `will do` (or whatever it ends up being called) to attributes only. | 19:27 | |
that feels somehow underpowered. | |||
lizmat | well, others are for variables only: will leave, will end, etc | 19:28 | |
jnthn | lizmat: It falls into the same category of much of the rest of the MOP, I think. | ||
masak | oh, there actually are a lot of new RT tickets. that explains it. | ||
FROGGS[mobile] | rurban: I have three kids with me, a car is no option I fear | 19:29 | |
nwc10 | FROGGS[mobile]: it might be that I simply can't make it. We're supposed to be on the sleeper overnight on Tuesday. I don't think we have any viable way to make a sane alternative plan. | ||
FROGGS[mobile] | yeah :o( | ||
masak | lizmat: I didn't get the impression the others are for variables only. | ||
lizmat | I'm not sure what "will leave" means for an attribute | 19:30 | |
masak | lizmat: I've seen no example of it, but I would expect being able to put `will end` on a routine, for example. | ||
lizmat | m: { my $a will leave say "bye" = 42; say $a } | ||
camelia | rakudo-moar 86b1b2: OUTPUT«5===SORRY!5=== Error while compiling /tmp/0od20F5qIbMissing blockat /tmp/0od20F5qIb:1------> 3{ my $a will leave7⏏5 say "bye" = 42; say $a } expecting any of: parameterized block» | ||
lizmat | m: { my $a will leave { say "bye" } = 42; say $a } | ||
camelia | rakudo-moar 86b1b2: OUTPUT«42bye» | ||
lizmat | m: { my $a will end { say "bye" } = 42; say $a } | 19:31 | |
camelia | rakudo-moar 86b1b2: OUTPUT«42» | ||
rurban | FROGGS[mobile]: 3 kids? Wife also? there are 2 more wifes there. | ||
lizmat | hmmm... guess something's not bothering exeucting the END block? | ||
masak | that looks reportable. | 19:32 | |
FROGGS[mobile] | rurban: aye, and nice :o) | ||
masak | anyway, I look forward to `is lazy` provided by a module :) | ||
rurban | We have a very nice rooftop terrace in the venue with cafe and perfect overview. kids can stay there | 19:33 | |
19:33
domidumont left
|
|||
FROGGS[mobile] | cool... and they want to visit the zoo I think | 19:34 | |
19:34
tinyblak left
|
|||
FROGGS[mobile] | but we don't have a concrete Plan yet | 19:34 | |
raydiak tried a 'is lazy' module w/the metamodel, but you can't get at the default closure w/out nqp; also tried a version that used a Proxy, but ran into some other problem | 19:35 | ||
lizmat | masak: don't bother, it's NYI | 19:36 | |
raydiak | .tell adu github.com/andydude/p6-c-parser/issues/4 | ||
yoleaux | raydiak: I'll pass your message to adu. | ||
lizmat | "for some reason exceptions are caught and not rethrown" as a comment in the code | ||
jnthn | raydiak: There's a .build method on Attribute | ||
raydiak | jnthn: part of the issue was it's a BOOTSTRAPATTR or whatever it's called | 19:37 | |
lizmat | jnthn: regarding END/INIT phasers: to what Block should I attach those ? | 19:38 | |
jnthn | lizmat: They don't go on blocks... | ||
lizmat | can I get from a PseudoStash to the associated Block ? | ||
ah that would explain | |||
jnthn | I think there's an add_phaser method in World iirc | ||
lizmat looks deeper | |||
ah, then the problem is: how to get at World in the trait_mod | 19:39 | ||
jnthn | raydiak: Those only show up in a handful of internal things, not in user code... | ||
lizmat: $*W :P | |||
lizmat | aha... hmm... | ||
raydiak | jnthn: not sure what I was doing, but it was in my own class; playing with it again now using your .build hint, I'll see how far I get | 19:40 | |
FROGGS[mobile] | lizmat: you can access $*W because traits are called from the actions directly, and dynamic variables "leak" | 19:41 | |
lizmat | aha, that make sense :-) | ||
jnthn | .oO( it's a leakture, not a bug... :) ) |
19:42 | |
RabidGravy | :) | ||
FROGGS[mobile] | that's also why Slang::Tuxic can just access %*LANG in EXPORT | 19:43 | |
lizmat looks deeper$ 6 ' { my $a will end { say "bye" } = 42 }' | 19:45 | ||
===SORRY!=== | |||
Object of type Block in QAST::WVal, but not in SC | |||
jnthn: ^^ | |||
suggestions ? | |||
code in trait: $*W.add_phaser($v.slash, 'END', $block) | |||
jnthn | $*W.add_object($block); before it, mebbe | 19:46 | |
FROGGS[mobile] | $*W.add_object($bl... | ||
lizmat | testing | ||
FROGGS[mobile] | phone typing ducks | ||
lizmat | suckd you mean :-) | 19:47 | |
FROGGS[mobile] | yeah, that :D | ||
19:48
zeleiadi left,
spider-mario left
|
|||
rurban | Wasn't there a plan to support unicode ops also? like → ⇒ ⇔ ≠ ≤ ≥ ÷ I added this now to our perl5: github.com/rurban/perl/commits/unicode-parse | 19:49 | |
sjn | rurban: you can already make your own unicode operators in Perl 6 | 19:52 | |
19:52
spider-mario joined
|
|||
raydiak | m: sub trait_mod:<is> (Attribute $a, :$lazy!) { say $a.build.perl }; class Foo { has $.foo is lazy = rand } # is this because the trait is parsed before the default? | 19:52 | |
camelia | rakudo-moar 86b1b2: OUTPUT«Mu» | ||
lizmat | sjn: we have them for set operations, why not for "normal" math ops as well ? | 19:53 | |
sjn | sure :) | ||
jnthn | lizmat: It's just a module away ;P | ||
raydiak: Yeah, you'd need to do something at compose time, as in the lazy thing I wrote | |||
lizmat | by that logic, we should get rod of unicode set operators and put them in the ecosystem | 19:54 | |
*rid | |||
sooner rather than later | |||
DrForr | Or resort to trigraphs :) | ||
raydiak | jnthn: thanks, will read, haven't backlogged...last tried this a week or two ago | 19:55 | |
19:55
mohij left
|
|||
FROGGS[mobile] | gnight | 19:55 | |
19:55
FROGGS[mobile] left
19:56
mohij joined
19:57
yqt joined
|
|||
raydiak backlogs, sees people working on it, goes and does something else :) | 20:00 | ||
20:01
espadrine left
20:07
mohij left
20:09
Rounin left
|
|||
dalek | kudo/nom: cfdf0a3 | lizmat++ | src/core/Variable.pm: my $a will end { say "byebye" } now works |
20:10 | |
timotimo | is that for when a variable leaves its scope? | 20:11 | |
lizmat | no, that's "will leave" | 20:12 | |
this is when we end the process | |||
vendethiel- | lizmat++ | ||
lizmat | m: { my $a will end { say "bye" } = 42; say $a } END say "byebye" | ||
camelia | rakudo-moar 86b1b2: OUTPUT«5===SORRY!5=== Error while compiling /tmp/W246ywT3tyStrange text after block (missing semicolon or comma?)at /tmp/W246ywT3ty:1------> 3$a will end { say "bye" } = 42; say $a }7⏏5 END say "byebye" expecting any of: infix…» | ||
lizmat | m: { my $a will end { say "bye" } = 42; say $a }; END say "byebye" | ||
camelia | rakudo-moar 86b1b2: OUTPUT«42byebye» | ||
lizmat | $ 6 '{ my $a will end { say "bye" } = 42; say $a }; END say "byebye"' | 20:13 | |
42 | |||
byebye | |||
bye | |||
vendethiel- | Since we lost the "nested phaser" a few days/weeks ago, this "will" thing will most definitely save us :-) | ||
timotimo | hum? | ||
vendethiel- | mean ENTER { my Lock $l .= new; LEAVE { $l.free } }; <- this used to work but doesn't anymore, right? | 20:14 | |
lizmat | there is no Lock.free ? | 20:15 | |
vendethiel- | that's just an exemple of nested phaser. | ||
(about lexical scope etc) | 20:16 | ||
lizmat | ah, but you don't have to have a scope on a phaser | 20:17 | |
m: { ENTER my $a = 42; LEAVE say $a } | |||
camelia | rakudo-moar 86b1b2: OUTPUT«42» | ||
vendethiel- | yeah, but in this case, it might be "cleaner" to leave the Lock untouchable from outside the phaser :-) | 20:18 | |
lizmat | m: { ENTER { my $a = 42; LEAVE say $a } } | ||
camelia | rakudo-moar 86b1b2: OUTPUT«42» | ||
lizmat | m: { ENTER { my $a = 42; LEAVE say $a }; LEAVE say "bye" } | ||
camelia | rakudo-moar 86b1b2: OUTPUT«42bye» | ||
lizmat | not the same thing | ||
vendethiel- | great. then I'm not sure what I was confusing that with, or which part of the (I think) p6weekly I misread.. | 20:19 | |
20:20
diana_olhovik_ left
|
|||
timotimo | if it's from the weekly, it's more likely i explained something poorly than you reading it wrong ;) | 20:20 | |
masak | vendethiel-: I submitted the LEAVE-inside-ENTER thing not working as an RT ticket, but jnthn rejected it on arguably good grounds. | 20:21 | |
vendethiel-: (thrust of the argument was "it's not spec") | |||
vendethiel- | aaah, that's probably that then, masak. timotimo++: nope, don't believe that. get some karma instead | ||
masak | I could find you the RT ticket if you're interested. | ||
vendethiel- | if it's not too much time, I am indeed | 20:22 | |
ugexe | m: role r1 { has $!rv; submethod BUILD(:$!rv = 1) { say $!rv }; }; role r2 does r1 { has $!rv2; submethod BUILD(:$!rv2 = 2) { say $!rv2 }; }; my $x = "xx"; $x does r2; # is there another way to access self at build time? | ||
camelia | rakudo-moar 86b1b2: OUTPUT«Package 'r2' already has a Submethod 'BUILD' (did you mean to declare a multi-method?) in any add_method at src/gen/m-Metamodel.nqp:434 in any apply at src/gen/m-Metamodel.nqp:1729 in any compose at src/gen/m-Metamodel.nqp:1882 in any speci…» | ||
skids | ugexe: by abusing attribute default values. | 20:23 | |
dalek | kudo/nom: 13dc82f | lizmat++ | src/core/Variable.pm: Some code esthetics |
||
vendethiel- | haha, I love how "will begin" is implemented :-) | ||
20:23
spider-mario left,
darutoko left
|
|||
masak | vendethiel-: rt.perl.org/Ticket/Display.html?id=123894 | 20:24 | |
vendethiel- | thanks masak | ||
masak | (I remembered slightly wrongly, because it wasn't those two phasers. but I think the reply still holds up for your case.) | ||
jnthn | masak: Note that { LEAVE say now - ENTER now; sleep 1; } should work out, and is different from { LEAVE { say now - ENTER now } } | 20:26 | |
vendethiel- | m: my $a = 0 will next { $a++ }; while $a < 50 { say $a }; #let's reinvent C! | ||
camelia | rakudo-moar 86b1b2: OUTPUT«5===SORRY!5=== Error while compiling /tmp/CIkcORPWd8Two terms in a rowat /tmp/CIkcORPWd8:1------> 3my $a = 07⏏5 will next { $a++ }; while $a < 50 { say expecting any of: infix infix stopper postfix …» | ||
vendethiel- | m: my $a will next { $a++ } = 0; while $a < 10 { say $a }; #let's reinvent C! | ||
camelia | rakudo-moar 86b1b2: OUTPUT«5===SORRY!5=== Error while compiling /tmp/4H9dQ63DFVVariable '$a' is not declaredat /tmp/4H9dQ63DFV:1------> 3my $a will next { $a++7⏏5 } = 0; while $a < 10 { say $a }; #let's expecting any of: postfix» | ||
masak | jnthn: *nod* | ||
jnthn | masak: Rakudo seems ot get the distinctiong right too | 20:27 | |
masak | nice. | ||
jnthn | masak: Sadly, ENTER doesn't work as an rvalue yet | ||
That's one of the tickets open in my browser for a couple of days to look at | |||
But I ended up working on making our hashes use a bunch less memory instead :) | |||
lizmat | jnthn: given a &block, how do I get to set $_ inside that block | 20:28 | |
that's one of the missing features of will foo { ... } atm | |||
jnthn | lizmat: Depends exactly how it's compiled | ||
lizmat: If with implicit, then passing it as an argument when invoking the block should work. | 20:29 | ||
lizmat | it enters as a $block in a trait_mod | ||
jnthn | m: my $a = { say $_ }; $a(42) | ||
camelia | rakudo-moar 86b1b2: OUTPUT«42» | ||
lizmat | ah, ok... | 20:30 | |
hmmm... | |||
jnthn | You can try that. If it doesn't work, we may be able to tweak how will foo { ... } blocks parse... | ||
20:31
spider-mario joined
|
|||
lizmat | $ 6 'my $a will leave { .say } = 42' | 20:34 | |
Too many positionals passed; expected 0 arguments but got 1 | |||
I guess we need to look at that then | |||
jnthn | rule trait_mod:sym<will> { <sym> [ <identifier> || <.panic: 'Invalid name'>] <pblock> } | 20:36 | |
Try making it <pblock(1)> at the end | |||
20:36
Foxcool left
20:37
Foxcool joined
|
|||
lizmat | will do | 20:38 | |
20:38
vendethiel- is now known as vendethiel
|
|||
lizmat | $ 6 'my $a will leave { .say }; $a = 42' | 20:42 | |
(Any) | |||
yeah, it gets the original value of the var | |||
$v.block.add_phaser('LEAVE', { $block($v.var) } ); # too naive | 20:43 | ||
jnthn | Very much so :) | ||
I guess in $v you have the variable's name | 20:44 | ||
lizmat | the Variable object | ||
jnthn | Right, but somehow you can get to the name of the symbol | ||
lizmat | multi sub trait_mod:<will>(Variable:D $v, $block, :$leave! ) { | ||
yeah, that would be $v.name | 20:45 | ||
20:45
Foxcool left
|
|||
jnthn | Hm, this is all rather related to the thread safety issues we have with phasers. But for now, for leave/enter at least, we know the caller of the trait is the relevant frame | 20:46 | |
So could try something like nqp::atkey(nqp::ctxcaller(nqp::ctx()), $v.name) or so | |||
Which is a cheaper spelling of CALLER::{$v.name} I guess | |||
lizmat | will play with that | 20:47 | |
20:47
Foxcool joined
20:49
mohij joined
|
|||
lizmat | $ 6 'my Int $a will leave { .say }; $a = 42' | 20:50 | |
Lexical with name '$a' does not exist in this frame | |||
guess I need to move a few more frames ? | |||
jnthn | oh...argh | 20:51 | |
hm, wait, show me le patch | |||
lizmat | $v.block.add_phaser('LEAVE', { $block(nqp::atkey(nqp::ctxcaller(nqp::ctx()), $v.name)) } ); | 20:52 | |
jnthn | yeah, then you're talking about the trait's caller | ||
Oh now, you wrapped it | |||
Hmm | |||
*no | |||
lizmat | again, being naive there :-) | 20:53 | |
jnthn | Yeah, but the wrapping is what I thought you'd forgot | ||
But it looks right | |||
Does --optimize=off help? | |||
lizmat | $ perl6 --optimize=off -e 'my Int $a will leave { .say }; $a = 42' | 20:54 | |
Lexical with name '$a' does not exist in this frame | |||
nah | |||
jnthn | Suspected not. | ||
20:54
Foxcool left
|
|||
jnthn | Ohhh | 20:54 | |
The LEAVE thing is processed by something not called directly | 20:55 | ||
So yes, you do need an extra level | |||
lizmat | yeah, trying that now | ||
what is the equivalent of CALLER::CALLER:: ? | |||
jnthn | Search for leave_handler or block_exit_handler or so in BOOTSTRAP.nqp for an idea | ||
Just call nqp::callerctx another time :) | |||
ugexe | m: my $a = [1,2,3]; my $b = [4,5]; my $c = []; my $d = [$a (|) $b (|) $c]; say $d; # the ordering here seems to be causing pandas current test failure. is it a bug with set or should panda change what it expects order wise? | 20:57 | |
camelia | rakudo-moar 13dc82: OUTPUT«set(5, 4, 3, 1, 2)» | ||
lizmat | it shouldn't | ||
jnthn | Panda shouldn't expect order there | 20:58 | |
lizmat | sets are basically a restricted hash and therefore the order is not fixed (anymore) | ||
$ 6 'my Int $a will leave { .say }; $a = 42' | |||
42 | |||
yeah! | |||
jnthn | Well, it never was on JVM< and Panda has had JVM issues recently too | ||
lizmat: yay :) | |||
20:59
egrep left,
egrep joined
|
|||
lizmat | $ 6 'my Int $a will enter { $_ = 42 }; say $a' | 21:01 | |
42 | |||
aren't KEEP / UNDO / FIRST / NEXT / LAST the same really ? | |||
21:01
TimToady left
|
|||
masak | the latter three may only occur in loops. | 21:02 | |
jnthn | We won't get it to work on the last 3 I doubt | ||
lizmat | yeah, but from the view of scopes, they would be the same, no? | ||
ok | |||
jnthn | But KEEP/UNDO are viable with the same technique | ||
As they're just conditioned leaves | |||
lizmat | I'll try KEEP / UNDO :-) | ||
masak | yeah, KEEP/UNDO are subsets of LEAVE | 21:03 | |
21:08
Foxcool joined
|
|||
lizmat | ugexe: merged your PR | 21:10 | |
ugexe | thanks | ||
lizmat | $ 6 'my Int $a will undo { .say }; $a = 42; fail' | 21:12 | |
42 | |||
:-) | |||
dalek | kudo-star-daily: 9f3195c | coke++ | log/ (2 files): today (automated commit) |
21:13 | |
rl6-roast-data: 7eb6578 | coke++ | / (9 files): today (automated commit) |
|||
masak | 'night, #perl6 | ||
21:14
zakharyas left
|
|||
lizmat | good night. masak | 21:14 | |
RabidGravy | yep panda worky again | 21:15 | |
21:15
dolmen joined
|
|||
lizmat | looks like FIRST is like ENTER | 21:17 | |
$ 6 'for ^2 { my Int $a will first { $_ = 42 }; say $a }' | |||
42 | |||
(Int) | |||
RabidGravy | nice :-) | 21:21 | |
21:22
vendethiel left
|
|||
dalek | ast: 87e6d13 | coke++ | S02-types/declare.t: RT #124461 - replace flawed test |
21:22 | |
synbot6 | Link: rt.perl.org/rt3//Public/Bug/Displa...?id=124461 | ||
21:25
cognominal joined
|
|||
[Coke] | can someone demonstrate a "num" overflow that doesn't happen on Num ? | 21:26 | |
21:26
RabidGravy left
21:28
vendethiel joined
|
|||
[Coke] | m: say Num.max; say num.max; | 21:30 | |
camelia | rakudo-moar 13dc82: OUTPUT«Cannot call max(Num: ); none of these signatures match: (Any:D: *%_) (Any:D: Any $by, *%_) in block <unit> at /tmp/x_Li2GKtJH:1» | ||
[Coke] | m: say num.max; | 21:31 | |
camelia | rakudo-moar 13dc82: OUTPUT«Cannot call max(num: ); none of these signatures match: (Any:D: *%_) (Any:D: Any $by, *%_) in block <unit> at /tmp/618_W1lICG:1» | ||
lizmat | m: say num.Range.max | ||
camelia | rakudo-moar 13dc82: OUTPUT«Inf» | ||
[Coke] | (locally that says -Inf) | ||
lizmat | m: say int.Range.max | ||
camelia | rakudo-moar 13dc82: OUTPUT«9223372036854775807» | ||
lizmat | m: say int8.Range.max | ||
camelia | rakudo-moar 13dc82: OUTPUT«127» | ||
lizmat | m: say bit.Range.max | 21:32 | |
camelia | rakudo-moar 13dc82: OUTPUT«Inf» | ||
lizmat | yuck | ||
21:32
bjz left
|
|||
lizmat | m: say int1.Range.max | 21:33 | |
camelia | rakudo-moar 13dc82: OUTPUT«0» | ||
lizmat | m: say int1.Range | ||
camelia | rakudo-moar 13dc82: OUTPUT«-1..0» | ||
lizmat | m: say uint1.Range | ||
camelia | rakudo-moar 13dc82: OUTPUT«0..1» | ||
21:34
TimToady joined
|
|||
dalek | ast: 45e6d35 | coke++ | S02-types/declare.t: RT #124461 - explicitly check that type boxed. |
21:34 | |
synbot6 | Link: rt.perl.org/rt3//Public/Bug/Displa...?id=124461 | ||
dalek | ast: 70231d3 | coke++ | S02-types/declare.t: RT #124467 - native junctions are no more |
21:36 | |
synbot6 | Link: rt.perl.org/rt3//Public/Bug/Displa...?id=124467 | ||
dalek | kudo/nom: 87b1eea | lizmat++ | src/ (2 files): Variable will foo &block cleanup - will init/post/compose will now throw NYI instead of silently doing nothing - will enter/leave/keep/undo/first/pre will now set $_ correctly jnthn++ for support and suggestions! |
21:41 | |
timotimo | can we just write multiple "will" in a row without problems? | 21:44 | |
lizmat | yes: | 21:45 | |
$ 6 'my $a will enter { $_ = "1".IO.open } will leave { .close }; say $a.lines' | |||
%*ENV<RAKUDO_VERBOSE_STACKFRAME>=1; sub a { die }; a | |||
the 2nd line is what is in file "1" :-) | 21:46 | ||
[Coke] | down to 1292 tickets. | ||
lizmat | looking at this, I wonder whether will phasers such as "enter" shouldn't write their result to $_ automagically | ||
[Coke] | uuuugh. | 21:47 | |
lizmat | seems this NY hackathon created more work than it solved :-) | ||
21:48
dolmen left
21:49
vendethiel left
|
|||
timotimo | they do what now? | 21:50 | |
write their result to $_? | |||
is that only for will phasers or also for block phasers? | |||
lizmat | nono, the variable is available as $_ inside the scope | ||
[Coke] | lizmat: little bit, yah. | ||
timotimo | ah | ||
so you could my $a will enter { .=lc }; OSLT? | 21:51 | ||
lizmat | my $a will enter { "1".IO.open } will leave { .close } # feels more natural | ||
my $a will enter { .=lc } = "FOO"; say $a # na, the initialization happens *after* the enter block is executed | 21:52 | ||
so I guess the use of "will enter" is limited anyway | 21:54 | ||
timotimo | now to look at the racyness of Proc::Async | ||
21:54
spider-mario left
|
|||
timotimo | how hard is it gonna be anyway ... ~_~ | 21:54 | |
21:55
spider-mario joined
|
|||
jnthn | [Coke]: num and Num can store the same value range | 21:57 | |
[Coke]: Though I had an idea for testing the decl is effective: write a multi x(num) { 1 }, multi x (Num) { 2 }, and then make sure calling it on a variable decalred as a num calls #1 | |||
21:58
virtualsue left
|
|||
timotimo | oh wow. these valgrind thread error detector tools are *really* noisy | 21:59 | |
==30166== ERROR SUMMARY: 2464 errors from 104 contexts (suppressed: 4531 from 77) | |||
probably not going to go through all of these tonight | |||
lizmat wishes #perl6 a good night! | 22:00 | ||
jnthn | o/ lizmat | ||
timotimo | gnite lizmat | ||
jnthn | timotimo: Yeah, well we deliberately race on things like the call count used for specialization. | 22:01 | |
timotimo | it seems like the DRD thinks our frame invocation is racy ... could be it just doesn't understand the libatomicops thing we use there? | ||
==30166== Conflicting load by thread 2 at 0x09d0fca0 size 8 | |||
==30166== at 0x4D874DD: AO_compare_and_swap_full (x86.h:142) | 22:02 | ||
jnthn | That's also possible | ||
timotimo | it might have an option for this kind of thing | ||
22:02
Foxcool left
|
|||
jnthn | I've not had time to dig deeply into its analysis model yet | 22:02 | |
timotimo | The macros DRD_IGNORE_VAR(x), ANNOTATE_TRACE_MEMORY(&x) and the corresponding client request VG_USERREQ__DRD_START_SUPPRESSION. Some applications contain intentional races. There exist e.g. applications where the same value is assigned to a shared variable from two different threads. It may be more convenient to suppress such races than to solve these. This client request allows to suppress such races. | 22:04 | |
there's also ANNOTATE_BENIGN_RACE_SIZED and ANNOTATE_BENIGN_RACE_STATIC | |||
ugexe | is there a way with phasers to access self to do something like: class XX { has $.var is rw; END { say "var = $.var" }; }; my $q = XX.new(var => 1); | 22:05 | |
jnthn | ugexe: No, because the phaser is not once per instance. | 22:06 | |
ugexe: I'd maintain a list of instances and then have the phaser to over them | 22:07 | ||
*go over them | |||
timotimo | jnthn: how do you feel about adding client requests all over moarvm's code base? | 22:11 | |
jnthn | timotimo: I generally dislike clutter. | ||
timotimo | fair enough | 22:12 | |
jnthn | Is there not a supressions file approach like in valgrind? | ||
uh, valgrind memcheck I mean | |||
timotimo | i haven't read up on that yet | ||
jnthn | k | ||
timotimo | suppression file lines start with what the suppression is called and then what tools it applies to | 22:16 | |
it seems like the method itself is tool-independent, or tool-agnostic or something like that | |||
dalek | ast: 5f6d6a6 | coke++ | S02-types/declare.t: RT #124461 add another verification for num Hard to distinguish between between num/Num jnthn++ |
22:18 | |
synbot6 | Link: rt.perl.org/rt3//Public/Bug/Displa...?id=124461 | ||
timotimo | jnthn: what about teaching the valgrinds about how the fixed size allocator works so that we'll be pointed to the place where a chunk of it gets "allocated", rather than where a page is added | 22:19 | |
jnthn | timotimo: I usually just switch the FSA into debug mode if I want that so far. | 22:20 | |
timotimo | helgrind seems to report writes to any place inside a page as conflicting | ||
jnthn | timotimo: Where it degenerates to using malloc for all | ||
Ah | |||
timotimo | ah, neato | ||
there's a -D for that? | |||
jnthn | you just tweak an 0 to a 1 at the top of fixedsizealloc.c | ||
But feel free to make something more convenient | |||
timotimo | OK | ||
maybe later | 22:21 | ||
22:22
kaare_ left
22:28
rurban left
|
|||
timotimo | so one of the races seems to be spesh possibly dropping in a spesh candidate while other threads could be invoking the frame | 22:31 | |
i think we race that intentionally? | 22:32 | ||
jnthn | I think we do something to protect the installation of 'em too | 22:34 | |
timotimo | huh ... interesting. reentrantmutex_lock (a read) is apparently conflicting with initialize_mutex (a write) | ||
there are interesting things to see in here | |||
but the chances that i'll figure out what's wrong with the Proc::Async implementation with this tool are ... slim | |||
22:40
mohij left
22:46
risou is now known as risou_awy,
risou_awy is now known as risou
|
|||
timotimo | the gen2 seems to trip up helgrind, too | 22:49 | |
22:53
rarara joined
|
|||
timotimo | Address 0x9ea49f0 is 9,824 bytes inside a block of size 12,288 alloc'd - this is all so useless :( | 22:54 | |
rjbs | perl6 has --doc to show program docs and -M which has to resolve a module, but I don't see a way to get module docs. Am I missing something? | 23:05 | |
timotimo | oh, that's a good point | ||
23:09
yqt left
23:12
vendethiel joined
23:23
spider-mario left
23:28
Isp-sec left
23:34
gfldex left,
vendethiel left
|
|||
rjbs | m: my %h; %h<a> = 1; %h.perl | 23:51 | |
camelia | ( no output ) | ||
rjbs | m: my %h; %h<a> = 1; say %h.perl | ||
camelia | rakudo-moar 87b1ee: OUTPUT«{:a(1)}<>» | ||
rjbs | What's the trailing <> mean? | ||
timotimo | "decont" | 23:56 | |
23:56
mule joined,
mule left
|
|||
timotimo | i'm hoping to find something in valgrind that'd let us annotate a traceback that includes MVM_interp_run with the moar bytecode traceback | 23:57 | |
rjbs | I see that "decont" has already been complained about recently, so I will be mostly quiet. | 23:59 |