»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:, or /msg camelia p6: ... | irclog: irc.perl6.org or colabti.org/irclogger/irclogger_logs/perl6 | UTF-8 is our friend! Set by moritz on 22 December 2015. |
|||
00:03
vendethiel- left
00:04
Woodi left
|
|||
tweakism | m: " ".chars | 00:08 | |
camelia | ( no output ) | ||
tweakism | m: say " ".chars | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«1» | ||
00:08
rindolf left
00:11
Woodi joined
00:12
Ben_Goldberg joined
00:13
AlexDaniel left
00:14
BenGoldberg left
00:18
virtualsue left
|
|||
timotimo | i have cake and i have momodora; the day is improving | 00:20 | |
00:29
edehont joined
|
|||
Hotkeys | m: say 1...3...-2...0...-5 | 00:32 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«(1 2 3 2 1 0 -1 -2 -1 0 -1 -2 -3 -4 -5)» | ||
Hotkeys | I didn't realize you could chain like that | ||
partly_ | m: role F {} sub MAIN() does F{} | 00:33 | |
m: role F {} sub MAIN() does F{ say "Boo" } | |||
camelia | rakudo-moar 0ad8b3: OUTPUT«5===SORRY!5=== Error while compiling /tmp/TVfD6WFzdNStrange text after block (missing semicolon or comma?)at /tmp/TVfD6WFzdN:1------> 3role F {}7⏏5 sub MAIN() does F{} expecting any of: infix infix stopper …» | ||
Hotkeys | probably need a semicolon | ||
after the role | |||
partly_ | ahh thanks | 00:34 | |
dalek | c: 9cfebc6 | (Eric de Hont)++ | doc/Type/Array.pod: Update Array.pod Make the difference for the shape method between normal arrays and arrays with fixed dimensions explicit. |
||
camelia | rakudo-moar 0ad8b3: OUTPUT«5===SORRY!5=== Error while compiling /tmp/bNLDndgJiwStrange text after block (missing semicolon or comma?)at /tmp/bNLDndgJiw:1------> 3role F {}7⏏5 sub MAIN() does F{ say "Boo" } expecting any of: infix infix st…» | ||
partly_ | m: role F {}; sub MAIN() does F{ say "Boo" } | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«5===SORRY!5=== Error while compiling /tmp/E27P3oUJmCAutovivifying object closures not yet implemented. Sorry. at /tmp/E27P3oUJmC:1------> 3ole F {}; sub MAIN() does F{ say "Boo" }7⏏5<EOL>» | ||
00:34
Ben_Goldberg is now known as BenGoldberg
|
|||
Hotkeys | and also F needs to do something | 00:34 | |
er | |||
m: role F {}; sub MAIN() does F { say "Boo" } | |||
camelia | rakudo-moar 0ad8b3: OUTPUT«5===SORRY!5=== Error while compiling /tmp/xedkVHSlBqCannot call trait_mod:<does>(Sub, F); none of these signatures match: (Mu:U $doee, Mu:U $role) (Variable:D $v, Mu:U $role)at /tmp/xedkVHSlBq:1» | 00:35 | |
Hotkeys | I don't think you can ' | ||
does' a sub | |||
partly_ | Yeah that's the error I'm running into | ||
m: role F[::Sub] {}; sub MAIN() does F{ say "Boo" } | |||
camelia | rakudo-moar 0ad8b3: OUTPUT«5===SORRY!5=== Error while compiling /tmp/mlkS9fBWFAAutovivifying object closures not yet implemented. Sorry. at /tmp/mlkS9fBWFA:1------> 3:Sub] {}; sub MAIN() does F{ say "Boo" }7⏏5<EOL>» | 00:36 | |
Hotkeys | space after F | ||
00:36
tmch left
|
|||
partly_ | m: role F[::Sub] {}; sub MAIN() does F { say "Boo" } | 00:36 | |
BenGoldberg | p: role F { }; | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«5===SORRY!5=== Error while compiling /tmp/W_Aeb8hjgHCannot call trait_mod:<does>(Sub, F); none of these signatures match: (Mu:U $doee, Mu:U $role) (Variable:D $v, Mu:U $role)at /tmp/W_Aeb8hjgH:1» | ||
BenGoldberg | m: role F { }; | 00:37 | |
camelia | ( no output ) | ||
BenGoldberg | m: role F { }; sub nosig does F { }; | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«5===SORRY!5=== Error while compiling /tmp/UieVzeMEVMCannot call trait_mod:<does>(Sub, F); none of these signatures match: (Mu:U $doee, Mu:U $role) (Variable:D $v, Mu:U $role)at /tmp/UieVzeMEVM:1» | ||
BenGoldberg | m: role F { }; sub nosig is F { }; | 00:38 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«5===SORRY!5=== Error while compiling /tmp/BfxNxc9SVvCan't use unknown trait 'is ' in a sub declaration.at /tmp/BfxNxc9SVv:1 expecting any of: rw raw hidden-from-backtrace hidden-from-USAGE pure default DEPRECATED inlinab…» | ||
partly_ | doc.perl6.org/language/objects#Para...ized_Roles ← Says that You can use parameter with role F[::Type], but this either seems not to work | 00:39 | |
m: role F[Sub] {}; sub MAIN() does F { say "Boo" } | |||
camelia | rakudo-moar 0ad8b3: OUTPUT«5===SORRY!5=== Error while compiling /tmp/P3ZeGd2TSpCannot call trait_mod:<does>(Sub, F); none of these signatures match: (Mu:U $doee, Mu:U $role) (Variable:D $v, Mu:U $role)at /tmp/P3ZeGd2TSp:1» | ||
00:40
spider-mario left
00:43
Ben_Goldberg joined
00:45
BenGoldberg left
|
|||
partly_ | I think the documentation tries to hint, that roles can only be used on classes | 00:46 | |
00:46
BenGoldberg_ joined
00:48
Ben_Goldberg left
|
|||
dalek | osystem: 5137513 | (Andy Weidenbaum)++ | META.list: Add module Crane |
00:52 | |
osystem: fe05525 | (Andy Weidenbaum)++ | META.list: Merge pull request #165 from atweiden/crane Add module Crane |
|||
00:52
kjs_ left
00:53
kjs_ joined
|
|||
edehont | Great fun adding something to the documentation: doc.perl6.org/routine/shape doc.perl6.org/type/Array#method_shape | 00:57 | |
Please tell me if something is wrong there. I will correct it immediately. | |||
01:00
kjs_ left
01:02
labster joined
|
|||
edehont | I have a question. When I Start multiple blocks that want to shift from an array at some point, how do I protect the array from being shifted more than once at the same time? Is there a locking mechanism? | 01:03 | |
01:05
BenGoldberg_ is now known as BenGoldberg
|
|||
TimToady | there's a lock for low-level access, but this probably means you want to use something like a channel instead | 01:07 | |
edehont | Thats what I want indeed, but I couldn't get it to work. I tried taps, but all the processes received all elements of the array at once. | 01:11 | |
01:14
BenGoldberg left
|
|||
TimToady | supplies are not exclusive; a channel will hand out exclusive values | 01:16 | |
edehont | That's where I went wrong. I will have a closer look at the channels and come back when I still can't get it to work. | 01:19 | |
01:21
BenGoldberg joined
|
|||
edehont | An example would still be appreciated, however :-) | 01:21 | |
My daily reboot is long overdue. CU! o/ | 01:27 | ||
timotimo | edenc: you could have used OO::Monitors from the ecosystem for this task | 01:33 | |
but using a Channel instead of an array that you pop from sounds like a better fit | |||
edehont | timotimo: So, a Channel is not something I can use to wrap around an array? | 01:36 | |
01:37
BenGoldberg left
01:39
BenGoldberg joined,
pmurias left
|
|||
geekosaur | you could think of a Channel as inter-thread IPC | 01:40 | |
you would not wrap it around anything. in theory you could pass the array through the Channel, but that's usually not making sensible use of IPC. | |||
01:41
BenGoldberg left
01:42
BenGoldberg joined
|
|||
edehont | geekosaur: I feel like someone with a hammer, looking for nails. I really have to go to sleep now. (2:43) I will look into the channels tomorrow. | 01:44 | |
timotimo | gnite :) | 01:46 | |
edehont | Bye! | ||
01:47
edehont left,
labster left
01:48
themonkeybob11 joined
01:49
mr_ron joined,
cdg left
01:53
themonkeybob11 left
|
|||
mr_ron | m: my @a; my $b = Buf.new(@a) | 01:53 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«This type does not support elems in any at gen/moar/m-Metamodel.nqp line 1723 in block <unit> at /tmp/NtgXHRtYbO line 1» | 01:54 | |
mr_ron | That's the new Base64 failure | 01:55 | |
m: my uint8 @a; my $b = Buf.new(@a) | |||
camelia | ( no output ) | ||
mr_ron | likely fix ... working on it ... | ||
s/fix/workaround/ | 01:59 | ||
02:13
cdg joined
|
|||
ugexe | m: sub foo(Blob $x) { say "OK"; }; foo("".encode); # s/Blob.new($str.ords)/$str.encode/ seems to work | 02:14 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«OK» | ||
02:14
autogen is now known as aleogen
02:19
partly__ joined
|
|||
ugexe | oops thats encode, not decode :x | 02:19 | |
mr_ron | I noticed - failure is on decode ... | ||
02:20
wamba left,
FROGGS left
02:23
partly_ left
02:24
tadzik left
|
|||
ugexe | ah its MIME::Base64 | 02:24 | |
02:24
M-tadzik joined
02:34
FROGGS joined
02:37
cdg left,
cdg joined
02:38
telex left
02:40
telex joined,
cdg_ joined
02:42
cdg left
02:45
ilbot3 left
02:47
ilbot3 joined
02:56
BenGoldberg left
02:57
BenGoldberg joined
02:58
molaf_ joined
03:00
Ben_Goldberg joined
03:02
BenGoldberg left,
molaf__ left
03:09
cdg_ left
|
|||
mr_ron | m: my @a = (); my $b = Buf.new(@a); say $b.perl; my @a1; my $b1 = Buf.new(@a1) | 03:10 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«Buf.new()This type does not support elems in any at gen/moar/m-Metamodel.nqp line 1723 in block <unit> at /tmp/Gl7lWoGswW line 1» | ||
03:10
kid511 joined
03:11
kid51 left
03:13
idiosyncrat_ left
03:14
Ben_Goldberg left
03:15
Ben_Goldberg joined
03:21
maybekoo2 left
03:42
skids joined
03:43
Ben_Goldberg left
03:45
Ben_Goldberg joined,
Actualeyes left
03:48
noganex joined
03:50
Actualeyes joined
|
|||
ugexe | m: my @a; my $b = Buf.new(|@a); say $b.perl | 03:51 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«Buf.new()» | ||
03:51
noganex_ left
03:57
kid511 left
04:07
Ben_Goldberg left
04:08
Ben_Goldberg joined
04:10
cdg joined
04:11
Ben_Goldberg left
04:12
Ben_Goldberg joined
04:15
themonkeybob11 joined
04:17
BenGoldberg joined
04:18
cdg left
04:19
Ben_Goldberg left
04:20
themonkeybob11 left,
Ben_Goldberg joined
04:22
BenGoldberg_ joined
04:23
BenGoldberg left
04:25
Ben_Goldberg left
04:27
mr_ron left
04:28
BenGoldberg_ left
04:29
BenGoldberg_ joined
04:32
Ben_Goldberg joined
04:34
BenGoldberg_ left
04:42
Ben_Goldberg left
04:59
khw left
05:13
labster joined
05:19
themonkeybob11 joined
05:27
skids left,
themonkeybob11 left
05:38
Cabanossi left
05:42
Cabanossi joined
|
|||
dalek | c: ecba519 | LLFourn++ | doc/Language/5to6-perlvar.pod: 5to6: Gave examples of how @INC and %INC in p6 or the closest p6 equivalent at least. |
05:44 | |
05:45
themonkeybob11 joined
05:51
themonkeybob11 left
05:55
themonkeybob11 joined
05:56
vendethiel joined
06:00
themonkeybob11 left
06:12
idiosyncrat_ joined
06:19
vendethiel left
06:25
idiosyncrat_ left
06:28
themonkeybob11 joined
06:38
pierrot left
06:42
vendethiel joined
06:43
darutoko joined
06:52
domidumont joined,
domidumont left
06:53
domidumont joined
06:58
domidumont left
06:59
domidumont joined
07:03
vendethiel left
|
|||
kaare_ | Any NativeCall supermen present? | 07:04 | |
07:37
cdg joined
07:38
_nadim joined
07:39
CIAvash joined
07:41
grassass joined
07:42
cdg left
07:52
tmch joined
08:09
jjido joined,
CIAvash left
08:17
zpmorgan left
08:27
firstdayonthejob joined
08:29
CIAvash joined
08:34
Laurent_R joined
08:35
domidumont left
08:46
hcit joined
08:52
labster left
08:54
labster joined
08:56
RabidGravy joined
|
|||
dalek | kudo/nom: a586b20 | lizmat++ | src/core/Parameter.pm: Streamline Parameter.ACCEPTS Improves from a few % (for simple :(Int).params[0]) to 50x for something like :(:a(:b(:c($x))) (Str $f, Str $k)).params[0] |
08:57 | |
08:58
lizmat joined
|
|||
lizmat | good *, #perl6! | 08:58 | |
dalek | osystem: 28512e7 | okaoka++ | META.list: Add Algorithm::KdTree to ecosystem See github.com/okaoka/p6-Algorithm-KdTree |
08:59 | |
osystem: 672bb20 | RabidGravy++ | META.list: Merge pull request #166 from okaoka/add-kdtree Add Algorithm::KdTree to ecosystem |
|||
llfourn | my commit to docs seems to have caused a segfault lol | 09:03 | |
travis-ci.org/perl6/doc | 09:04 | ||
09:05
lizmat left
|
|||
llfourn | (trying again now) | 09:07 | |
09:18
lizmat joined
09:19
lizmat left
|
|||
_nadim | someone can enlighten me here? | 09:23 | |
===SORRY!=== Error while compiling /home/lab/devel/devel/perl_modules/P6-Data-Dump-Tree/42_type_regexp.t | |||
Only identical operators may be list associative; since 'does' and 'does' differ, they are non-associative and you need to clarify with parentheses | |||
llfourn | golf? | ||
09:23
vendethiel joined
|
|||
_nadim | sure, my $d = Data::Dump::Tree.new does DDTR::MatchDetails does DDTR::PerlString ; | 09:25 | |
RabidGravy | no, golf is | 09:26 | |
09:26
avenj left
|
|||
RabidGravy | m: class F { }; role G { }; role H { }; my $f = F.new does H does G; | 09:27 | |
09:27
maybekoo2 joined
|
|||
camelia | rakudo-moar 0ad8b3: OUTPUT«5===SORRY!5=== Error while compiling /tmp/myHncVJ05iOnly identical operators may be list associative; since 'does' and 'does' differ, they are non-associative and you need to clarify with parenthesesat /tmp/myHncVJ05i:1------> 3G { }; role H …» | 09:28 | |
llfourn | RabidGravy++ # that's some nice golf | ||
m: class F { }; role G { }; role H { }; my $f = (F.new does H) does G; | |||
camelia | ( no output ) | ||
llfourn | _nadim: ^^ | 09:29 | |
RabidGravy | yeah | ||
llfourn | m: class F { }; role G { }; role H { }; my $f = (F but H,G).new | ||
_nadim | well putting the parenthesis was prety obvious and listed in the error message, what I asked fr what enlightenment, IE, why. | ||
camelia | ( no output ) | ||
llfourn | m: class F { }; role G { }; role H { }; my $f = (F but H,G).new.perl.say | 09:30 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«()» | ||
llfourn | oops :P | ||
09:30
avenj joined
|
|||
RabidGravy | the does doesn't return the thing so it isn't list associative | 09:30 | |
afaik | |||
_nadim | Ah, makes sense, thank you. | 09:31 | |
llfourn | m: class F { }; role G { }; role H { }; my $f = F but H,G; say $f.^name; | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«F+{H}» | ||
llfourn | camelia slow today? | ||
RabidGravy | since yesterday | ||
llfourn | m: class F { }; role G { }; role H { }; my $f = F but H but G; say $f.^name; | 09:32 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«5===SORRY!5=== Error while compiling /tmp/DTfPanXbM9Only identical operators may be list associative; since 'but' and 'but' differ, they are non-associative and you need to clarify with parenthesesat /tmp/DTfPanXbM9:1------> 3role G { }; role…» | ||
llfourn | m: class F { }; role G { }; role H { }; my $f = F but (H but G); say $f.^name; | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«Method 'mixin' not found for invocant of class 'Perl6::Metamodel::ParametricRoleGroupHOW' in block <unit> at /tmp/qfdxknjRVy line 1» | ||
llfourn | m: class F { }; role G { }; role H { }; my $f = (F but H) but G; say $f.^name; | 09:33 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«F+{H}+{G}» | ||
_nadim | I've added a new method that takes a does list. cheating a bit till I understood, well someone explained, why. | ||
llfourn | _nadim: you can just do .^mixin | 09:34 | |
m: class F { }; role G { }; role H { }; my $f = F.^mixin(H,G).new; say $f.^name; | |||
camelia | rakudo-moar 0ad8b3: OUTPUT«F+{H,G}» | ||
llfourn | m: class F { }; role G { }; role H { }; my $f = F.new does H,G; say $f.^name; | 09:35 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«F+{H}» | ||
llfourn | m: class F { }; role G { }; role H { }; my $f = F.new does (H,G); say $f.^name; | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«F+{H,G}» | ||
_nadim | llfourn: nice! | ||
llfourn | oh and that works, does can take a list | ||
_nadim | even nicer IMO | 09:36 | |
09:38
lizmat joined,
sortiz joined
|
|||
sortiz | \o #perl6 | 09:39 | |
09:40
jjido left
|
|||
lizmat | sortiz o/ | 09:40 | |
dalek | Iish: 996042f | (Salvador Ortiz)++ | lib/DBDish/ (4 files): Better Statement execution handling - Add .Executed and .Finished methods - Cleaner rows affected reporting - More info on error reports |
09:41 | |
Iish: 6df5b22 | (Salvador Ortiz)++ | lib/DBDish/Pg/Native.pm6: Pg: Export constants, Str (not str) to up level |
|||
Iish: c1d1ac2 | (Salvador Ortiz)++ | lib/DBDish/StatementHandle.pm6: Factorize StatementHandle.allrows as multi methods |
|||
Iish: a692de8 | (Salvador Ortiz)++ | / (6 files): mysql: Reworked internals, now with native methods. Add Bool :Prefetch (default True) to `.prepare` for select data read mode This switch between `mysql_store_result` and `mysql_use_result`, see the C API for pros and cons. Now handles columns with Blob (binary data) type. Closes #10, our oldest. See `t/26-mysql-blob.t` for usage details. |
|||
Iish: 782a899 | (Salvador Ortiz)++ | lib/DBIish/CommonTesting.pm6: Updated common test suite, testing new features |
|||
09:41
rindolf joined
09:42
maybekoo2 left
|
|||
dalek | kudo/nom: 7fab8e7 | lizmat++ | src/core/Buf.pm: Fix problem with Buf.new(my @a) Spotted by Ronald Schmidt |
09:44 | |
09:45
spider-mario joined
|
|||
dalek | ast: b2ac729 | lizmat++ | S03-operators/buf.t: Add tests for Blob|Buf.new(my @a) |
09:49 | |
lizmat | .oO( we need more tests ) |
||
.tell jnthn I'm a bit confused as to the meaning of Signature.ACCEPTS | 09:54 | ||
yoleaux | lizmat: I'll pass your message to jnthn. | ||
llfourn is interested in the subject of Signature.ACCEPTS | 09:55 | ||
lizmat | .tell jnthn as it seems to include a check on "returns" | ||
yoleaux | lizmat: I'll pass your message to jnthn. | ||
lizmat | llfourn: how so? | ||
llfourn | lizmat: well we have this feature of role requiring multi methods | ||
lizmat | I'm about to refactor it, but I'm unsure as to what it should exactly do? | ||
llfourn | but it is buggy | 09:56 | |
lizmat | yeah, but that doesn't use Signature.ACCEPTS (anymore) | ||
llfourn | lizmat: yes but I think it should | ||
lizmat | llfourn: it still is?? | ||
it's still buggy ??? | |||
llfourn | I think that if we get Signature.ACCEPTS right a lot of things could fall into place | ||
09:56
jjido joined
|
|||
llfourn | yes | 09:56 | |
09:56
ChoHag_ is now known as ChoHag
|
|||
lizmat | is there a ticket I should check? | 09:56 | |
llfourn | rt.perl.org/Public/Bug/Display.html?id=127303 | 09:57 | |
because it doesn't use ACCEPTS it uses string comparisions which don't work out when comparing signatures | |||
lizmat checks | |||
llfourn | I also think that if a role requires multi foo(Int) { }, you should be able to satisfy that requirement with multi foo (Real) { } etc | 09:58 | |
09:58
kjs_ joined
|
|||
llfourn | I haven't thought it out fully but I think if we re-imagined role requiring methods with stubs to check Signature.ACCEPTS to see if it has been implemented in general it could be an amazing feature. | 09:59 | |
lizmat | ok, that makes sense.. I'll be looking at resolving that ticket now | 10:00 | |
partly__ | So i played around with Exceptions yesterday/today. I added a var RAKUDO_ONLY_ROBOTS which when set will print errors in format %f:%l,%c→%m | ||
llfourn | m: role R { method foo (Int) { ... } }; class A does R { method foo(Str) { } } # IMO this should fail | 10:01 | |
camelia | ( no output ) | ||
llfourn | lizmat: it depends if we want to take role-as-interface specification seriously or not | ||
partly__ | Currently only X::Comp::Exceptions are printed out like this, but I though about extending it to all Exceptions, may be with a role. Do you think it's a good idea? | ||
lizmat | partly__: I like the idea, but fail to see how that would easily generalize | 10:02 | |
llfourn | partly__: an idea, we have augment" | 10:03 | |
partly__: maybe you can make the changes in a module | |||
partly__ | lizmat: well the role offer just a proto sub which needed to be implemented by an exception if it wants to have errorformat compatible errors | 10:04 | |
s/offer/offers/g | |||
llfourn | do augment Exception { }, and somehow get it all to go into an environment variable and then we can see how well the idea works in practice. | ||
lizmat | ah, ok, like that... hhmmm... | ||
sounds like a plan I guess: not sure what jnthn / TimToady would think about it | 10:05 | ||
RabidGravy | I'm actually failing to find a use case that isn;t already catered for by using specific exception types, but that's me | ||
partly__ | RabidGravy: There whole error printing logic is all over the place. Just the ===SORRY | 10:06 | |
.. just the ===SORRY!=== stuff is duplicated at least 3 times | |||
Every exception besides the X::Comp exception have an own logic how to construct the error message (which i think makes the more readable for humans). It's hard do create one method which just reformats the .gist/.message returns | 10:07 | ||
llfourn | m: use MONKEY-TYPING; role R { method do-something { "win".say } }; BEGIN augment class X::AdHoc does R { }; try { die "foo" }; say $!.do-something | 10:08 | |
partly__ | But augment may be a good alternative. | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«winTrue» | ||
llfourn | Though the above doesn't work if you do augment Exception so maybe it's not a good idea. | 10:09 | |
(I think it's a bug) | |||
partly__ | m: use MONKEY-TYPING; augment class Exception { method f() { } }; try { die "foo" }; say $!.f(); | 10:10 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«Method 'f' not found for invocant of class 'X::AdHoc' in block <unit> at /tmp/_ymMJfFOZQ line 1» | ||
llfourn | yeah :\ | ||
it seems I RT'd something similar RT #127520 | 10:11 | ||
synopsebot6 | Link: rt.perl.org/rt3//Public/Bug/Displa...?id=127520 | ||
10:11
kjs_ left
|
|||
partly__ | Also why is Method not a compile time exception? | 10:12 | |
llfourn | partly__: because you can add methods at runtime | 10:13 | |
partly__ | Because it's not a descendant of X::Comp it does not have a linenumber and file (which is pretty helpfull) | ||
llfourn | hmm it should still have those I would have though? | ||
partly__ | llfourn: → and this methods would not have a line number | ||
makes sense | 10:14 | ||
llfourn | or at least when it's thrown you get a line number? | ||
anyway I need to learn more about exceptions | |||
partly__++ for looking into improving them :) | |||
partly__ | llfourn: yeah when thrown, make sense | ||
llfourn | food & | 10:15 | |
partly__ | I kind of trying that, but it's hard to completely understand where what is thrown and initialized. | ||
Another question. Given that I use rakudobrew and I have a cloned git repository of rakudo I'm working on, how do I command rakudobrew to build the rakudo version in a specified dir and install it? | 10:16 | ||
Is it even possible to install a custom version with rakudobrew if you do not maintain an official fork? | 10:17 | ||
10:17
araujo_ left
|
|||
[Tux] | test 22.254 | 10:18 | |
test-t 12.638 | |||
csv-parser 52.116 | |||
10:19
chienjo joined
10:20
chienjo left
|
|||
Woodi | hi #perl6 :) | 10:28 | |
more WordPress fun: news.softpedia.com/news/popular-wor...1383.shtml | 10:29 | ||
nine | kaare_: what do you need? | 10:39 | |
10:46
lizmat left
10:48
kjs_ joined,
tochjammer joined,
xiaomiao joined
10:50
labster left
10:52
TEttinger left
|
|||
partly__ | Is there some default short cut for pushing something in an array? I.e: @a ← "foo" | 10:52 | |
(besides just push) | 10:53 | ||
llfourn | partly__: .append | 10:56 | |
oh you want it short. No. | 10:58 | ||
m: my @a = <one two three>; @a[*] = "four"; say @a.perl | 10:59 | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«["four", Mu, Mu]» | ||
llfourn | m: my @a = <one two three>; @a[*+0] = "four"; say @a.perl | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«["one", "two", "three", "four"]» | 11:00 | |
llfourn | m: my @a = <one two three>; @a[+*] = "four"; say @a.perl | ||
RabidGravy | just what I was going to say | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«["one", "two", "three", "four"]» | ||
llfourn | i'd stick with @a.push: "foo", that way is almost as bad as php $a[] = "foo" # if I remember php correctly | 11:01 | |
what is the first one trying to do anyway? | 11:03 | ||
m: my @a = <one two three>; @a[*] = <four five six>; @a.perl.say | |||
camelia | rakudo-moar 0ad8b3: OUTPUT«["four", "five", "six"]» | ||
llfourn | m: my @a = <one two three>; @a[^*] = <four five six>; @a.perl.say | 11:04 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«["four", "five", "six"]» | ||
11:04
RabidGravy left
|
|||
llfourn | to me it makes more sense that * defaults to .elems rather than doing the same thing as ^*. | 11:04 | |
CIAvash | m: my @a = <one two three>; "four" ==> @a; say @a.perl | 11:05 | |
11:05
ssm joined
|
|||
camelia | rakudo-moar 0ad8b3: OUTPUT«["one", "two", "three", "four"]» | 11:05 | |
llfourn stands corrected | |||
m: my @a = <one two three>; @a <== "four"; say @a.perl; | 11:06 | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«["one", "two", "three", "four"]» | ||
llfourn | m: @a ← "foo" | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«5===SORRY!5=== Error while compiling /tmp/_tTiSZQyWiVariable '@a' is not declaredat /tmp/_tTiSZQyWi:1------> 3<BOL>7⏏5@a ← "foo"» | 11:07 | |
llfourn | m: my @a = <one two three>; @a ← "four"; say @a.perl; | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«5===SORRY!5=== Error while compiling /tmp/5VtNvtzVK9Confusedat /tmp/5VtNvtzVK9:1------> 3my @a = <one two three>; @a7⏏5 ← "four"; say @a.perl; expecting any of: infix infix stopper statement end …» | ||
11:08
AlexDaniel joined
|
|||
AlexDaniel | llfourn: hmm what would be the unicode equivalent of ==> and <== ? | 11:08 | |
llfourn | AlexDaniel: is ← being used for anything? | 11:09 | |
AlexDaniel | llfourn: no gist.github.com/AlexDaniel/c89bd2786f9b63f31e4c | ||
llfourn | this thing? ⟸ | ||
AlexDaniel: ooh nice | 11:10 | ||
AlexDaniel++ | |||
AlexDaniel | llfourn: ⟸ is cool but how is that going to look like in a fixed-width font, hmm… | ||
llfourn | I think you just answered that question :P | 11:11 | |
11:11
kjs_ left
|
|||
llfourn | ⇐ # shorter | 11:11 | |
partly__ | llfourn: thanks for the hint with <== | ||
llfourn | that was CIAvash++ but no problem :) | 11:12 | |
partly__ | CIAvash :) | ||
CIAvash | :) | ||
AlexDaniel | llfourn: ⇒ would probably be =>. So ⇐ is probably not good enough | ||
⤆ ⤇ maybe | |||
11:12
kjs_ joined
|
|||
llfourn | ⬅ bolder? | 11:13 | |
AlexDaniel | :/ | ||
llfourn | :D ⟽ will stop making suggestions | 11:14 | |
I seem to remember there being some conterversy about ==> and <== | 11:16 | ||
partly__ | Well if you really want to add a unicode sign for that i would gow with ⇐, because you can enter it in vim with digraphs | ||
AlexDaniel | partly__: uh, but fat arrow? | ||
partly__: => | |||
m: say 42 => 69 | |||
camelia | rakudo-moar 0ad8b3: OUTPUT«42 => 69» | ||
partly__ | ohh right | 11:17 | |
llfourn | ➧ # fat arrow | ||
partly__ | I can't enter ⟸ with COMPOSE or digraphs afaik. At least I find only the short DOUBLE ARROW | 11:18 | |
AlexDaniel | partly__: well, just because you can't enter some character doesn't mean that we can't use it :) | 11:19 | |
(go fix your tools!) | |||
partly__ | Uhh don't get me started on Xkb and stuff :-O | 11:20 | |
dalek | line-Perl5: 7906dce | (Stefan Seifert)++ | / (5 files): Fix calling inherited package methods of Perl 5 packages Post-GLR changes broke Perl5Package's FALLBACK which is used when calling inherited package methods. Need to use slurpy arguments now. |
11:22 | |
partly__ | There is no difference between ? and so, is there? | ||
llfourn | partly__: they both call .so afaik | ||
partly__ | thanks | ||
11:24
jjido left
|
|||
AlexDaniel | m: say so ?.so | 11:28 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«False» | ||
AlexDaniel | m: say ? ? ? ? .WHAT # WAT? :) | 11:30 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«False» | 11:31 | |
llfourn | m: say ?!?!?! Cool | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«True» | ||
[Tux] | test 22.599 | 11:32 | |
test-t 12.951 | |||
csv-parser 54.036 | |||
(rebuilt from scratch) | |||
seems to be slower again | |||
AlexDaniel | llfourn: yeah, that's even better | 11:33 | |
llfourn | .tell lizmat btw RT #127444 is about Signature.ACCEPTS. Wrt to what it's meant to do, I thought that it A.ACCEPTS(B) should return true if B accepts a subset of A's parameters. ie every :(Real $b) ~~ :(Int $a) # True | ||
yoleaux | llfourn: I'll pass your message to lizmat. | ||
synopsebot6 | Link: rt.perl.org/rt3//Public/Bug/Displa...?id=127444 | ||
AlexDaniel | m: say +?!~-?+~!?+!+~? Cool | ||
llfourn | |Tux|: nooo getting slower :P | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«0» | 11:34 | |
llfourn | although I don't think that's what's causing camelia to be so slow | ||
AlexDaniel | camelia: stop mining bitcoins! | 11:36 | |
m: my %h; %h <== ‘hi’ | 11:38 | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«Trailing item in Hash.append in block <unit> at /tmp/WVUbzMjWFt line 1» | ||
AlexDaniel | m: my $l; $l <== ‘foo’, ‘bar’; say $l | 11:39 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«[foo bar]» | ||
11:39
M-tadzik is now known as tadzik
11:42
jjido joined
11:43
Skarsnik joined
11:45
tochjammer left
11:47
lizmat joined
|
|||
llfourn | I have a sad panda story | 11:49 | |
I used panda --prefix=~/tmp/somewhere install blah | 11:50 | ||
which actually created a dir named ~ | |||
then I did rm -rf ~ to fix my mistake | |||
vendethiel | yes, that's correct | ||
oh | |||
oops. | |||
llfourn | it's ok because apparently I have so much crap in ~ that nothing I care about got deleted | ||
ofc I understand why that happened in retrospect | 11:51 | ||
vendethiel | you'd like panda to warn if $prefix.starts-with('~')? | 11:52 | |
(and abort) | |||
llfourn | I think that's probably a good idea | ||
11:53
firstdayonthejob left
11:56
firstdayonthejob joined
|
|||
timotimo | in general, i think it'd be cool if we did the proper thing with paths in env vars that (may?) have variable names in them and the ~ | 11:58 | |
11:58
RabidGravy joined
|
|||
llfourn | m: say $*HOME | 11:59 | |
k-man | always prefix things with ./~ to ensure it gets the file not the glob is what I was tought... but would it work in that instance I'm not sure | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«"/home/camelia".IO» | ||
kaare_ | nine: Oh, I really want to use the select(2) system call. | ||
llfourn | k-man: o/ I certainly agree :) | ||
k-man | :) | 12:00 | |
kaare_ | But it's not in the 5 -> 6 migration path, so I was looking at the POSIX module, trying to see how to implement it. | ||
llfourn | k-man: It would have worked. rm -rf ./~ would have deleted the right thing | ||
k-man | ls: ./~: No such file or directory so i guess it would work | ||
yeah | |||
RabidGravy | kaare_, strangely I made a noddy binding to select just the other day to test something, it works | 12:01 | |
kaare_ | RabidGravy: OK, can you share some code? | ||
RabidGravy | depends on what you want to do with it as to whether it's useful to you | 12:02 | |
kaare_ | I would call it. Any other purposes available? | 12:03 | |
llfourn | ah I seem I *did* delete my rakudobrew and panda installations so at least the culprit was punished. | 12:04 | |
12:04
wamba joined
|
|||
RabidGravy | well I was going to share the code until you were sarcastic | 12:04 | |
12:04
xiaomiao left
|
|||
RabidGravy | ;-p | 12:04 | |
kaare_ | ok, sorry, sorry! | 12:05 | |
Being sarcastic would be something like "I' like to serve it on a bed of Jerusalem Artichokes" or something ;-) | |||
RabidGravy | I only needed to test for the "no FDs just for the waiting side effect" | ||
so if you want to use it to wait for the file handles then you will have to implement the making the FD sets yourself | 12:06 | ||
kaare_ | No, I know very little Perl 6, almost no c, and absolutely nothing about the system calls. So it's a bit challenging | ||
RabidGravy | gist.github.com/jonathanstowe/23a9...0fef8c8588 | ||
well, you're stuffed then | 12:07 | ||
12:07
xiaomiao joined
|
|||
kaare_ | Actually, I'm sure I can use that to get some actual play started. Thanks. | 12:08 | |
RabidGravy | the hard bit is implementing the FD_SET macro | 12:09 | |
kaare_ | Is that what is done with vec() in Perl 5? | 12:10 | |
12:11
spider-mario left
|
|||
RabidGravy | er possibly | 12:11 | |
think I've used vec once in twenty years | |||
12:11
spider-mario joined
12:12
xiaomiao left
|
|||
kaare_ | OK, thanks anyway. I've used all available time today, so I'll have to stuff it in the play projects drawer again. Hopefully not for too long. | 12:13 | |
CIAvash | llfourn++ for the require fix # wanted to say this a few weeks ago but ... :) | 12:15 | |
12:16
SCHAAP137 joined
12:18
Cabanossi left
|
|||
Skarsnik | damn, I though Discord:ver<0.0.1>:auth<Sylvain Colinet [email@hidden.address] already installed | 12:19 | |
error in panda was solved x) | |||
12:20
xiaomiao joined
|
|||
llfourn | CIAvash: thanks! # thanks to RabidGravy++ for saving the ecosystem after the require fix broke everything :P | 12:20 | |
RabidGravy | moi? | 12:21 | |
llfourn | toi! | ||
timotimo | the error is solved if and only if you --force, or if you up the version number :) | ||
at least that's what i seem to recall | 12:22 | ||
kaare_ | nine: One more q, though. I wonder why I don't need to include any c headers. | ||
RabidGravy | Skarsnik, with regard to the H::UA thing, in the case where the Response constructor gets no data or where it can't find a valid HTTP response line I propose to just set the code to 500 with some headers indicating that it was set locally and let the upstream decide what to do with that? | 12:24 | |
Skarsnik | There is a Internal execption already in h::UA | 12:25 | |
damn DBIish can't be installed | |||
kaare_ | RabidGravy I meant <sigh> | 12:26 | |
RabidGravy | kaare_, because it "only" dynamically links to the library at run time it doesn't need that, it just needs the name of the function and the library where it is found | ||
nine | kaare_: because NativeCall doesn't compile anything. It accesses the binary libraries directly. You tell NativeCall how the library looks like by giving it the function signatures in Perl 6 | ||
RabidGravy | and getting the arguments right helps too if you don't want a segfault | ||
partly__ | m: sub f() returns Str { "asd" }; sub f() returns Int { 3 }; my Str $b = f(); say $b; | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«5===SORRY!5=== Error while compiling /tmp/dhQGpcR3X5Redeclaration of routine fat /tmp/dhQGpcR3X5:1------> 3Str { "asd" }; sub f() returns Int { 3 }7⏏5; my Str $b = f(); say $b; expecting any of: horizontal whitespace …» | ||
Skarsnik | hm, it's new? t/26-mysql-blob.t | 12:27 | |
partly__ | No idea how to express the above in one line, but basically instead of being "smart" and picking the first variant of the sub it picks the one which returns Int | 12:29 | |
12:30
pierrot joined,
woolfy joined
|
|||
woolfy | The monster is alive! | 12:30 | |
12:31
woolfy left
|
|||
partly__ | Hmm the return type is not a part of the signature so it's the same routine for the parser? | 12:31 | |
vendethiel | :o | ||
partly__: no overloading on return type :) | 12:32 | ||
RabidGravy | partly__, it also needs to be a "multi" | ||
partly__ | ok | 12:33 | |
12:34
Laurent_R left
|
|||
RabidGravy | in principle you could implement your own dispatcher that takes iinto account a declared return type but in the general case it is not possible | 12:35 | |
kaare_ | The thing I don't get is, how does it know what to call. What if I want a 'select' in another c library? | ||
RabidGravy | you would give the native trait the library name | 12:36 | |
in the "select" case it is assumed to be in the already loaded C runtime library | |||
timotimo | i don't think a c compiler lets you have two functions called "select" from different libraries | 12:37 | |
except perhaps if you #undefine it in between usages and add the other definition in the middle? | |||
dalek | Iish: 97d14f1 | (Sylvain Colinet)++ | t/26-mysql-blob.t: Added test skip in t/26 if mysql fail to connect to not prevent DBIish to be installed |
12:38 | |
RabidGravy | C++ has to be good for something ;-) | 12:39 | |
Skarsnik | timotimo, I think it work with dlopen, since you just pick up symbol on a given file | ||
timotimo | right, there you can have overloading | ||
Skarsnik: right. that's why i said "a c compiler" :) | 12:40 | ||
Skarsnik | I am not sure what happened | ||
vendethiel | timotimo: you can't #undefine a function :P | ||
timotimo | vendethiel: why not? | ||
vendethiel | because preprocessor <=> compiler | ||
timotimo | that makes sense | ||
RabidGravy | you probably could hack around it in the preprocessor but I don't want to think about that | 12:41 | |
Skarsnik | You can do fake overloading | 12:42 | |
in C | |||
with like checking a size of the type given and have macro around that xD | |||
RabidGravy | yeah after all the first C++ implementations were just extensions to the preprocessor, awful and slow but somewhat worky | 12:43 | |
Skarsnik | like void real_function(data, sizedata) {} #defined function(x) real_function(x, sizeof(x)) | ||
RabidGravy | I think SCO shipped one like that until they went boom | 12:44 | |
vendethiel | you can do overloading in C with C11 :) | 12:51 | |
#define function(x) _Generic((x), float: ...) | |||
RabidGravy | anyway this isn't getting any code written, lots of stuff to write and not enough time | 12:52 | |
and I must not get distracted by doing a binding to getpeername() as I don't need that right now | 13:00 | ||
Skarsnik | x) | 13:01 | |
have gptrixie do it for you x) | 13:03 | ||
damn perl6 now look really faster than 2-3 months ago x) | 13:04 | ||
RabidGravy | no, no, I'm not going to do it at all | ||
lizmat | hoelz.ro/blog/finding-most-common-russian-ngrams hoelzro++ | 13:07 | |
yoleaux | 11:33Z <llfourn> lizmat: btw RT #127444 is about Signature.ACCEPTS. Wrt to what it's meant to do, I thought that it A.ACCEPTS(B) should return true if B accepts a subset of A's parameters. ie every :(Real $b) ~~ :(Int $a) # True | ||
synopsebot6 | Link: rt.perl.org/rt3//Public/Bug/Displa...?id=127444 | ||
lizmat | .tell hoelzro note that you can do Str.comb(Int $n) for $n chars (which is much faster :-) | 13:08 | |
yoleaux | lizmat: I'll pass your message to hoelzro. | ||
timotimo | heyo lizmat :) | ||
lizmat | timotimo o/ | 13:09 | |
lizmat just got home | |||
13:09
edehont joined
13:10
edehont left,
jjido left,
edehont joined
13:11
edehont left
13:13
edehont joined
13:16
edehont left
13:18
kid51 joined
|
|||
llfourn | lizmat: doh that should be the other way around. :(Int $a) ~~ :(Real $b) # True | 13:23 | |
lizmat | yeah, these things can trip you up :-) | 13:24 | |
llfourn | yeP A.ACCEPTS(B) is $B ~~ $A gets me every time :P | 13:25 | |
dalek | kudo/nom: 38a2bfe | lizmat++ | src/core/Signature.pm: Some refinements in Capture eqv Capture |
||
lizmat | afk again for a few hours& | ||
llfourn | m: say :(Int $a) ~~ :(Real $b) | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«True» | ||
llfourn | m: say :(Int $a) ~~ :(Real $b?) | 13:26 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«True» | ||
llfourn | m: say :(Int $a?) ~~ :(Real $b) | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«False» | ||
llfourn | m: say :(Int $a?) ~~ :(*@a) | 13:27 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«True» | ||
llfourn | m: say :(Int $a?) ~~ :($a is rw) | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«False» | 13:28 | |
llfourn | m: say :(Int $a) ~~ :($a is rw) | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«True» | ||
llfourn | ah ha! | ||
I knew I could find a way to trip it up | |||
m: say :($a) ~~ ($a is rw) | 13:30 | ||
m: say :($a) ~~ :($a is rw) | |||
camelia | rakudo-moar 0ad8b3: OUTPUT«5===SORRY!5=== Error while compiling /tmp/DDPbVQ4KacVariable '$a' is not declaredat /tmp/DDPbVQ4Kac:1------> 3say :($a) ~~ (7⏏5$a is rw)» | ||
rakudo-moar 0ad8b3: OUTPUT«True» | |||
masak finally sits down and starts tinkering with his GPW talks | 13:31 | ||
yoleaux | 5 Mar 2016 15:12Z <pmurias> masak: it's not DWIM to me as I wouldn't ever expect that without looking it up | ||
5 Mar 2016 15:13Z <pmurias> masak: it seems to be something inherited from awk | |||
masak | oh, awk. didn't know that. | ||
I think I agree that it's not all that obvious. though I have a feeling it's rather *convenient*, and we might want to think about not throwing that away. | |||
timotimo | oh hey masak :) | 13:32 | |
what were you talking about there? | |||
my first guess is flip-flop operators :) | |||
masak | "" as record separator when doing line-based input | 13:33 | |
timotimo | oh, for paragraphs? | ||
llfourn | .tell lizmat another possible bug: say :($a) ~~ :($a is rw) # returns True but it should be False IMO, is rw is narrower | 13:34 | |
yoleaux | llfourn: I'll pass your message to lizmat. | ||
masak | (with the semantics "read paragraph-wise" or "separator is /\n\n+/") | ||
timotimo | yes, rw is narrower | ||
partly__ | I'm getting the exception cannot unbox to a native string | 13:35 | |
FROGGS | masak: ohh you start now? phew, and I thought starting yesterday was a bad idea :o) | 13:36 | |
masak | partly__: are you able to show a (golfed) piece of code that produces this error? | ||
partly__ | i have a line number (i guess it's an int) which i try to concat to a string. | ||
timotimo | huh, that should stringify just fine for you | ||
masak | FROGGS: I tried to start yesterday. but the procrastination is strong with this one. | ||
timotimo | can you golf that? | ||
partly__ | timotimo: this is in rakudo/src/core/Exception.pm | ||
FROGGS | currently I've got 120 lines of notes / stubbed slides | 13:39 | |
I hope that's enough for a 40 minutes talk | |||
though I guess I need less slides per minute anyway, because I'm going to explain much per slide | 13:40 | ||
partly__ | timotimo, masak: gist.github.com/kalkin/7e3492ac9c4...n-pm6-L909 | 13:41 | |
timotimo | ooooh feed syntax | ||
Skarsnik | hm, This page was generated the 2016-03-06 in 26.6092489 seconds with Perl 6.c (rakudo (2015.12.199.g.5.ed.58.f.6)) - This page was generated the 2016-03-06 in 27.96024130 seconds with Perl 6.c (rakudo (2016.2.88.g.7.fab.8.e.7)) for the same page | ||
FROGGS | partly__: you probably want to join the routine names, no? | ||
Skarsnik | weird that it's 2 sec slower | 13:42 | |
masak | partly__: well, the `nqp::hllize($routine)` stands out as a very likely candidate for your troubles | ||
FROGGS | partly__: so try nqp::hllize($routine).name in the map block | ||
timotimo | Skarsnik: if it's run on our p6c, it can very well be interfered with by other processes and hard drive seeking times/caching etc etc | ||
partly__ | FROGGS: actually i want to print %f:%l→ %m | ||
i wanted to get the linenumbers and copy pasted from sub l() | 13:43 | ||
llfourn | if you scroll up [Tux]'s CSV benchmarks seemed to be slower as well | ||
Skarsnik | I don't know, time was consistent between each day for these | ||
partly__ | which is called in L915 | ||
where do i find docs on nqp::hllize? | |||
Skarsnik | it's a lot of DBIish call and Template::Mojo behind | 13:44 | |
FROGGS | partly__: if it is anywhere it is here: github.com/perl6/nqp/blob/master/d...s.markdown | 13:45 | |
llfourn | tux.nl/Talks/CSV6/speed4.html # charts putting recent spike in slowness in perspective [Tux]++ | 13:46 | |
[Tux] | thnx | ||
timotimo | :BY<&defoid W W u u u U u U u u> | 13:56 | |
timotimo is reminded of a spooky ghost | |||
WTB: a html-export or app or something to work more easily with QAST dumped output | 13:58 | ||
but the current dump format is absolutely horrifying to parse | 14:01 | ||
masak | would a dump format especially developed for the purpose help? | 14:04 | |
timotimo | yes | 14:05 | |
can even be json | |||
llfourn | I flag to turn on json execption dumps would be nice | ||
s/I/a/ | 14:06 | ||
partly__ | when recompiling rakudo it takes 52 seconds at State parse and 8 at optimize and 17 at mast even if I changed only one line. Is there a way to speed it up at some of the stages? | 14:09 | |
timotimo | there is not, sadly | ||
a theoretical way to make things faster is to have a setting that strips out a few things | 14:10 | ||
14:10
Laurent_R joined
|
|||
timotimo | Set, Bag, Mix and friends are likely candidates, as well as the sockets and parallelism stuff | 14:10 | |
partly__ | ic, thanks | 14:13 | |
timotimo | if you're interested, you could try to build that :) | ||
not sure how to best go about that | |||
partly__ | timotimo: let me add support for VIM errorformat to the exceptions and if I finish it up, then we will see :). | 14:14 | |
timotimo | oh, neat | ||
btw, with so many exceptions giving pretty good suggestions what to do instead, we could totally have a tool that creates and optionally immediately applies changes to your code | 14:15 | ||
partly__ | Btw here is a syntastic perl6 checker which handles some of the exceptions i've seen with the current error format github.com/kalkin/syntastic/blob/p.../perl6.vim | 14:16 | |
It's mostly copy/pasta from the perl checker, but it kind of works | 14:17 | ||
timotimo | cool | ||
Skarsnik | gah, did some backtrace disapear again? I get Use of uninitialized value of type Any in string context without line/file | 14:24 | |
14:26
Cabanossi joined
|
|||
dalek | c: c2e3e18 | jjatria++ | doc/Language/5to6-nutshell.pod: Fix markup in nutshell headers |
14:29 | |
c: 1fd720c | sylvarant++ | doc/Language/5to6-nutshell.pod: Merge pull request #415 from jjatria/fix-nutshell-headers Fix markup in nutshell headers |
|||
partly__ | m: "asd".^roles ∈ Stringy | 14:30 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«WARNINGS for /tmp/Yz7SIZa7rG:Useless use of "∈" in expression ".^roles ∈ Stringy" in sink context (line 1)» | ||
partly__ | m: Stringy ∈ "asd".^roles | 14:31 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«WARNINGS for /tmp/QsvGA_YuqS:Useless use of "∈" in expression "Stringy ∈ \"asd\".^roles" in sink context (line 1)» | ||
timotimo | how about a "say" in there? | ||
14:31
TimToady left
|
|||
partly__ | m: say(Stringy ∈ "asd".^roles) | 14:31 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«True» | ||
partly__ | Ahh nice, thanks | 14:32 | |
I it idiomatic enough for a check if given something implements a role? | |||
14:33
TimToady joined
|
|||
masak | m: say "asd" ~~ Stringy | 14:34 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«True» | ||
masak | partly__: that's idiomatic ;) | ||
partly__ | masak: ic. I must learn to embrace ~~ even if it always looks to me like a lot of MAGIC | 14:36 | |
:) | |||
masak | it's the right kind of magic | ||
and IMO it's fewer moving parts than ∈ and .^roles | |||
jnthn | It's probably also a dozen times faster :) | 14:37 | |
yoleaux | 09:54Z <lizmat> jnthn: I'm a bit confused as to the meaning of Signature.ACCEPTS | ||
09:55Z <lizmat> jnthn: as it seems to include a check on "returns" | |||
partly__ | masak: yes of course | ||
14:39
partly__ is now known as kalkin,
kalkin is now known as kalkin-
15:07
Ven joined
15:08
zpmorgan joined
15:14
khw joined
15:20
Ven left
15:21
brrt joined
|
|||
brrt | hey #perl6. i'm looking for a way to automatically run a TAP test and get a boolean for broken/not broken | 15:22 | |
timotimo | "prove" should do that for you | 15:23 | |
llfourn | brrt: by boolean do you mean p6 Bool or shell status? | ||
brrt | hmm, gooid point timotimo | ||
llfourn | either way I guess prove is the answer :P | ||
timotimo | prove it. | ||
brrt | y'all know | 15:24 | |
i figured something out, about python, just this week | |||
it dawned on me that python is not actually a scripting language | |||
timotimo | oh? | 15:25 | |
do enlighten us | |||
brrt | making a script, as in, a small thing that easily wires together a lot of external functionality, as per bash script, javascript, perl, ruby even | ||
is a *huge* pain in python | |||
timotimo | what, because it forces you to be so correct about things? :P | ||
brrt | what do you think is equivalent to q:x["foo bar"] | ||
llfourn | import herp from derp; herp("foo bar") # or something | 15:26 | |
timotimo | subprocess.Popen? | ||
brrt | it is; import subprocess; try: output = subprocess.check_output(['foo', 'bar']);str_output = output.decode('utf-8'); except subprocess.Error as e: logging.exception(e) yadyaydayadyadya | ||
python is about as unfluent in calling out, shelling out, as java might well be | 15:27 | ||
llfourn | but isn't JS pretty similar in that? | 15:28 | |
I mean JS has script in the name so it must be a script | |||
but I guess it's not java at all so it may as well not be a script | |||
brrt | good point | 15:29 | |
geekosaur | brrt, the line between script and language has been at best extremely bluirry for years | ||
brrt | counterpoint: javascript is very much 'scripting' it's native environment, notably, the browser | ||
llfourn | good counterpoint | ||
geekosaur | you can't even use something like "runs from the top" vs. "uses a defined entry point" --- FORTRAN violates that | 15:30 | |
llfourn | I guess we can synthesize by saying that node is not a scripting language | ||
brrt | agreed on that | ||
geekosaur: my point on scripting is actually simple: does it exist to leverage the functionality of other systems, or does it exist to build systems of? | 15:31 | ||
llfourn | geekosaur: but what do you think about brrt's definition of easily being able to interact and take effect on the outside environment. | ||
timotimo | C scripts CPUs :P | ||
brrt | extreme example of the former being bash, extreme example of the latter being, well, fortran | ||
15:32
CIAvash left
|
|||
brrt | my point here is that python is amazingly un-good at being like bash | 15:32 | |
geekosaur | brrt, I'd say perl itself (in all its forms) messes with your definition :) | ||
brrt | oh, yes | ||
gloriously :-) | |||
but perl is better at being like bash, than python is | |||
at least, that's how i feel when writing it | 15:33 | ||
15:34
zakharyas joined
|
|||
geekosaur | (I also wonder what you'd think of m4 -i | sh) | 15:34 | |
(the original V7 manpage's comment on that was glorious) | |||
I'd also note that tcl was designed to be a scripting glue language, and its shellout stuff has always been wonky (only really fixed in very recent versions) | 15:36 | ||
mostly because that points up that you aren't so much talking about scripting, as being a *shell* glue language. python and tcl are glue at the *function* level, not the shell level | 15:37 | ||
15:37
nbrown joined,
tmch left
|
|||
llfourn | even though python is apparently not a scripting language it is used as the sole delivery mechanism by Ansible in order to configure stuff. | 15:37 | |
geekosaur | it also elevates the shell in ways that are largely unjustified. the shell is actually a pretty lousy way to do anything other than the most straightforward glue | ||
which is a large part of why Larry created Perl | 15:38 | ||
brrt | no, now i'm thinking your taking my 'like bash' to literally | ||
geekosaur | actually I'm taking your example in scrollback of running a subprocess in python | ||
yes, it's annoying to do the stuff that's trivial in the shell. my counterpoint is it's easier to do something more complex than that in Python, than it is to do it in a shell | 15:39 | ||
brrt | yes | ||
but my point was slightly different than that | |||
geekosaur | also the shell makes it easy to ignore error cases, where python forces you to deal with them | 15:40 | |
brrt | to bash, the environment with which it interacts, is your OS with all its tools and environment | ||
python makes it dififcult and annoying to deal with its environment in the same way | |||
you'll be basically be a happier python programmer using only python modules and never calling out to anything | |||
so python limits - culturally - its environment to the python-world as it were | 15:41 | ||
llfourn | os.environ["FOO"] = .. vs %ENV{FOO} = .. vs FOO= | 15:42 | |
brrt | as a result, your python program will deal with the world in a pythonic way | ||
i'm not bashing python, by the way | |||
geekosaur | right, I'm thinking that that is actually quite common in modern languages... and it has good reasons | ||
brrt | yes. but for the purposes of scripting together some behavior, that mostly lives elsewhere, its just not as easy or fluent as perl or even bash would have been | 15:43 | |
geekosaur | so, while people tend to point to things like the "line noise" aspect of perl 5, I think their real problem is that it requires them to switch mental contexts too much --- some things work like shell, others like other things. most people have trouble doing that kind of context switching | 15:44 | |
brrt | hmmm | ||
probably that is true, yes | |||
geekosaur | python and many other languages address that by bringing as much as possible into a single context | ||
brrt | (can i have prove run a single test?) | 15:45 | |
yes, that makes it a bit like java | |||
llfourn | (yes you can: prove -e 'perl6 -Ilib' some/test.t) | ||
geekosaur | (this also comes up in Haskell, many FFI interfaces look very much like their original languages instead of like Haskell and there are fairly severe impedance mismatches when combining with Haskell code) | ||
llfourn | (if you mean single test file) | 15:46 | |
brrt | (that is exactly what i meant :-)) | ||
hmm interesting point geekosaur | 15:48 | ||
15:49
kjs_ left
15:50
tmch joined
15:52
nbrown left
|
|||
nine | brrt: I see the dividing line between scripting languages and others in if the programs and libraries are delivered primarliy in source or in binary form | 15:53 | |
brrt | hmmm | ||
that is also not unreasonable | |||
hoelzro | lizmat: ah, thanks for the tip! I didn't know about that variant of .comb! | 15:56 | |
yoleaux | 13:08Z <lizmat> hoelzro: note that you can do Str.comb(Int $n) for $n chars (which is much faster :-) | ||
timotimo | how come t/spec/S32-num/power.rakudo.moar passes some TODOs? | 16:00 | |
16:05
maybekoo2 joined
16:06
zpmorgan left
|
|||
dalek | kudo-star-daily: 4fcecc7 | coke++ | log/ (8 files): today (automated commit) |
16:07 | |
16:09
skids joined
16:13
havenwood left
16:15
havenwood joined
|
|||
AlexDaniel | timotimo: I think that it's fine. Which ones exactly? | 16:18 | |
timotimo: some of them are “passes on OSX, fails on Linux” | |||
timotimo | TODO passed: 13-15, 68-70 | 16:20 | |
Skarsnik | hm, how do I know what moar version is installed? | 16:21 | |
timotimo | moar --version | ||
m: say $*VM.version | |||
camelia | rakudo-moar 0ad8b3: OUTPUT«v2016.2.8.ga.329.e.2.d» | ||
Skarsnik | Oh yeah moar --version | ||
timotimo | m: say $*VM.perl | ||
AlexDaniel | timotimo: ok 13-15 links to rt.perl.org/Ticket/Display.html?id=127500 | ||
camelia | rakudo-moar 0ad8b3: OUTPUT«(timeout)» | 16:22 | |
AlexDaniel | timotimo: which kinda explains it | ||
timotimo | ah, ugh | ||
AlexDaniel | and 68-70 is about the same issue | ||
timotimo | OK, thank you for looking! | ||
AlexDaniel | timotimo: well, I am the one who marked those as todo… :) | 16:23 | |
Skarsnik | hm, that's weird 1042.226562 Mb /opt/bin/moar how the hell this script take 1GB already | ||
16:24
cognominal left
|
|||
timotimo | uh oh :) | 16:24 | |
Skarsnik | If it's stay like that it's alright, but it should be more like < 100Mb xD | 16:25 | |
16:31
themonkeybob11 left
|
|||
timotimo | yeah, we hardly ever stay under 100 megabytes for complicated scripts ;( | 16:32 | |
16:32
themonkeybob11 joined
|
|||
timotimo | we've got many optimization opportunities ahead of us | 16:33 | |
16:35
tmch left
|
|||
brrt | another question.... | 16:35 | |
is it possible to make 'prove' really, really, really quiet | |||
or otherwise, to redirect the stdout/stderr of perl5 system() to /dev/null | 16:36 | ||
nine | You can close STDOUT and STDERR before calling system() or use shell redirection in your system() command | 16:37 | |
Skarsnik | Oh it's growing | 16:38 | |
It look like I get back the leak jnthn fixed | |||
Yep, it's leaking again | 16:40 | ||
hoelzro | re-opening STDOUT/STDERR to /dev/null is recommended; if you close them, an open in the child program could end up with descriptor 1 or 2, and your child program could mess up its output if it tries writing diagnostic messages to STDERR | 16:43 | |
Skarsnik | gist.github.com/Skarsnik/03b970d2a4b827ba1e1d | ||
16:44
wamba left
|
|||
Skarsnik | timotimo, should I repport this or something? | 16:44 | |
vendethiel | brrt: just 2>/dev/null when calling the commend? | 16:46 | |
16:46
cognominal joined
16:50
themonkeybob11 left
|
|||
ugexe | is there much of a difference between acting on Supply.act vs Channel inside a start { }? other than the all the helpers Supply provides | 16:55 | |
timotimo | Skarsnik: dunno; can you find out if it's coming from the savecapture thingie? | 16:58 | |
Skarsnik | hm, I don't really have time to look at that precisly | 17:00 | |
I can look at moar commit maybe? | |||
skids | ugexe: Supply blocks on emit, Channel does not block on send. | ||
17:03
CIAvash joined
|
|||
skids | ugexe: also, Channel only hits one of its multiple receivers for each event. | 17:03 | |
ugexe | doesn't .act do that for Supply? | ||
Skarsnik | How do I find what version/date is ga329e2d in Moar | ||
ugexe | oh i see what you mean | 17:04 | |
hoelzro | Skarsnik: Wed Mar 2 18:20:32 2016 +0100 | ||
(via git-show) | |||
17:08
zakharyas left
|
|||
Skarsnik | ok thx | 17:08 | |
hm, must be a change in rakudo or nqp then? | 17:09 | ||
17:09
xinming_ is now known as xinming
17:10
kjs_ joined
17:14
Laurent_R left
17:15
Laurent_R joined,
brrt left
17:18
brrt joined
17:21
domidumont joined
|
|||
jnthn | ugexe: The big difference between supplies and channels is that with supplies, your .act runs on whatever thread does the emit, whereas with channels there's an actual queue there and sending a value does nothing more than putting it into the queue. | 17:28 | |
ugexe: So, rather different computation models. | 17:29 | ||
ugexe | ah i see! | ||
17:32
idiosyncrat_ joined
17:33
wamba joined
|
|||
mst | jnthn: have we gone over the 'go channels are bad and you should feel bad' article and checked that ours don't have any of those problems? | 17:37 | |
might make a nice blog post actually comparing and constrasting | |||
ugexe is trying to find hacky ways to use data from a handle (IO::Socket::INET for instance) in another thread | |||
mst | if somebody tried to write said thing up would you be willing to try and review it? | ||
vendethiel | mst: that article itself is ... pretty bad, tbh :v | 17:40 | |
mst | vendethiel: oh? from what I've read elsewhere the criticisms are all at least somewhat valid | ||
17:41
CIAvash left
17:42
idiosyncrat_ left
17:43
idiosyncrat_ joined
|
|||
vendethiel | from what I've seen, it's "they're bad when misused" | 17:43 | |
mst | right, but things like the panicking seems to make it quite easy to misuse them | 17:45 | |
also, this is the channel for a perl language, making things DWIM when you do the obvious thing as opposed to telling people "the obvious thing is wrong, you should've read the documentation and managed to guess <completely different thing>" is kinda part of the schtick, no? | 17:46 | ||
17:49
firstdayonthejob left,
firstdayonthejob joined,
CIAvash joined
|
|||
vendethiel | mst: yeah, I've never liked the panic model in go anyway (I don't like go much at all, to be fair, so I guess that's expected, but for simple uses, go channels work well enough) | 17:50 | |
mst | it seems to me that channels are meant to be "I need to pass stuff around and am probably not CPU bound on the passing stuff around so whatever" | 17:51 | |
17:53
firstdayonthejob left
17:54
firstdayonthejob joined
18:01
firstdayonthejob left,
firstdayonthejob joined
|
|||
skids | Perl 6 Channels are not like Go channels. jnthn actually mentioned once wondering whether they should be renamed to avoid confusion. | 18:05 | |
For example they already buffer infinitely, and are not syncronization mechanisms between sender/receiver as they do not block on send. | 18:06 | ||
(There is still a problem shutting them down, but we can get runaway senders rather than leaked receiver loops. And the base class can be built upon to fix that.) | 18:08 | ||
18:14
sjoshi joined
18:16
kjs_ left
18:17
kjs_ joined
|
|||
RabidGravy | jnthn, you know the change you made to the generation of attribute accessors, it appears that the generate_accessor whilst actually making the rw accessors right, doesn't actually set the rw flag | 18:22 | |
so a leetle hack I have in Staticish don't work no more | |||
mst | skids: go channels don't *have* to block on send | 18:23 | |
skids: infinite buffers are bad though, eventually you need backpressure or to load shedding | |||
18:32
kjs_ left
18:36
kjs_ joined
18:42
Actualeyes left
18:50
kjs_ left
18:56
themonkeybob11 joined
18:59
brrt left
19:02
Ven joined
19:03
Ven left
19:05
firstdayonthejob left
19:12
tmch joined
19:15
zacts left
19:17
zacts joined
|
|||
stmuk | GPW schedule ist complete! | 19:19 | |
timotimo | awesome | 19:20 | |
lizmat | stmuk: thanks for the Durham tip | ||
yoleaux | 13:34Z <llfourn> lizmat: another possible bug: say :($a) ~~ :($a is rw) # returns True but it should be False IMO, is rw is narrower | ||
19:21
CIAvash left
|
|||
stmuk | lizmat: you visited? | 19:21 | |
lizmat | yeah, we only had 2 hours before having to make it back to the ferry | 19:22 | |
and lost half an hour looking for a parking space | |||
but we walked from the train station to the cathedral, had some tea on the green, and then back to the station again | |||
stmuk | its beautiful .. I spent some time at university there | ||
lizmat | the weather didn't cooperate much (at some point it hailed) | 19:23 | |
but it was nice enough for us to put it on the list of places to revisit at a later time :-) | |||
stmuk | :) | ||
lizmat | but not early on a Saturday afternoon :) | 19:24 | |
stmuk | the driving is awful .. | ||
lizmat | well, we were at a disadvantage driving a van that was too high for any of the parking garages in the center | 19:25 | |
dalek | osystem: b600659 | RabidGravy++ | META.list: Update META -> META6.json for Staticish |
||
stmuk | the castle is part of the university and it's possible to stay there cheaply and that includes parking in front of the cathedral | 19:26 | |
19:26
abaugher left
|
|||
timotimo | there's no way for a num or str to ever not be p6definite, right? | 19:26 | |
19:26
abaugher joined
|
|||
timotimo | m: use nqp; my str $a; say nqp::p6definite($a) | 19:26 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«True» | 19:27 | |
timotimo | hm, do we have a clue why camelia's reacting so slow? | ||
m: use nqp; my num $a; say nqp::p6definite($a) | |||
camelia | rakudo-moar 0ad8b3: OUTPUT«True» | ||
RabidGravy | another sunday another module needs fixing | ||
lizmat | m: use nqp; my str $a; say nqp::isnull_s($a) | 19:30 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«(timeout)» | ||
lizmat | what? | ||
m: use nqp; my str $a; say nqp::isnull_s($a) | |||
camelia | rakudo-moar 0ad8b3: OUTPUT«0» | 19:31 | |
lizmat | perhaps some rogue processes are eating all of camelia's CPU in thatb VM ? | ||
fwiw, I sorta expected that to return 1 | 19:32 | ||
timotimo | hm, doesnt need decont, does it? | 19:33 | |
lizmat | doesn't make a difference, so I would gather it doesn't | 19:34 | |
timotimo | i just patched Perl6/Optimizer.nqp to not emit an "if p6definite($foo) { $foo } else { &operator() }" for += and friends | ||
er | |||
only for native variables, of course | |||
19:36
CIAvash joined
19:37
dj_goku left,
dj_goku joined
|
|||
AlexDaniel | lizmat: yeah. camelia is misbehaving lately | 19:41 | |
19:42
themonkeybob11 left
|
|||
timotimo | nine: can you have a quick look at some monitoring or something to see what could be wrong? | 19:42 | |
19:42
sftp left
|
|||
dalek | kudo/nom: 25eef56 | timotimo++ | src/Perl6/Optimizer.nqp: don't need to check native vars for definite in metaop_assign opt |
19:51 | |
lizmat | Weeee! a commit by someone other than me! wheeee :-) | ||
19:51
sftp joined
|
|||
timotimo | sorry about that, liz .. i've had ideas in the recent days, but nothing materialized into code | 19:52 | |
19:52
sjoshi left
|
|||
lizmat | I just get depressed if I do a git pull and all it says is "already up to date" :-( | 19:52 | |
timotimo | understandable | 19:53 | |
19:58
CIAvash left
|
|||
sortiz | Skarsnik++ # mysql availability test. | 19:58 | |
dalek | Iish: 98279dc | (Salvador Ortiz)++ | / (2 files): mysql: Blob columns returns Buf not Blob. Test for return type and NULL. |
20:00 | |
Iish: 3cad692 | (Salvador Ortiz)++ | t/26-mysql-blob.t: Merge branch 'master' of github.com:perl6/DBIish |
|||
20:00
labster joined
|
|||
20:01
brrt joined
|
|||
lizmat | timotimo: and then I won't be able to make it to the GPW this year and see all of the P6 crew :-( | 20:02 | |
timotimo | :( | 20:04 | |
20:09
Cabanossi left
|
|||
jnthn | lizmat: I won't be there either, fwiw | 20:10 | |
sortiz | .oO( It will be time to ask for commit bit in rakudo? ) |
||
jnthn | RabidGravy: The "not marked is rw" thing sounds worth fixing; could you RT it so I don't forget? :) | ||
Will add a test too :) | |||
RabidGravy | okay | 20:11 | |
jnthn | mst: Would certainly be able to read/comment on such a post. | ||
(Also need to read that blog post you linked properly, rather than just skimming it :)) | 20:12 | ||
20:12
Cabanossi joined
|
|||
Skarsnik | jnthn, I don't know if you saw this gist.github.com/Skarsnik/03b970d2a4b827ba1e1d the last output is with a today rakudo, the first is when you patched arg.c in more to fix a leak | 20:12 | |
jnthn | Skarsnik: Curious, and exact same program being run? | 20:14 | |
Skarsnik | Yes | ||
jnthn | Wonder what's to thank for that... It's a much slower leak than the last one at least | ||
Skarsnik | The modules involved did not get any change too | ||
jnthn | OK. Valgrind output would be useful again. | 20:15 | |
20:16
Util left
|
|||
jnthn | There's been very few patches in Moar in the meantime...odd. | 20:16 | |
20:16
dalek left
20:17
labster left,
darutoko left
|
|||
RabidGravy | jnthn, rt.perl.org/Ticket/Display.html?id=127665 | 20:19 | |
jnthn | RabidGravy: Thanks! :) | ||
RabidGravy | y'see it turns out my modules are better than roast for determining compatibility issues | 20:22 | |
I find one every week ;-) | 20:23 | ||
jnthn | Over time we'll transcribe much that into roast, I hope :) | ||
20:23
SCHAAP137 left
|
|||
jnthn | Hopefully by us doing converage analysis and spotting gaps proactively, rather than just by continually busting your modules :) | 20:24 | |
*coverage | |||
20:24
domidumont left
20:25
davido joined
|
|||
skids | mst: yeah backpressure and an eventual failure mode is definitely needed, and the mechanism for that needs both time and queue depth components, and shouldn't happen per-value-passed so it isn't itself a force multiplier. Lessons learned from networking :-). | 20:26 | |
mst | skids: yep | ||
skids: I quite like erlang's approach where the more full a process' mailbox, the more reductions you're charged for sending to it | 20:27 | ||
seems like an elegant way to propagate backpressure across the system from overloaded components | |||
20:27
Begi joined
20:30
jjido joined,
labster joined
|
|||
Skarsnik | and I don't have scrolling in screen, annoying | 20:30 | |
20:32
musiKk_ joined
|
|||
skids | Unfortunately the majority of the very clever solutions to queueing problems developed for networking rely on the fact that the network is allowed to drop packets. Stochasctic fair queueing wouldn't go over well internally in a program :-). | 20:33 | |
20:33
SCHAAP137 joined
|
|||
Skarsnik | damn it barely leak in valgrind lol | 20:35 | |
jnthn, I added valgring output in gist.github.com/Skarsnik/03b970d2a4b827ba1e1d | 20:36 | ||
jnthn | Yowser, something's going rotten in cleanup up at the top there too...but that looks familiar, I thought I'd fixed that... | 20:38 | |
Skarsnik: Anyways, thanks...will dig thorugh that some more in the next couple of days | 20:39 | ||
20:40
wamba left,
virtualsue joined
|
|||
Skarsnik | I wqs like, yay, no more leak, I can run this bot on this server, after a while it was taking 1Gb of memory... not fun x) | 20:42 | |
jnthn scribbled a blog post about what he got up to in the last week or so... 6guts.wordpress.com/2016/03/06/dig...lity-work/ | 20:45 | ||
20:47
geraud joined,
ely-se joined
20:48
brrt left
|
|||
lizmat | jnthn++ | 20:48 | |
argh, dalek awol ? | 20:51 | ||
I've just committed 978754607176392f68 | 20:52 | ||
"Make :($a) ~~ :($a is rw) return False" | |||
jnthn: ^^^ was that the one you were going to look at ? | |||
nine | timotimo: several rakudo builds were running in parallel eating all memory | 20:53 | |
20:55
jjido_ joined
|
|||
jnthn | lizmat: Hm, yeah, I'd expect if anything :($a is rw) ~~ :($a) might be true in so far as rw is a constraint | 20:55 | |
But not the other way around | |||
lizmat | ok, well that's fixed now :-) | ||
jnthn | lizmat++ | ||
lizmat | I'll be looking at Signature.ACCEPTS again tomorro | 20:56 | |
20:56
AlexDaniel left
20:57
jjido left
|
|||
lizmat | jnthn: "The patch doing so it’s quite " isn't ??? | 20:58 | |
20:58
kaare_ left
|
|||
lizmat | m: dd :(42) ~~ :(666) # jnthn, do you agree that this is a bug ? | 21:00 | |
camelia | rakudo-moar 0ad8b3: OUTPUT«Bool::True» | ||
Skarsnik | great openssl that crash again >< | 21:03 | |
moritz | jnthn: "The patch doing so it’s quite ready for prime-time yet" you probably meant *isn't* quite ready for prime time? | 21:04 | |
21:04
kjs_ joined
|
|||
moritz | also, jnthn++ | 21:05 | |
RabidGravy | yeah nice | ||
jnthn++ | |||
21:07
idiosyncrat_ left
21:13
wamba joined
21:15
bjz left
|
|||
autarch | jnthn: those performance improvements are very exciting! | 21:16 | |
jnthn | lizmat: Fixed, thanks | 21:17 | |
moritz: Thanks for pointing out also :) | |||
lizmat: Yeah, :(42) ~~ :(666) should certainly be False | |||
21:18
maybekoo2 left
|
|||
autarch | jnthn: I have a module that performs abysmally for no reason I can figure out - it might be a good thing to look at for perf improvements - github.com/perl6/Pod-To-HTML/tree/...treewalker - github.com/autarch/perl6-Pod-TreeWalker | 21:19 | |
lizmat | jnthn: ok, so how do I handle spectests that implicitely relay on that? | ||
jnthn: actually, the problem is more like: | |||
autarch | and the associated Pod-To-HTML branch which uses that module is also very slow - github.com/perl6/Pod-To-HTML/tree/...treewalker | ||
21:20
davido left
|
|||
lizmat | m: dd :($a where * == 42) ~~ :($a where * == 42) # we can't see inside the WhateverCode, so we can only assume mismatch | 21:20 | |
camelia | rakudo-moar 978754: OUTPUT«Bool::True» | ||
lizmat | *rely | ||
21:23
zpmorgan joined,
jjido_ left
21:25
molaf_ left
|
|||
ugexe | Skarsnik: maybe set up a local SSL MITM proxy to log whats happening :( | 21:26 | |
jnthn | autarch: Yes, real examples of slow stuff is useful. Will put those on my list of things to analyze; thanks! | 21:27 | |
lizmat: Errata I guess... :) | |||
moritz | does it make sense to return a tri-state thingy? | 21:29 | |
True if we know it's a match, False if we know it's not, and Bool if we know that we don't know? | |||
21:29
bjz joined
|
|||
lizmat | and how would that affect MMD / role composition ? | 21:30 | |
only True will break role composition, no ? | |||
jnthn | moritz: That won't work out so well for smart-matching I guess... | ||
moritz | do we even consider signatures for role composition? | ||
21:30
bjz left
|
|||
moritz | jnthn: right | 21:30 | |
21:31
bjz joined
|
|||
jnthn | lizmat: I guess we'll just have to see what the actual fallout is... | 21:31 | |
21:31
themonkeybob11 joined
|
|||
lizmat | okidoki | 21:31 | |
jnthn | lizmat: Was the best you uncovered actually about roles? | 21:32 | |
lizmat: I did write various tests for role composition and sigatures | |||
moritz: Yeah, we do these days...was fairly late-breaking... | |||
(As in, not long before 6.c) | |||
lizmat | jnthn: yeah, t/spec/S06-signature/introspection.t tests 118-121 | ||
jnthn | That's not about roles though? | 21:33 | |
lizmat | it's about signatures and is-perl-idempotent | 21:34 | |
and that uses eqv | 21:35 | ||
and it's Parameter eqv Parameter that I fixed so that it won't match | |||
m: dd :(42) eqv :(666) | 21:36 | ||
camelia | rakudo-moar 978754: OUTPUT«Bool::False» | ||
lizmat | m: dd :(42) ~~ :(666) | ||
camelia | rakudo-moar 978754: OUTPUT«Bool::True» | ||
21:36
aindilis left
|
|||
lizmat | m: dd :(42) eqv :(42) | 21:37 | |
camelia | rakudo-moar 978754: OUTPUT«Bool::True» | ||
lizmat | that works, because we don't internally always make that a Callable | ||
m: dd :(42).params[0] | |||
camelia | rakudo-moar 978754: OUTPUT«Int $ where { ... }» | ||
lizmat | hmmm....ah, yes, Parameter.perl is still stupid | 21:38 | |
jnthn | lizmat: Yeah...I note that the tests for default values have been written sensitive to this | ||
21:39
themonkeybob11 left,
BenGoldberg joined
|
|||
lizmat | anyway, I think the tests on lines 211-214 are highly suspect | 21:40 | |
jnthn | I'd agree | ||
Time for me to rest, I think | 21:41 | ||
'night o/ | |||
lizmat | gnight, jnthn | ||
21:44
themonkeybob11 joined
21:45
bjz left,
rindolf left
21:47
Begi left
|
|||
timotimo | gnite jnthn :) | 21:47 | |
RabidGravy | toodles | 21:48 | |
timotimo | tu tu ru | ||
21:49
themonkeybob11 left
21:54
firstdayonthejob joined
21:55
kjs_ left
21:59
kjs_ joined
|
|||
timotimo | what on earth | 22:02 | |
can someone try a perl6 --output=optimize foobar.p6 | less | |||
and not scroll to the bottom | |||
and tell me what happens to their cpu usage? | |||
lizmat | any foobar will do ? | 22:03 | |
$ perl6 --output=optimize -e '' | 22:04 | ||
Use of Nil in string context | |||
? | |||
moritz | I guess it needs to produce some output | ||
otherwise scrolling or not doesn't make much sense | |||
22:05
kjs_ left
|
|||
moritz | timotimo: no specialties in CPU usage here | 22:05 | |
$ echo 'say slurp "README.md"' > foobar.p6 | |||
$ ./perl6-m --output=optimize foobar.p6 |less | |||
perl6-m simply exits, less buffers its output. All is as I'd expect. | 22:06 | ||
sleep time here& | |||
lizmat | good night, moritz | 22:07 | |
22:07
kjs_ joined
22:08
FROGGS left
22:09
brrt joined,
brrt left
|
|||
rudi_s | Hi. Can I somehow access the variable name which was used to call a function? So a call like foo($x); yields '$x' inside foo. | 22:12 | |
22:13
themonkeybob11 joined
|
|||
sjn | rudi_s: could you describe the problem you're trying to solve, that lead to this question? | 22:18 | |
22:20
wamba left
|
|||
rudi_s | sjn: I'm thinking about a DSL-like language which allows the setting of certain variables. And I thought it would be nice if something like my $a = 'foo'; my $b = 'bar'; result $a, $b; would work and result could figure out, that $a and $b were set. | 22:20 | |
I know I could use a hash, or not perl and instead write my own parser and so own. - But I liked the idea and was curious if it's possible. | 22:21 | ||
geekosaur | timotimo/moritz, presumably you need it to produce more than PIPE_BUF amount of output | 22:22 | |
timotimo | moritz: is say slurp readme.md more than a page ful? | 22:25 | |
sjn | rudi_s: sounds like you're looking for making a grammar and then some actions that do the right thing with "result $a, $b;" | ||
22:25
RabidGravy left
|
|||
timotimo | because when i do that, i get a single cpu full of usage | 22:25 | |
100% kernel according to htop | |||
well, not 100%, but nearly so | |||
rudi_s | sjn: When I said DSl-like language I meant perl6 with "nice" operators and the like to still be able to use the full power of perl6 if I want to. | 22:26 | |
22:26
TEttinger joined
|
|||
sjn | so you want to extend Perl6 itself? | 22:27 | |
rudi_s | sjn: Yes. | ||
timotimo | m: sub test(\foo) { say foo.VAR.name }; my $hello; my $rudi; test($hello); test($rudi); | 22:28 | |
camelia | rakudo-moar 978754: OUTPUT«$hello$rudi» | ||
timotimo | rudi_s: this is what the dd sub does, too | ||
rudi_s | timotimo: Wow, awesome. - Thank you! Perl6 is really crazy. - Still not sure if this is a good idea but I like that it can be done. | 22:29 | |
22:29
John[Lisbeth] joined,
SCHAAP137 left
22:30
BenGoldberg left
|
|||
rudi_s | timotimo: Can this be combined with "slurpy" arguments? So I could get all passed variables in test($hello, $rudi)? | 22:30 | |
lizmat | rudi_s: only with nqp trickery | ||
22:30
vendethiel left,
BenGoldberg joined
|
|||
John[Lisbeth] | What is perl 5 from the perspective of perl 6 users? | 22:31 | |
sjn | hi John[Lisbeth] :) | ||
rudi_s | Hm, that's too bad. | ||
sjn | John[Lisbeth]: they're friends and family :D | ||
John[Lisbeth] | I was talking to the guys in perl 5 and basically they said perl 6 was a different and seperate langauge than perl, but then I saw couple of talks by Larry Wall and he seems to be behind perl 6 | 22:32 | |
I guess I don't know the difference besides a cleaned up syntax and cleaned up type system | |||
sjn | yes, it is, and yes he is | ||
timotimo | i've never done any perl5, so i only know the parts it does worse than p6 | 22:33 | |
so obviously i don't like it | |||
sjn | there are a LOT of differences. in fact, Perl 6 isn't based on Perl 5 at all (no common code), but somewhat inspired by the good bits | ||
timotimo | :P | ||
John[Lisbeth] | can you use perl 5 code in your perl 6 scripts though objects or something? | ||
sjn | we'd like to think the bad bits in perl5 have been significantly improved :D | ||
timotimo | yes, you can | 22:34 | |
sjn | John[Lisbeth]: use Inline::Perl5; | ||
timotimo | Inline::Perl5 for that direction and Inline::Perl6 for the other direction exist and work well | ||
22:34
musiKk_ left
|
|||
John[Lisbeth] | Can I get perl 6 from my ubuntu repos? | 22:34 | |
timotimo | yes, but you'll get a ridiculously outdated version | ||
John[Lisbeth] | it's stable aint it? | ||
sjn | much better to follow instructions on perl6.org | ||
timotimo | it's pre-alpha, the one you'll get | ||
John[Lisbeth] | Maybe there's a ppa | 22:35 | |
timotimo | it'll be lacking many features, and have many bugs, and also be very slow and use a lot more memory than it would if you got it from perl6.org or somewhere else | ||
sjn | John[Lisbeth]: the one you get from following the instructions on perl6.org is up-to-date and stable | ||
John[Lisbeth] | All I care is to get the most recent stable version of perl 6 | 22:36 | |
timotimo | then you can use what perl6.org recommends. rakudo star tarball, or a docker image, for example | ||
John[Lisbeth] | But muh sudo apt-get update && sudo apt-get ugprade | ||
sjn would love that too | 22:37 | ||
lizmat | m: dd :(&foo:(--> Bool)).params[0] # timotimo: seems wrong to have a post-constraint here? | ||
camelia | rakudo-moar 978754: OUTPUT«Parameter &foo = &foo where { ... }» | ||
sjn | maybe drop by the Ubuntu irc channel and ask for it too? :) | ||
John[Lisbeth] | I am sure I can find it on the google machine | ||
timotimo | uh, no clue about that stuff :S | ||
22:38
_nadim left
|
|||
sjn | package info for ubuntu's rakudo package says the maintainer is Ubuntu Developers [email@hidden.address] | 22:38 | |
and Original-Maintainer: Debian Rakudo Maintainers [email@hidden.address] | |||
lizmat | .tell jnthn dd :(&foo:(--> Bool)).params[0] # seems wrong to have a post-constraint here? | ||
yoleaux | lizmat: I'll pass your message to jnthn. | ||
John[Lisbeth] | I basically have been studying functional programming for 2 years | 22:42 | |
timotimo | dinner! \o/ | ||
John[Lisbeth] | I saw an old video about unix programming and how you can use pipelines to string little programs together making one big process that data flows through to solve a problem | ||
timotimo | lizmat: maybe that's how we implement subsignatures? :( | 22:43 | |
John[Lisbeth] | foo | bar | baz turned out to be simliar to baz (bar (foo)) in lisp and that took me a couple years to find out | ||
and now I suppose I am looing for a language that can do what lisp can do with recursion but that can also do other things too. | 22:44 | ||
sjn | Lisp is really nice, but if you'd like something more multi-paradigm, you can't do much better than Perl 6 atm | 22:46 | |
Perl 6 has some really nice functional programming features, plus lots of other neat stuff which you can make use of as you want/need | 22:48 | ||
John[Lisbeth] | can you program lazily? | ||
or work with inifnite lists? | |||
sjn | yep | ||
yep | 22:49 | ||
22:49
tardisx joined
|
|||
John[Lisbeth] | ok then it pretty much satisfies my need. I have an o'rielly book about awk and sed, and then an o'rielly book about bash, and then I'm gonna take on perl 6 | 22:49 | |
sjn | afaic, the canonical example is Perl6's super-short implementation of the fibionacci sequence | ||
my @fib := 1, 1, *+* ... *; | 22:50 | ||
lizmat | timotimo: oddly enough, there's a separate sub_signature attribute in Parameter | ||
ok, I have no inspiration anymore, so I bid you all a good night! | |||
sjn | m: my @fib := 1, 1, *+* ... *; say @fib[20]; | ||
camelia | rakudo-moar 978754: OUTPUT«Type check failed in binding; expected Positional but got Seq (?) in block <unit> at /tmp/2sRDvXc48M line 1» | ||
sjn | oh noes! | 22:51 | |
lizmat | m: my @fib = 1, 1, *+* ... *; say @fib[20]; | ||
camelia | rakudo-moar 978754: OUTPUT«10946» | ||
lizmat | sjn: GLR took care of the need for binding | ||
sjn | aah | ||
lizmat | although admittedly, the error is LTA | 22:52 | |
sjn | ok, so there are some examples out there that need updating | ||
lizmat | very likely :-) | ||
sleep& | |||
sjn | nn! | ||
John[Lisbeth]: check out perl6intro.com for a soft introduction (there are more learning resources on perl6.org, so you may want to use that as a starting point for your explorations :) | 22:53 | ||
22:54
jjido joined
23:01
BenGoldberg left
23:02
avenj left,
avenj joined
23:13
salva left
|
|||
timotimo | sjn: how do you program lazily in perl6? | 23:20 | |
i'm a bit saddened that i get so much METAOP_ASSIGN in my code ... | 23:26 | ||
sjn usually lies in bed when programming lazily :) | 23:27 | ||
timotimo | it's understandable that it wouldn't turn it into the resulting code already in the optimizer, because it kind of doesn't know if it'd turn into a list thing or not, so it refuses to do stuff, as it doesn't know how to handle @ or % sigiled vars either | ||
23:27
kjs_ left
|
|||
timotimo | sjn: i just mean compared to haskell, perl6 doesn't offer "lazy programming" | 23:28 | |
sjn | ah, sure. | ||
although the comparison was more with Lisp | |||
timotimo | what does lisp offer in terms of lazy programming? | 23:29 | |
23:29
jolts joined
|
|||
sjn | isn't infinite lists a feature of that? | 23:30 | |
sjn googles, and is reminded that it's called "lazy evaluation" | 23:31 | ||
timotimo | that's more like "we have iterators" + "our lists don't have to be created by exhausting an iterator" | ||
sjn | but no, I'm guessing type inference isn't (yet?) a haskell-feature Perl 6 has yet... | 23:32 | |
and that's a "lazy programming" feature, iirc | 23:33 | ||
timotimo | no, we don't do type inference | ||
i'm not sure that counts as "lazy programming" | 23:34 | ||
but i may have no idea what you mean by that | |||
i was focusing on lazy evaluation | |||
sjn | type inference = "dear compiler: here are the bits and pieces, you figure out what order to run it in" or someting like that :) | 23:35 | |
seems pretty lazy to me :D | |||
timotimo | in haskell it's more like "you better have thought this out up front, dear developer. because if your shit doesn't work right 100%, you'll get an error" | 23:36 | |
that's more a "careful programming" feature | |||
sjn | sounds like the type of lazy you find in the Perl communty (cf. "laziness, hubris and impatience" :) | 23:37 | |
23:39
Laurent_R left
|
|||
timotimo | m: my @a = 1, 2, 3; @a ,= 2, 3; say @a.perl | 23:40 | |
camelia | rakudo-moar 978754: OUTPUT«(my \Array_78888720 = [Array_78888720, (2, 3)])» | ||
timotimo | i don't think that's useful :D | 23:41 | |
but what do i know | |||
i think it's actually a bug | |||
sjn | hm | ||
wouldn't you use unshift for that? | |||
timotimo | well, yeah, but this is about optimizing METAOP_ASSIGN in more cases | 23:42 | |
sjn | ah | ||
timotimo | currently it bails out when it can't tell it doesn't get a regular scalar variable | ||
i *think* we used to have something to ensure metaop-assign with list-assignment stuff DTRT | |||
23:45
idiosyncrat_ joined
|
|||
timotimo | i mean ... i guess i can kick out that check and see what the spec tests think | 23:46 | |
23:54
spider-mario left
|