Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2014-05-28

Perl 6 | Reference Documentation | Rakudo

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

All times shown according to UTC.

Time Nick Message
00:04 woolfy1 joined #perl6
00:07 xragnar_ joined #perl6
00:23 grondilu joined #perl6
00:24 grondilu In Complex.pm, why are $.re and $.im defined as num?   Why not just Real?
00:24 * grondilu remembers that to have annoyed him a bit while writing a RC entry lately.
00:30 profan joined #perl6
00:37 * grondilu now remembers it was in http://rosettacode.org/wiki/K-means%2B%2B_clustering#Perl_6
00:43 * lowbitrate now understands why IRC is a slow conversation chat
00:44 dalek Net--IRC/new-handler: f063741 | (Jarrod Funnell)++ | lib/Net/IRC/CommandHandler.pm:
00:44 dalek Net--IRC/new-handler: CommandHandler facelift: 'method foo($ev) is cmd {}'
00:44 dalek Net--IRC/new-handler: review: https://github.com/TiMBuS/Net--IRC/commit/f063741f9c
00:44 Timbus what th
00:45 Timbus i forgot that happened
00:46 Timbus lowbitrate, it depends on what you need it to be ready for :v
00:47 lowbitrate The basics of web dev.
00:48 lowbitrate Database access and, well, thats all.
00:48 lowbitrate Frameworks would be good, but nothing's new come out, so raw-PSGI isn't *that* harmful
00:49 lowbitrate Timbus
00:49 Timbus hrmmm not sure how well the DBI works yet
00:50 lowbitrate I see.
00:50 Timbus you should try it and see what works :P
00:51 lowbitrate Well, if if doesn't explode, why not.
00:51 Timbus when people need something to work, people tend to make it happen
00:52 profan Anyone here knowledgeable about obscure perl6 errors?
00:52 lowbitrate this would be a good side project, but I can't risk stability.
00:52 profan Running into some mess when trying to run panda's bootstrapper.
00:52 profan https://pastee.org/ufnwe
00:52 lowbitrate after everything's done in perl 5, I will try to port to perl 6.
00:53 Timbus that's probably a good idea
00:53 lowbitrate thanks for the help
00:54 lowbitrate I guess, by making a simple read of your error, that 'use' can't read more than one argument.
00:54 profan For clarity, the top part is the beginning of the bootstrapper (https://github.com/tadzik/panda/blob/master/bootstrap.pl), and the bottom part is the error ejected.
00:54 lowbitrate yet, I have no deep understanding, so I won't be helping too much
00:55 Timbus thats odd, i use lib 'etc'; all the time
00:55 grondilu profan: perl6 --version ?
00:56 profan grondilu: that might be it, "perl6 version 2012.01 built on parrot 4.0.0 revision 0
00:56 Timbus woooah
00:56 lowbitrate maybe use lib('...')
00:56 Timbus it belongs in a museum
00:56 lowbitrate or update lol
00:56 profan I seem to be running an ancient version of perl6, even though I just compiled and installed the latest rakudo.
00:56 profan Will sort that out :P
00:56 Timbus you might have two
00:56 lowbitrate good luck
00:57 profan Timbus: probably
01:03 Timbus .tell japhb Hey take a look at my CommandHandler branch for net::IRC and tell me what you think. I think it's great and could be further explored. Maybe integrate it into ::Bot and have things like command renaming and conflict resolution between modules
01:03 yoleaux Timbus: I'll pass your message to japhb.
01:09 Pleiades` joined #perl6
01:14 dayangkun joined #perl6
01:15 SevenWolf joined #perl6
01:18 panchiniak left #perl6
01:23 profan Turned out it was the old perl6 in there still, sorted it out by building and installing it properly, thanks guys :)
01:36 [Coke] yay, think I finally tricked the submodules in moarvm into behaving
01:36 [Coke] yay, I am now getting a moarvm build on the daily star build....
01:37 [Coke] I suspect there may be far too much cheating going on here. :P
01:40 Sqirrel_ joined #perl6
01:42 jack_rabbit joined #perl6
01:44 Su-Shee_ joined #perl6
01:56 klapperl_ joined #perl6
01:57 * [Coke] has to kill it and restart it in screen.
01:58 geekosaur ob reptyr
01:59 [Coke] -> homeish
02:04 BenGoldberg joined #perl6
02:08 bbkr joined #perl6
02:30 water joined #perl6
02:30 colomon_ joined #perl6
02:33 btyler joined #perl6
02:40 bbkr joined #perl6
02:50 Pleiades` joined #perl6
02:56 dalek rakudo-star-daily: 9d79992 | coke++ | bin/star.sh:
02:56 dalek rakudo-star-daily: * fix issue with moarvm git submodules
02:56 dalek rakudo-star-daily: * re-enable parrot runs..
02:56 dalek rakudo-star-daily: review: https://github.com/coke/rakudo-star-daily/commit/9d799921d8
02:56 dalek rakudo-star-daily: e2424ff | coke++ | log/ (10 files):
02:56 dalek rakudo-star-daily: today (automated commit)
02:56 dalek rakudo-star-daily: review: https://github.com/coke/rakudo-star-daily/commit/e2424ff5a4
02:56 [Coke] ^^ now contains runs for parrot & moar
02:56 [Coke] will run daily going forward.
02:59 dj_goku joined #perl6
02:59 dj_goku left #perl6
03:00 dj_goku joined #perl6
03:01 dj_goku lizmat: thanks about the gmake issue with OSX.
03:03 rurban joined #perl6
03:18 btyler joined #perl6
03:24 Tene joined #perl6
03:36 [Coke] m: my $a = set(1..7); say $a.combinations(3);
03:36 camelia rakudo-moar 851811: OUTPUT«1 2 3 1 2 4 1 2 5 1 2 6 1 2 7 1 3 4 1 3 5 1 3 6 1 3 7 1 4 5 1 4 6 1 4 7 1 5 6 1 5 7 1 6 7 2 3 4 2 3 5 2 3 6 2 3 7 2 4 5 2 4 6 2 4 7 2 5 6 2 5 7 2 6 7 3 4 5 3 4 6 3 4 7 3 5 6 3 5 7 3 6 7 4 5 6 4 5 7 4 6 7 5 6 7␤»
03:36 [Coke] m: my $a = set(1..7); say $a.combinations(3).perl
03:36 camelia rakudo-moar 851811: OUTPUT«([1, 2, 3], [1, 2, 4], [1, 2, 5], [1, 2, 6], [1, 2, 7], [1, 3, 4], [1, 3, 5], [1, 3, 6], [1, 3, 7], [1, 4, 5], [1, 4, 6], [1, 4, 7], [1, 5, 6], [1, 5, 7], [1, 6, 7], [2, 3, 4], [2, 3, 5], [2, 3, 6], [2, 3, 7], [2, 4, 5], [2, 4, 6], [2, 4, 7], [2, 5, 6], [2…»
03:59 Ben_Goldberg joined #perl6
04:01 rindolf joined #perl6
04:01 dayangkun joined #perl6
04:03 kaare_ joined #perl6
04:18 bjz joined #perl6
04:28 telex joined #perl6
04:47 SamuraiJack joined #perl6
04:59 darutoko joined #perl6
05:05 rurban joined #perl6
05:08 rurban1 joined #perl6
05:08 denis_boyun joined #perl6
05:16 chankey joined #perl6
05:25 kaare_ joined #perl6
05:31 profan So when panda tells me I need to precompile a dependency, what exactly am I supposed to do? Haven't managed to find any helpful information anywhere.
05:32 profan I've gotten to the point where I've figured out how to actually compile the module to a .pir file, but not where panda actually looks for it when compiling modules
05:33 xinming_ joined #perl6
06:17 Sqirrel joined #perl6
06:21 kaleem joined #perl6
06:24 denis_boyun_ joined #perl6
06:29 BAMbanda joined #perl6
06:29 BAMbanda I want to contribute to duckduckgo's search engine and they've open sourced instant search options
06:29 BAMbanda their api uses a perl backend
06:30 BAMbanda perl6 has captured my curiosity, would learning perl6 still help me learn how to contribute using their backend api?
06:30 BAMbanda will I be able to understand perl5 if I start using perl6? counter intuitive?
06:31 nwc10 At a guess, and to be honest, I think that it would be hard going from Perl 6 to Perl 5. However, I can't answer this from personal experience as I know Perl 5 very well, and don't know Perl 6 that well.
06:32 BAMbanda nwc10, may I ask why you think it would be difficult? Is the language that big of a difference?
06:32 nwc10 The "natural" idiomatic way of doing things will be different
06:33 BAMbanda ehh, i might as well learn both. why not :)
06:33 nwc10 I think if one has got used to various of the powerful Perl 6 operators, one will keep trying to look for them in Perl 5 to solve the problem, and find them missing
06:36 BAMbanda nwc10, yeah true, bit it'll allow for good compare and contrast.
06:37 BAMbanda If a feature is missing, it will reinforce my incentive to use perl6 to solve problems!
06:40 virtualsue joined #perl6
06:41 BAMbanda wait, most important of all. I'm sorry that I haven't read through all the documentation
06:42 BAMbanda will the existing CPAN modules work for the most part? Like without much modificatin
06:42 BAMbanda will Perl6 be backwards compatible
06:44 nwc10 no. Rather too much of CPAN ends up depending on implementation details of Perl 5 - either because it ends up using XS code (and hence is tied to the particular C implementation), or because it happens to rely on one of the ugly quirks of the language
06:44 nwc10 I believe that the specific choise is not to worry about backwards compatibility, and fix the bigger picture problems with the language
06:45 nwc10 there are plans on how to interface back to CPAN modules, but I'm not sure what the state of them is
06:46 BAMbanda http://perlcabal.org/syn/S01.html
06:47 BAMbanda nwc10, according to larry, you can choose which perl version you wish to use a the beginning of each lexical scope
06:47 BAMbanda :), good enough for me at the moment, that's actually pretty cool
06:52 FROGGS joined #perl6
06:58 zakharyas joined #perl6
07:02 denis_boyun_ joined #perl6
07:05 djanatyn joined #perl6
07:07 tadzik if only it was implemented :)
07:07 tadzik (it is, partially)
07:09 rurban joined #perl6
07:13 mtj joined #perl6
07:20 rurban joined #perl6
07:28 timotimo hello o/
07:28 timotimo i'm a bit sad i missed lowbitrate
07:28 timotimo i could have told 'em that DBIish is none too shabby and that dancer is quite cool, but there's no web framework using the async I/O or multithreading yet
07:30 Timbus i wasnt too sure, but i still tried to make him use it :o
07:31 timotimo :)
07:31 Timbus bully him into using perl 6
07:31 Timbus 'stop enjoying yourself, stop enjoying yourself' i chant, while slapping his hand into the keyboard
07:32 timotimo hahahaha, that's mean :)
07:38 sergot morning o/
08:04 markov left #perl6
08:05 pdcawley joined #perl6
08:11 felher joined #perl6
08:12 virtualsue joined #perl6
08:21 rurban joined #perl6
08:28 dakkar joined #perl6
08:29 zakharyas joined #perl6
08:40 Thunktone joined #perl6
08:41 dalek Perlito: 616768c | (Flavio S. Glock)++ | / (4 files):
08:41 dalek Perlito: Perlito5 - grammar emitter - "before" bugfix
08:41 dalek Perlito: review: https://github.com/fglock/Perlito/commit/616768ccc2
08:42 rurban joined #perl6
08:46 donaldh joined #perl6
08:47 dalek Perlito: 234d9e6 | (Flavio S. Glock)++ | / (3 files):
08:47 dalek Perlito: Perlito5 - grammar - allow special variables in "for" loop
08:47 dalek Perlito: review: https://github.com/fglock/Perlito/commit/234d9e68e6
08:47 zakharyas joined #perl6
08:53 dmol joined #perl6
09:06 zakharyas joined #perl6
09:14 pdcawley joined #perl6
09:15 pdcawley_ joined #perl6
09:17 pdcawley_ joined #perl6
09:41 bbkr joined #perl6
09:43 lizmat m: "foo" ~~ m/<ws>+/
09:43 masak good just-before-noon, #perl6
09:43 camelia rakudo-moar 851811: OUTPUT«(timeout)»
09:43 lizmat good *, masak, JIT for a new rakudobug, I'm afraid
09:44 timotimo that's not a bug
09:44 timotimo <ws> is perfectly capable of matching the empty string
09:45 timotimo as often as you'd like it to
09:45 lizmat but should it hang ?
09:45 timotimo there's an ample supply of empty strings in "foo"
09:47 masak lizmat: it shouldn't hang, but the fact that it doesn't is well-known and a bit hard to fix.
09:47 Psyche^ joined #perl6
09:47 masak lizmat: it comes down to analysis of quantifiers of things that can always match ''
09:47 lizmat so it has a rakudobug already ?
09:47 masak of course, we could probably special-case <ws>+ and <ws>* and get a better user experience sooner :)
09:47 masak lizmat: I'm pretty sure it has a rakudobug already.
09:48 lizmat ok
09:51 masak lizmat: https://rt.perl.org/Ticket/Display.html?id=75586
09:52 timotimo i wonder if we could get something going in that direction with bytecode specialization related analysis
09:52 lizmat wow that's an old chestnut  :-)
09:53 masak yep, comes up now and then ;)
09:54 masak I think we should start with <ws>+ and <ws>*, since people seem to go for those most often.
09:54 masak lunch &
09:55 woolfy1 jnthn : Remember the Hammerhead-whisky we had in Prague?  it seems to be very special!  http://www.whisky-pages.com/stories/hammerhead.htm
09:59 kurahaupo joined #perl6
10:01 snuffles joined #perl6
10:04 denis_boyun_ joined #perl6
10:08 dalek Perlito: b3219ea | (Flavio S. Glock)++ | / (4 files):
10:08 dalek Perlito: Perlito5 - js - implement "\( @a )"
10:08 dalek Perlito: review: https://github.com/fglock/Perlito/commit/b3219eae49
10:13 jnthn I don't consider <some_rule_that_matches_zero_width>+ being infinite a Rakudo bug.
10:13 jnthn It's just a user error.
10:14 jnthn For <ws> we may want to provide a syntactic warning.
10:14 jnthn 'cus I can imagine <ws>+ or <ws>* may be a common thinko.
10:14 lizmat it obviously is a trap, judging from the number of people who fell in it the past years
10:15 jnthn That particular case is, yeah. Which is why I can see it wants a compile time warning
10:15 jnthn I do not think we should go trying to do runtime detection of infinite loops though. :P
10:16 jnthn We already have enough problems with hard-to-eliminate sanity checks on hot paths.
10:16 pecastro joined #perl6
10:16 jnthn But a <ws> that is literally quantified I can see us warning on.
10:17 Juerd Instead of trying to detect an infinite loop, would it be feasible to disallow repetition on zerowidths altogether?
10:19 jnthn We can't statically know what's zero-width.
10:19 jnthn We can't statically know <ws> is
10:19 jnthn It's just a normal rule.
10:19 jnthn And you can override anything.
10:19 rurban1 joined #perl6
10:20 lizmat that would imply you cannot make <ws>+ a compile time error, just a warning, is what you're saying?
10:20 jnthn lizmat: I think the contract implied between rule and ws lets us single it out for special treatment.
10:22 jnthn It's not error vs warning, it's more "is this common enough to look for with a heuristic"
10:22 lizmat ok
10:26 zakharyas joined #perl6
10:27 rurban joined #perl6
10:28 donaldh joined #perl6
10:28 Timbus i accidentally triggered the same 'bug' today, parsing out a comma or space or both separated list:  "asdf" ~~ /[','|\s?]+/;
10:28 Timbus clearly not correct regex but still an annoying way to find out
10:31 lizmat especially when deeply embedded in code  :-(
10:31 Timbus i guess its too complicated for the regex engine to not search for a zero-width thing in the same position more than once?
10:32 lizmat maybe a JIT would see this and scream murder ?
10:42 sergot m: (1, Any).join(':').say;
10:42 camelia rakudo-moar 851811: OUTPUT«use of uninitialized value of type Any in string context␤1:␤»
10:42 sergot m: (1, '').join(':').say;
10:42 camelia rakudo-moar 851811: OUTPUT«1:␤»
10:43 nhayashi joined #perl6
10:43 sergot is it correct?
10:43 lizmat I would say yes
10:43 Timbus looks right
10:44 Timbus m: (1, ()).join(':').say;
10:44 camelia rakudo-moar 851811: OUTPUT«1␤»
10:44 lizmat an empty string is not an empty list
10:44 Timbus cool
10:45 sergot thanks :)
10:54 Manju_ joined #perl6
10:57 Manju_ left #perl6
10:59 lizmat jnthn: when making the RESTRICTED settings, is there a reason not to include --ll-exception ?
11:18 pecastro joined #perl6
11:27 dalek rakudo/nom: 0a70378 | (Elizabeth Mattijsen)++ | src/core/ (2 files):
11:27 dalek rakudo/nom: We need $*CWD when we need %*ENV
11:27 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/0a70378044
11:27 dalek rakudo/nom: 3438956 | (Elizabeth Mattijsen)++ | src/core/ (2 files):
11:27 dalek rakudo/nom: Get proper $*DISTRO info for Mac OS X
11:27 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/34389563cc
11:27 dalek rakudo/nom: 0d32312 | (Elizabeth Mattijsen)++ | tools/build/Makefile- (3 files):
11:27 dalek rakudo/nom: We need %*ENV and $*CWD to do qx//
11:27 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/0d323120e9
11:31 rurban joined #perl6
11:36 araujo joined #perl6
11:51 thou joined #perl6
11:52 lizmat seems some recent changes to nqp::tellfh broke IO::Handle.tell on parrot
11:52 lizmat $ perl6-p t/spec/integration/advent2010-day03.t
11:52 lizmat 1..12
11:52 lizmat ok 1 - dir
11:52 lizmat ok 2 - dir
11:52 lizmat Can only use repr_unbox_int on a SixModelObject
11:52 lizmat in method tell at gen/parrot/CORE.setting:13960
11:52 lizmat does that ring a bell with anybody ?
11:53 donaldh OH
11:53 donaldh Well I implemented tellfh in nqp for parrot
11:54 donaldh and added tests.
11:54 lizmat well, it breaks one of the (new?) advent tests
11:56 donaldh oh, okay. I'll take a look
11:57 lizmat is $fh.gist.substr(0,2), 'IO', 'IO handle gist'; # seems to be the breaker
11:58 donaldh Yes, advent2010-day03.t is new
12:00 donaldh $fh.gist uses tell.
12:00 moritz eeks.
12:01 lizmat moritz: why the eeks ?
12:01 lizmat seems like a legit thing for .gist on an IO::Handle ?
12:02 donaldh "IO::Handle<$!path>(opened, at line {$.ins} / octet {$.tell})"
12:04 dalek rakudo/nom: 973bae7 | (Elizabeth Mattijsen)++ | src/core/Kernel.pm:
12:04 dalek rakudo/nom: Add darwin specific version / release to $*KERNEL
12:04 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/973bae7b2d
12:04 dalek roast: 0f1f2cd | (Elizabeth Mattijsen)++ | S02-magicals/config.t:
12:04 dalek roast: darwin now as "macosx" as distro name
12:04 dalek roast: review: https://github.com/perl6/roast/commit/0f1f2cd2ca
12:10 zakharyas joined #perl6
12:10 pdcawley joined #perl6
12:11 dalek rakudo/nom: 1079ac1 | (Elizabeth Mattijsen)++ | docs/ChangeLog:
12:11 dalek rakudo/nom: Mention $*DISTRO/KERNEL changes
12:11 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/1079ac115b
12:15 * donaldh is afk (while rakudo builds)
12:15 lizmat donaldh++
12:20 moritz lizmat: it doesn't seem legit for .gist to fail, that's all
12:20 lizmat ah ok  :-)
12:20 moritz are all file handles tell-able?
12:20 lizmat sockets generally aren't, are they IO::Handle ?
12:21 moritz role IO::Socket does IO { ... }
12:21 moritz seems like "no"
12:21 moritz oh, but
12:21 moritz nm
12:22 dalek rakudo/nom: ac74318 | (Elizabeth Mattijsen)++ | tools/build/Makefile- (3 files):
12:22 dalek rakudo/nom: Add --ll-exception to setting making
12:22 dalek rakudo/nom:
12:22 dalek rakudo/nom: This is mostly useful for those cases where an error in the setting only shows
12:22 dalek rakudo/nom: when making the RESTRICTED setting.  The stack trace then is *really* useful.
12:22 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/ac7431845f
12:24 dalek Perlito: 2223dad | (Flavio S. Glock)++ | / (5 files):
12:24 dalek Perlito: Perlito5 - parser - implement 5.20 "prototype" attribute
12:24 dalek Perlito: review: https://github.com/fglock/Perlito/commit/2223dad55e
12:25 jnap joined #perl6
12:34 denis_boyun_ joined #perl6
12:35 dalek rakudo-star-daily: 16c17ee | coke++ | bin/star.sh:
12:35 dalek rakudo-star-daily: do less work when we don't need to
12:35 dalek rakudo-star-daily: review: https://github.com/coke/rakudo-star-daily/commit/16c17eee53
12:35 dalek rakudo-star-daily: d47ec36 | coke++ | bin/star.sh:
12:35 dalek rakudo-star-daily: test jvm also
12:35 dalek rakudo-star-daily: review: https://github.com/coke/rakudo-star-daily/commit/d47ec36893
12:35 rurban joined #perl6
12:35 dalek rakudo-star-daily: f925e5f | coke++ | log/ (7 files):
12:35 dalek rakudo-star-daily: today (automated commit)
12:35 dalek rakudo-star-daily: review: https://github.com/coke/rakudo-star-daily/commit/f925e5f47d
12:38 [Coke] ok. next run of ^^ should have log files for all three star backends.
12:38 lizmat [Coke]++
12:44 moritz [Coke]++
12:45 [Coke] is there a -flag to disable deprecation warnings?
12:45 donaldh lizmat: nqp::tellfh was missing a :returns(int)
12:45 [Coke] or a 'use' ?
12:47 moritz [Coke]: I'm not aware of one, but IMHO it would be a good idea
12:49 [Coke] on by default is fine for dev work, but need a way to shut those off for shipped code.
12:50 dalek nqp: 5cebf27 | (Donald Hunter)++ | src/vm/parrot/QAST/Operations.nqp:
12:50 dalek nqp: nqp::tellfh should return int. lizmat++
12:50 dalek nqp: review: https://github.com/perl6/nqp/commit/5cebf27823
13:03 skids joined #perl6
13:04 guru joined #perl6
13:06 lizmat [Coke]: not yet, but as a stop-gap: Deprecation.report returns the deprecation report *and* clears the deprecations
13:07 lizmat m: say $*OS
13:07 camelia rakudo-moar 851811: OUTPUT«linux␤Saw 1 call to deprecated code during execution.␤================================================================================␤$*OS called at:␤  /tmp/tj1ejE2jiA, line 1␤Please use $*DISTRO.name instead.␤---------------------------------…»
13:07 lizmat m: say $*OS; END Deprecation.report;
13:07 camelia rakudo-moar 851811: OUTPUT«linux␤»
13:08 [Coke] that's fine for now; gives the dev a way to say "yes, I know about these"
13:09 lizmat cycling&
13:10 dalek Perlito: 1060d42 | (Flavio S. Glock)++ | / (2 files):
13:10 dalek Perlito: Perlito5 - perl5 - implement 5.20 "hash slices"
13:10 dalek Perlito: review: https://github.com/fglock/Perlito/commit/1060d42c1e
13:18 zakharyas joined #perl6
13:35 oetiker joined #perl6
13:36 rurban joined #perl6
13:39 thou joined #perl6
13:41 [Sno] joined #perl6
13:44 dalek Perlito: 4de7011 | (Flavio S. Glock)++ | t5/01-perlito/530-hash-slice.t:
13:44 dalek Perlito: Perlito5 - tests - 5.20 "hash slices"
13:44 dalek Perlito: review: https://github.com/fglock/Perlito/commit/4de70111d6
13:45 btyler joined #perl6
13:46 slava-wr0k good time of day all :D
13:48 bluescreen10 joined #perl6
13:49 sergot m: my @a = 1,2,3,4,5; say @a.grep({ $_ > 3 });
13:49 camelia rakudo-moar 851811: OUTPUT«4 5␤»
13:50 sergot m: my @a = 1,2,3,4,5; @a.grep({ $_ > 3 })>>:delete; say @a;
13:50 camelia rakudo-moar 851811: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/gPPU97ZJh9â�¤Missing << or >>â�¤at /tmp/gPPU97ZJh9:1â�¤------> [32m 1,2,3,4,5; @a.grep({ $_ > 3 })>>:delete[33mâ��[31m; say @a;[0mâ�¤    expecting any of:â�¤        pair valueâ�¤Â»
13:50 sergot m: my @a = 1,2,3,4,5; @a.grep({ $_ > 3 })>>.:delete; say @a;
13:50 camelia rakudo-moar 851811: OUTPUT«Default constructor for 'Int' only takes named arguments␤  in method new at src/gen/m-CORE.setting:852␤  in method dispatch:<hyper> at src/gen/m-CORE.setting:1267␤  in block  at /tmp/XnwhKXPeCB:1␤␤»
13:50 sergot oh, right...
13:50 bluescreen100 joined #perl6
13:53 moritz sergot: what are you trying to do?
13:53 moritz @a.=grep: {! $_ > 3 }   ?
13:55 araujo joined #perl6
13:56 [Coke] gah, building modules on jvm is slooooow
13:57 sergot moritz: I wanted to delete every item greater than 3.
13:58 moritz @a.=grep: { $_ <= 3 }
13:58 moritz done
13:58 timotimo >>:delete doesn't work because :delete is just an adverb that's meaningful to &postcircumfix:<{ }> and &postcircumfix:<[ ]>
13:58 timotimo whereas >> wants a postfix operator (or a method call with a . in front)
14:00 sergot ok, thanks!
14:00 sergot moritz++
14:00 sergot timotimo++
14:01 liztormato joined #perl6
14:03 treehug88 joined #perl6
14:05 araujo joined #perl6
14:07 zakharyas joined #perl6
14:12 lue joined #perl6
14:15 dalek Perlito: b98fb26 | (Flavio S. Glock)++ | / (3 files):
14:15 dalek Perlito: Perlito5 - js - implement 5.20 "hash slices"
14:15 dalek Perlito: review: https://github.com/fglock/Perlito/commit/b98fb2608b
14:21 kaare_ joined #perl6
14:22 nebuchadnezzar hello, something I found interesting http://techblog.realestate.com.au/the-abject-failure-of-weak-typing/
14:23 araujo joined #perl6
14:25 Alina-malina joined #perl6
14:27 moritz I find it... weak
14:27 moritz it rants about exceptions in Java
14:27 moritz and says "don't use them, except..."
14:27 moritz but doesn't provide good alternatives
14:27 moritz the good alternatives (ADTs) that are listed later on don't work in java
14:28 Timbus i think the alternative he is uh 'lightly hinting towards', is scala
14:28 nebuchadnezzar I found this article as something like “use Scala or Haskell” ;-)
14:28 moritz it kinda looks like a Haskeller thrown into a Java universe and unable to cope with
14:28 moritz it
14:30 moritz yeah, using Scala or Haskell is fine if you build a new thing from scratch, and have a team that can work with it
14:31 * moritz stops ranting about the rant, and goes home
14:41 liztormato left #perl6
14:50 thou joined #perl6
14:51 Pleiades` joined #perl6
14:55 dalek rakudo-star-daily: 16fb5f2 | coke++ | log/ (15 files):
14:55 dalek rakudo-star-daily: today (automated commit)
14:55 dalek rakudo-star-daily: review: https://github.com/coke/rakudo-star-daily/commit/16fb5f2e7e
14:56 [Coke] ^^ there we go. as expected, moar & parrot are clean, jvm is not
14:58 liztormato joined #perl6
14:59 liztormato [Coke]: Will look at jvm failures when I get back
15:00 [Coke] liz++
15:05 guru joined #perl6
15:12 jnap joined #perl6
15:13 rurban joined #perl6
15:18 liztormato left #perl6
15:20 spider-mario joined #perl6
15:25 bbkr joined #perl6
15:29 bbkr hi. I've wrote simple tutorial for beginners about creating APIs: http://blogs.perl.org/users/pawel_bbkr_pabian/2014/05/perl-6-meets-json-rpc.html do you think it's worth including on http://planeteria.org/perl6/ ?
15:29 pmurias joined #perl6
15:30 bbkr (assuming masak's feline hotel is not copyrighted :P )
15:30 [Coke] can't include articles, only whole blogs.
15:31 bbkr that's ok
15:35 bbkr blog location is http://blogs.perl.org/users/pawel_bbkr_pabian/ . do you need RSS url ?
15:37 pmurias is there a moarvm jit gsoc blog somewhere?
15:38 PerlJam bbkr++
15:38 JimmyZ pmurias: yes
15:40 JimmyZ pmurias: http://brrt-to-the-future.blogspot.com/2014/05/moarvm-as-machine.html
15:43 [Coke] bbkr: will add it after lunch, remind me.
15:43 bbkr [Coke]: thanks
15:44 bbkr when is your lunch? I have no idea what time zone you are in :)
15:48 kaleem joined #perl6
16:11 dalek nqp: 6aa177f | (Donald Hunter)++ | src/vm/parrot/QAST/Operations.nqp:
16:11 dalek nqp: Modify nqp::cwd on parrot to be consistent with jvm, moar.
16:11 dalek nqp: review: https://github.com/perl6/nqp/commit/6aa177f6a4
16:11 dalek nqp: 6cc7d6e | (Donald Hunter)++ | src/vm/parrot/QAST/Operations.nqp:
16:11 dalek nqp: Add nqp::writefh on parrot backend.
16:11 dalek nqp: review: https://github.com/perl6/nqp/commit/6cc7d6ec41
16:13 masak hello, from a train! \o
16:13 nwc10 a moving train?
16:14 molaf__ joined #perl6
16:15 denis_boyun_ joined #perl6
16:18 panchiniak joined #perl6
16:21 sivoais joined #perl6
16:22 denis_boyun__ joined #perl6
16:22 vendethiel joined #perl6
16:23 masak nwc10: yes. my frame of reference (which currently attaches to the train) is moving backwards.
16:27 colomon bbkr: [Coke] is normally in the Eastern US time zone, to the best of my knowledge.
16:29 nwc10 masak: and this is pleasing? :-)
16:30 nwc10 (it is not yet clear if this train is likely to arrive in the right place at the right time, and experience suggests that it is wrong to assume the best)
16:30 masak nwc10: it's pleasing because the train is taking me home, and I don't have to do any more teaching today :)
16:30 denis_boyun joined #perl6
16:30 nwc10 and tomorrow is a public holiday?
16:31 moritz it is in .de
16:31 nwc10 it is in .at
16:32 masak also in .se
16:37 6JTAAULKA joined #perl6
16:40 moritz m: say 'de' ~| 'at'
16:40 camelia rakudo-moar 851811: OUTPUT«eu␤»
16:40 moritz \o/
16:40 hoverboard joined #perl6
16:41 nwc10 masak: implying that you (likely) don't have to do any teaching tomorrow either
16:42 masak correct.
16:42 moritz m: say <de se at>.combinations(2).perl
16:42 nwc10 yay.
16:42 camelia rakudo-moar 851811: OUTPUT«(["de", "se"], ["de", "at"], ["se", "at"]).list␤»
16:43 moritz m: for <de se at>.combinations(2) -> $c { say "$c: ", [~|] $c.list }
16:43 camelia rakudo-moar 851811: OUTPUT«de se: we␤de at: eu␤se at: su␤»
16:43 masak m: say .[0] ~| .[1] for <de se at>.combinations(2)
16:43 camelia rakudo-moar 851811: OUTPUT«we␤eu␤su␤»
16:44 masak moritz: :P
16:44 nwc10 r: say lines()
16:44 camelia rakudo-{parrot,moar} 851811: OUTPUT«There were three men came out of the West Their fortunes for to try And these three men made a solemn vow John Barleycorn must die  They've ploughed, they've sewn, they've harrowed him in Threw clouds upon his head And these three men made a solem…»
16:44 camelia ..rakudo-jvm 851811: OUTPUT«␤»
16:44 nwc10 could we have something less ASCII?
16:44 moritz nwc10: any suggestions?
16:45 nwc10 no, not hugely. I wondered if it might be a fun game to change it monthly, based on some metric for contribution
16:45 nwc10 some metric that roughly corresponds to useful, and is hard to game
16:45 * moritz just changes it now and then
16:49 dalek evalbot: 03ae78a | moritz++ | stdin:
16:49 dalek evalbot: not-only-ASCCI stdin
16:49 dalek evalbot:
16:49 dalek evalbot: nwc10++
16:49 dalek evalbot: blatantly stolen from http://www.gaelicmatters.com/irish-songs-lyrics.html#gleanntan
16:49 dalek evalbot: review: https://github.com/perl6/evalbot/commit/03ae78a215
16:49 moritz m: say lines[0]
16:49 camelia rakudo-moar 851811: OUTPUT«Céad slán ag sléibhte maorga Chontae Dhún na nGall␤»
16:49 nwc10 that will do nicely :-)
16:51 lizmat [Coke]: I assumed you meant spectest failures on jvm...    :-(
16:51 lizmat incorrectly
16:51 Rotwang joined #perl6
16:51 moritz m: say slurp().comb.grep(*.chr > 127)
16:51 camelia rakudo-moar 851811: OUTPUT«===SORRY!===␤Cannot convert string to number: base-10 number must begin with valid digits or '.' in '⏏C' (indicated by ⏏)␤»
16:51 moritz m: say slurp().comb.grep(*.ord > 127)
16:51 camelia rakudo-moar 851811: OUTPUT«é á é ú á é á ú ú ’ ú í í á ’ á í í ’ ú í ’ á ó ’ á í ú á í ó ’ á é á ú á ’ í é ó í í é á á é é é ú í í é á ó á á á á ó ú é á ’ á ’ á á ú á á í á ó á á á ’␤»
16:51 moritz m: say slurp().comb.grep(*.ord > 127).uniq.elems
16:51 camelia rakudo-moar 851811: OUTPUT«6␤»
16:52 moritz m: say slurp().comb.grep(*.ord > 127).elems
16:52 camelia rakudo-moar 851811: OUTPUT«78␤»
16:52 lizmat and now in NFG  :-)
16:55 guru joined #perl6
16:55 masak http://arewewebyet.com/ -- a page to be inspired by (for something similar for Perl 6 -- "are we production yet")
16:56 btyler masak: I think 'arewewebyet' is an easier one to keep tabs on, as the tools for building web apps fall into a few pretty clean categories
16:57 btyler compared to the fairly nebulous idea of 'prod'
16:57 masak btyler: sure.
16:58 masak the fact that 'prod' is more nebulous doesn't mean we shouldn't have a page like that, though.
16:58 panchiniak joined #perl6
16:59 dalek Perlito: 7985938 | (Flavio S. Glock)++ | / (5 files):
16:59 dalek Perlito: Perlito5 - js - implement '__SUB__'
16:59 dalek Perlito: review: https://github.com/fglock/Perlito/commit/79859389dc
17:05 dalek roast: b103fcb | (Elizabeth Mattijsen)++ | S17-supply/watch_path.t:
17:05 dalek roast: Only run watch_path tests as subtest on OS X
17:05 dalek roast:
17:05 dalek roast: Please add more or less reliable tests for your flavour of OS
17:05 dalek roast: review: https://github.com/perl6/roast/commit/b103fcb681
17:06 itz joined #perl6
17:11 treehug88 joined #perl6
17:16 [Coke] .tell bbkr blog added, will take a little while to show up in the feed.
17:16 yoleaux [Coke]: I'll pass your message to bbkr.
17:18 [Coke] lizmat: module failures on rakudo-star-jvm, sorry
17:18 [Coke] though java was dirty for ages.
17:18 [Coke] 2 failures on rakudo.jvm
17:18 [Coke] (spectest)
17:18 [Coke] 10 on rakudo.parrot
17:19 lizmat hmm.. ... I've only seen one and donaldh worked on that
17:19 [Coke] S17-supply/last.rakudo.jvm 7 - the last 15 works
17:19 [Coke] S17-supply/minmax.rakudo.jvm 6 - ascending alpha works
17:20 lizmat ok, will look at those
17:20 itz I'm getting test fails on "panda install Inline" on both star and trunk.  Is this a known issue?
17:20 dalek roast: a6f3a8b | (Elizabeth Mattijsen)++ | S (5 files):
17:20 dalek roast: Lowercase all OS names being checked against
17:20 dalek roast:
17:20 dalek roast: As $*DISTRO.name is always lowercase and space deprived
17:20 dalek roast: review: https://github.com/perl6/roast/commit/a6f3a8b2aa
17:20 zakharyas joined #perl6
17:22 * [Coke] sees this in roast and shudders:
17:23 [Coke] }
17:23 [Coke] else {
17:23 lizmat you'd rather see:
17:23 [Coke] lizmat: you may also be interested in
17:23 lizmat } else {
17:23 lizmat ?
17:24 [Coke] lizmat: yes, but code formatting isn't a hill I wish to die on.
17:24 [Coke] lizmat: also, here: https://github.com/coke/rakudo-star-daily/blob/master/log/jvm-test-modules.log
17:24 lizmat the deprecation messages ?
17:24 [Coke] (look for fail) - those might warrant roast tests if they're failing for some reason that isn't already rakudobug'd
17:27 lizmat [Coke]: can't reproduce the S17-supply failures on JVM, must be load dependent
17:28 raiph joined #perl6
17:29 lizmat am about to do some X-Men 3D, so don't want to start anything deep right now
17:31 jeffreykegler joined #perl6
17:35 dalek roast: 4ac7069 | (Elizabeth Mattijsen)++ | packages/Test/Tap.pm:
17:35 dalek roast: Increase default timeout to 10 seconds
17:35 dalek roast:
17:35 dalek roast: This will hopefully fix most spurious failures when under load
17:35 dalek roast: review: https://github.com/perl6/roast/commit/4ac706918d
17:36 lizmat [Coke]: ^^^  should help with eliminating spurious errors in spectesting S17-supply/*.t
17:36 [Coke] lizmat++
17:36 lizmat off to do see some 3D X-Men&
17:38 [Coke] WOOT
17:38 cogno joined #perl6
17:46 raiph https://news.ycombinator.com/item?id=7803529 # Starting point for a Rakudo IDE?
17:46 jeffreykegler left #perl6
17:46 [Coke] I figured we'd eventually use rakudo-jvm and take over eclipse
17:49 FROGGS joined #perl6
17:49 vendethiel let's use intellij instead :D
17:51 FROGGS o/
17:51 yoleaux 27 May 2014 22:44Z <lizmat> FROGGS: please use @*INC for ordering, note that it now lives in src/core/Inc.pm
17:51 [Coke] wow, I haven't heard intellij in aaages.
17:52 * vendethiel is using intellij in his internship and totally loving it
17:52 FROGGS lizmat: locally I have a version of eleven that uses @*INC and does not break panda
17:55 dalek rakudo/eleven: 2daea40 | (Tobias Leich)++ | lib/lib.pm6:
17:55 dalek rakudo/eleven: "use lib" places a CompUnitRepo in @*INC
17:55 dalek rakudo/eleven: review: https://github.com/rakudo/rakudo/commit/2daea40fbf
17:56 treehug8_ joined #perl6
18:00 dalek rakudo/eleven: ca7121f | (Tobias Leich)++ | src/core/CompUnitRepo/Local/ (2 files):
18:00 dalek rakudo/eleven: add .Str and .gist to CompUnitRepo::*
18:00 dalek rakudo/eleven: review: https://github.com/rakudo/rakudo/commit/ca7121f928
18:00 dalek rakudo/eleven: dfca3e9 | (Tobias Leich)++ | src/core/ (3 files):
18:00 dalek rakudo/eleven: use @*INC for the order of CompUnitRepos
18:00 dalek rakudo/eleven:
18:00 dalek rakudo/eleven: Before we use a priority to do that, but @*INC is needed anyway. This also
18:00 dalek rakudo/eleven: moves the setup code from core_epilog to Inc.pm.
18:00 dalek rakudo/eleven: review: https://github.com/rakudo/rakudo/commit/dfca3e959d
18:01 dalek rakudo/eleven: 070e6d5 | (Donald Hunter)++ | src/core/IO.pm:
18:01 dalek rakudo/eleven: Refactor readfh, seek, tell to use nqp ops on parrot. Remove backend specifics.
18:01 dalek rakudo/eleven: review: https://github.com/rakudo/rakudo/commit/070e6d5c74
18:01 dalek rakudo/eleven: 3094a76 | (Timo Paulssen)++ | src/Perl6/Optimizer.nqp:
18:01 dalek rakudo/eleven: don't trip over custom range operators
18:01 ribasushi joined #perl6
18:01 FROGGS jnthn: are you there?
18:01 dalek joined #perl6
18:02 xusia joined #perl6
18:04 cogno joined #perl6
18:07 vendethiel m: my @letters = <a b>; say (@letters, @letters>>uc).combinations(2)>>join('').perl
18:07 camelia rakudo-moar 851811: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/E6e7FL_RTR�Preceding context expects a term, but found infix > instead�at /tmp/E6e7FL_RTR:1�------> [32mtters = <a b>; say (@letters, @letters>>[33m�[31muc).combinations(2)>>join('').perl…»
18:08 vendethiel m: my @letters = <a b>; say (@letters, @letters>>.uc).combinations(2)>>.join('').perl
18:08 camelia rakudo-moar 851811: OUTPUT«("ab", "aAB", "bAB")␤»
18:10 vendethiel uh-oh
18:12 [Coke] r: "lazy anagrams".comb.pick(*).join.trim.say
18:12 camelia rakudo-moar 851811: OUTPUT«azn aasgayrlm␤»
18:12 camelia ..rakudo-parrot 851811: OUTPUT«rag ansalazmy␤»
18:12 camelia ..rakudo-jvm 851811: OUTPUT«ynsgaaamzarl␤»
18:14 Vlavv joined #perl6
18:15 vendethiel any idea how to do what I tried. Not sure why I get 3 letters stuff
18:16 xenoterracide joined #perl6
18:18 guru joined #perl6
18:18 retupmoca m: my @letters = <a b>; say (@letters, @letters>>.uc).flat.combinations(2)>>.join('').perl
18:18 camelia rakudo-moar 851811: OUTPUT«("ab", "aA", "aB", "bA", "bB", "AB")␤»
18:21 vendethiel I *really* don't like perl(6) flattening
18:21 vendethiel ... and it indeed seems it doesn't like me either.
18:33 hummeleB1 joined #perl6
18:33 donaldh some more IO housekeeping goodness https://github.com/rakudo/rakudo/pull/272
18:36 masak vendethiel: for what it's worth, I'm not entirely sold on flattening either. it's an "expensive" feature, in terms of unit of beginner surprise per unit of usefulness.
18:37 * moritz tends to agree
18:37 vendethiel m: say <a b>.perl; my @a = <a b>; say @a.perl;
18:37 camelia rakudo-moar 851811: OUTPUT«("a", "b")␤Array.new("a", "b")␤»
18:37 vendethiel and I'm like, what ? putting it into a flattening container itemized it ?
18:38 beastd joined #perl6
18:38 dalek rakudo/nom: f8a2b50 | (Donald Hunter)++ | src/core/IO.pm:
18:38 dalek rakudo/nom: Remove special case in cwd for parrot backend.
18:38 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/f8a2b50f38
18:38 dalek rakudo/nom: 65c175e | (Donald Hunter)++ | src/core/IO.pm:
18:38 dalek rakudo/nom: Remove special case in IO::Handle.write for parrot backend.
18:38 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/65c175ee34
18:38 dalek rakudo/nom: 0a5072c | (Donald Hunter)++ | tools/build/NQP_REVISION:
18:38 dalek rakudo/nom: Bump NQP revision to get latest IO nqp ops on parrot.
18:38 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/0a5072c3ed
18:38 dalek rakudo/nom: 42cd53f | (Tobias Leich)++ | / (2 files):
18:38 dalek rakudo/nom: Merge pull request #272 from donaldh/parrot_io
18:38 dalek rakudo/nom:
18:38 dalek rakudo/nom: Remove some more parrot specifics in IO.pm
18:38 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/42cd53f525
18:41 masak m: say ['a', 'b'].perl
18:41 camelia rakudo-moar 851811: OUTPUT«["a", "b"]␤»
18:41 bbkr joined #perl6
18:41 masak vendethiel: I think that's how the itemized version looks. Array.new() is the not-itemized version.
18:44 vendethiel I'm even more confused.
18:44 vendethiel m: say ['a', 'b'].WHAT; say ('a', 'b').WHAT
18:44 camelia rakudo-moar 851811: OUTPUT«(Array)␤(Parcel)␤»
18:44 vendethiel what's going on in there ?
18:45 masak [] creates an Array (item).
18:45 masak () creates a Parcel.
18:45 vendethiel [] creates an Array (item) but Array.new doesn't ?
18:45 masak or is it the commas that create the Parcel? I guess it is.
18:45 masak vendethiel: Array.new creates an Array, too, sure.
18:45 vendethiel most probably the commas, but that's not really relevant here
18:46 masak vendethiel: but Array.new is not in item context, as far as I know.
18:46 moritz vendethiel: http://doc.perl6.org/language/containers
18:46 vendethiel okay. Right. So, Array.new creates an array, not in item context.
18:47 vendethiel So why is it in item context in `(@a, @a>>.uc)` ?
18:48 vendethiel m: say <a b>.perl; my @a = <a b>; say @a.perl; say (@a, @a>>.uc).perl;
18:48 camelia rakudo-moar 851811: OUTPUT«("a", "b")␤Array.new("a", "b")␤(Array.new("a", "b"), ("A", "B"))␤»
18:48 vendethiel so, it's not actually in item context. Then I don't know why I need to call .flat on that
18:48 masak me neither.
18:48 moritz vendethiel: http://doc.perl6.org/language/containers
18:48 masak detrain &
18:48 vendethiel moritz: I still can't comprehend or explain it
18:49 moritz vendethiel: operations can chose whether to work on a flat or a structured list
18:49 vendethiel that seems awful :/
18:50 moritz vendethiel: if you want to make an operation always see the flat list, use .flat
18:50 vendethiel to me, it's like : "see these complicated rules about flattening and whatnot ? well, sometimes it's the operation that decides ! good luck, I hope you have tons of doc at your disposal - and good tools !"
18:51 vendethiel I don't mean that meanly, but that's a big WAT for me here
18:53 vendethiel "The % and @ sigils in Perl 6 generally indicate flattening. That means that flattening list context iterates over them as if there was no container boundary:"
18:54 donaldh FROGGS++ (for merging my pull request)
18:55 FROGGS donaldh++ # for doing the hard work :o)
18:55 FROGGS (and a nice one)
18:56 moritz vendethiel: do you see the line you quoted as contradicting anything you've observed?
18:56 vendethiel yes. I'd expect the @ variables to flatten, as said in these lines
18:58 moritz in none of the examples I've seen a ()/Parcel structure inside a @-sigiled variable
18:58 moritz note that this doesn't transitively apply to a any methods you call on an array variable
18:59 vendethiel it says "it flattens". I just expected it to .. flatten. like `[@foo]` flattens
18:59 donaldh FROGGS: only 63 more #?if parrot conditionals to go
18:59 FROGGS yeah
18:59 moritz m: my @a = <a b>; my @b = (@a, @a>>.uc); say @b.perl;
18:59 vendethiel m: my @a = <a b>; say @(@a, @a>>.uc).combinations(2)>>.join('').perl
18:59 camelia rakudo-moar 851811: OUTPUT«Array.new("a", "b", "A", "B")␤»
18:59 camelia rakudo-moar 851811: OUTPUT«("ab", "aAB", "bAB")␤»
19:00 vendethiel still doesn't flatten with that @
19:00 vendethiel even more surprising now ...
19:02 moritz m: my @a = <a b>; say @(@a, @a>>.uc).perl
19:02 camelia rakudo-moar 851811: OUTPUT«("a", "b", ("A", "B")).list␤»
19:02 moritz vendethiel: @( ... ) is equivalent to .list, which means it removes an outer scalar container
19:02 moritz vendethiel: it doesn't go inside the list and tries to flatten it
19:03 vendethiel at that point, I'll just stop talking about it before I get mad :)
19:03 vendethiel I'll just put it in the "what I think are perl 6 misfeatures" and learn to deal with it
19:04 vendethiel and remember to call .flat() explicitly when I want flattening, really
19:04 moritz I'm not saying it's good, just that there's a logic behind it
19:04 moritz which I've tried to explain in http://doc.perl6.org/language/containers#Non-flattening_contexts and evidently failed
19:04 vendethiel if it takes more than 2 pages to explain something that should be that simple, really :/
19:05 vendethiel "why"
19:08 bbkr [Coke]: thanks for adding my blog
19:08 yoleaux 17:16Z <[Coke]> bbkr: blog added, will take a little while to show up in the feed.
19:08 rurban joined #perl6
19:09 [Coke] donaldh++ donaldh++
19:11 dwarring joined #perl6
19:11 [Coke] moritz: those docs are helpful, but I am probably always going to have to refer to those docs to figure out what is going on.
19:18 FROGGS lizmat: btw, eleven is not spectest clean atm, it looks like some tests push string to @*INC and we do not handle that case yet
19:22 hoverboard joined #perl6
19:26 Sqirrel joined #perl6
19:28 vendethiel no uniq on p6doc?
19:43 moritz lots of stuffing missing on p6doc, actually :(
19:44 vendethiel I had hoped I could pass it a predicate
19:53 [Coke] a what now?
19:54 [Coke] a comparator?
19:55 vendethiel yea
19:56 moritz a comparator would make it O(n^2)
19:56 moritz with a transformer it could be linear
19:57 moritz @words.uniq(:map(*.lc)) # might be useful and fast
19:58 dalek roast: 272eaa2 | (David Warring david.warring@gmail.com)++ | integration/advent2010-day23.t:
19:58 dalek roast: adding advent 2010 day 23
19:58 dalek roast: review: https://github.com/perl6/roast/commit/272eaa2a16
20:04 vendethiel moritz: yeah, yeah :)
20:04 [Coke] seems like that's covered by doing the transformation before the uniq.
20:04 [Coke] @words.map(*.lc).uniq
20:05 vendethiel [Coke]: but then I don't have my words with their uppercases anymore ;)
20:05 [Coke] sure you do, they're in words.
20:06 [Coke] unless you're keeping track of the order they were in, you're not going to know which was which post-transformation anyway.
20:06 Sqirrel joined #perl6
20:06 vendethiel what ?
20:06 vendethiel I'm not sure I understand
20:07 [Coke] let's say you have @words = <this THAT THIS that>; you do a unique my way, you get <this that>. What do you get moritz's way?
20:07 [Coke] or, I suppose: what do YOU mean, you lose the uppercases?
20:07 vendethiel m: my @words = <HeLLo yOu How aRe yoU doiNG>; say @words.map(*.lc).uniq
20:07 camelia rakudo-moar 851811: OUTPUT«hello you how are doing␤»
20:07 vendethiel here's my issue.
20:07 [Coke] m: my @words = <HeLLo yOu How aRe yoU doiNG>; say @words.map(*.lc).uniq ; say @words
20:07 camelia rakudo-moar 851811: OUTPUT«hello you how are doing␤HeLLo yOu How aRe yoU doiNG␤»
20:07 [Coke] again, what's the issue?
20:08 vendethiel what's NOT the issue ?
20:09 [Coke] I see that the transformation is lowercase, yes. if you want the uppercased version, you have the original list still...
20:09 tadzik vendethiel: what do you expect to happen?
20:09 vendethiel but the original list doesn't have its duplicates filtered.
20:09 timotimo .o( when do we get tail call optimization? )
20:09 vendethiel .o( as soon as you implement it ! )
20:09 [Coke] if you filter the duplicates, how can you decide WHICH VERSIOn to keep?
20:09 moritz the first.
20:10 [Coke] so, you have @words = <this THAT THIS that> - what does your filtered version look like?
20:10 moritz <this THAT>
20:10 [Coke] is that significant, or you are you just picking the most likely tie breaker?
20:11 vendethiel whichever, really.
20:11 [Coke] see, if you don't care, why do you care? ;)
20:11 vendethiel I don't understand.
20:11 vendethiel or are you just making fun of me ?
20:11 [Coke] (i get it, you could have ThiS thaT...)
20:11 tadzik can't you .uniq(:by(*.lc)) or something?
20:11 [Coke] No, I'm definitely not making fun of you.
20:12 tadzik and still, I'd be surprised if this was an actual problem you encountered
20:12 tadzik the xample seems... a bit contrived
20:12 vendethiel school stuff
20:12 vendethiel well, not mine, but I'm trying to do the perl 6 version
20:13 * moritz has written  my %seen; my @uniq = @list.grep: { !%seen{.lc}++ };  or the equivalent thereof often enough
20:14 tadzik m: my @a = <a A B b>; @a.uniq(:by(*.lc)).perl.say
20:14 camelia rakudo-moar 851811: OUTPUT«("a", "A", "B", "b").list␤»
20:14 [Coke] m: my @a = <a A B b>; @a.uniq(:barf-orama(*.lc));
20:14 tadzik oh, I expected a builtin moritz transform :)
20:14 camelia rakudo-moar 851811: ( no output )
20:15 [Coke] m: my @a = <a A B b>; @a.uniq(:bye(*.lc)); # worse. auto-named args--
20:15 camelia rakudo-moar 851811: ( no output )
20:15 PerlJam m: my @a = <a A B b>; @a.uniq(:as(*.lc));
20:15 camelia rakudo-moar 851811: ( no output )
20:15 * PerlJam camelia m: my @a = <a A B b>; say @a.uniq(:as(*.lc));
20:15 * camelia rakudo-moar 851811: OUTPUT«a B␤»
20:15 PerlJam oops
20:16 PerlJam heh
20:16 tadzik heh, that worked :D
20:16 PerlJam m: my @a = <a A B b>; say @a.uniq(:as(*.lc));
20:16 camelia rakudo-moar 851811: OUTPUT«a B␤»
20:16 tadzik PerlJam++
20:16 denis_boyun_ joined #perl6
20:17 moritz woah.
20:17 tadzik I expected that'd be named :by though, as with .sort(:by)
20:17 rindolf joined #perl6
20:17 moritz :by is typically a comparison
20:17 * PerlJam read the documentation
20:18 moritz lizmat++ # brining us .uniq(:as) and :with
20:19 * moritz wonders if a grap would work faster than a gather/take in .uniq
20:21 timotimo a grap?
20:23 vendethiel what I needed to write was actually a program to combinate indents from a word instead of the other way around
20:23 vendethiel that'd use comb tho I guess
20:25 moritz timotimo: sorry, grep
20:25 timotimo combinate? :)
20:26 timotimo moritz: i thought i had missed the newest hottest functional programming idiom or something :)
20:31 denis_boyun___ joined #perl6
20:32 Sqirrel joined #perl6
20:32 pippo joined #perl6
20:34 tadzik wow, that blogs.perl.org post
20:34 tadzik bbkr++
20:35 vendethiel could use <available> :D
20:35 vendethiel bbkr++
20:36 denis_boyun_ joined #perl6
20:37 hoverboard joined #perl6
20:38 virtualsue joined #perl6
20:40 colomon !!!!
20:41 timotimo nice post :)
20:42 * colomon had no idea we had that functionality available.
20:44 timotimo that's why such a blog post is especially good to have, bbkr++
20:44 denis_boyun__ joined #perl6
20:44 cognominal joined #perl6
20:48 ssutch joined #perl6
20:49 vendethiel m: class UrlBuilder { my Str $.path = ""; method Str { $!path; }; method infix:</>($self: Str $path) { $!path ~= "/$path"; }; method infix:<.>( $!path ~= ".$path"; }; }; my $url = new UrlBuilder(url => "foo/bar"); say ($url / "foo" / "bar" . "json");
20:49 camelia rakudo-moar 851811: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/9wc334eH_wâ�¤Missing blockâ�¤at /tmp/9wc334eH_w:1â�¤------> [32m= "/$path"; }; method infix:<.>( $!path [33mâ��[31m~= ".$path"; }; }; my $url = new UrlBuil[0mâ�¤    expecting any of:â�¤        c…»
20:49 colomon timotimo: very good point.  bbkr++
20:50 vendethiel m: class UrlBuilder { my Str $.path = ""; method Str { $!path; }; method infix:</>($self: Str $path) { $!path = $!path ~ "/$path"; }; method infix:<.>(Str $path) { $!path = $!path ~ ".$path"; }; }; my $url = new UrlBuilder(url => "foo/bar"); say ($url / "foo" / "bar" . "json");
20:50 camelia rakudo-moar 851811: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/qK0uXM_U44�Attribute $!path not declared in class UrlBuilder�at /tmp/qK0uXM_U44:1�------> [32mpath) { $!path = $!path ~ ".$path"; }; }[33m�[31m; my $url = new UrlBuilder(url => "foo/b[0m…»
20:50 vendethiel uh?
20:52 vendethiel m: class UrlBuilder { my Str $.path = ""; method Str { $.path; }; method infix:</>($self: Str $path) { $.path = $.path ~ "/$path"; }; method infix:<.>($self: Str $path) { $.path = $.path ~ ".$path"; }; }; my $url = UrlBuilder.new(url => "foo/bar"); say ($url / "foo" / "bar" . "json");
20:52 camelia rakudo-moar 851811: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/8c6QL8CZD8�Unsupported use of . to concatenate strings; in Perl 6 please use ~�at /tmp/8c6QL8CZD8:1�------> [32m"foo/bar"); say ($url / "foo" / "bar" . [33m�[31m"json");[0m�»
20:52 vendethiel :[
20:57 donaldh an async IO version of JSON::RPC would be super awesome. bbkr++
20:57 * lizmat is back from the days of future past
20:59 lizmat FROGGS: will test eleven and fix any test issues (unless you beat me to it)
21:05 [Coke] lizmat: I should go see it, yes? ;)
21:05 colomon DOFP?  It was good.
21:05 lizmat yes, I would put it in the top 3 of X-men movies :-)
21:05 lizmat seriously, for once the story made mostly sense
21:06 [Coke] when was the last time someone said that about such a messed up time travel plot? ;)
21:06 [Coke] i wonder if I shoudl dig up the comic and read it before I go.
21:06 [Coke] ... or if said comic is now worth more.
21:07 colomon I'd maybe even consider it for top two.
21:07 colomon [Coke]: I'm pretty sure what you remember of the comic is more than is needed.  :)
21:07 colomon It's the same logical setup, pretty much everything else is different.
21:07 [Coke] URK.
21:08 [Coke] mint condition x-men#141 - 720USD
21:08 colomon That's $720?
21:08 [Coke] ditto #142.
21:08 [Coke] I have both of those. (not mint, but in pretty good shape)
21:08 * colomon desperately tries to remember if he has copies of those issues.  (Certainly not mint if he does.)
21:09 * colomon didn't start reading X-men on a regular basis until #153, but has bits and pieces of Byrne's run in the original
21:11 lizmat moritz: wrt to uniq using gather / take: that was actually put in by TimToady: the original implementation used map {} afair
21:12 [Coke] wow, amazing price drop off. "GEM MINT" 720$; "VERY FINE;NEAR MINT" $84
21:12 [Coke] "raw value", whatever that means. (comicspriceguide.com)
21:15 timotimo there's things we know we have, things we don't know we have, things we know we don't have and probably also things we don't know we don't have.
21:18 hoverboard joined #perl6
21:19 lizmat timotimo: and then there's Mu
21:22 timotimo always.
21:23 lizmat .oO( Perl 5 now has COW, Perl 6 has Mu )
21:24 lizmat ( unless you specify -DPERL_NO_COW when compiling Perl 5)
21:25 denis_boyun joined #perl6
21:29 lizmat donaldh: confirmed no pbs with parrot spectest anymore, so donaldh++
21:30 [Coke] pbs?
21:30 lizmat problems ?
21:30 denis_boyun__ joined #perl6
21:30 [Coke] ah
21:30 [Coke] PBS == "public broadcasting system" to me.
21:30 lizmat I guess it is shorthand from another era  :-)
21:31 lizmat from a time I used to ttalk
21:32 lizmat but for now, sleep&
21:35 denis_boyun joined #perl6
21:39 REPLeffect joined #perl6
21:43 ivanshmakov joined #perl6
21:43 SevenWolf joined #perl6
21:50 ivanshmakov joined #perl6
21:56 denis_boyun_ joined #perl6
22:00 denis_boyun__ joined #perl6
22:01 cotto joined #perl6
22:09 donaldh sigh, looks like there is work needed on nqp::openpipe for all backends. And the function signature is wrong, which is probably my fault.
22:12 donaldh .tell jnthn Any thoughts about how to implement cancel on an async server socket's supply? Could we return a new Supply but cancellable or something?
22:12 yoleaux donaldh: I'll pass your message to jnthn.
22:32 telex joined #perl6
22:35 skids joined #perl6
22:40 bjz_ joined #perl6
22:46 jnap joined #perl6
22:46 jnthn evening, for a short moment.
22:46 yoleaux 22:12Z <donaldh> jnthn: Any thoughts about how to implement cancel on an async server socket's supply? Could we return a new Supply but cancellable or something?
22:47 jnthn .tell donaldh to see how it works for Supply.interval; you just .close the tap.
22:47 yoleaux jnthn: I'll pass your message to donaldh.
22:47 pippo left #perl6
23:42 kurahaupo joined #perl6
23:54 Ulti am I crazy to want something like this to exist?  multi sub bag (Any $a where ?$a.^methods.grep('Bag') --> Bag) { $a.Bag }
23:55 panchiniak left #perl6
23:55 lue r: my @a = 1,2,3,2; say @a; say @a.WHAT;    say bag @a; say (bag @a).WHAT;  # Ulti
23:55 camelia rakudo-{parrot,moar} 851811: OUTPUT«1 2 3 2␤(Array)␤bag(1, 2(2), 3)␤(Bag)␤»
23:55 camelia ..rakudo-jvm 851811: OUTPUT«1 2 3 2␤(Array)␤bag(2(2), 1, 3)␤(Bag)␤»
23:56 Ulti lue ?
23:56 lue There's already a "bag" that gives you a Bag
23:57 Ulti r: class MyStuff {}; my $s = MyStuff.new(); say bag $s;
23:57 camelia rakudo-{parrot,jvm,moar} 851811: OUTPUT«bag(MyStuff.new())␤»
23:57 Ulti MyStuff knows how to be a bag...
23:58 Ulti why would I want a bag with one thing in that knows how to make a bag out of itself
23:58 Ulti ~$s calls .Str as far as I can tell?
23:59 lue then call $s.Bag :)
23:59 Ulti yeah but then why not just do Bag.new() ??? why have bag as a sub
23:59 lue But... didn't you wish for a sub bag ?
23:59 Ulti it begs to be the coercing type either through making a new bag or perhaps first checking if the object knows how to make a bag
23:59 Ulti no I pasted what I wished for

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

Perl 6 | Reference Documentation | Rakudo