Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2017-11-03

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:12 azawawi good night &
00:21 cdg joined #perl6
00:28 Cabanossi joined #perl6
00:30 BenGoldberg joined #perl6
00:31 lizmat joined #perl6
00:39 COMBORICO joined #perl6
00:46 raschipi squashable6: next
00:46 squashable6 raschipi, ⚠🍕 Next SQUASHathon in ≈9 hours (2017-11-04 UTC-12⌁UTC+14). See https://github.com/rakudo/rakudo/wiki/Monthly-Bug-Squash-Day
00:59 evalable6 joined #perl6
01:06 aborazmeh joined #perl6
01:06 aborazmeh joined #perl6
01:22 cdg joined #perl6
01:38 cdg joined #perl6
01:53 COMBORICO Anyone on the shortwave tonight?
01:55 * geekosaur hasn't been on shortwave in years >.>
01:55 geekosaur (too much radio noise hereabouts)
01:55 khw joined #perl6
01:56 COMBORICO Still have the equipment?
01:56 geekosaur in storage somewhere
01:57 geekosaur little handheld doesn't go below 30 MHz, can't even listen... not that I have a suitable antenna
01:58 Cabanossi joined #perl6
01:58 COMBORICO Were you able to get the same distant stations regularly?
02:02 kalkin-- joined #perl6
02:11 darkmorph joined #perl6
02:23 COMBORICO m: my @array = 1..3; say <1 2 3> eqv @array;
02:23 camelia rakudo-moar 264eef798: OUTPUT: «False␤»
02:25 Herby_ joined #perl6
02:25 Herby_ \o/
02:27 COMBORICO Goodnight y'all.
02:28 bitrauser_ joined #perl6
02:36 Actualeyes joined #perl6
02:47 colomon joined #perl6
02:56 ilbot3 joined #perl6
02:56 Topic for #perl6 is now »ö« Welcome to Perl 6! | https://perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:,  or /msg camelia p6: ... | irclog: http://irc.perl6.org or http://colabti.org/irclogger/irclogger_logs/perl6 | UTF-8 is our friend!
02:58 Cabanossi joined #perl6
03:01 cdg joined #perl6
03:09 Herby_ Working my way through Think Perl 6 and stuck on this exercise: Write a subroutine named
03:09 Herby_ avoids
03:09 Herby_ that takes a word and a string of forbidden letters,
03:09 Herby_ and that returns
03:09 Herby_ True
03:09 Herby_ if the word doesn’t use any of the forbidden letters.
03:09 Herby_ whoops, sorry for the weird paste
03:13 piojo Herby_: do you know that regexes interpolate not only strings, but arrays as well?
03:13 Herby_ I figured it would require that but I can't figure out how to interpolate variables in a regex
03:13 Herby_ I was thinking something of:  print True if $word ~~ / <[$letters]> /
03:13 Herby_ but that's not quite working for me
03:14 piojo try putting the letters in an array
03:15 Herby_ m: my $letters = "test"; my @a = $letters.comb; say @a;
03:15 camelia rakudo-moar 264eef798: OUTPUT: «[t e s t]␤»
03:17 piojo and you can interpolate an array directly into a regex. It's interpreted as "or"
03:18 Herby_ m: my $word = "test"; my @a = "zy".comb; say "Letters found" if $word ~~ @a;
03:18 camelia rakudo-moar 264eef798: ( no output )
03:18 Herby_ m: my $word = "test"; my @a = "es".comb; say "Letters found" if $word ~~ @a;
03:18 camelia rakudo-moar 264eef798: ( no output )
03:18 Herby_ ?
03:19 Herby_ m: my $word = "test"; my @a = "es".comb; say "Letters found" if $word ~~ /@a/;
03:19 camelia rakudo-moar 264eef798: OUTPUT: «Letters found␤»
03:19 Herby_ m: my $word = "test"; my @a = "zy".comb; say "Letters found" if $word ~~ /@a/;
03:19 camelia rakudo-moar 264eef798: ( no output )
03:19 Herby_ gotcha :)
03:19 Herby_ thanks!
03:21 piojo welcome. Let me know if I ever give the wrong level of hints :)
03:27 evalable6 joined #perl6
03:27 noganex_ joined #perl6
03:27 napo1eon joined #perl6
03:43 Geth ¦ doc: 39539835bf | (Alex Chen)++ (committed using GitHub Web editor) | doc/Type/Grammar.pod6
03:43 Geth ¦ doc: Rewrite Type/Grammar.pod6
03:43 Geth ¦ doc:
03:43 Geth ¦ doc: Review needed
03:43 synopsebot Link: https://doc.perl6.org/type/Grammar
03:43 Geth ¦ doc:
03:43 Geth ¦ doc: And plz help improving examples of `*%opt` arguments.
03:43 Geth ¦ doc:
03:43 Geth ¦ doc: I have try :
03:43 Geth ¦ doc: <…commit message has 12 more lines…>
03:43 Geth ¦ doc: review: https://github.com/perl6/doc/commit/39539835bf
03:43 Geth ¦ doc: 474fcc802e | (Alex Chen)++ (committed using GitHub Web editor) | doc/Type/Grammar.pod6
03:43 Geth ¦ doc: Merge pull request #1645 from perl6/W4anD0eR96-patch-1
03:43 Geth ¦ doc:
03:43 Geth ¦ doc: Rewrite Type/Grammar.pod6
03:43 Geth ¦ doc: review: https://github.com/perl6/doc/commit/474fcc802e
03:52 raschipi_ joined #perl6
03:55 cdg joined #perl6
03:58 Cabanossi joined #perl6
04:11 mempko joined #perl6
04:15 Geth ¦ DBIish: lefth++ created pull request #108: Fix infinite loops when passing certain arrays to pg-array-str
04:15 Geth ¦ DBIish: review: https://github.com/perl6/DBIish/pull/108
04:19 piojo Speaking of which, is there a standard way using timeouts in a test?
04:22 piojo The test API might be: finishes-within 10, &func, 'func timed out and may be an infinite loop.';
04:25 awwaiid joined #perl6
04:30 piojo Oh, and on an unrelated note, there's a small issue in the recent doc/Type/Grammar change--is Alex Chen around?
04:31 geekosaur the problem with time-based tests is they don't work at all well with free CI which might not bother to give you something resembling the entire time
04:34 piojo geekosaur: in this case, it's a very fast function which entered an infinite loop for some inputs. 0.25 seconds should be plenty of time for the test. (But running on a shared server, that's not perfectly predictable.)
04:34 piojo So our solution right now is to just not write that sort of test?
04:35 piojo or to write a test for the value and the test runner will automatically decide if it's taking unreasonably long?
04:42 Cabanossi joined #perl6
05:18 cdg joined #perl6
05:28 mempko joined #perl6
05:40 wander joined #perl6
05:45 wander Recently, when I talk with friend about parse a C program using Perl 6 Grammar
05:46 wander I said, Grammar doesn't perform a typical lexical analysis, but match the whole program by regexes
05:46 wander Does it make sense?
05:46 wander .ask moritz ^^
05:46 yoleaux wander: I'll pass your message to moritz.
05:48 geekosaur it's a perfectly good parser; the regexes it understands are extended and extensible to form a grammar
05:48 wamba joined #perl6
05:48 geekosaur you could parse C with it, if you wanted to write the parser. you could even deal with the typedef issue
05:49 geekosaur ...maybe even better than most parsers, since the typedef keyword could define new type tokens on the fly sym:type<...>
05:50 geekosaur sorry, think that would be ctype:<...> or similar
05:54 raschipi "but match the whole program", this doesn't make sense, the grammars are used to parse Perl6 and it doesn't happen...
05:55 piojo Well perl6 regexes aren't actually regular expressions. Grammars aren't even close.
05:55 geekosaur ^
05:55 piojo so the words we use to describe regular expressions don't strictly apply.
05:55 piojo perl6 grammars don't "match"
05:56 geekosaur what perl 6 calls a regex is much, much more powerful than what is normally called a regex. and grammars unleash their full power
05:57 piojo wander: in your recent grammar documentation change, you should probably change the commas back to '(', ')' because the meaning is different
06:00 piojo wander: -Every type declared with C<grammar> (which doesn't explicitly states its-superclass)
06:00 piojo +Every type declared with C<grammar>, which doesn't explicitly states its+superclass,
06:01 piojo ^ I'm not sure that change is right
06:01 piojo you changed it to say that "grammar does not state its superclass"
06:09 wander piojo: can it be "Every type declared with C<grammar> and not explicitly stateing its superclass, becomes a subclass of I<Grammar>."
06:09 wander I myself have been confuse with the '()' version, but still I change it in a wrong way
06:09 piojo wander: that seems the most clear and correct way
06:10 piojo wander: That's understandable. Do you agree with me about the intended meaning?
06:11 wander sure
06:11 piojo I never used a grammar with a base class before. I didn't realize you could, but I just checked it and it's valid
06:11 piojo so your new revision is the best way of saying it :)
06:11 piojo I mean, what you wrote two minutes ago
06:12 piojo wander: typo, s/stateing/stating/
06:12 wander I see
06:14 Geth ¦ doc: b7616acbaa | (Alex Chen)++ (committed using GitHub Web editor) | doc/Type/Grammar.pod6
06:14 Geth ¦ doc: Fix wrong expression, piojo++
06:14 Geth ¦ doc: review: https://github.com/perl6/doc/commit/b7616acbaa
06:14 synopsebot Link: https://doc.perl6.org/type/Grammar
06:15 piojo thanks!
06:18 wander As for parsing C program by Grammar, in fact I've implemented a dirty parser of a subset of C. I found it, unlike Lex/Yacc, has a typical lexical analysis stage.
06:19 evalable6 joined #perl6
06:19 wander It seems like I am parsing the program(code) by "matching" using rules/tokens/regexes, associated actions
06:29 piojo I think the associate actions is what makes it not just matching
06:29 piojo *associated
06:30 piojo And even gathering the input into match groups is more than a pure "match / fail to match" test would do.
06:38 nadim_ joined #perl6
06:42 darutoko joined #perl6
06:44 wander The mainly difference is, let's think about a number 42, in Lex/Yacc way, 42 becomes token NUMBER and then be passed to Yacc; in Grammar way, some rules/tokens say, "Hey, I want a <number>!", so it turns to token number, which trys to get a <number> from the text with a CURSOR.
06:45 wander so in Lex/Yacc , lexical analysis pushes syntax analysis, while in Grammar it is on the contrary
06:53 piojo Parsing theory is really cool, but I somehow manage to forget everything almost as soon as I learn it
06:53 piojo because I don't normally write more than one type of parser
06:54 piojo so all the distinctions between different types don't stick in the "useful knowledge" part of my brain
06:55 piojo I've never used Lex or Yacc. Just grammars and hand-coded functions that are specific to one syntax, like CSV
06:57 Cabanossi joined #perl6
06:59 Todd joined #perl6
07:00 Todd Hi All,  How do I make this test case insensititive?
07:00 Todd perl6 -e 'my $x="abcDEF"; if ( $x ~~ /abcdef/ ) { say "yes";} else { say "no";}' no
07:01 geekosaur m:i/.../ or /:i .../
07:01 evalable6 geekosaur, rakudo-moar 264eef798: OUTPUT: «(exit code 1) ===SORRY!=== Error while compiling /tmp/nhsg7vyVsN␤Undeclared routine:␤    or used at line 1␤»
07:01 * geekosaur fwaps evalable6
07:02 Todd Perfect.  Thank you!
07:02 Todd # perl6 -e 'my $x="abcDEF"; if ( $x ~~ m:i/abcdef/ ) { say "yes";} else { say "no";}' yes
07:03 Todd I thought "m" meant match?  do I need to use "m" only because I did not care about case?
07:03 geekosaur m is used to make it easier to add adverbs, or if you need to use a delimiter other than /
07:04 geekosaur you can ut the adverbs inside the match as the first thing instead
07:04 geekosaur *can put
07:04 geekosaur rx// is how you quote a regex as a value instead of immediately matching like m// or plain //
07:04 geekosaur er, I think I mean qr//
07:05 Todd I understand now
07:10 wander Todd, m// matches $_ by default
07:10 wander m: $_ = "42"; say m/42/
07:10 camelia rakudo-moar 264eef798: OUTPUT: «「42」␤»
07:11 geekosaur so does //
07:11 geekosaur the only difference is m// is more explicit, and lets you switch delimiters and put the adverbs on the m
07:12 geekosaur perl 5 also uses m// but only has the switch-delimiters thing, since the 'adverbs' are appended
07:12 Todd Thank you!
07:16 wander m: $_ = "42"; say /42/
07:16 camelia rakudo-moar 264eef798: OUTPUT: «/42/␤»
07:16 wander geekosaur: ^^
07:16 wander does it?
07:17 geekosaur huh?
07:17 wander you say // matches $_ by default
07:18 wander m: $_ = "42"; say "l" if /42/
07:18 camelia rakudo-moar 264eef798: OUTPUT: «l␤»
07:19 wander :P
07:19 geekosaur hm, I did mean rx// earlier apparently.
07:19 * geekosaur would be asleep, but thunderstorm
07:20 evalable6 joined #perl6
07:32 Todd If it was any of you guys that told me about "spurt" and "slurp", I have been using both like crazy.  Thank you!
07:42 domidumont joined #perl6
07:43 Piotr_ joined #perl6
07:47 domidumont joined #perl6
07:51 abraxxa joined #perl6
07:57 Cabanossi joined #perl6
07:59 domidumont joined #perl6
07:59 wander .ask moritz if your new book is reachable in SafariBooksOnline
07:59 yoleaux wander: I'll pass your message to moritz.
08:01 cpage_ joined #perl6
08:07 moritz wander: I have no idea
08:07 yoleaux 05:46Z <wander> moritz: ^^
08:07 yoleaux 07:59Z <wander> moritz: if your new book is reachable in SafariBooksOnline
08:07 moritz wander: if the old one is, the new will likely be available as well
08:09 wander_ joined #perl6
08:10 pecastro joined #perl6
08:24 rindolf joined #perl6
08:25 wander joined #perl6
08:27 Cabanossi joined #perl6
08:44 pecastro joined #perl6
08:49 pmurias joined #perl6
08:54 zakharyas joined #perl6
08:57 Cabanossi joined #perl6
09:05 patrickz joined #perl6
09:12 cdg joined #perl6
09:19 ivans joined #perl6
09:27 Cabanossi joined #perl6
09:32 lowbro joined #perl6
09:32 lowbro joined #perl6
09:36 piojo Are there simple guidelines for how to organize functions/modules so circular dependencies aren't a problem?
09:36 piojo I just realized Perl 6 is the only language I've used in a long time that doesn't allow two classes to call each other's functions
09:38 piojo (I know about forward declarations, but the modules can't include each other so dispatch will always fail)
09:39 araujo joined #perl6
09:42 moritz you can, if you load the other module at run time
09:42 moritz though it tends to be best to avoid it
09:43 piojo moritz: thanks. I'd like to avoid it, but this project is in early stages so things are changing
09:43 moritz premature modularization is the root of some evil :-)
09:44 pmurias piojo: if you keep the classes in a single file won't the forward declarations fix stuff?
09:44 piojo hmm... I feel like I've gotta keep things a little small, since perl 6 isn't statically parsed by IDEs
09:44 piojo and I need to find things by scrolling/searching
09:44 piojo and vim tabs (per file) to go from one logical area to another
09:45 Geth ¦ doc: a011ba984a | (Tom Browder)++ (committed using GitHub Web editor) | doc/Language/tables.pod6
09:45 Geth ¦ doc: add another pod renderer
09:45 Geth ¦ doc: review: https://github.com/perl6/doc/commit/a011ba984a
09:45 synopsebot Link: https://doc.perl6.org/language/tables
09:47 piojo grr, when I write "require XXX;", the compiler tells me:
09:47 piojo This type (NQPMu) does not support associative operations
09:47 piojo I finally know what that means, but that error message really, REALLY needs to die
09:47 piojo we will lose users because of that.
09:53 Ven joined #perl6
09:54 moritz what does it mean?
09:54 piojo I think it means something can't be serialized (in a precompiled module) by the compiler
09:54 piojo usually, though I'm sure it can happen in other cases
09:54 piojo my thought was that it should be changed to an exception, and caught (within the compiler) so a higher level error can be shown
09:55 piojo but I don't know if that's feasible, since I don't know the guts of perl 6...
09:57 Cabanossi joined #perl6
09:58 cdg joined #perl6
10:07 sena_kun joined #perl6
10:12 cosimo joined #perl6
10:20 sproctor joined #perl6
10:22 pecastro joined #perl6
10:25 piojo moritz: Actually, I can't figure out runtime module loading to allow modules to reference each other circularly
10:28 piojo A.pm6:  (try require B) === Nil and say "Failed to load B!"; unit module A;
10:28 piojo B.pm6: unit module B; use A;
10:28 piojo c.p6: use lib '.'; use B;
10:29 piojo And when I make little changes like adding a "say" statement, weird stuff happens. Like it may work suddenly, or it may say SORRY, Expected MAST::Frame, but didn't get one
10:32 sproctor m: my $part = "1|2";my $reg = rx/<$part>/;say "1" ~~ $reg;
10:32 camelia rakudo-moar 264eef798: OUTPUT: «「1」␤»
10:32 sproctor So... that works. Why?
10:34 jnthn <$part> is the syntax for "interpolate this string as if it were regex syntax"
10:34 jnthn As opposed to rx/$part/ which would treat it as a literal string to be matched
10:34 sproctor Yeah. So I'm trying to find that in the docs.
10:37 sproctor @piojo surely circular references are a bad sign?
10:38 piojo sproctor: I don't know about that. After all, this is why forward declaration exists. Could you write an Employee class and an Employer class without the two ever calling each other's methods?
10:39 lizmat you can stub a class:
10:39 yoleaux 2 Nov 2017 23:44Z <jnthn> lizmat: Yes, we only create a new affinity workers reluctantly, e.g. if the existing ones have stuff in their queues.
10:39 yoleaux 2 Nov 2017 23:48Z <jnthn> lizmat: That tends to work out pretty well: web servers scale their threads for message handling appropriately by load, for example.
10:39 sproctor I see your point.
10:39 piojo lizmat: how do I call its methods after stubbing it? I must import its symbols somehow.
10:40 lizmat m: class A { ... }; class B { my $a = A.foo }; class A { method foo { } }
10:40 camelia rakudo-moar 264eef798: ( no output )
10:40 piojo lizmat: they're in different files, for the sake of navigation and my own sanity
10:40 piojo I plan to reorganize everything later, but this is such early development
10:40 piojo I just want it to work now, and refactor in a month
10:41 lizmat piojo: are they to be always used together nonetheless?
10:41 lizmat .oO( I just want it to work now, and refactor in a month )
10:41 piojo lizmat: there's a lot of database work, and I'm not sure which data needs to come from which sources yet, so I'm having a hard time organizing things perfectly
10:41 lizmat I've heard that before :-)
10:41 piojo lizmat: yeah, but I'm the one that ends up doing all the refactoring for everyone else :P
10:42 piojo I'm the only one I know that has the Refactoring book
10:42 lizmat hehe
10:42 sproctor Always an issue.
10:42 lizmat well, what I can say from experience is that it is better to make things right the first time
10:42 lizmat and knowing that, don't be afraid to throw away the first version
10:43 lizmat because it made you figure out there was a better way to do it
10:45 piojo lizmat: that is reasonable, I'm just not sure it's doable. This is a new type of project for me
10:46 azawawi joined #perl6
10:46 azawawi hi
10:46 piojo A web service which mostly gets stuff from a database and does simple logic and data transformations. And I'm trying to categorize the functions based on the data they deal with, but there are dependencies, and data that needs to be cached for speed
10:46 piojo So if the classes can't talk to each other, I'm going to have to do something horrible like storing cached data in dynamic variables!
10:47 lizmat in memory caching?  memcached caching?  database caching ?
10:47 piojo caching of some important and mostly unchanging database records
10:48 piojo Also, there are functions that deal mostly with game level data (static, not changing), but needs to deal a little with per-player data (from a different class)
10:48 piojo and like I said, I'm quite capable of organizing it, but I don't want this reorganization to be a daily thing.
10:49 lizmat reorganization should only be a daily thing for a overseeable period of time  :-)
10:59 sproctor So, you've got (for example) a GameState that includes a list of Players and a Player that contains a reference to the GameState? What if you define a GameStateRole that gives all the information that the Player needs and the same for Player. Then GameState can include a PlayerRole and Player can include a GameStateRole.
11:02 leont joined #perl6
11:05 Ven joined #perl6
11:07 piojo sproctor: it's a little uglier than that
11:08 piojo The files are modules, not classes, since the server is stateless and doesn't remember anything--all data lives in the DB (except some cached frequently accessed hashes)
11:10 ZzZombo joined #perl6
11:10 piojo sproctor: there's a PlayerData module and a SceneManager module. PlayerData::load($user) gets some relevant data from the DB, and also gets more specific data from other modules (It will add info from SceneManager::get-state($user))
11:10 ZzZombo Hello there!
11:10 piojo the problem is that one of those other modules wants to access data that has a getter inside PlayerData.pm6
11:12 sproctor Hmmmm
11:12 ZzZombo I'm confused by https://docs.perl6.org/language/functions#sub_MAIN
11:13 sproctor In what way?
11:13 piojo sproctor: In this case, I should move it, but am I going to keep moving things around and changing dependencies and eventually get myself stuck?
11:13 sproctor surely unstuck.
11:13 ZzZombo Shouldn't it be `:$file($data)` instead of `:file($data)`?
11:14 cdg joined #perl6
11:14 leont timotimo: ping?
11:14 ZzZombo Also, if there a way to read from Windows registry?
11:16 piojo ZzZombo: :file($data) is a way of writing a key-value pair. The key is 'file', the value is $data, but in this case it does something more interesting--
11:16 sproctor Ah ha! Of course.
11:16 AlexDaniel joined #perl6
11:17 piojo when you do that in a function signature, it means you expect to receive a named argument called "file", but locally it'll be assigned to a variable called $data
11:17 ZzZombo ah, I see. Thanks!
11:19 pecastro joined #perl6
11:27 Cabanossi joined #perl6
11:28 AlexDaniel squashable6: next
11:28 squashable6 AlexDaniel, 🍕🍕 SQUASHathon is in progress! The end of the event in 2 days and ≈0 hours. See https://github.com/rakudo/rakudo/wiki/Monthly-Bug-Squash-Day
11:28 squashable6 AlexDaniel, No! It wasn't me! It was the one-armed man! Backtrace: https://gist.github.com/32319090b838a1551be7537f4b06daab
11:28 AlexDaniel oops…
11:32 piojo The only way I could find to include a module at runtime is to use "require MyModule;" inside a method/sub (not a class/module)
11:33 moritz the main code of a module runs at compile time
11:33 moritz you could do it in INIT I assume
11:33 piojo moritz: I don't think that works, for some reason
11:34 moritz m: INIT require Test; say Test.^name
11:34 camelia rakudo-moar 264eef798: OUTPUT: «Test␤»
11:34 piojo moritz: it works different for .pm6 modules
11:34 moritz :(
11:34 squashable6 joined #perl6
11:34 piojo after that, I can access the code in that function as ::('MyModule').some-function()
11:34 AlexDaniel squashable6: next
11:34 squashable6 AlexDaniel, 🍕🍕 SQUASHathon is in progress! The end of the event in 2 days and ≈0 hours. See https://github.com/rakudo/rakudo/wiki/Monthly-Bug-Squash-Day
11:34 squashable6 AlexDaniel, Log and stats: https://gist.github.com/d1e7939fa368342337be84d15d676010
11:34 piojo err, :: ('MyModule').some-function()
11:35 piojo it's cumbersome but I'm glad to know this is possible, in case of emergency.
11:36 Geth ¦ whateverable: 61a995c389 | (Aleks-Daniel Jakimenko-Aleksejev)++ | bin/Squashable.p6
11:36 Geth ¦ whateverable: Expect that the log may be empty
11:36 Geth ¦ whateverable: review: https://github.com/perl6/whateverable/commit/61a995c389
11:39 wamba joined #perl6
11:44 Geth ¦ doc: patzim++ created pull request #1647: Update ecosystem module upload docs (CPAN).
11:44 Geth ¦ doc: review: https://github.com/perl6/doc/pull/1647
11:44 squashable6 🍕 patzim++ opened pull request “Update ecosystem module upload docs (CPAN).”: https://github.com/perl6/doc/pull/1647
11:44 squashable6 🍕🍕🍕  First contribution by patzim++! ♥
11:44 squashable6 🍕 AlexDaniel++ wrote a comment on “Useless  "Documentation for " in some page titles.”: https://github.com/perl6/doc/issues/1623#issuecomment-341681896
11:44 squashable6 🍕🍕🍕  First contribution by AlexDaniel++! ♥
11:44 squashable6 🍕 AlexDaniel++ labeled issue “Useless  "Documentation for " in some page titles.”: https://github.com/perl6/doc/issues/1623
11:44 squashable6 🍕 AlexDaniel++ labeled issue “Useless  "Documentation for " in some page titles.”: https://github.com/perl6/doc/issues/1623
11:51 wander joined #perl6
11:52 margeas joined #perl6
11:55 wander jnthn, thanks for https://irclog.perlgeek.de/perl6/2017-11-03#i_15396016
11:55 Ven joined #perl6
11:55 wander I've been looking for it for one day
11:57 Cabanossi joined #perl6
12:00 wander I believe interpolating regexes is useful, it should be documented.
12:01 wander By the way, how do you guys think about https://github.com/perl6/doc/issues/1646
12:06 wander m: my token tok { a }; say "a" ~~ /<.&tok>/
12:06 camelia rakudo-moar 264eef798: OUTPUT: «「a」␤»
12:06 wander m: my token tok { a }; say "a" ~~ /<.tok>/
12:06 camelia rakudo-moar 264eef798: OUTPUT: «No such method 'tok' for invocant of type 'Match'. Did you mean 'to'?␤  in block <unit> at <tmp> line 1␤␤»
12:06 wander m: grammar { token TOP { <.tok> }; token tok { a } }.parse("a")
12:06 camelia rakudo-moar 264eef798: ( no output )
12:06 wander m: say grammar { token TOP { <.tok> }; token tok { a } }.parse("a")
12:06 camelia rakudo-moar 264eef798: OUTPUT: «「a」␤»
12:08 wander ^^ interesting, the syntaxes are quite the same, but indeed very different
12:08 wander outside grammar, `&` is needed, why is it needed?
12:11 piojo wander: any time you want to write a callable without calling it, like to get a reference to a function.
12:12 wander yes, i see that. but inside `grammar` things are different
12:13 piojo wander: really? in general, the are, but it looks like this case is pretty similar
12:13 wander that's why I say they "are quite the same, but indeed very different".
12:14 wander you know, f is so different from &f
12:15 piojo Regarding https://github.com/perl6/doc/issues/1646 , I don't agree
12:15 cdg joined #perl6
12:15 piojo oh, I need to read the criticism first
12:16 piojo but when I look up a routine or class, I like to see info about it, not just the API
12:16 piojo (A short description, not an essay.)
12:19 piojo Making this change seems like a step backwards from the criticism here: https://www.reddit.com/r/perl/comments/79wjtz/what_are_the_most_disliked_programming_languages/dp6r8j7/
12:19 piojo because info in /Language/* is harder to find than type/routine pages. It doesn't usually come up on searches.
12:19 piojo It's probably just not as full of keywords for indexing.
12:21 wander I wonder if '/routine/*` don't have a independent file, but gather messages from other files
12:21 wander s/<<a/an/
12:22 moritz that's correct
12:23 piojo wander: oh, you're right. So /routine/* doesn't contain descriptions. That's just /type/*
12:23 moritz the routine docs mostly resides the in the doc/Type/**.pod files
12:23 piojo I really, really like the descriptions in /Type/*, and they come up on searches so they're more helpful than an equivalent description would be in /language/
12:24 piojo and when I use new libraries in other languages, the ones where I can only find pure API reference drive me mad.
12:25 piojo I wonder if the complainer was really talking about other situations, like the fact that we have 3 pages about perl 6's OOP
12:25 wander while 2 pages about grammar :-(
12:28 DrForr IIRC one of those grammar pages is a full-on tutorial, so "only 2 pages" isn't quite the whole story.
12:28 piojo does the regex page count as another?
12:29 piojo When I was writing a toy parser, I wanted to know everything, I found myself looking at all of them. but I'm not sure combining them would have any benefit.
12:30 piojo I feel like things get "buried" when there's too much data
12:30 DrForr http://theperlfisher.blogspot.cz/2016/02/from-regular-expressions-to-grammars-pt.html might help.
12:31 mcmillhj joined #perl6
12:33 wander piojo: regex page is relevant. if I want to talk about some feature in regex doc, for completeness it involves grammar, and vice versa
12:33 piojo DrForr: I don't mean for right now. Just saying I wouldn't suggest consolidating everything without a really good idea about how it should be organized.
12:33 wander but they do be different things
12:37 llfourn joined #perl6
12:37 DrForr Regexes start to shade into grammars when you find yourself wanting a name for a term...
12:38 wander when it comes to documentation, https://docs.racket-lang.org/
12:39 ChoHag_ joined #perl6
12:39 wander it's quite neat and useful, with distinctive levels
12:43 wander DrForr: inside https://design.perl6.org/S05.html#Grammars Regex and Grammar are in the same file. but FWIW, it will be too large, and many people only want to know about regex.
12:45 DrForr But that's a design document, not actual documentation.
12:45 DrForr (I will fully admit to not having watched much of this discussion.)
12:55 wander just it's headache for me finding Regex, Grammar, Grammar Tutorial are ... I don't know how to say it ...  stir together(?)
12:58 DrForr Well, I find that regex, labeling terms, and parsing full-on text exists on a continuum.
12:59 DickClarke https://www.usenix.org/system/files/conference/woot17/woot17-paper-unruh.pdf
12:59 harrison joined #perl6
13:00 bdmatatu joined #perl6
13:08 cdg joined #perl6
13:19 ZzZombo <ZzZombo> Also, if there a way to read from Windows registry?
13:21 mson joined #perl6
13:21 DrForr You could potentially bind with NativeCall, not sure how that'd work on Windows though.
13:31 aborazmeh joined #perl6
13:31 aborazmeh joined #perl6
13:35 wamba joined #perl6
13:40 zakharyas joined #perl6
13:48 pecastro joined #perl6
14:01 darkmorph joined #perl6
14:04 khw joined #perl6
14:13 eliasr joined #perl6
14:19 ab6tract joined #perl6
14:19 ab6tract good afternoon, #perl6!
14:19 ab6tract big hugs from Amsterdam
14:20 ab6tract quick question: didn't we used to have some kind of joke about 42 and the meaning of life?
14:20 * moritz hugs back
14:20 moritz m: say 42.WHY
14:20 camelia rakudo-moar fccc75152: OUTPUT: «No documentation available for type 'Int'.␤Perhaps it can be found at https://docs.perl6.org/type/Int␤»
14:20 moritz hmmm
14:21 ab6tract ah! .WHY
14:21 ab6tract that makes a lot more sense than .WHAT in terms of being a joke that wouldn't also make a lot of people unhappy :
14:21 ab6tract :)
14:22 ab6tract seems like it's been removed though
14:23 moritz m: 'Life, the Universe and Everything'.WHY
14:23 camelia rakudo-moar fccc75152: ( no output )
14:23 moritz m: say 'Life, the Universe and Everything'.WHY
14:23 camelia rakudo-moar fccc75152: OUTPUT: «42␤»
14:23 moritz got it!
14:23 moritz m: say 'something else'.WHY
14:23 camelia rakudo-moar fccc75152: OUTPUT: «No documentation available for type 'Str'.␤Perhaps it can be found at https://docs.perl6.org/type/Str␤»
14:25 ab6tract thanks moritz. that significantly improves my mood for the afternoon :D
14:28 ab6tract moritz: hmm, it seems that installing p6doc does not make documentation available via .WHY. i wonder if it is possible to make this work?
14:29 moritz ab6tract: I don't know either
14:33 lizmat ab6tract: to make that in any way performant, that probably would have to be a different setting, like e.g. RESTRICTED setting
14:33 lizmat invoked with something like: 'use why' ?
14:33 mcmillhj joined #perl6
14:42 Thrush joined #perl6
14:42 Ven joined #perl6
14:43 Thrush I'm wondering why these two commands give different output, and how to make them the same:  Command 1:  (@a X @a X @a).say;  Command 2:  ((@a X @a) X @a).say;
14:44 Thrush m: my @a = <a b>; (@a X @a X @a).say; ((@a X @a) X @a).say
14:44 camelia rakudo-moar fccc75152: OUTPUT: «((a a a) (a a b) (a b a) (a b b) (b a a) (b a b) (b b a) (b b b))␤(((a a) a) ((a a) b) ((a b) a) ((a b) b) ((b a) a) ((b a) b) ((b b) a) ((b b) b))␤»
14:44 Thrush m: my @a = <a b>; (@a X @a X @a).say;
14:44 camelia rakudo-moar fccc75152: OUTPUT: «((a a a) (a a b) (a b a) (a b b) (b a a) (b a b) (b b a) (b b b))␤»
14:44 Thrush m: my @a = <a b>; ((@a X @a) X @a).say;
14:44 camelia rakudo-moar fccc75152: OUTPUT: «(((a a) a) ((a a) b) ((a b) a) ((a b) b) ((b a) a) ((b a) b) ((b b) a) ((b b) b))␤»
14:45 Thrush The reason I ask is because I'm writing code that needs to do a product of arrays together, but not all at once (so I can't do @a X @b X @c X @d etc.).
14:45 cdg joined #perl6
14:46 Thrush There's an "accumulator" array, and it will get other arrays "product-ed" onto it, and I want it to take the first form (that is:  @a X @a X @a) instead of the second (that is:  (@a X @a) X @a).
14:46 Thrush Is there a way to do this simply?
14:48 ab6tract somewhat related question. What is .WHO all about?
14:49 ZzZombo joined #perl6
14:49 ZzZombo joined #perl6
14:51 MasterDuke Thrush: can you wait and just do the product at the end once you've accumulated all the arrays?
14:51 Thrush MasterDuke:  Maybe, but the number of arrays is different.  They'll be created in a loop.
14:52 ggoebel joined #perl6
14:52 Thrush MasterDuke:  You know, using [X] on a collective array might work.  I'm testing it out now...
14:52 MasterDuke maybe something like: my @products = [X] @arrays ?
14:52 ChoHag joined #perl6
14:54 Thrush MasterDuke:  I'm trying that out, and it appears to work.  So, good suggestion!  I'm still wondering how to do it through one accumulator array.
14:55 ab6tract never mind, i've managed to grok it a bit
14:55 wander Thrush, https://docs.perl6.org/language/operators#Operator_Precedence
14:56 wander look up Meaning of $a ! $b ! $c
14:58 Thrush It seems that "@a = @a X @b" isn't the same as "@a X= @b".  Is this by design, or is it a mistake?
14:58 cdg joined #perl6
14:58 Thrush m: my @a = <a b>; my @b = <a b>; @a = @a X @b;  @a.say
14:58 camelia rakudo-moar fccc75152: OUTPUT: «[(a a) (a b) (b a) (b b)]␤»
14:58 Thrush m: my @a = <a b>; my @b = <a b>; @a X= @b;  @a.say
14:58 camelia rakudo-moar fccc75152: OUTPUT: «[b b]␤»
14:59 Thrush Shouldn't "@a = @a X @b" be the same as "@a X= @b" ?
15:00 cdg_ joined #perl6
15:01 Thrush MasterDuke:  While your suggestion works, I need an accumulator array that gets "producted", then "grepped", then "producted", then "grepped", over and over.  So I can't just store them all up in one array, then do a product.  The product is "as you go along", if that makes sense.
15:02 wander X is a metaoperator
15:02 cdg__ joined #perl6
15:02 ilmari https://docs.perl6.org/language/operators#index-entry-X_%28cross_meta_operator%29
15:02 wander so in `X=`, `X`modify`=`
15:02 Thrush wander:  So does X being a metaoperator make a difference?
15:03 ilmari Thrush: it means that the X in @a X= @b is not the same operator as the X in @a X @b
15:03 mempko joined #perl6
15:03 Thrush wander, ilmari:  I'm trying to follow, but I'm confused.
15:04 ilmari m: my @a = <A B>; my @b = <a b>; say @a Z @b; @a Z= @b; say @a
15:04 camelia rakudo-moar fccc75152: OUTPUT: «((A a) (B b))␤[a b]␤»
15:04 kalkin-- m: class Tile { has $.x; has $.y; method draw() { say "drin"; } }; my @map; for 0..^10⁶ { @map.append: Tile.new(:x(rand), :y(rand)) }
15:04 camelia rakudo-moar fccc75152: ( no output )
15:05 kalkin-- The above script takes a lot of time, any hints how to make it faster?
15:05 kalkin-- Or should I just use for each tile an array with all the needed values?
15:06 kalkin-- Or even go as far as using repr('CStruct')?
15:06 wander <ilmari> Thrush: it means that the X in @a X= @b is not the same operator as the X in @a X @b
15:07 wander that is it, I think it's directly enough, they are not the same
15:08 ilmari read the link I posted about the cross metaop
15:09 wamba joined #perl6
15:09 kalkin-- Hmm using a CStruct isn't that much faster, only a second
15:10 Thrush I see that the X (and Z) metaoperator can take an infix operator.  Can it also take a block/lambda ?
15:12 Cabanossi joined #perl6
15:13 Thrush I read the link you supplied, ilmari.  But I don't see how it applies to the difference between "@a = @a X @b" and "@a X= @b"
15:14 ilmari Thrush: it means that X= is not your usual <op>= shorthand
15:14 AlexDaniel joined #perl6
15:14 ilmari because X is a metaop of its own, that looks confusingly similar to the X infix op
15:15 squashable6 🍕 AlexDaniel++ labeled issue “rw (what it stands for)”: https://github.com/perl6/doc/issues/1639
15:15 ilmari ditto the Z metaop (it even says in the docs it's not the same as the Z binop, maybe X should too)
15:16 squashable6 🍕 AlexDaniel++ labeled issue “named capture using non-capturing group confusion”: https://github.com/perl6/doc/issues/1634
15:16 squashable6 🍕 AlexDaniel++ labeled issue “rw (what it stands for)”: https://github.com/perl6/doc/issues/1639
15:16 squashable6 🍕 AlexDaniel++ labeled issue “Missing docs for creatin…”: https://github.com/perl6/doc/issues/1641
15:16 squashable6 🍕 AlexDaniel++ labeled issue “Deadlink for Metamodel::…”: https://github.com/perl6/doc/issues/1642
15:16 squashable6 🍕 AlexDaniel++ labeled issue “doc >>. on lists of Callables”: https://github.com/perl6/doc/issues/1643
15:16 setty1 joined #perl6
15:16 AlexDaniel squashable6: shut up for a little bit
15:16 squashable6 AlexDaniel, .oO( Mmmm… pizza! )
15:18 squashable6 🍕🍕🍕  First contribution by W4anD0eR96++! ♥
15:22 diakopter joined #perl6
15:24 AlexDaniel squashable6: ok you can be loud again
15:24 squashable6 AlexDaniel, ALRIGHT, LET'S DO IT!!!
15:25 diakopter -
15:26 Thrush I just found that I can make ((@a X @a) X @a) be the same as (@a X @a X @a) with this:  ((@a X @a) X @a).map( {|$_[0],$_[1]} )
15:26 Thrush m: my @a = <a b>;  ((@a X @a) X @a).map( {|$_[0],$_[1]} ).say
15:26 camelia rakudo-moar fccc75152: OUTPUT: «((a a a) (a a b) (a b a) (a b b) (b a a) (b a b) (b b a) (b b b))␤»
15:27 Thrush I am wondering if there is a simpler way to write that argument to map().
15:30 Thrush Question:  How do I create a 10-element array of all 1?  [1] x 10 doesn't seem to work:
15:30 wander m: my @a = <a b>; say ((@a X @a) X @a).map( *.flat );
15:30 camelia rakudo-moar fccc75152: OUTPUT: «((a a a) (a a b) (a b a) (a b b) (b a a) (b a b) (b b a) (b b b))␤»
15:30 Thrush m: ([1] x 10).perl
15:30 camelia rakudo-moar fccc75152: ( no output )
15:30 Thrush m: ([1] x 10).perl.say
15:30 camelia rakudo-moar fccc75152: OUTPUT: «"1111111111"␤»
15:31 wander say (flat [1] xx 10)
15:31 evalable6 wander, rakudo-moar fccc75152: OUTPUT: «(1 1 1 1 1 1 1 1 1 1)»
15:33 diakopter who are all these peeps
15:33 squashable6 🍕 zoffixznet++ submitted a review on pull request “Update ecosystem module upload docs (CPAN).”: https://github.com/perl6/doc/pull/1647#pullrequestreview-74119946
15:33 squashable6 🍕🍕🍕  First contribution by zoffixznet++! ♥
15:34 ugexe run, its old man diakopter
15:34 squashable6 🍕 zoffixznet++ wrote a comment on “Update ecosystem module upload docs (CPAN).”: https://github.com/perl6/doc/pull/1647#issuecomment-341738663
15:36 Thrush m: my @a = <a b>; say ((@a X @a) X @a).map( *.flat );
15:36 camelia rakudo-moar fccc75152: OUTPUT: «((a a a) (a a b) (a b a) (a b b) (b a a) (b a b) (b b a) (b b b))␤»
15:36 Thrush m: my @a = <a b>; my @b = @a X @a; my @c = (@b X @a).map( *.flat ); @c.say
15:36 camelia rakudo-moar fccc75152: OUTPUT: «[((a a) a) ((a a) b) ((a b) a) ((a b) b) ((b a) a) ((b a) b) ((b b) a) ((b b) b)]␤»
15:37 Thrush Why don't those produce the same output?  I'm so confused about what "flat" does.
15:38 Thrush m: my @a = <a b>; my @c = ((@a X @a) X @a).map( *.flat ); @c.say
15:38 camelia rakudo-moar fccc75152: OUTPUT: «[(a a a) (a a b) (a b a) (a b b) (b a a) (b a b) (b b a) (b b b)]␤»
15:39 Thrush Is there a nice page that explains "flat" ?  I've read documentation about it, but it still puzzles me.
15:40 AlexDaniel squashable6: log
15:40 squashable6 AlexDaniel, Log and stats: https://gist.github.com/7d58c213d81551aa4892f5b5040ef1da
15:40 Zoffix joined #perl6
15:41 Zoffix Thrush: dunno about docs, but .flat flattens all nested, non-scalarized Itearables into a single, flat iterable
15:41 Zoffix m: dd (1, (2, (3,))).flat
15:41 camelia rakudo-moar fccc75152: OUTPUT: «(1, 2, 3).Seq␤»
15:41 wander Thrush, container counts
15:41 Zoffix However, if an iterable is inside a scalar container, it's treated as a single item and not a collection of items, and those aren't flattened
15:41 Zoffix m: dd (1, $(2, (3,))).flat
15:41 camelia rakudo-moar fccc75152: OUTPUT: «(1, $(2, (3,))).Seq␤»
15:41 AlexDaniel Thrush: we can probably improve the docs to make it clearer. Perhaps consider filing an issue on https://github.com/perl6/doc/issues/
15:42 squashable6 🍕 AlexDaniel++ labeled issue “need example of alternate test descriptions”: https://github.com/perl6/doc/issues/1586
15:42 Zoffix Thrush: I found this document helpful when I struggled with containers. Perhaps it'd be of help to you as well: https://docs.perl6.org/language/containers  Once you master containers, .flat's behaviour becomes obvious
15:42 wander zoffix: https://irclog.perlgeek.de/perl6/2017-11-03#i_15396393
15:43 Thrush m: dd (1, (2, (3,))).flat
15:43 camelia rakudo-moar fccc75152: OUTPUT: «(1, 2, 3).Seq␤»
15:43 Thrush m: dd [1, [2, [3,]]].flat
15:43 camelia rakudo-moar fccc75152: OUTPUT: «(1, $[2, [3]]).Seq␤»
15:43 Thrush m: dd [1, [2, [3]]].flat
15:43 camelia rakudo-moar fccc75152: OUTPUT: «(1, $[2, [3]]).Seq␤»
15:43 Zoffix Thrush: note that Arrays create scalar containers for their elements. Lists don't
15:44 Zoffix m: dd [1, [2, [3]]].»<>.flat
15:44 camelia rakudo-moar fccc75152: OUTPUT: «(1, 2, $[3]).Seq␤»
15:44 Zoffix m: dd [1, [2, [3, [3, 4]]]].»<>.flat
15:44 camelia rakudo-moar fccc75152: OUTPUT: «(1, 2, $[3, [3, 4]]).Seq␤»
15:44 telex joined #perl6
15:44 Zoffix m: dd [1, [2, [3, [3, 4]]]].»List.flat
15:44 camelia rakudo-moar fccc75152: OUTPUT: «5===SORRY!5=== Error while compiling <tmp>␤Missing dot on method call␤at <tmp>:1␤------> 3dd [1, [2, [3, [3, 4]]]].»7⏏5List.flat␤    expecting any of:␤        postfix␤»
15:44 Zoffix m: dd [1, [2, [3, [3, 4]]]]».List.flat
15:44 camelia rakudo-moar fccc75152: OUTPUT: «(1, 2, 3, $[3, 4]).Seq␤»
15:44 Thrush Zoffix:  Thanks for the clarification about Arrays creating scalar containers.
15:45 * Zoffix squints at these evals... something don't feel right :)
15:45 Thrush m: dd [1, [2, [3, [3, 4]]]]>>.List.flat
15:45 camelia rakudo-moar fccc75152: OUTPUT: «(1, 2, 3, $[3, 4]).Seq␤»
15:46 Zoffix Oh right. ». also follows the "do not descend into containerized iterables" thing :)
15:47 Zoffix wander: sounds like we're talking about the same thing. This is what I expect /routine/ docs to be like: https://docs.perl6.org/type/IO::Handle#method_open  The describe what the routine does and references other methods for details on what encodings you can set, etc. It doesn't go into showing a million of examples of how to .open() everything under the moon. That'd be the job for IO guides in /language/
15:52 Thrush If flat() works on non-scalar containers, then why do these say()s produce different output?  my @a = <a b>; (@a, @a).flat.say; my @b = (@a, @a); @b.flat.say
15:52 Thrush m: my @a = <a b>; (@a, @a).flat.say; my @b = (@a, @a); @b.flat.say
15:52 camelia rakudo-moar 1c2c7d845: OUTPUT: «(a b a b)␤([a b] [a b])␤»
15:53 Thrush m: my @a = <a b>; [@a, @a].flat.say; my @b = (@a, @a); @b.flat.say
15:53 camelia rakudo-moar 1c2c7d845: OUTPUT: «([a b] [a b])␤([a b] [a b])␤»
15:53 Thrush m: my @a = <a b>; (@a, @a).flat.say; my @b = (@a, @a); @b.List.flat.say
15:53 camelia rakudo-moar 1c2c7d845: OUTPUT: «(a b a b)␤(a b a b)␤»
15:53 Herby_ joined #perl6
15:53 Zoffix Thrush: in the first version, you're sticking two `@a`s into a List, which doesn't make any containers. In the second version, you're sticking two `@a`s into Array `@b` and arrays create containers, so the second one is scalarized (is that a term?) and hence unflattened
15:53 Thrush Ahhh... I think I see something now.
15:54 wander starts with sigil `@`, `@b` is Array, not List
15:55 ugexe m: my @a = <a b>;  my @b = (@a X @a); say @b.map(|(@a X |*)) # from perlawhirl 4 days ago
15:55 camelia rakudo-moar 1c2c7d845: OUTPUT: «((a a a) (b a a) (a a b) (b a b) (a b a) (b b a) (a b b) (b b b))␤»
15:55 mcmillhj joined #perl6
15:57 Zoffix wander: `@` just defaults to Array. The sigil indicates the type is Positional, not that it's an Array
15:57 Cabanossi joined #perl6
15:57 Zoffix m: my @a := 1, 2, 3; my @b := class Foo does Positional {}; say @a.^name; say @b.^name
15:57 camelia rakudo-moar 1c2c7d845: OUTPUT: «List␤Foo␤»
15:58 Zoffix Happy SQUASHathoning \o
15:58 * Zoffix &
15:58 Zoffix left #perl6
15:58 wander zoffix: so after redesign/rearrange, /language/ should document the basic usage, like outline, and set links to details in /type/?
15:58 wander have learned it XD
16:02 wander what's important is, if possible, build a guideline on "How To Document". Now it is separated in CONTRIBUTING.md, EXAMPLES.md and STYLEGUIDE.md, and can be improved
16:02 cdg joined #perl6
16:04 Thrush I notice sometimes there are methods that look like this:  object.method( blah ); and sometimes ones that look like this:  object.method: blah;  Is there a difference?  Where can I read up on the differences?
16:06 Thrush And does someone have a good link to read up on the "*" symbol?  That is, the one that is often used as a argument?
16:06 jnthn Thrush: They semantics are the same, the syntax is different, though. : means that the rest of the statement is the arguments.
16:06 Thrush jnthn:  Does that mean that they're always interchangeable?
16:07 jnthn Thrush: It's especially nice when doing `$obj.meth: { ... }` when the block spans several lines; then you don't have to stick a closing ) after the block
16:08 jnthn Thrush: In terms of their semantics, yes; they compile into the very same thing. It's just a syntax difference with regards to the parsing of arguments.
16:08 mcmillhj joined #perl6
16:10 MasterDuke Thrush: https://docs.perl6.org/type/Whatever
16:13 dakkar joined #perl6
16:14 troys joined #perl6
16:14 dakkar hello! is the metacpan-like service at hack.p6c.org usable? I notice that Zef has it configured
16:15 dakkar I maintain https://www.thenautilus.net/metacpan.atom and I wanted to see if I could make one for p6 module releases
16:16 cdg joined #perl6
16:16 diakopter ugexe: omg
16:18 [Coke] "diakopter? That's a name I've not heard in a long time"
16:18 [Coke] ~~
16:19 ugexe dakkar: jdv79 was doing the metacpan work. additional interest/collaboration may inspire him to continue.
16:20 dakkar ugexe: thank you, good to know!
16:21 mcmillhj joined #perl6
16:24 Ven joined #perl6
16:27 Piotr joined #perl6
16:28 mcmillhj joined #perl6
16:29 Zoffix joined #perl6
16:30 Zoffix dakkar: you may wanna subscribe to this Issue: https://github.com/perl6/modules.perl6.org/issues/81  It should be resolved fairly soon, since some people expect it to and it'll have a JSON API to fetch recent stuff.
16:31 * dakkar looks
16:33 squashable6 🍕 W4anD0eR96++ wrote a comment on “add operator declarators to /type/Sub”: https://github.com/perl6/doc/issues/1573#issuecomment-341757350
16:35 dakkar Zoffix: nice! not what I need, but very good that's in the works
16:35 Zoffix dakkar: what do you need?
16:36 dakkar my feed diffs the changelog between the last stable release and the latest release
16:37 Zoffix dakkar: that might be tough, as it doesn't look like having a ChangeLog is an established practice for our ecosystem
16:37 dakkar ouch
16:38 Zoffix Just flipping through http://modules.perl6.org/search/?q=from%3Acpan and found only one module that got "Changes" file in it
16:38 cdg_ joined #perl6
16:38 dakkar (the program that generates the feed: https://www.thenautilus.net/cgit/metacpan-diff-feed/tree/meta.pl )
16:38 dakkar good habits are hard to keep up! ☺
16:38 Zoffix :)
16:39 Zoffix We could add that as an item for TODO Issues dists being flagged as http://modules.perl6.org/todo/
16:40 mcmillhj joined #perl6
16:40 Zoffix Filed as an issue: https://github.com/perl6/modules.perl6.org/issues/93
16:40 dakkar at some point I'd like to make another feed with "the interesting parts" of the full diff between releases, although the definition of "interesting" is a bit fuzzy
16:40 Zoffix \o
16:40 Zoffix left #perl6
16:41 dakkar Zoffix: thank you! we can't have p6 dists being less awesome that p5 ones 😜
16:42 Geth ¦ ecosystem: e43f433e15 | (Jonathan Worthington)++ (committed using GitHub Web editor) | META.list
16:42 Geth ¦ ecosystem: Remove Cro distributions; they're now on CPAN
16:42 Geth ¦ ecosystem: review: https://github.com/perl6/ecosystem/commit/e43f433e15
16:44 dakkar oh Cro! another thing I want to play with
16:46 buggable New CPAN upload: cro-0.7.1.tar.gz by JNTHN https://cpan.metacpan.org/authors/id/J/JN/JNTHN/Perl6/cro-0.7.1.tar.gz
16:46 buggable New CPAN upload: cro-core-0.7.1.tar.gz by JNTHN https://cpan.metacpan.org/authors/id/J/JN/JNTHN/Perl6/cro-core-0.7.1.tar.gz
16:46 buggable New CPAN upload: cro-http-0.7.1.tar.gz by JNTHN https://cpan.metacpan.org/authors/id/J/JN/JNTHN/Perl6/cro-http-0.7.1.tar.gz
16:46 buggable New CPAN upload: cro-tls-0.7.1.tar.gz by JNTHN https://cpan.metacpan.org/authors/id/J/JN/JNTHN/Perl6/cro-tls-0.7.1.tar.gz
16:46 buggable New CPAN upload: cro-websocket-0.7.1.tar.gz by JNTHN https://cpan.metacpan.org/authors/id/J/JN/JNTHN/Perl6/cro-websocket-0.7.1.tar.gz
16:46 buggable New CPAN upload: cro-zeromq-0.7.1.tar.gz by JNTHN https://cpan.metacpan.org/authors/id/J/JN/JNTHN/Perl6/cro-zeromq-0.7.1.tar.gz
16:47 mson joined #perl6
16:49 dakkar jnthn: is this the release with the 'delegate' feature in Cro::HTTP::Router?
16:49 jnthn http://cro.services/docs/releases#0.7.1 for anyone curious what's in the release
16:49 jnthn dakkar: Yes
16:49 dakkar yay!
16:50 dakkar implement authentication in one router, delegate to the other router that actually runs the logic
16:51 jnthn gah, and now I see them on the site, I see Text::Markdown doesn't cope so well with nested bulletpoints
16:51 timotimo jnthn: i believe these change lists were meant to have nested lists
16:51 timotimo yeah
16:52 jnthn Yeah, just checked, the Markdown is correct
16:52 jnthn Also just glanced the container build log and yeah, it installed latest Text::Markdown while building
16:56 jnthn Well, will either work around that or see if I can patch the module later
16:56 jnthn Time to eat now :)
16:56 Cabanossi joined #perl6
16:58 timotimo good nom
16:58 timotimo jnthnom :)
16:59 leont timotimo: https://github.com/Leont/yamlish/commit/b460d9b43b5f6ec782cfced829c12d3c1960f175#commitcomment-25354281
16:59 ilmari leont: did you say you'd thrown the yaml test suite at yamlish?
17:00 timotimo leont: subst used to have a but where it accessed a semi-random $/ up the scope, now it properly accesses the one in the scope subst is called from, which is read-only in this method
17:07 leont That is almost making sense, but not quite
17:07 buggable joined #perl6
17:07 leont The problem is that it's overwriting the $/ of its outer scope?
17:07 timotimo m: "hi" ~~ /./; say $/; "foobar".subst(/.../, "!!!"); say $/
17:07 camelia rakudo-moar 1c2c7d845: OUTPUT: «「h」␤「foo」␤»
17:08 timotimo c: 2017.08 "hi" ~~ /./; say $/; "foobar".subst(/.../, "!!!"); say $/
17:08 committable6 timotimo, ¦2017.08: «「h」␤「foo」»
17:08 timotimo c: 2017.07 "hi" ~~ /./; say $/; "foobar".subst(/.../, "!!!"); say $/
17:08 committable6 timotimo, ¦2017.07: «「h」␤「foo」»
17:08 timotimo hold on
17:08 timotimo c: 2017.08 sub test($/) { say $/; "foobar".subst(/.../, "!!!"); say $/ }; "hi" ~~ /./; test($/);
17:08 committable6 timotimo, ¦2017.08: «「h」␤「h」»
17:08 timotimo c: 2017.10 sub test($/) { say $/; "foobar".subst(/.../, "!!!"); say $/ }; "hi" ~~ /./; test($/);
17:08 committable6 timotimo, ¦2017.10: «「h」␤「h」»
17:08 timotimo c: HEAD sub test($/) { say $/; "foobar".subst(/.../, "!!!"); say $/ }; "hi" ~~ /./; test($/);
17:08 committable6 timotimo, ¦HEAD(1c2c7d8): «「h」␤Cannot assign to a readonly variable ($/) or a value␤  in sub test at /tmp/E_PQY0jVMi line 1␤  in block <unit> at /tmp/E_PQY0jVMi line 1␤ «exit code = 1»»
17:09 timotimo c: 2017.10 sub test($/) { say $/; "foobar".subst(/.../, "!!!"); say $/ }; "hi" ~~ /./; test($/); say $/
17:09 committable6 timotimo, ¦2017.10: «「h」␤「h」␤「h」»
17:09 timotimo not sure where exactly it ended up assigning, or if it skipped it altogether
17:09 timotimo BBL
17:14 leont Thanks! I think I now understand it better :-)
17:18 telex joined #perl6
17:21 El_Che any alpine devs around?
17:26 kalkin-- I'm trying to find out what the difference is between 1..3 and 1...3 when I use it in a for loop
17:26 kalkin-- m: for 1..3 { say $_ }; for 1…3 { say $_ }
17:26 camelia rakudo-moar 1c2c7d845: OUTPUT: «1␤2␤3␤1␤2␤3␤»
17:32 robertle joined #perl6
17:35 mr-foobar joined #perl6
17:36 Geth ¦ doc: fd7cce7a03 | MasterDuke17++ (committed using GitHub Web editor) | doc/Type/Whatever.pod6
17:36 Geth ¦ doc: Some grammar and consistency fixes
17:36 synopsebot Link: https://doc.perl6.org/type/Whatever
17:36 Geth ¦ doc: review: https://github.com/perl6/doc/commit/fd7cce7a03
17:36 squashable6 🍕🍕🍕  First contribution by MasterDuke17++! ♥
17:41 greppable6 joined #perl6
17:42 domidumont joined #perl6
17:47 buggable New CPAN upload: OAuth2-Client-Google-0.1.0.tar.gz by BDUGGAN https://cpan.metacpan.org/authors/id/B/BD/BDUGGAN/Perl6/OAuth2-Client-Google-0.1.0.tar.gz
17:48 diakopter has someone made Cro versions of these benchmark targets? https://www.techempower.com/benchmarks/
17:49 robertle ;;[[[[[[[[']
17:50 ilmari hello robertle's (cat|child)
18:00 AlexDaniel joined #perl6
18:05 AlexDaniel squashable6: status
18:05 squashable6 AlexDaniel, 🍕🍕 SQUASHathon is in progress! The end of the event in 1 day and ≈17 hours. See https://github.com/rakudo/rakudo/wiki/Monthly-Bug-Squash-Day
18:05 squashable6 AlexDaniel, Log and stats: https://gist.github.com/b9d6933e91be8e123bfd1c9e1465838c
18:08 AlexDaniel hm, so GitHub now signs all commits made with its online editor?
18:09 AlexDaniel .oO( … what's the point? )
18:10 knight__ joined #perl6
18:12 Cabanossi joined #perl6
18:13 knight__ Hello, Is there any "native" possibility to call Perl5 modules from Perl6, I do not want use Inline::Perl5
18:13 knight__ ?
18:13 lucs m: say 'spaces?' xx 3
18:13 camelia rakudo-moar 32412170b: OUTPUT: «(spaces? spaces? spaces?)␤»
18:16 lucs Oh, xx is for lists, sorry.
18:19 perlpilot knight__: What's wrong with Inline::Perl5?
18:20 Piotr joined #perl6
18:21 mst knight__: what do you mean 'native'
18:21 mst given what it's doing is calling code written in a completely different programming language, Inline::Perl5 seems as native as you're going to get to me.
18:21 knight__ perlpilot: I do not want rewrite program. Lazy boy :-)
18:21 mst what?
18:21 mst the whole point of Inline::Perl5 is you don't have to rewrite anything
18:22 * mst looks confused
18:22 knight__ mst: I understand, but I wrote whole program, and someone ask me, that Do Perl6 works with Perl5 modules.
18:22 mst what?
18:23 knight__ mst: Again, I wrote whole program, in Perl6 with perl6 modules.
18:23 mst ok?
18:23 knight__ I sent this program, and
18:23 mst Inline::Perl5 for rakudo lets you call perl5 code from rakudo
18:23 mst Inline::Perl6 for perl5 lets you call rakudo from perl5
18:23 mst what's the problem?
18:24 knight__ My professor :-)
18:24 knight__ I cannot do it by my own.
18:24 mst I still don't understand what you're asking for.
18:24 perlpilot ah, that's a different problem.  Get your prof to use Perl 6
18:25 mst knight__: if it was perl homework, then writing it in a completely different language was an error.
18:26 knight__ it was in perl, but I can write in perl6, but he does not know anything about perl6, he is asking to use perl5 modules to be imported in my program ...
18:26 mst knight__: perl6 is not perl.
18:26 knight__ I know, I was asking him about it.
18:27 mst but 'use Some::Perl5::Module:from<Perl5>;' works
18:27 mst so I don't see how that isn't the answer
18:28 knight__ Ok, AGAIN
18:28 knight__ I wrote program in Perl6
18:28 knight__ He knows about it.
18:29 mst ok?
18:29 knight__ I sent the program, and he wrote me email. And He mentioned that, Perl6 has native support of perl5 modules.
18:29 mst yes, via Inline::Perl5
18:29 knight__ -> Without installing Perl6 modules -> Inline::Perl5
18:29 [Coke] he's wrong
18:29 mst no
18:30 mst :from<Perl5> is native perl6 syntax, and works if you have Inline::Perl5
18:30 [Coke] he might be thinking of some 12 year old project that isn't a thing anymore.
18:30 mst like I keep telling you
18:30 knight__ mst: But He does not want install any Perl6 modules :-)
18:30 mst knight__: tough
18:30 knight__ yep :-)
18:31 knight__ *never ending story*
18:37 knight__ moritz: and everyone who helped me, thank you, Perl6 is IMO fantastic language, bye, I must do homeworks in different language, bye Perl6 for now! :-(
18:37 knight__ Bye all
18:37 knight__ left #perl6
18:39 bisectable6 joined #perl6
18:40 Herby_ m: say .join('') for <c e r a>.permutations
18:40 camelia rakudo-moar 32412170b: OUTPUT: «cera␤cear␤crea␤crae␤caer␤care␤ecra␤ecar␤erca␤erac␤eacr␤earc␤rcea␤rcae␤reca␤reac␤race␤raec␤acer␤acre␤aecr␤aerc␤arce␤arec␤»
18:41 pmurias joined #perl6
18:45 evalable6 joined #perl6
18:52 [Coke] m: <w h a t>.join.say
18:52 camelia rakudo-moar 32412170b: OUTPUT: «what␤»
18:53 Herby_ ah nice
18:56 cdg joined #perl6
18:58 Rawriful joined #perl6
19:00 cdg joined #perl6
19:01 mcmillhj joined #perl6
19:14 wander do we have a build-in role like Comparable?
19:16 [Coke] "what is comparable" ?
19:17 cdg_ joined #perl6
19:18 wander I can compare two instances of it
19:18 perlpilot string compare?
19:18 perlpilot numeric compare?
19:18 geekosaur an example of something that *isn't* comparable is complex numbers
19:18 perlpilot generic compare?
19:18 geekosaur meaningfully
19:19 geekosaur you can force an order on it easily enough but it doesn't represent anything meaningful about the relationship between the values
19:19 AlexDaniel m: class Foo { has $.z }; multi sub infix:<cmp>(Foo:D $a, Foo:D $b) { say ‘hi’; Less }; (Foo.new(:42z), Foo.new(:50z), Foo.new(:2z)).sort.say
19:19 camelia rakudo-moar 32412170b: OUTPUT: «(Foo.new(z => 42) Foo.new(z => 50) Foo.new(z => 2))␤»
19:20 AlexDaniel that doesn't do what I wanted it do :S
19:20 Geth ¦ doc: de1d46d801 | (Patrick Sebastian Zimmermann)++ | doc/Language/modules.pod6
19:20 Geth ¦ doc: Update ecosystem upload docs (CPAN).
19:20 Geth ¦ doc:
19:20 Geth ¦ doc: As explained here: https://rakudo.party/post/CPAN6-Is-Here
19:20 Geth ¦ doc: review: https://github.com/perl6/doc/commit/de1d46d801
19:20 synopsebot Link: https://doc.perl6.org/language/modules
19:20 squashable6 🍕 patzim++ merged pull request “Update ecosystem module upload docs (CPAN).”: https://github.com/perl6/doc/pull/1647
19:20 Geth ¦ doc: e0b91762fc | (Patrick Sebastian Zimmermann)++ | 31 files
19:20 Geth ¦ doc: Merge branch 'master' of https://github.com/perl6/doc
19:20 Geth ¦ doc: review: https://github.com/perl6/doc/commit/e0b91762fc
19:20 Geth ¦ doc: 76badf6457 | (Patrick Zimmermann)++ (committed using GitHub Web editor) | doc/Language/modules.pod6
19:20 Geth ¦ doc: Merge pull request #1647 from patzim/master
19:20 Geth ¦ doc:
19:20 Geth ¦ doc: Update ecosystem module upload docs (CPAN).
19:20 Geth ¦ doc: review: https://github.com/perl6/doc/commit/76badf6457
19:20 squashable6 🍕 patzim++ wrote a comment on “Update ecosystem module upload docs (CPAN).”: https://github.com/perl6/doc/pull/1647#issuecomment-341801833
19:20 perlpilot geekosaur: https://github.com/rakudo/rakudo/blob/master/src/core/Complex.pm#L474  :)
19:21 geekosaur yes, I said you can force an ordering on it
19:21 wander maybe 'role Comparable[::Type] { method compare(Type $o --> Order) { ... } }'
19:22 wander not so good :(
19:23 AlexDaniel wander: well, the comparison is done with cmp op, so in theory it should be possible to add another candidate with params restricted to objects of your class and that should work, except that it doesn't…
19:23 wander I will try it
19:25 AlexDaniel how can I make &sort call my own cmp?
19:25 AlexDaniel without forcing it to do so by passing a callable to it
19:26 Rawriful joined #perl6
19:27 geekosaur I think you can't? this sounds like the same issue we already have for other types, if a method is invoked from a method on Any then you get the Any candidate instead of the actual type's candidate
19:28 wander m: class Foo { has $.z }; multi sub infix:<cmp>(Foo:D $a, Foo:D $b) { say ‘hi’; Less }; (Foo.new(:42z), Foo.new(:50z), Foo.new(:2z)).sort(&infix:<cmp>).say
19:28 camelia rakudo-moar 32412170b: OUTPUT: «hi␤hi␤hi␤(Foo.new(z => 42) Foo.new(z => 50) Foo.new(z => 2))␤»
19:28 geekosaur or Cool, etc. something near the root doesn;t specialize to types toward the leaves
19:28 Rawriful joined #perl6
19:29 wander AlexDaniel: ^^ is it?
19:33 AlexDaniel wander: yea, but this way it doesn't have to be infix:<cmp>, you can call it any way you want
19:34 AlexDaniel wander: it's probably the first time I see someone wanting Comparable, which is probably a very reasonable wish but people usually people don't notice its absence because you can just pass a code block to &sort :)
19:35 AlexDaniel greppable6: infix\:\<cmp\>
19:35 greppable6 AlexDaniel, https://gist.github.com/59fd62f246bd12d8e266ad84d2407495
19:38 AlexDaniel so what's the point of this? https://github.com/ugexe/zef/blob/c5e45a0625da04c7c5e577ab2156922eb5a2b25c/lib/Zef/Distribution.pm6#L145
19:38 AlexDaniel “allow easier sorting” what's so easier about it?
19:46 squashable6 🍕 bduggan++ self-assigned issue “Deadlink for Metamodel::…”: https://github.com/perl6/doc/issues/1642
19:46 squashable6 🍕🍕🍕  First contribution by bduggan++! ♥
19:47 wander joined #perl6
19:47 Geth ¦ doc/enum_how: 5d08cfcc98 | (Brian Duggan)++ | doc/Type/Metamodel/EnumHOW.pod6
19:47 Geth ¦ doc/enum_how: Add Metamodel::EnumHOW page
19:47 Geth ¦ doc/enum_how:
19:47 Geth ¦ doc/enum_how: Resolves #1642
19:47 Geth ¦ doc/enum_how: review: https://github.com/perl6/doc/commit/5d08cfcc98
19:48 wander AlexDaniel: yes, I should get used to the Perlish way
19:50 Geth ¦ doc: bduggan++ created pull request #1648: Add Metamodel::EnumHOW page
19:50 Geth ¦ doc: review: https://github.com/perl6/doc/pull/1648
19:50 squashable6 🍕 bduggan++ opened pull request “Add Metamodel::EnumHOW page”: https://github.com/perl6/doc/pull/1648
19:57 Cabanossi joined #perl6
19:59 darkmorph joined #perl6
20:03 releasable6 joined #perl6
20:06 mcmillhj joined #perl6
20:12 travis-ci joined #perl6
20:12 travis-ci Doc build passed. Brian Duggan 'Add Metamodel::EnumHOW page
20:12 travis-ci https://travis-ci.org/perl6/doc/builds/296950054 https://github.com/perl6/doc/commit/5d08cfcc98ac
20:12 travis-ci left #perl6
20:13 mcmillhj joined #perl6
20:18 Piotr joined #perl6
20:24 mcmillhj joined #perl6
20:38 squashable6 🍕 AlexDaniel++ wrote a comment on “Mention 「my %h{Int}」 syn…”: https://github.com/perl6/doc/issues/1588#issuecomment-341820678
20:38 mcmillhj joined #perl6
20:40 squashable6 🍕 AlexDaniel++ wrote a comment on “Grammar.parse talks abou…”: https://github.com/perl6/doc/issues/1583#issuecomment-341821228
20:40 mempko joined #perl6
20:48 kaare_ joined #perl6
20:54 mcmillhj joined #perl6
20:56 azawawi joined #perl6
20:56 azawawi hi
20:57 b2gills left #perl6
21:02 pecastro joined #perl6
21:03 azawawi timotimo: ping
21:06 HelpWithPerl joined #perl6
21:06 mcmillhj joined #perl6
21:06 HelpWithPerl Hey gus
21:06 b2gills joined #perl6
21:06 HelpWithPerl guys*
21:07 HelpWithPerl I'm having trouble using the "perl6" command on my debian machine
21:07 HelpWithPerl If I go into the location where all the perl files are stored, there is an executable called "perl6"
21:08 HelpWithPerl If I run that, I can write perl code and it works, but not otherwise
21:08 [Coke] is that diretory in your path?
21:09 bitrauser_ left #perl6
21:09 [Coke] when you say it doesn't work, can you put a copy of the error you're seeing in a nopaste somewhere?
21:09 bitrauser joined #perl6
21:10 [Coke] also may be of interest: how you installed perl6 on that box, and when you *can* run perl6, what does perl6 --version say?
21:10 [Coke] if it's https://packages.debian.org/jessie/rakudo, don't use that one
21:11 bitrauser Good UTC+01:00, everyone, and happy Squashaton :) Hope I'm not too late.
21:12 [Coke] HelpWithPerl: I'm heading out, but if you provide that info, I'm sure folks can help you
21:15 HelpWithPerl The message I'm seeing is: bash: perl6: command not found
21:15 geekosaur that just means you need to set $PATH
21:15 HelpWithPerl Ah, okay
21:16 HelpWithPerl Stupid question: how do I do that? :3
21:16 geekosaur export PATH=/path/to/the/perl6/dir:$PATH
21:16 geekosaur and add that or something similar to it to ~/.bash_profile (you may already have PATH settings in there, in which case just stick the perl6 dir at the front of the existing setting)
21:18 espadrine joined #perl6
21:19 geekosaur (it's not a great idea to put add-on packages directly in /usr/bin on most systems, that directory is owned by the system package manager and it will often find ways to mess things up if you start dropping extra stuff in it.)
21:19 geekosaur oh, if you already have ~/.profile then don't create a ~/.bash_profile, use ~/.profile instead.
21:20 mempko joined #perl6
21:20 HelpWithPerl I was just about to ask
21:20 geekosaur if you have both then you potentially have a bit of a problem, as bash will only read ~/.bash_profile in that case. (but .bash_profile may have something in it to read .profile. this is not unusual if you switch shells a lot for e.g. testing reasons)
21:21 * geekosaur does that ... but, uh. am far from the normal user case
21:22 pecastro joined #perl6
21:22 geekosaur also some linuxes give you a full set fo shell dotfiles with the common stuff in .profile and shell specific add-ons in .bash_profile, .zshprofile, etc.
21:24 mcmillhj joined #perl6
21:25 geekosaur (further confused by zsh having separate shstyle and csh-style dotfiles and they interact in weird ways)
21:26 HelpWithPerl Interesting stuff
21:26 HelpWithPerl Anyway, I've opened the .profile file
21:27 HelpWithPerl And am just wondering if there's any specific place I need to add export PATH=/path/to/the/perl6/dir:$PATH
21:27 geekosaur pretty much anywhere not inside an "if"
21:28 HelpWithPerl The first time I read that, I read it as "anywhere inside an "if"
21:30 HelpWithPerl Okay, I've added that command into .profile, and I'm trying to do the "perl6" command, but it gives the same error message
21:30 geekosaur yes, I said "and add"
21:31 geekosaur chnaging that file means it should be there next time you log in. you also have to do it in any open terminals for the current session
21:31 R0b0t1_ joined #perl6
21:33 Yes_ joined #perl6
21:35 HelpWithPerl I think I've messed something up
21:35 HelpWithPerl I don't have a bash_profile, only a .profile, so I've added the export PATH=/path/to/the/perl6/dir:$PATH to there, at the very bottom
21:35 HelpWithPerl Then I saved the file
21:36 HelpWithPerl And then I opened a new terminal, and tried to run the perl6 command
21:36 mcmillhj joined #perl6
21:38 MasterDuke HelpWithPerl: can you paste the exact line you added?
21:39 HelpWithPerl Sure: export PATH=/path/to/the/perl6/dir:$PATH
21:40 MasterDuke you need to put the acutal path there. something like: /usr/local/bin/:$PATH
21:41 geekosaur right, I don't know where you foudn the perl6 command so I tried to make it clear that you need to put that directory (not the full path to perl6 itself, just the directory part!) ther
21:42 pecastro joined #perl6
21:48 HelpWithPerl Guys
21:48 HelpWithPerl IT WORKS1
21:48 HelpWithPerl Thanks so much!
21:57 azawawi https://gist.github.com/azawawi/ec06083efcc6692463e1bf04340f6331 # a quick ::pack Benchmark of Data::MessagePack vs MsgPack
21:59 MasterDuke azawawi: that's around ruby/python/etc speed now?
22:00 azawawi MasterDuke: yup near it :)
22:00 azawawi MasterDuke: i didnt benchmark it.. let me check it :)
22:01 COMBORICO joined #perl6
22:04 COMBORICO m: my @digits = <1 2 3 6 5 4 7 8 9>; my @removed-digits = splice @digits, 3, 3, 4, 5, 6;
22:04 camelia rakudo-moar 8b24bf5cd: ( no output )
22:04 COMBORICO Oops, dang it. Forgot say.
22:07 azawawi MasterDuke: python script does it in 0.057s (25 iterations, 10k list size) vs 2.15s for the Perl 6 native version (MsgPack)
22:07 azawawi MasterDuke: at least we're getting there :)
22:08 MasterDuke cool
22:09 azawawi MasterDuke: heap corruption is still there
22:10 azawawi MasterDuke: but at higher list size counts (30_000 is the mark on my machine)
22:10 azawawi MasterDuke: this improved a lot... https://github.com/azawawi/perl6-msgpack/commit/ef0d5ba6c316e63514f9fea08461bd6ac42a93c9
22:10 MasterDuke azawawi: maybe you should .tell dogbert17, he's good at tracking those sorts of things down
22:12 MasterDuke valgrind and gdb weren't very helpful, but you could also try asan
22:12 azawawi MasterDuke: it is a nativecall thing... happens exactly here https://github.com/azawawi/perl6-msgpack/blob/master/lib/MsgPack/Packer.pm6#L25
22:13 MasterDuke azawawi: nine might also be a good person to ask, he does a lot with NativeCall
22:14 azawawi MasterDuke: either i dont fully understand the msgpack sbuffer implementation or we have a bug with nativecall buffer index lookup
22:16 mson joined #perl6
22:23 cdg joined #perl6
22:27 comborico1611 joined #perl6
22:27 comborico1611 m: @digits = <1 2 3 6 5 4 7 8 9>; my @removed_digits = splice @digits,  3, 3, 4, 5, 6; say @removed_digits; say @digits;
22:27 camelia rakudo-moar 8b24bf5cd: OUTPUT: «5===SORRY!5=== Error while compiling <tmp>␤Variable '@digits' is not declared␤at <tmp>:1␤------> 3<BOL>7⏏5@digits = <1 2 3 6 5 4 7 8 9>; my @remov␤»
22:28 comborico1611 m: my @digits = <1 2 3 6 5 4 7 8 9>; my @removed_digits = splice @digits,  3, 3, 4, 5, 6; say @removed_digits; say @digits;
22:28 camelia rakudo-moar 8b24bf5cd: OUTPUT: «[6 5 4]␤[1 2 3 4 5 6 7 8 9]␤»
22:28 comborico1611 Another typo . . .
22:39 azawawi https://travis-ci.org/azawawi/perl6-msgpack/builds/296986289  # macOS and Linux tests are now passing :)
22:42 Cabanossi joined #perl6
22:46 mcmillhj joined #perl6
22:56 mempko joined #perl6
22:58 mcmillhj joined #perl6
23:00 wamba joined #perl6
23:06 rindolf joined #perl6
23:06 cdg joined #perl6
23:12 Cabanossi joined #perl6
23:13 mcmillhj joined #perl6
23:20 cdg joined #perl6
23:23 MasterDuke .tell azawawi btw, `$packed = (^$size).map({$buffer[$_]})` should be faster than repeatedly .appending
23:23 yoleaux MasterDuke: I'll pass your message to azawawi.
23:27 mcmillhj joined #perl6
23:34 grumble joined #perl6
23:43 mcmillhj joined #perl6
23:48 Geth ¦ doc: 0333bf50e8 | (Aleks-Daniel Jakimenko-Aleksejev)++ | 3 files
23:48 Geth ¦ doc: Document LEAVE + exit trap
23:48 Geth ¦ doc:
23:48 Geth ¦ doc: Resolves #1581
23:48 Geth ¦ doc: review: https://github.com/perl6/doc/commit/0333bf50e8
23:48 squashable6 🍕 AlexDaniel++ closed issue “Using exit() when you re…”: https://github.com/perl6/doc/issues/1581
23:56 squashable6 🍕 AlexDaniel++ wrote a comment on “add invocant to glossary”: https://github.com/perl6/doc/issues/1557#issuecomment-341854661
23:56 Cabanossi joined #perl6
23:57 squashable6 🍕 AlexDaniel++ labeled issue “Discuss performance benefits of native types”: https://github.com/perl6/doc/issues/1534
23:58 squashable6 🍕 AlexDaniel++ unlabeled issue “Discuss performance benefits of native types”: https://github.com/perl6/doc/issues/1534
23:59 grondilu joined #perl6

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

Perl 6 | Reference Documentation | Rakudo