»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:, or /msg camelia p6: ... | irclog: irc.perl6.org or colabti.org/irclogger/irclogger_logs/perl6 | UTF-8 is our friend!
Set by moritz on 22 December 2015.
buggable 🎺🎺🎺 It's time for the monthly Accidental /win Lottery 😍😍😍 We have 2 ballots submitted by 2 users! DRUM ROLL PLEASE!... 00:00
And the winning number is 4! Congratulations to AlexDaniel-! You win a can of WD40!
knight__ in other words: if I 'use something' I cannot add method to something, but if I use require I can add methots/var - class variables.
?
00:03 wander joined
Geth doc/master: 4 commits pushed by (Alex Chen)++ 00:04
raschipi There are multiple ways to find names of things. The first is the lexical pad. When you use my, you're adding the name there.
00:04 mempko left
raschipi Each scope has it's own, and the compiler can look up a name in multiple of them. 00:05
00:05 mcmillhj joined
knight__ I understand, you have symbol table at some scope 00:05
scope may be block, sub, class, whatever
raschipi The second one is package lookup, when you call something with a package name Package::Corp::variable, for example. 00:06
knight__ but, can I add some vars/function to "use something" module?
00:06 callyalater left
raschipi The packages are a lot like hashes, they're called stashes in P6. 00:06
What 'use' does is to take package names and install the names into the pad 00:07
what will be installed is defined by what you're using
The third way to find a name is through method resolution
knight__ raschipi: Only names, not every symbol which I defined for exporting? 00:08
or name of module is index to scope of module?
raschipi Yes, everything that was setup to export.
Don't know anything else other than names, though. 00:09
For exporting a name and a reference is setup.
00:10 mcmillhj left, Piotr_ left
raschipi Feel free to ask anything I didn't make clear. 00:11
knight__ raschipi: Does Module have own scope?
raschipi or name of module is index to scope of module? No, it's impossible to name a scope outside of it.
knight__ I mean
you have own symbol table for every module 00:12
raschipi Yes, each module has it's own scope and it's impossible to get to it unless it sends references.
timotimo there's the package scope where things declared "our" go
you can reach that
knight__ Yep, and my module's symbol table for "use" 00:13
raschipi Perl6 will automatically take the references from the EXPORT sub and is export trait and install in the local scope. You can't get to it otherwise.
knight__ can I change it?
raschipi Yes, anything created with 'our' will be installed in both the pad and the package stash. You can get those things through the stash.
change what? 00:14
knight__ the symbol table
I will show you on python
w8
00:17 mcmillhj joined
knight__ pastebin.com/dmirnwWq 00:17
So, I made class 00:18
with a class variable
and I dynamically added "b" variable
It can be done via __dict__
Also I can add dynamically method
raschipi For classes, that is bread and butter, very easy 00:19
Or do you want to do it to packages? That is done through a Stash docs.perl6.org/type/Stash
geekosaur methods can be added at runtime via the MOP
knight__ And I think, that In case of perl6 require, I can add dynamically method/var because it is in runtime 00:20
and not compiled
raschipi A Stash is a hash you can write to, like any other Hash.
timotimo knight__: symbols from "require" and methods in classes are entirely different 00:21
raschipi What is difficult, although some are working on it, is to change the lexical pad because it's set up at compile time.
but you didn't ask for that. 00:22
00:22 mcmillhj left
knight__ raschipi: can I use Stash on "use module"? 00:23
can I change the state of compiled part? 00:24
I still dont get what is the real purpose of require.
raschipi Some are asking for a way to change the compile part at compile time, but it's not implemented yet.
knight__ raschipi: so Stash you can use only on objects which are "included via require"? 00:25
raschipi You can require something and then get to it with it's full name. Then you can set up alises for what you want to have short names.
timotimo m: say Str.WHO.^name
camelia Stash
timotimo a Stash is installed on every class, for example
most of them are empty, though
m: say Bool.WHO.perl 00:26
camelia {:!False, :True}
timotimo enums have stashes with contents
00:26 BenGoldberg joined
knight__ Ok, so only "required" objects can I stash? 00:26
Ok, so only "required" objects can I Stash?
timotimo that question doesn't make sense to me 00:27
knight__ timotimo: can I use Stash - change method for example Int?
not Inheritance, dynamic... 00:28
raschipi not for methods, you need the MOP for that.
knight__ Ok, I am reading MOP docs 00:30
but I must go to bed, see ya, and thank you.
I am only want to know diffrences from "formal way".
timotimo stash is not how methods are looked up 00:31
also, i think Stash is immutable 00:32
geekosaur perl 6 is not python, methods don't live in a package symbol table
perl 6 is also not javascript, foo["x"] (or perl 6 equivalent foo{"x"}) is not the same as foo.x 00:33
every language does this differently; trying to carry things like that over to a different language won't work
knight__ You are right, but I am trying to understand how it works in Perl.
But I have not found some docs about it. 00:34
ok, I must go!
GN!
And thank you
geekosaur docs.perl6.org/language/objects#Me...rospection 00:35
which links to a couple of docs
00:36 leah2 left
knight__ thanks 00:36
gN!
00:36 knight__ left
timotimo should probably also tell them that perls 5 and 6 differ greatly in this respect 00:38
00:39 aborazmeh joined, aborazmeh left, aborazmeh joined 00:47 Morfent joined 00:50 Merfont left
raschipi Perl6 is the only language that I know where every type of resolution uses a different method for it. All others I know reuse some for different things. 00:51
00:55 leah2 joined
Geth doc: c125a14a27 | (Alex Chen)++ (committed using GitHub Web editor) | doc/Language/grammars.pod6
Fix link
00:55
synopsebot Link: doc.perl6.org/language/grammars
00:57 llfourn_ joined 00:58 llfourn left
Geth doc: 7c39640b42 | (Alex Chen)++ (committed using GitHub Web editor) | doc/Language/regexes.pod6
Fix link
00:59
synopsebot Link: doc.perl6.org/language/regexes
01:03 mson left, Actualeyes left 01:06 mson joined 01:16 mcmillhj joined
Geth doc: 1506fe00f2 | (Alex Chen)++ (committed using GitHub Web editor) | doc/Language/regexes.pod6
Update regexes.pod6

Note that wildcard C<.> now match "\n". Rewrite comments in regexes to make it practical
01:20
synopsebot Link: doc.perl6.org/language/regexes
01:21 mcmillhj left 01:27 mcmillhj joined 01:30 cdg joined 01:31 mcmillhj left 01:34 cdg left 01:35 margeas left 01:38 wander left 01:41 mcmillhj joined 01:46 mcmillhj left 01:57 aindilis left 01:58 Herby_ joined
Herby_ o/ 01:58
02:00 cdg joined 02:01 wander joined 02:12 Cabanossi left 02:14 mcmillhj joined 02:15 Cabanossi joined 02:19 mcmillhj left 02:22 eliasr left
COMBORICO Does ?/ have a name? 02:26
raschipi Never saw that 02:29
COMBORICO It is under regex.
say ~$/ if "abcdef" ~~ / bc.e /; 02:30
evalable6 bcde
02:30 bitrauser_ joined 02:31 Herby_ left
raschipi RIght, $/, not ?/ 02:31
it's the match variable
COMBORICO Oops! Getting sleepy . . .
Match variable! Okay, thanks. How is it different than topical variable ($_) 02:33
wander I've seen "Greedy matching can be explicitly requested with the ! modifier"
m: say 'fooobar' ~~ /fo**:{1..3}obar/;
camelia Nil
wander m: say 'fooobar' ~~ /fo**:?{1..3}obar/;
camelia 「fooobar」
wander m: say 'fooobar' ~~ /fo**:!{1..3}obar/;
camelia 「fooobar」
geekosaur $_ is the target of things. $/ is the result of things (specifically, matches)
COMBORICO Hmm! I like that summary. 02:34
02:34 bitrauser left
wander I think `/fo**:{1..3}obar/` equals to `/fo**:!{1..3}obar/` 02:34
COMBORICO I'll credit your name in my textbook.
wander but oops, they don't.
geekosaur wander, ! tells ** to match as much as it can. : tells it not to allow backtracking after it commits to a match. they do interact but they're very different things 02:35
wander I don't replace ":" with "!" 02:38
02:39 bdmatatu left
wander since ":?" works well, and it said "!" is the explicit way to enable greedy matching, seems ":" should be as ":!" 02:39
02:41 astj left
wander Having tried to add "!" at other position, but no one works. 02:43
If "!" is the explicit way to enable greed, and `/fo**:{1..3}obar/` using greedy, there is a way to explicitly request greedy with "!" in the regex 02:44
02:45 troys is now known as troys_ 02:46 ilbot3 left
wander geekosaur, sorry for my aggressive expression..suddenly notice it 02:48
02:48 astj joined 02:50 Mrofnet joined 02:51 COMBORICO left 02:53 Morfent left 02:54 mcmillhj joined, Todd joined 02:56 ilbot3 joined, ChanServ sets mode: +v ilbot3
Todd Hi All! Do we have a "slurp" (to eat noisely) only it write the whole thing instead of reading the whole thing? I have tried "slop", "upchuck". I have a string with everything I want it in that I want to write to disk. www.freethesaurus.com/slurp is not help. Google give me tons of perl5 hits. 02:56
02:58 mcmillhj left
Todd Wait. Just found it: rosettacode.org/wiki/Write_entire_file#Perl_6 It is `spurt` 02:58
03:04 raschipi left 03:07 mcmillhj joined
wander Todd, docs.perl6.org/language/io#Writing_to_files 03:10
colomon more broadly, docs.perl6.org/type/IO::Path 03:11
colomon had it open to look up .modified
03:12 darkmorph left, mcmillhj left
wander colomon, there is sometimes message leading with "*", such as "* colomon had it open to look up .modified", how do you do that? 03:12
geekosaur /me 03:13
colomon typed “/me” first (I think)
wander thank you
colomon it’s instictive at this point, and my client hides it once I type it. :)
TEttinger Todd: spit is somewhat customary in lisps as the counterpart to slurp
spurt rhymes so that makes sense somewhat 03:14
03:21 mcmillhj joined
Todd I was looking for something with a sence of humor. Whoever came up with slurp (which I adore) had a sense of humor! :-) 03:21
03:26 mcmillhj left 03:30 noganex_ joined 03:33 noganex left, mcmillhj joined 03:38 mcmillhj left
TEttinger slurp I think goes way back to before perl, though I'm not sure 03:38
03:43 Cabanossi left 03:45 Cabanossi joined, mcmillhj joined 03:50 mcmillhj left 03:53 cdg left, cdg joined 03:57 mempko joined 03:58 cdg left 03:59 mcmillhj joined 04:02 wander left 04:03 mcmillhj left 04:12 TimToady left 04:13 aindilis joined, TimToady joined 04:22 aborazmeh left, wamba joined 04:26 troys_ is now known as troys 04:32 BenGoldberg left 04:38 mempko left
piojo1 I noticed something weird when making a class indexable: accessing elements via the class (not instance) as C{$key} is mis-parsed as a closure. C<x> works, and C<<$key>> even works 04:39
m: class C { method m() handles <EXISTS-KEY AT-KEY DELETE-KEY ASSIGN-KEY BIND-KEY> { state %; } }; C<foo> = 42;
camelia ( no output )
piojo1 m: class C { method m() handles <EXISTS-KEY AT-KEY DELETE-KEY ASSIGN-KEY BIND-KEY> { state %; } }; C{'foo'} = 42;
camelia 5===SORRY!5=== Error while compiling <tmp>
Autovivifying object closures not yet implemented. Sorry.
at <tmp>:1
------> 3N-KEY BIND-KEY> { state %; } }; C{'foo'}7⏏5 = 42;
piojo1 Is this a bug? 04:42
04:42 Cabanossi left 04:44 Cabanossi joined
piojo1 Oh, and being more explicit with "." to clarify that it's a method call solves the problem: 04:51
m: class C { method m() handles <EXISTS-KEY AT-KEY DELETE-KEY ASSIGN-KEY BIND-KEY> { state %; } }; C.{'foo'} = 42;
camelia ( no output )
04:52 mcmillhj joined 04:55 wander joined 04:56 mcmillhj left 05:00 khw left 05:06 mcmillhj joined 05:11 mcmillhj left 05:12 xinming_ left 05:31 mcmillhj joined 05:33 mson left
Todd Hi All, I have a mystery. Two computers with Rakudo 2017.08.1. This command gives me two separate results:my $CurlTmpFile = $?FILE.IO ~ ".tmp"; 05:35
05:35 wamba left
Todd computer 1: /home/linuxutil/CurlUtils.pm6 (CurlUtils).tmp 05:35
computer 2: /home/linuxutil/CurlUtils.pm6.tmp 05:36
I am stumped. I need the results of computer 2
05:36 mcmillhj left
ugexe use $*PROGRAM instead of $?FILE 05:36
Todd testing 05:39
./CurlUtilsTest.pl6.tmp 05:41
I need the path too
and not pl6. I need pm6 05:42
I need the name of the module, not the calling program 05:44
05:47 ivans left
Todd I whacked it with 05:51
my $CurlTmpFile = $?FILE.IO ~ ".tmp"; my $CurlTmpFile ~~ s/" "\(.*?\)//;
and just removed the extra "my" 05:52
05:56 troys left, Cabanossi left 05:58 Actualeyes joined 05:59 Cabanossi joined 06:04 mcmillhj joined 06:09 mcmillhj left 06:26 espadrine left 06:31 CacoS joined
wander .ask moritz why `say 'fooobar' ~~ /fo**:{1..3}obar/;` results differently with `say 'fooobar' ~~ /fo**:!{1..3}obar/;` 06:32
yoleaux wander: I'll pass your message to moritz.
06:36 mcmillhj joined, mempko joined 06:41 mcmillhj left
Todd Hi All, I am trying to replace leading spaces with another character. How would I modify the following to only replace leading spaces (I do not want them trimmed)? 06:45
$ perl6 -e 'my $x=" abc d e"; $x ~~ s:global/" "/x/; say $x;' xxabcxdxxe
piojo1 m: my $x = ' ab c d '; $x ~~ s/ ^' '+ //; say $x.perl; 06:47
camelia "ab c d "
piojo1 Todd: don't use :global unless you want the substitution to repeat
Todd testing 06:48
Rats, it subs all the leading spaces with a single character. 06:50
$ perl6 -e 'my $x=" abc d e"; $x ~~ s/^" "+ /x/; say $x;'
xabc d e
This is my eventual goal: 06:51
perl6 -e 'my $x=" abc d e"; $x ~~ s/^" "+ /&nbsp;/; say $x;'
wander perl6 -e 'my $x=" abc \n d \n e "; $x ~~ s:g/^^" "+ /&nbsp;/; say $x;' 06:52
if multi-line 06:53
06:53 mcmillhj joined, napo1eon joined
piojo1 Todd: by the way, that $?FILE bug is a result of this: rt.perl.org/Public/Bug/Display.html?id=128442 06:54
Todd: as wander said, ^^ and $$ are for matching the start/end of a line. ^ and $ match the start/end of the whole input. 06:55
Todd not multiline. "^^" still replaces all the spaces with a single character.
piojo1 oh, I see the problem now. I suggest using code to count the number of spaces you matched 06:57
06:57 wander left 06:58 mcmillhj left
Todd Thanks for the bug url. Mean I's not losing my mind. Well, any more than I already ... 06:58
piojo1 I'll give an example in a moment...
Todd I am try to split the string into and array and reassenbling it. What a pain!
piojo1 no need. you can put the spaces in a match group (one match per space), then count the number of matches 06:59
when you have that, add back the nbsp;:
m: say 'nbsp' x 3
camelia nbspnbspnbsp
Todd did you say you had an example? 07:01
piojo1 removing some crap from it...
TEttinger m: my $x=" abc \n d \n e "; $x ~~ s:g/^^" " /&nbsp;/; say $x; 07:02
camelia &nbsp; abc
&nbsp; d
&nbsp; e
piojo1 m: my $x=" abc d e"; $x ~~ s/^ (' ')* /{ say "matched $0.elems() spaces"; "&nbsp;" x $0.elems; }/; say $x;
camelia matched 2 spaces
&nbsp;&nbsp;abc d e
07:03 rindolf joined
piojo1 TEttinger: I think the issue is to replace more than one leading space, not to do a per-line change 07:03
TEttinger I'm not totally sure what the question is here, what I pasted was an attempt to only remove the initial leading space
07:03 wander_ joined
TEttinger that's what I gathered from <Todd> Rats, it subs all the leading spaces with a single character. 07:03
piojo1 Todd: my example is printing both $x and debugging output, but you can ignore the debugging output. It should replace $x as needed 07:04
Todd I want to change each space into `&nbsp;`
testing
TEttinger err
each leading space, or every space?
and I don't know quite what leading means here, if it's the first space on a line or the first space in a string or the first section of spaces before a non-space char 07:06
wander_ m: my $x=" abc \n d \n e "; $x ~~ s:g/^^(" ")+ /{"&nbsp;"x$/[0].elems}/; say $x;
camelia &nbsp;&nbsp;abc
&nbsp;&nbsp;&nbsp;d
&nbsp;&nbsp;e
wander_ Todd, ^^
Todd $ perl6 -e 'my $x=" abc d e "; $x ~~ s:g/^^(" ")+ /{"&nbsp;"x$/[0].elems}/; say $x;' 07:07
&nbsp;&nbsp;abc d e
perfect! Thank you! How in the world did you figure that out?! 07:08
07:08 AlexDaniel joined, mcmillhj joined
wander_ you need more information of the match, so do a capture 07:08
and to get the exact match 07:09
Todd Yo guys have created a monster! 07:11
&nbsp;&nbsp;Used Dev Size : 1855871108 (1769.90 GiB 1900.41 GB)<br>
07:13 mcmillhj left
Todd This stuff is working so well, I am about to giggle. 07:13
07:18 rindolf left 07:21 rindolf joined
piojo1 Todd: perl6 regexes are complicated, but awesome. But I recently discovered a lot of the perl6 grammar power exists in perl5, but you had to use weird syntax and modifiers to make it work 07:25
The power has been brough forward, so it's a first class part of the language.
Todd My first YUGE programming efforts were about 30 years ago with Pascal and Modula2. Now I do a lot of Sys admin work and I write myself a lot of stuff. I use to do it in bash and batch. What a pain in the neck. So I moved to Perl. I hvae been programming Perl5 for a while when moved to Perl 6. I adore Perl 6. (The subs in p5 drives me nuts [@_]). I am not doing any new code in p5. Transitioning from Modula2 to Perl gave me a migra 07:29
07:30 wander_ left
Todd top down, for which I am very grateful. Some p5 guys are crabby about p6. I don't get it. Soon as I got a load of p6, I dropped P5 like a hot potato. 07:30
07:33 mcmillhj joined 07:37 mcmillhj left 07:45 mcmillhj joined 07:50 mcmillhj left
Todd Is "slurp" support to create a file if it does not exist? 07:52
07:53 wander joined
AlexDaniel no 07:53
Todd rats!
Thank you!
07:57 mcmillhj joined
AlexDaniel m: dd Rat xx 10 07:57
camelia (Rat, Rat, Rat, Rat, Rat, Rat, Rat, Rat, Rat, Rat).Seq
07:57 Util joined 08:01 mcmillhj left 08:04 mempko left
Todd :-) 08:04
08:11 wamba joined 08:12 Cabanossi left 08:14 Cabanossi joined 08:17 setty1 joined 08:21 mtj_ joined
wander m: sub f { "hello" }; say &f.CALL-ME(); 08:24
camelia No such method 'CALL-ME' for invocant of type 'Sub'
in block <unit> at <tmp> line 1
wander ^^ surprised
08:29 mcmillhj joined
AlexDaniel squashable6: next 08:29
squashable6 AlexDaniel, ⚠🍕 Next SQUASHathon in 2 days and ≈1 hour (2017-11-04 UTC-12⌁UTC+14). See github.com/rakudo/rakudo/wiki/Mont...Squash-Day
08:30 releasable6 left, releasable6 joined 08:33 mcmillhj left, wander left 08:40 jonas1 joined, mcmillhj joined 08:42 Cabanossi left 08:44 Cabanossi joined 08:45 mcmillhj left 08:51 parv joined, mcmillhj joined 08:52 zakharyas joined, sproctor joined 08:53 ivans joined 08:54 sproctor left 08:56 mcmillhj left 08:57 sproctor joined
Todd Bye Bye. Thank you all so much. You guys heped me complete an over a month long progject. 09:01
09:01 Todd left 09:03 mcmillhj joined 09:07 Piotr_ joined, mcmillhj left 09:09 AlexDaniel left
moritz good morning 09:13
yoleaux 06:32Z <wander> moritz: why `say 'fooobar' ~~ /fo**:{1..3}obar/;` results differently with `say 'fooobar' ~~ /fo**:!{1..3}obar/;`
moritz why wouldn't it? it's not the same regex :) 09:14
with : you disable backtracking, so the first part matches all o's, causing the "obar" to fail 09:16
with ! you re-enable it, so the quantifier can give up the extra o again
:! seems kinda non-sensical
09:18 TheGrimFandango joined 09:19 espadrine joined 09:20 TheGrimFandango left, TheGrimFandango joined 09:27 TheGrimFandango left
moritz huh 09:27
Invalid json? File: /root/.zef/store/Grammar-ErrorReporting-0.2.tar.gz/Grammar-Error-Reporting-0.2/.gitignore
09:27 TheGrimFandango joined
moritz I never expected my .gitignore to be valid json... 09:27
09:27 Ven joined, wamba left 09:28 Ven is now known as Guest37250 09:29 TheGrimFandango left, TheGrimFandango joined 09:30 robertle joined 09:31 TheGrimFandango left, TheGrimFandango joined 09:33 TheGrimFandango left, TheGrimFandango joined 09:35 TheGrimFandango left, TheGrimFandango joined 09:37 TheGrimFandango left, TheGrimFandango joined 09:39 notostraca joined 09:40 knight__ joined, TEttinger left 09:45 TheGrimFandango left, TheGrimFandango joined
knight__ hello, what does WARNING: unhandled Failure detected in DESTROY. mean? 09:46
09:47 TheGrimFandango left, TheGrimFandango joined
moritz it means that something failed in a destructor 09:47
and since the destructor is called from the garbage collector, there is no caller which could receive an exception 09:48
09:49 TheGrimFandango left, TheGrimFandango joined 09:51 TheGrimFandango left, TheGrimFandango joined, Actualeyes left 09:53 TheGrimFandango left
sproctor @moritz is .gitignore not the first line in your .gitignore? 09:53
(Also looking forward to the Grammars book :) )
09:53 TheGrimFandango joined
knight__ I am lost with this require, when I use last perl6 Rakudo version 2017.09-489-g6ad06fad9 09:53
somehow it works 09:54
but
when I use 2016.12 built on MoarVM version 2016.12
nope
09:55 TheGrimFandango left, TheGrimFandango joined 09:56 Cabanossi left 09:57 TheGrimFandango left, TheGrimFandango joined
knight__ Can someone look to my code bitbucket.org/najt/perl_project/co...st_require ? I do not know what shall I do... 09:58
?
09:59 TheGrimFandango left, Cabanossi joined, TheGrimFandango joined
DrForr When someone else installs your module the build process should pick up dependencies, I wouldn't really go to that much trouble to catch errors. 10:02
(also, "omg" doesn't really help me understand what your problem is...) 10:03
knight__ Yep, but my task is something like: When I have not installed depends, you program should work for case ./program -h -> should shows the help message.
/usr/bin/perl6 main.p6 --buy-sell='buy' --currency=CZK --date="2015-10-09" 10:04
===SORRY!=== Error while compiling /home/a/Skola/PJS2/projekt/perl/main.p6
Undeclared names: MBANK used at line 65 NBP used at line 64 NBPref used at line 63
/usr/bin/perl6 --version
This is Rakudo version 2016.12 built
DrForr lib/MBANK.pm6 and class MBANK::MBANK don't quite work together. 10:07
moritz sproctor: the .gitignore file is under version control, so it doesn't list itself 10:09
sproctor Oh. See I generally don't put mine in the repo. Different strokes I guess. 10:10
DrForr Convention would be to create lib/MBANK/MBANK.pm6 in your case, then the require() call would be looking for the correct file.
moritz sproctor: if you don't put it under version control, you can place it in .git/config/exclude
DrForr Also just a personal question - --currency=CZK - do you by chance hail from Czechia? If so, ahoj from Prague :) 10:11
knight__ :-D Cau, ale som zo Slovenska 10:12
nine knight__: replace "require" by "use" and don't try to handle dependency errors. If the default error message for an unsatisfied dependency can be improved, please let us know, so we can fix it for everyone. 10:13
knight__ nine: I cannot, because this is my TASK by my professor. If some "perl" develop can send him mail about it. 10:14
10:14 araujo left
knight__ :-) 10:14
DrForr Okay, now I'm *really* curious :) An actual programming class using Perl 6. I've got a retrospective meeting right now, but I'm *really* curious about this school, where it is, how we can help... 10:15
knight__ He teaches Perl5, but I want Perl6. 10:16
and :-X
moritz knight__: maybe show us how you use the module that you import? 10:21
10:21 aborazmeh joined, aborazmeh left, aborazmeh joined 10:22 wander joined 10:23 TheGrimFandango left, TheGrimFandango joined
knight__ moritz: In module I have a class, I am calling class and making instance of it 10:24
bitbucket.org/najt/perl_project/sr...ew-default
10:25 TheGrimFandango left
knight__ "use module" version ^ 10:25
10:25 TheGrimFandango joined
El_Che knight: a reason you use that specific version? I see debian 9 an ubuntu 17.04 have it 10:25
10:26 astj left
knight__ moritz: I make @ with instances of bank 10:26
10:26 astj joined, astj left, astj joined
knight__ and calls methods in map 10:26
So, I am changing online inner state of Objects
s/online/only 10:27
El_Che: do you mean This is Rakudo version 2016.12 ?
It is from Debian repo
Description:Debian GNU/Linux 9.2 (stretch) 10:28
10:28 Aaronepower joined
knight__ I have compiled new version from repo via rakudobrew 10:28
El_Che In case you're using newer feature, I have debian packages available
knight__ This is Rakudo version 2017.09-489-g6ad06fad9
El_Che github.com/nxadm/rakudo-pkg
knight__ require version works, but 10:29
10:29 TheGrimFandango left
knight__ I have problem with destructor DESTROY something... 10:29
moritz knight__: I think at this point, the easiest way to catch the error is to do something like
10:29 TheGrimFandango joined
knight__ what I mentioned, when I joined here 10:29
moritz BEGIN { try { require module1; require module2; .. } # handle errors here }
and then do the regular "use" calls below that 10:30
knight__ but It will not solve one thing
if someone call ./program -h
and you have not dependencies
it will crash
or it will not work
am I right?
moritz right 10:31
10:31 TheGrimFandango left
moritz ok, let my try to eplain some more background 10:31
10:31 TheGrimFandango joined
moritz in Perl 5, the compiler looks for symbols such as class names in the symbol table 10:31
Perl 6 tends to look in lexical scopes more 10:32
but, lexical scopes are immutable at run time
so, in Perl 5, when you do a "require Foo" followed by Foo->import(), thins Just Work[tm]
that is, you get all the symbols that a "use Foo;" would import
it can't work that way in Perl 6 10:33
if you do a require Foo; in Perl 6
then *only* the symbol Foo is available in the caller's scope
because that's the only symbol that the compiler knows about at compile time
so now you have two options 10:34
specify all the symbols that you need as literals in the call to require
or, work from the one symbol you have
10:35 TheGrimFandango left
moritz if for example Foo exports a subroutine bar, you can do a require Foo <&bar>; 10:35
10:35 TheGrimFandango joined
moritz or if use'ing MBANK makes MBANK::MBANK available, you might have to access it explicitly through the symbol table 10:36
require MBANK;
MBANK.WHO<MBANK>.new
instead of MBANK::BANK.new
10:37 TheGrimFandango left, steeznson joined
pmurias bartolin: github.com/rakudo/rakudo/issues/1225 10:37
10:37 TheGrimFandango joined 10:39 wander left
knight__ moritz: Thank you! 10:39
nine moritz, knight__: why not just move all the relevant (module using) code into a module and have the main script be something like: if check-requirements() { load-main-module(); } else { print-nice-help-text(); }? 10:40
Then you can still use "use" and all the automatic symbol loading in the main module _and_ have your error message if requirements are missing 10:41
knight__ nine: because it is another task, I mast make modules :-)
must*
och 10:42
sorry
I mean different
moritz nine: I think the idea is to offer reduced functionality when some modules are not available
nine moritz: and my idea is to split the functionality of the program into parts that are only loaded when their respective requirements are met. My example code split the program into the parts "do-something-useful and print-helpdesk" but it can be split in other ways, too. 10:44
10:46 notbenh joined 10:47 wander joined
nine Did I actually write "print-helpdesk"? I meant "print-helpmessage" of course :) 10:50
wander moritz, so can I say, in ":!", "!" override ":"? does it imply we can only have one modifier on quantifier?
10:51 TheGrimFandango left, TheGrimFandango joined
moritz nine: a 3D printer could print a literal help desk :-) 10:53
10:53 TheGrimFandango left, TheGrimFandango joined
moritz wander: yes, and I think so 10:53
:! is like "give me less! No, more!" :-) 10:54
10:56 raschipi joined
knight__ moritz: One question, what If I use require in in my module e.g MBANK? 10:57
I mean installed via CPAN
some modules
So, in module MBANK I use require HTTP::Tinyish;
wander thank you 10:58
moritz knight__: the same rules apply inside modules 10:59
10:59 bdmatatu joined
moritz afk 11:02
wander I am looking for the implementation of hyper operator "»". Anyone knows its location? Maybe rakudo/rakudo/src/... 11:04
11:04 setty1 left 11:07 margeas joined, bdmatatu left, mr-foobar left
jnthn wander: It'll be in at least 3 places: Grammar.nqp for the parsing, Actions.nqp for code-gen, and the code-gen largely just emits calls to some functions in CORE.setting probably in metaops.pm 11:08
wander thanks 11:09
11:10 literal joined, avar joined, avar left, avar joined
wander I've seen them. 11:14
11:14 parv left 11:17 ilmari left 11:28 Cabanossi left, Aaronepower left 11:29 steeznson left, Cabanossi joined 11:35 TheGrimFandango left, TheGrimFandango joined 11:37 TheGrimFandango left, TheGrimFandango joined 11:46 Guest37250 left 11:51 leah2 left 11:56 piojo1 left, leah2 joined 12:00 knight__ left 12:03 TheGrimFandango left, TheGrimFandango joined 12:05 TheGrimFandango left, TheGrimFandango joined 12:07 TheGrimFandango left, TheGrimFandango joined
Geth doc: 79adcdef4f | (Alex Chen)++ (committed using GitHub Web editor) | doc/Language/regexes.pod6
Improve example of quantifier's modifier

  `:?` is non-sensical
12:07
synopsebot Link: doc.perl6.org/language/regexes
12:08 Ven joined 12:09 darutoko joined, TheGrimFandango left, Ven is now known as Guest67908, TheGrimFandango joined 12:12 bdmatatu joined 12:13 TheGrimFandango left, TheGrimFandango joined 12:15 mson joined, TheGrimFandango left, TheGrimFandango joined
wander m: say [1,2,3]>>( &sin ); 12:17
camelia Too many positionals passed; expected 1 argument but got 2
in block <unit> at <tmp> line 1
wander m: say [1,2,3]>>.( &sin );
camelia No such method 'CALL-ME' for invocant of type 'Int'
in block <unit> at <tmp> line 1
wander m: say [1,2,3]>>.&sin;
camelia [0.841470984807897 0.909297426825682 0.141120008059867]
wander what are the details about "Too many positionals passed; expected 1 argument but got 2" 12:19
12:20 Guest67908 left 12:22 wamba joined 12:25 wander left 12:27 Cabanossi left, TheGrimFandango left, wamba left, TheGrimFandango joined, Exodist left
raschipi m: sub joinsay { @_>>.gist.join('---').put }; [1,2,3]>>( &joinsay ) 12:28
camelia 1---sub joinsay (*@_) { #`(Sub|62261368) ... }
2---sub joinsay (*@_) { #`(Sub|62261368) ... }
3---sub joinsay (*@_) { #`(Sub|62261368) ... }
12:29 Cabanossi joined, TheGrimFandango left
raschipi Why is it adding a reference as the second argument I don't know. 12:29
12:29 Exodist joined, TheGrimFandango joined
raschipi m: sub joinsay { @_>>.gist.join('---').put }; say [&sin,&cos,&tan]>>.( &joinsay ) 12:30
camelia Cannot resolve caller sin(Sub); none of these signatures match:
(Numeric \x)
(Cool \x)
(num $x --> num)
in block <unit> at <tmp> line 1
raschipi m: sub joinsay { @_>>.gist.join('---').put }; say [1,2,3]>>.( &joinsay ) 12:33
camelia No such method 'CALL-ME' for invocant of type 'Int'
in block <unit> at <tmp> line 1
raschipi m: say [&sin,&cos,&tan]>>.( 3 ) 12:34
camelia [0.141120008059867 -0.989992496600445 -0.142546543074278]
12:37 wander joined 12:41 zakharyas left 12:43 TheGrimFandango left, TheGrimFandango joined 12:45 TheGrimFandango left, TheGrimFandango joined 12:46 Ven_ joined
wander maybe in this case, >> works like github.com/rakudo/rakudo/blob/6389...#L487-L493 12:46
but I cannot trace then, see no how deepmap/nodemap work 12:47
that might be the reason why adding function reference exists 12:48
12:53 zakharyas joined 12:59 mcmillhj joined 13:01 Khisanth left
raschipi deepmap and nodemap are in Any 13:02
wander but not in detail 13:03
13:05 cdg joined 13:10 cdg_ joined
raschipi codesearch.debian.net/search?q=pac...o++nodemap I can see an implementation in src/core/metaops.pm line 658 13:11
13:12 Cabanossi left 13:13 Khisanth joined, cdg left 13:14 Cabanossi joined, kyan joined
wander seen 13:15
13:16 Piotr_ left 13:27 ilmari joined 13:30 zakharyas left
wander m: sub see-what-pass { dd @_; }; [1,2,3]>>( &see-what-pass ); 13:35
camelia [1, sub see-what-pass (*@_) { #`(Sub|60245232) ... }]
[2, sub see-what-pass (*@_) { #`(Sub|60245232) ... }]
[3, sub see-what-pass (*@_) { #`(Sub|60245232) ... }]
13:37 darkmorph joined
wander m: sub postfix:<!> { dd @_; }; [1,2,3]>>!; 13:37
camelia [1]
[2]
[3]
wander how to test a sub trait, that is, &func.is-nodal(True/False) or something 13:41
perlpilot m: sub foo is nodal {}; say &foo.nodal 13:44
camelia True
perlpilot m: sub foo {}; say &foo.nodal; # for completeness :)
camelia No such method 'nodal' for invocant of type 'Sub'
in block <unit> at <tmp> line 1
13:45 telex left
perlpilot oh, that's interesting 13:45
raschipi m: sub foo {}; say &foo.?nodal;
camelia Nil
perlpilot yeah, do that :)
13:48 aborazmeh left, japanoise joined
japanoise Hi, I'm doing an article on programming languages. I'm interested in if anyone knows of a big killer-app written in p6. Something that would make it essential to have a p6 environment installed. In the spirit of this article: prog21.dadgum.com/35.html 13:49
13:50 kyan left
tyil does perl 6 itself count? ;) 13:51
japanoise no
tyil :(
japanoise self-hosting is a requirement to be a respectable language, not an interesting project
13:51 wamba joined
raschipi Perl6 isn't self-hosted either... 13:52
perlpilot japanoise: there are no big anything written in Perl 6 yet that I'm aware of.
raschipi yet
Altreus get on with it then
japanoise hmmm, dang, thanks for the help perlpilot and raschipi. I'll lurk in case someone else knows of one
13:53 telex joined
raschipi Well, not public software anyway.There is someone who runs a radio on Perl6, but they won't release it. I don't even see why a language should have any focus on public software to be considered interesting. 13:56
timotimo Cro has the potential to be pretty killer
14:01 Mrofnet left 14:02 Mrofnet joined
DrForr japanoise: No need to sit around waiting, go out there and do the big thing! :) 14:03
14:04 Ven_ left
tyil most things that need a big project already have one, no need to duplicate an existing big project just so we can say its doable in perl 6 I think 14:04
Juerd stackoverflow.blog/2017/10/31/disl...languages/ # painful 14:05
jnthn Successful big projects don't usually just appear out of nowhere. They tend to grow out of small projects. :)
mspo yeah who are all of these people explicitly hating on perl? 14:06
Juerd mspo: I like to think they're all beginning programmers who feel intimidated by its power, but I fear it's a rather widespread hate. 14:08
14:08 tpoikela joined
Juerd Explicit Perl hate has been going on for several years now, at least in the European hackerspaces and hacker congresses that I've visited. 14:08
14:09 jdv79_ is now known as jdv79
jdv79 why is forking a bad idea in rakudo? i believe i remember someone said that the other day. 14:10
ugexe because it’s multi threaded
wander perlpilot, thank you 14:11
DrForr Juerd: I've seen it in person as well at Open Source Days. 14:12
tpoikela anyone had issues with 'perl6 -c' being stuck on lengthy grammar file? 14:13
jnthn jdv79: Because the forked child will be missing all but one of its threads, and so will usually deadlock in short order (like, the next time it tries to GC and wants to sync the threads up). 14:14
14:14 lowin left
DrForr tpoikela: I've had issues but not with the -c file, and not in a while. 14:14
s/file/flag/
Juerd DrForr: I almost cried when thousands of attendees cheered at this slide pbs.twimg.com/media/CXby58QU0AEoYGD.jpg 14:16
tpoikela If I introduce a syntax error, it's flagged correctly. Once I correct the syntax, 'perl -c' does not finish in ~5 mins
14:17 aindilis left
Juerd ^ from 32c3 presentation "The Perl Jam 2" by Netanel Rubin, full talk at media.ccc.de/v/32c3-7130-the_perl_jam_2 14:17
Beware, it's a rather hateful presentation.
DrForr I'm not surprised.
14:17 aindilis joined
Juerd But, it was one of the most popular talks of that congress and I think it's wise if the Perl community (or communities?) stopped ignoring this... 14:18
It's also the primary reason why I think Perl 6 has a much better chance of survival with a different name.
DrForr Oh, it's *that* speech. Arse acts as if 15-year-old barely-perl4 code is modern Perl. 14:19
El_Che Juerd: we learnt to ignore trolls
(while I agree about the naming, for other reasons) 14:20
sjn Juerd: I actually talked about those talks at GPW in Nüremberg last year. Even there, a lot of people weren't aware about that presentation 14:22
jdv79 jnthn: that seems odd but ok. i thought there was a way to fork off and retain all threads.
raschipi jdv79: There's no such thing. 14:23
14:23 tpoikela left
jdv79 oh, i guess its just a solaris thing 14:24
Juerd sjn: Good illustration of the divide between the Perl community and the larger software hacking community.
jdv79 i never tried it but i vaguely remember somthing about it. but ok. just curious. 14:25
Juerd If Perl 6 (and 5, for that matter) is to be a success outside our echo chamber, I think these trolls should be addressed instead of ignored, but that doesn't seem to be a popular opinion. 14:26
raschipi In Solaris you'll have to use their interfaces exclusively to get that feature. I think there's not much interest in a non-portable runtime. 14:27
14:27 Cabanossi left 14:28 troys joined
sjn Juerd: I'd love to hear your opinions on my talk, btw. :) www.youtube.com/watch?v=tpOZCTBvs70 14:28
14:29 Cabanossi joined
DrForr Well, I know I didn't get much traction at Open Source Days or DevDays Vilnius - Copenhagen was only worth meeting friends really, and if Vilnius weren't paid for I wouldn't have gone. 14:30
Juerd sjn: I will watch it and let you know later 14:32
14:37 AlexDaniel joined
AlexDaniel .u 🕷 14:37
yoleaux No characters found 14:38
AlexDaniel u: 🕷
unicodable6 AlexDaniel, U+1F577 SPIDER [So] (🕷)
14:41 Ven joined, Ven is now known as Guest82369 14:44 cgfbee left, wamba left 14:45 TheGrimFandango left, TheGrimFandango joined 14:46 awwaiid left, mempko joined 14:47 TheGrimFandango left, TheGrimFandango joined 14:48 zakharyas joined 14:49 raschipi left 14:53 cgfbee joined, M-Illandan joined
ugexe Juerd: i think some rather address the trolls with implementation than superficial issues like name (where changing it will not result in less trolls, only different ones) 14:53
14:54 mack[m] joined
[Coke] When I talk with other developers, I usually include "yes, the name is definitely confusing, but try the actual language, it's amazing." 14:54
mspo "types are cool but sigils are not" 14:55
"symbols are hard to understand but whitespace is easy to see" 14:56
"I don't know what CGI is" 14:59
;)
DrForr Hey, we just had someone here this morning saying that they were learning programming with Perl 6. 15:01
15:02 pilne left
Juerd ugexe: I personally know several people who don't want to even try the implementation because it's Perl, and they don't want to be a Perl programmer because Perl is dead, sucks, etc. 15:04
jdv79 that's harsh 15:05
Juerd ugexe: It may be superficial, but its effect has worried me for a decade and continues to do so.
ugexe and yet we also have recent interviews with people like Garu who have stated people are showing up to Perl meetings because of Perl 6. Which is what i've personally always idealized
Juerd ugexe: And during that decade I've only seen confirmation of the effects.
mspo there are stigmas for groups 15:06
they're never going away. You're either on-trend or not.
15:07 pmurias left
Juerd In any case, StackOverflow presents us with the clear statistic that among their users, Perl seems to be the most disliked programming language 15:07
lizmat well, it's the most in something then, as Zoffix tweeted :-) 15:08
timotimo i read the article a bit
Juerd That's not trolling, and there may be statistical biases (positive interpretation: at least everybody knows Perl exists).
timotimo there's also the possibility that people who used to work with X will put X in their "disliked technologies" box if they simply "moved on"
AlexDaniel I thought it simply means that people don't want to deal with it 15:09
wander m: my $neighbors = ((-1, 0), (0, -1), (0, 1), (1, 0)); my $p = (2, 3); say $neighbors »»+«» ($p, *);
camelia ((1 3) (2 2) (2 4) (3 3))
AlexDaniel squashable6: next
squashable6 AlexDaniel, ⚠🍕 Next SQUASHathon in 1 day and ≈18 hours (2017-11-04 UTC-12⌁UTC+14). See github.com/rakudo/rakudo/wiki/Mont...Squash-Day
mspo I didn't realize there were enough perl jobs left to distriminate so actively
but it's a damning post nevertheless
wander interesting, how does, in the world, chaining hyper work 15:10
mspo I'm positive very few of those people have ever worked with perl but oh well
wander m: my $neighbors = ((-1, 0), (0, -1), (0, 1), (1, 0)); my $p = (2, 3); say $neighbors »»+«» ($p);
camelia ((1 2) (3 2) (2 3) (4 3))
DrForr You could easily turn it around and say "I don't want admin work, and Perl keeps showing up for those, so adding 'perl' to the Dislike column filters out admin work." Probably too long to be viable. 15:11
timotimo haha 15:12
Juerd DrForr: Sure, spin it any way you feel comfortable with...
DrForr Shrug.
AlexDaniel m: my $neighbors = ((-1, 0), (0, -1), (0, 1), (1, 0)); my $p = (2, 3); say $neighbors »»»»»+»»»»» ($p, *); 15:13
camelia ((1 3) (2 2) (2 4) (3 3))
AlexDaniel cool
Juerd AlexDaniel: Whoa, that line would need a 12 line comment block to explain what it does :) 15:14
[Coke] isn't that the same as »+» ? 15:17
DrForr It's now made it to The Register - t.co/4txaClU0jS
lizmat "Take from this what you may: it's perhaps worth noting that The Register proudly runs on Perl." 15:18
mspo the fact that ruby has fallen so quickly is just a show how weird this survey is 15:19
timotimo on the register survey perl is barely ahead of VB and Java
tyil >people who've never used perl and hear other people who've never used perl talk negatively on perl, say perl is bad 15:20
nothing new to me
15:21 pmurias joined
AlexDaniel DrForr: and on that page in the survey people hate perl as much as they hate Java and Visual Basic 15:22
wander [Coke], it's the same, but `say $neighbors »»+«» ($p);` means?
timotimo java is doing very well, though, in total
tyil DrForr: would've been nice if they'd show some cleaner code in the article tbh 15:24
15:28 callyalater joined
DrForr tyil: People that write clean code are inside the echo chamber, most others see Matt's Script Archive-level code. 15:29
pmurias Juerd: on the positive side that means Perl is 80% liked?
lizmat japh's and obfuscated Perl code contests didn't help either :-(
ugexe visual basic has 80% dislike but is in a different table 15:30
mspo it's not like most python code rolling around is any good :) 15:33
wander .ask AlexDaniel can you please explain how `$neighbors »»+«» ($p, *)` executes? 15:34
yoleaux wander: I'll pass your message to AlexDaniel.
15:36 raschipi joined
AlexDaniel wander: actually I don't know. Seems like * is not needed and it works if you pass ($p,) 15:38
yoleaux 15:34Z <wander> AlexDaniel: can you please explain how `$neighbors »»+«» ($p, *)` executes?
AlexDaniel wander: and also the inner »« make no difference, at least in this case 15:39
[Coke] I'm not sure what we can do to help people like our language other than make a great language. we're not going to get that far away from the name, so anyone who hates perl can still hate us even if the front door has a piece of paper taped over the word perl.
tyil [Coke]: just create nice projects and show the power of perl I guess
AlexDaniel we can actually have a usable alternative name if we stop the internal naysaying 15:40
wander Grammar is quite powerful in my recent tasks :) 15:41
[Coke] AlexDaniel: Sure, just give us a name that we can all agree on.
AlexDaniel 6lang
raschipi can't start with a digit
AlexDaniel it can.
[Coke] I would prefer not.
raschipi TIMTOWDY said no digits
starting with digits makes it an invalid identifier 15:42
AlexDaniel who said that it has to be a valid identifier
tyil not in perl 6
:'D
or does it
AlexDaniel and that you cannot use sixlang where it really has to
wander slang, XD 15:43
lizmat "Perl Reinvented" # how's that for a name :-)
tyil lizmat: sounds like perl++
but then we have the bad connotations of perl AND c++
raschipi Larry Wall said it has to be a valid identifier
wander lol
15:43 sjoshi joined
[Coke] I still don't agree with the premise that calling it something other than Perl 6 is actually going to be beneficial on the whole. You're certainly not going to win over anyone who already hates it just because it's *called* Perl. It's still a perl, even if you call it something else. 15:43
AlexDaniel it doesn't have to be a valid identifier. I said that.
15:43 sjoshi left
raschipi that means you're wrong 15:43
AlexDaniel /o\
lizmat "Same Old Wine In A Brand New Bottle" # naysayers argument 15:44
tyil I think we could better spend our time working on projects showing the cool perl 6 stuff
instead of debating what to call it
[Coke] lizmat: right.
lizmat agree
AlexDaniel [Coke]: I have these conversations all the time. “What did you use to do that?” “Perl 6” “Huh, *perl*…”
[Coke] I get that on the surface it seems like it'll help, but I remain unconvinced.
AlexDaniel give me something that has no “perl” in it and it will solve the confusion 15:45
tyil japanoise was looking for a cool perl 6 project, but we don't have any, instead we're here arguing how to call it
instead of making that project
[Coke] AlexDaniel: Sure, me too. And I then have a conversation about it.
raschipi besides, no one can even convince the others, how are they going to convince TimToady who still prefers Perl6?
AlexDaniel [Coke]: I'd much rather not have a conversation about a goddamn name and how we got here
raschipi: TimToady seems to be fine with the idea of having alternative marketable name 15:46
raschipi: or at least that's how I understood it.
15:46 jonas1 left
[Coke] I only see those conversations getting more involved once there's a name change. 15:46
raschipi Well, to have an effect we would have to hide Perl6.
tyil do we?
AlexDaniel we don't.
tyil or do we just need to show how awesome it is? 15:47
and then reveal the name?
15:47 TheGrimFandango left
pmurias AlexDaniel: are you having those conversations while talking with real people or on reddit etc.? 15:47
AlexDaniel pmurias: real life
tyil if you can show something cool, and make people ask "what lang is that", and you can say its perl 6, people will have no issues with it
15:47 TheGrimFandango joined
DrForr Then to misquote a T-shirt, "F*ck up some code." 15:48
perlpilot tyil: it would be neat if someone did presentations like that (with a name reveal at the end) at varioius conferences.
*various 15:49
15:49 TheGrimFandango left
tyil perlpilot: if I were any good at presenting and perl I'd consider it 15:49
15:49 aindilis left, TheGrimFandango joined
AlexDaniel fwiw 6lang.org 15:49
15:49 eliasr joined 15:50 domidumont joined
tyil now we have 3 different domains all pointing to the same resource 15:51
15:51 mr-foobar joined
tyil that'll confuse more than solve the issue I think 15:51
AlexDaniel what's the third?
tyil didnt rakudo get its own domain as well for it?
AlexDaniel rakudo is a compiler, 6lang is a language 15:52
15:52 kyan joined
tyil except some use Rakudo to refer to the language as well now 15:52
AlexDaniel hopefully not
lizmat I think we need to rephrase Godwin's law: "As an on-line discussion grows longer, the probability of a comparison involving the naming of Perl 6 approaches 1.
tyil this entire naming debate only fractures the community further and makes things more confusing for possible new perlers
lizmat "
AlexDaniel but I'm saying that there we have it, a domain name that's already ours, with a name that's unique enough to be googlable, short and rememberable to be marketable, etc. etc. 15:53
15:53 TheGrimFandango left
tyil and one that still not everyone agrees with 15:53
AlexDaniel and then I see this nonsense about it not being a valid identifier. Out of all issues, is it really worth considering?
15:53 TheGrimFandango joined
pmurias one could argue that Rakudo actually implements the Rakudo language not Perl 6 as roast which is supposed to be the spec has loads of fudges (sometimes even for things that are contradictory/don't make sense) 15:53
tyil all I want is for people to stop arguing about the name tbh 15:54
and just make something cool
[Coke] I could care less about the identifier. Don't particularly care for it.
tyil: well, this is the wrong project for that. :)
tyil :(
[Coke] we've been arguing about it for 17 years already.
(out for lunch, later!) 15:55
tyil then its a good time to stop :)
15:55 TheGrimFandango left, TheGrimFandango joined
AlexDaniel yeah, we now finally switched to “master”, there's a usable issue tracker for those who can't work with RT, maybe it's time to actually do something about the name 15:55
perlpilot AlexDaniel: like ... leave it alone? :> 15:56
AlexDaniel perlpilot: that doesn't solve the every day problem I have
which is “perl 6” being confused with perl (5)
15:56 domidumont left
tyil AlexDaniel: I understand your problem, I am facing it at almost every meetup myself, but if we can just show something cool we made and then reveal its perl 6, that'd work a lot better than starting to talk about it and all the cool stuff you could do with it, but nobody does 15:57
15:57 domidumont joined
AlexDaniel I do something cool with perl 6 all the time, people still remember that I've done it with “perl” 15:57
and I don't have 10 minutes every time to explain why it's “6” 15:58
tyil write it down on a card and hand it out :p
jdv79 are the differences tween package, module, and class doc'd? 15:59
15:59 COMBORICO joined
jdv79 i can't find it on the docs site 15:59
AlexDaniel fwiw I was against any other name for a long time, until I started facing this damn issue on regular basis 16:00
so for everyone who is against alternative names – go and talk to people about perl 6 and see how it works out.
tyil I was in favor of changing the name for a while, but then I realized there's other issues around
16:00 cdg joined
tyil I know people will look weird when you mention "perl" and they ignore the number you say after it 16:00
16:01 TheGrimFandango left, troys is now known as troys_
tyil but as japanoise pointed out perfectly today, there's nothing good around to show the cool tricks you can pull off with perl 6 yet 16:01
16:01 TheGrimFandango joined, mcmillhj left
tyil and I think having something like that would do much more good to the entire naming debacle than constantly trying to change the name 16:02
16:02 cdg_ left
wander tyil, NQP is a cool project 16:02
16:03 TheGrimFandango left, TheGrimFandango joined
wander today I introduce it to my friends, especially it describes grammar using Grammar in Grammar.nqp and Actions.nqp 16:03
DrForr Grammars are what I usually tout as well in talks. 16:05
16:05 cdg_ joined
wander maybe not something, people say, "practical", but it is awesome 16:06
timotimo tyil isn't very useful for people though
perlpilot In the (very few) production things I've done with Perl 6, grammars are the reason I used Perl 6
timotimo rpython is also a pretty amazing project, but apart from the pypy devs it's not useful (topaz is kind of dead? was it hiphop that used rpython or was it another one?) 16:07
16:07 TheGrimFandango left
tyil timotimo: ? 16:07
I'm not useful? :(
16:07 TheGrimFandango joined, troys_ is now known as troys
lizmat tyil: pretty sure timotimo either forgot a colon or tabbed wrong 16:08
timotimo lol
wat
im eant nqp
tyil I'm still hurt
timotimo no, tyil, you're perfect
lizmat huggable hug tyil
hmmm...
timotimo .hug tyil
huggable hugs tyil
lizmat ah
tyil \o/
16:08 mcmillhj joined
pmurias technically NQP isn't written in Perl 6 16:09
16:09 cdg left, TheGrimFandango left, TheGrimFandango joined
timotimo IMO moarvm is also a cool project, but it's not of much use to anybody outside the perl6 community 16:09
tyil I thought perl 6 was written in perl 6
perlpilot tyil: it is ... sorta
moritz tyil: the high-level bits are
16:09 COMBORICO1611 joined
perlpilot tyil: also, NQP is a subset of Perl 6 with a few extra constraints and it's own bit of weirdness. 16:10
tyil Ive used nqp once to get some performance gain
but it didnt make the code prettier :p
timotimo that's just low-level ops you're putting into perl6 code, though 16:11
at least i assume that's what you did
tyil I did it on advice of my gf
timotimo nqp:: isn't an entirely accurate name for those ops
tyil she's better at perl than me
timotimo it's true, when you use nqp:: ops directly you save on a lot of overhead from mediocre code-gen 16:12
that's also why JSON::Fast uses so many nqp:: ops
AlexDaniel is reminded of github.com/MasterDuke17/Text-Diff-...6c61e4a772
timotimo but almost all nqp::blah ops map directly to a moarvm opcode rather than a sub written in "actual" nqp
tyil timotimo: c-could you merge te PR to sort the keys when using to-json
timotimo oh 16:13
i totally forgot about that :o
COMBORICO1611 For regex character class proper use of + quantifer, should it be / \d/+ / or / \d+ /
timotimo it's \d+
tyil :> 16:14
COMBORICO1611 Naughty Rosenfield, a typo.
perlpilot COMBORICO1611: why would you think it's the first one?
COMBORICO1611 A typo in a beginner's book.
wander oops
tyil thats a pretty big typo :(
wander I thought it's my fault just now
since recently I update regex doc some times 16:15
16:16 CcS_ joined
COMBORICO1611 Thanks for the help on that typo. Back to the book. 16:16
16:17 TheGrimFandango left, TheGrimFandango joined
wander cro may be a practical project. someone introduced it to me a few days ago 16:17
raschipi it's in beta, otherwise it would count 16:18
16:19 TheGrimFandango left, rindolf left, CacoS left, TheGrimFandango joined
wander yes 16:19
16:21 TheGrimFandango left
moritz \o 16:21
16:21 perlpilot left, TheGrimFandango joined
jdv79 what's the currying syntax again? 16:21
16:22 rindolf joined
moritz you mean * + 5 ? 16:22
jdv79 partial func application
timotimo .assuming
jdv79 ah
16:23 TheGrimFandango left, khw joined, TheGrimFandango joined
jdv79 thanks! 16:23
timotimo sure
jdv79 i thought it started with a but that was all i had
timotimo looking for methods on Code or so might have been a useful hint 16:24
m: say Code.^methods
camelia (<anon> <anon> <anon> <anon> <anon> <anon> arity count signature prec outer static_id file line of returns Capture ACCEPTS Str new perl BUILDALL)
timotimo m: say Code.^methods>>.name
moritz m: say Routine.^methods
camelia (<anon> <anon> <anon> <anon> <anon> <anon> arity count signature prec outer static_id file line of returns Capture ACCEPTS Str new perl BUILDALL)
(<anon> <anon> <anon> <anon> <anon> <anon> <anon> <anon> <anon> <anon> <anon> <anon> <anon> <anon> <anon> <anon> onlystar candidates cando multi soft wrap unwrap yada package leave perl BUILDALL fire_if_phasers add_phaser has-phaser phasers WHY set_wh…
timotimo ok, not on Code, then?
Block has it 16:25
16:25 setty1 joined
timotimo m: say Block.^methods 16:25
camelia (<anon> <anon> of returns add_phaser fire_if_phasers fire_phasers has-phasers has-phaser phasers assuming WHY set_why pos perl BUILDALL <anon> line <anon> prec perl <anon> file of ACCEPTS <anon> <anon> count signature Str <anon> arity returns Capture …
timotimo m: say Block.^methods.sort
camelia Method object coerced to string (please use .gist or .perl to do that)
in block <unit> at <tmp> line 1
Method object coerced to string (please use .gist or .perl to do that)
in block <unit> at <tmp> line 1
Method object coerced to string (…
timotimo haha
m: say Block.^methods.sort(*.name)
camelia (<anon> <anon> <anon> <anon> <anon> <anon> <anon> <anon> ACCEPTS BUILDALL BUILDALL Capture Str WHY add_phaser arity assuming count file fire_if_phasers fire_phasers has-phaser has-phasers line new of of outer perl perl phasers pos prec returns returns…
timotimo not helping :P
raschipi What are all those anonymous methods?
16:27 Guest82369 left
timotimo m: (.file, .line).say for Block.^methods 16:27
camelia No such method 'file' for invocant of type 'ForeignCode'
in block <unit> at <tmp> line 1
timotimo oh, hmm
m: (try (.file, .line).say) for Block.^methods
camelia ( no output )
timotimo that's not how, them? 16:28
raschipi (.?file, .?line).say for Block.^methods 16:30
m: (.?file, .?line).say for Block.^methods
camelia (Nil Nil)
(Nil Nil)
(SETTING::src/core/Block.pm 6)
(SETTING::src/core/Block.pm 7)
(SETTING::src/core/Block.pm 9)
(SETTING::src/core/Block.pm 29)
(SETTING::src/core/Block.pm 40)
(SETTING::src/core/Block.pm 47)
(SETTING::src/core/Block.p…
16:30 CcS__ joined
COMBORICO1611 Is the following a typo for regex character-class: / (<[\d.-]>+) / 16:31
wander m: / (<[\d.-]>+) / 16:32
camelia ( no output )
wander m: / \d/+/
camelia 5===SORRY!5===
Regex not terminated.
at <tmp>:1
------> 3/ \d/+/7⏏5<EOL>
Regex not terminated.
at <tmp>:1
------> 3/ \d/+/7⏏5<EOL>
Unable to parse regex; couldn't find final '/'
at <tmp>:1
------> 3/ \d/+/7⏏5<EOL…
wander seems not
m: say "42..--12" ~~ / (<[\d.-]>+) /
camelia 「42..--12」
0 => 「42..--12」
COMBORICO Does it look normal?
wander ^^ that is it 16:33
16:33 Ven joined
COMBORICO Thanks! 16:33
wander yes, maybe you can look up on regexes doc 16:34
16:34 Ven is now known as Guest47329
wander as for this 16:34
docs.perl6.org/language/regexes#En...and_ranges
16:34 CcS_ left
COMBORICO Back to book. 16:34
16:39 TheGrimFandango left
ugexe AlexDaniel: I have talked to people are about Perl 6 all the time. And it wouldn't surprise me if some of them have finally started implementing some Perl 6 in production for CLI tools (their idea) 16:39
16:39 TheGrimFandango joined
AlexDaniel ugexe: did it include a 5-minute lecture to deconfuse perl5 and perl 6? 16:40
ugexe no
jdv79 This type (NQPMu) does not support associative operations
AlexDaniel so how did they know that perl5 and perl 6 are different languages?
16:41 TheGrimFandango left, Bucciarati joined, TheGrimFandango joined
ugexe i didn't ask, same as I wouldnt ask why someone knows the difference between C and C++ 16:41
16:42 Cabanossi left
AlexDaniel when they were talking about it, did they say “perl” or “perl 6”? :) 16:42
ugexe perl 6
wander p6, in my situation
raschipi This confusion looks like people confusing C and C++ or Java and Javascript, it's immaterial. 16:43
ugexe one of the biggest gripes, camelia, went away at my last gig when they saw the plushie even
16:43 Aaronepower joined
wander jdv79, what is the code causes this exception? 16:44
16:44 Cabanossi joined
AlexDaniel ugexe: not sure how this is possible. Let me know if you figure it out 16:44
ugexe figure what out? 16:45
jdv79 got that when i tried to .assuming() a sub
but i can't golf it; again
AlexDaniel how you can possible approach someone with some programming experience, talk to them about perl 6 and not have perl 6 confused with perl5
y 16:46
ugexe AlexDaniel: ive worked with senior developers for awhile now
as in: im not talking to people with little to no programming experience
AlexDaniel and?
wander I've face that exception few days ago :)
ugexe and i dont know what your point is
timotimo tyil: added tests and docs to :sorted-keys and uploaded to cpan 16:47
raschipi Just tell them: "it's like java and javascript, two different languages", done.
AlexDaniel it's like if we created a new language called “python 4” and then you come up to a random senior developer and talk to him how cool “python 4” language is, and he never confuses it with the real python language. I don't get it.
timotimo JavaSixpt
AlexDaniel java and javascript are different languages, that's easy. Perl 5 and Perl 6 are different languages? That's a bit harder. 16:48
ugexe these aren't random senior developers
tyil timotimo: awesome, thanks!
AlexDaniel so they already knew about perl 6? OK cool.
raschipi "Perl 5 and Perl 6 are different languages?" You mean they aren't or that it's difficult to explain?
AlexDaniel raschipi: it's difficult to explain. 16:49
ugexe im responding to and countering all the things you keep attempting to make sound improbable
lizmat "Perl Reboot"
seems to be popular in the film business nowadays
16:51 TheGrimFandango left
AlexDaniel ugexe: it's not about things being probable or improbable. We have a problem and I'd love to have a solution for it. But if you never experienced problems with “perl 6” as a name then I'd say that it is improbable, yes 16:51
16:51 TheGrimFandango joined
ugexe "so for everyone who is against alternative names – go and talk to people about perl 6 and see how it works out." 16:51
AlexDaniel yeah
ugexe you are saying things like this. i respond, and you do not like the response
16:52 mcmillhj_ joined
AlexDaniel well why not, I like it. 16:52
ugexe because you are framing the situation
16:53 TheGrimFandango left, TheGrimFandango joined
AlexDaniel I was trying to understand how come you not noticed the issue, and I didn't really understand what happened there (and if the issue was there in these particular cases) 16:53
AlexDaniel shrugs
so you talked to people about “perl 6” and it was fine. OK I guess? 16:54
16:54 mcmillhj left
ugexe there you go again 16:55
buggable New CPAN upload: JSON-Fast-0.9.6.tar.gz by TIMOTIMO cpan.metacpan.org/authors/id/T/TI/...9.6.tar.gz 16:56
lizmat "Perl 6 skates to where the puck is going to be, not where it has been" 16:57
16:59 TheGrimFandango left, TheGrimFandango joined
jdv79 i don't get it. ll-exception says its coming from Block.pm line 200 which is an eval 16:59
i think i'll not use assuming() then for now
17:00 domidumont left 17:01 TheGrimFandango left, TheGrimFandango joined, domidumont joined 17:04 Aaronepower left
COMBORICO1611 I just want to confirm I am following the statement properly: say "foobar" ~~ / foo <?before bar> /; This reads in English as, "Say 'foo' if 'foobar' smart-matches the character-class, which instructs 'foo' must be before 'bar." Is this correct? 17:06
17:06 Zoffix joined
Zoffix jdv79: what's the code that produces the error? 17:06
17:07 zakharyas left
jdv79 i can't golf it. it seems to be something about the context. 17:07
17:08 zakharyas joined
Zoffix COMBORICO1611: s/character-class/regex/; and it'd be right 17:08
jdv79 i can golf it in situ which is weird but the enclosing context is - i hhave no idea
Zoffix COMBORICO1611: character class is one of the elements of regex that matches a class of characters, e.g.: <[abc]>
COMBORICO1611 What is s/character...? 17:09
Zoffix COMBORICO1611: s/foo/bar/ in programmers' speak means "replace 'foo' with 'bar'"
COMBORICO1611: it comes from there being a substitution operator in awk(?)/perl/rakudo 17:10
COMBORICO1611 Mmm, I don't think this intention is to replace, but to produce a string if there is a match.
Zoffix m: my $stuff = "character-class meows"; $x ~~ s/"character-class"/foos/; say $x
camelia 5===SORRY!5=== Error while compiling <tmp>
Variable '$x' is not declared
at <tmp>:1
------> 3my $stuff = "character-class meows"; 7⏏5$x ~~ s/"character-class"/foos/; say $x
Zoffix m: my $stuff = "character-class meows"; $x ~~ s/"character-class"/foos/; say $stuff
camelia 5===SORRY!5=== Error while compiling <tmp>
Variable '$x' is not declared
at <tmp>:1
------> 3my $stuff = "character-class meows"; 7⏏5$x ~~ s/"character-class"/foos/; say $st
raschipi it's from sed originally
Zoffix m: my $stuff = "character-class meows"; $stuff ~~ s/"character-class"/foos/; say $stuff
camelia foos meows
COMBORICO1611 I believe you are referring to a different operation. The title of the section in the book where the example comes from is Look-around Assertions 17:11
Zoffix COMBORICO1611: it's just a colloquialism. What I meant is your description is correct, other than what you called a "character class" is called a "regex"
COMBORICO1611 OH.
Zoffix Unless I'm misunderstanding what you said :) 17:12
17:12 SCHAPiE left, releasable6 left, releasable6 joined
COMBORICO1611 How about if I say, " . . . if 'foobar' smart-matches the character-class of Regex, which instructs . . . "? 17:13
mspo u: 🐳
unicodable6 mspo, U+1F433 SPOUTING WHALE [So] (🐳)
17:16 eater joined
callyalater A perl by any other name would code as sweet. 17:17
17:19 TheGrimFandango left, TheGrimFandango joined
COMBORICO Heh 17:19
17:19 domidumont left, sproctor left 17:20 SCHAPiE joined 17:21 TheGrimFandango left, TheGrimFandango joined
El_Che lo 17:21
APic Yo 17:22
17:23 TheGrimFandango left, domidumont joined, TheGrimFandango joined
Zoffix Anyway. Stopped by to comment on the naming discussion that I missed: the community fracturing that was mentioned can be avoided if people on each side of the issue don't merely ignore what the other side is saying. It's perfectly probably that one person will have only positive experiences from using "Perl 6" name, while another experiences only negative. The proposition of the naming debate is this: "A new 17:25
name will solve some of the challenges having 'Perl' in the name presents, such as reaching an audience who would love the language, but don't even reach the point of trying Rakudo Perl 6 because they think it's THE "perl" some of their mates were slagging off at some conf they attended". There exist both people who think the name change won't accomplish that goal and those who think "Perl 6" carries benefit.
17:25 TheGrimFandango left
Zoffix So we're NOT CHANGING the name. We're introducing an ALIAS to the name. So the group that likes or benefits from "Perl 6" name can continue using it, while the group that wants to prove the given proposition as true can go ahead and do so. Lastly, the subject of what the alias itself should be: I've seen dozens and dozens of proposals with dozens and dozens of Yay and Nay votes for them. It's highly unlikely 17:25
any particular name would have a concensus giving the naming issue itself is contentious, so we'll collect some of the prominent suggestions and present them to TimToady during 6.d release for him to pick or invent one of his own and that will be the alias. This might not be the ideal outcome the proposition-proving side might be looking for, but since it's them who have to prove something, they will have to
compromise and work with what's given to them. So to summarize: the focus of the current issue is creating a name *ALIAS* not a new name; people who don't like the idea; can continue to use the "Perl 6" name; our Dictator will dictate during 6.d release what the alias name should be.
17:25 TheGrimFandango joined 17:27 TheGrimFandango left, TheGrimFandango joined
Zoffix s/perfectly probably/perfectly probable/; s/concensus giving the/concensus given the/; s/idea; can/idea can/; 17:27
:)
17:28 Piotr_ joined 17:29 TheGrimFandango left
COMBORICO As a complete beginner to Pro with a week under my belt, but adequately aware of the Perl6 name issue, I totally agree with your position. 17:29
Pro is Perl.
17:29 TheGrimFandango joined
Zoffix \o/ 17:29
COMBORICO I like the article that guy wrote that promoted the name Rakudo. 17:30
If you're bored, out of curiosity what are some of the other aliases that have come up? 17:31
17:31 TheGrimFandango left, TheGrimFandango joined 17:33 TheGrimFandango left, TheGrimFandango joined 17:35 TheGrimFandango left
Zoffix COMBORICO: this article? rakudo.party/post/The-Hot-New-Lang...med-Rakudo 17:35
17:35 TheGrimFandango joined, kyan left
Zoffix COMBORICO: from memory, the ones that came up: P6, psix, Perl++, Rakudo, Camelia, 6lang, Gloria 17:36
COMBORICO1611 Zoffix, yes. awk
Zoffix Yeah, that guy re-kindled the naming debate with that article :)
El_Che wow
huge backlog 17:37
17:37 TheGrimFandango left
COMBORICO1611 Thumbs down: P6 (really bad), psix (really bad), I actually thought to myself Perl++ but decided against for confusion of a melting of Perl and C++, 17:37
17:37 TheGrimFandango joined
COMBORICO1611 I only like Rakduo in that list. 17:37
Zoffix leaves to do $urgent-things
\o
17:37 Zoffix left
geekosaur get ++y in a different way: e.g. beryl? 17:38
El_Che COMBORICO1611: Perl++ does Perl 5 a huge disservice
one of the reasons to change is that both languages benefit 17:39
COMBORICO I'm a beginner so i don't know. I like Rakudo. AWK
I agree. Awk
Lol i mean afk
(beginner)
17:42 Cabanossi left
wander go to bed 17:43
17:43 mikey joined 17:44 Cabanossi joined 17:45 mikey left, mikey joined, TheGrimFandango left 17:49 wamba joined 17:53 zakharyas left 18:00 robertle left 18:01 COMBORICO1611 left 18:02 napo1eon left 18:04 wamba left, wamba joined 18:07 COMBORICO left 18:08 Guest47329 left 18:10 mikey left, TheGrimFandango joined, COMBORICO joined 18:13 Cabanossi left 18:14 Cabanossi joined 18:15 Ven joined, Ven is now known as Guest11104 18:18 cdg joined 18:21 TheGrimFandango left 18:22 cdg_ left, cdg_ joined 18:26 cdg left 18:29 troys is now known as troys_ 18:31 cdg joined, cdg left 18:34 cdg_ left 18:38 kyan joined 18:40 Guest11104 left 18:46 COMBORICO left 18:47 COMBORICO joined
COMBORICO Wander, haha. 18:50
19:01 mcmillhj_ left 19:04 mson left 19:10 mcmillhj joined 19:14 darutoko left 19:24 Ven joined, Ven is now known as Guest15573 19:25 CcS__ left, domidumont left 19:26 Cabanossi left 19:28 cpage__ joined, Cabanossi joined 19:30 cpage left, cpage__ is now known as cpage
COMBORICO I'm reading this book here, and it says, " toad assertions are useful to specify conditions that cannot easily be expressed as regexes". Aren't code assertions apart of regex system, or am i missing something? 19:35
Toad = code. 19:36
moritz well, they embed regular code in regex code
COMBORICO On a side note, here's what's wrong with P6 Alias for Pearl 6. People are going to ask what does P6 stand for, and then you'll say pearl 6. So I argue that P6 is not a true alias. 19:37
raschipi regex is overloaded here, it's both the whole Perl6 construct and the rules system they use.
moritz more precise would have been "cannot easily be expressed by declarative regex elements"
but that is *really* nitpicking
raschipi Pearl is another language. 19:38
COMBORICO To me, his statement makes it sound as if code assertions are separate system from regular expressions.
Perl, using voice recognition
El_Che COMBORICO: it is an abrevation
COMBORICO P6 or regex (both, i know). 19:39
Thanks moritz, I'll add your verbage to my notes.
19:46 callyalater left 19:47 DickClarke joined, troys_ is now known as troys
COMBORICO m: say "Matched $/" if "A12B34D50" ~~ / (\D) <?{ say ~$0}> \d\d$ /; 19:47
camelia A
B
D
Matched D50
timotimo COMBORICO: please note that the regex optimizer might one day decide to start matching this at the D rather than at the A 19:48
because it knows the width of the match must be 3 and it's supposed to be anchored at the end of the line 19:49
end of string*
19:57 bdmatatu left
raschipi In other words, can't rely on the internal works of the regex engine. 20:00
20:02 cdg joined 20:03 cdg left, cdg_ joined
timotimo of course the optimization might bail out if there's a code assertion in play 20:06
COMBORICO Hmm. Interesting.
timotimo but since <?{ }> cannot move the match around, and is always zero-width, i wouldn't say it should 20:07
if you want side effects, you can put a bare { } block and that should always execute
20:07 wamba left
raschipi But it would execute always the same way? 20:21
COMBORICO What is the $0 variable called in regex? Capture Variable? 20:24
20:25 eugene_barsky joined
eugene_barsky Hi 20:25
yoleaux 30 Oct 2017 21:57Z <raiph> eugene_barsky: er, hi. (better late than never...) :) In answer to your SO, aiui, almost anything that makes #perl6 a great place to experience P6 is on topic.
COMBORICO I understand it's special because it does not need to be declared.
Hey, Eugene. 20:26
20:26 troys is now known as troys_
eugene_barsky I've just forgotten to put .slurp before .words and strangely it works: 20:26
my @words = $file_all.IO.words;
Is it normal? :)
20:27 Cabanossi left
eugene_barsky noticed it after debugging the whole program. :) 20:27
raschipi words will read the file word at a time
to avoid putting it all in memory, to deal with large files 20:28
eugene_barsky Is it slower than reading the whole file with slurp and then .words?
raschipi COMBORICO: $0 is the first positional in the capture
AlexDaniel squashable6: next
squashable6 AlexDaniel, ⚠🍕 Next SQUASHathon in 1 day and ≈13 hours (2017-11-04 UTC-12⌁UTC+14). See github.com/rakudo/rakudo/wiki/Mont...Squash-Day
20:29 Cabanossi joined
raschipi I'm going, g'night everyone. 20:29
20:29 raschipi left
COMBORICO Wait 20:29
20:30 cdg joined
geekosaur eugene_barsky, probably a little slower since it['s avoiding loading the whole file into memory. classic time/space tradeoff 20:31
docs.perl6.org/type/IO::Path#method_words btw
eugene_barsky geekosaur: thanks, I couldn't find it in the docs!
geekosaur: I was looking here docs.perl6.org/language/io 20:32
20:34 cdg_ left
geekosaur yes, that page is a tutorial and doesn't go into detail. the trick here is that .IO is a coercer to an IO::Path object 20:35
which is why the page directs you look at the IO role and IO::Path and IO::Handle classes for the real story 20:37
eugene_barsky geekosaur: and of course I missed these redirections :) 20:38
geekosaur right at the top
eugene_barsky Yes, now I see them. That was silly of me, but I was in a hurry. :) 20:39
If I have to print a long-long line, how to split it in two lines in the program and not get a newline? 20:42
say "my very long line my very long line my very long line my very lomy very long line ng line my very long line my very long line my very long line ";
evalable6 my very long line my very long line my very long line my very lomy very long line ng line my very long line my very long line my very long line
geekosaur \ + newline 20:46
xxx\
yyy
oh, hm, no
:(
eugene_barsky It seems I tried that (coming from bash) :)
20:54 evalable6 left, evalable6 joined, ChanServ sets mode: +v evalable6 20:59 mcmillhj left 21:00 darkmorph left 21:06 mson joined 21:07 mempko left 21:09 mempko joined
COMBORICO Question: / (a || b)+ / # matches aaaa or bbbb, but not abab, right? 21:14
geekosaur m: say so "abab" ~~ /(a || b)+/ 21:15
camelia True
COMBORICO Thanks! 21:18
m: my $str = 'number 42'; say "The number is $0" if $str ~~ / number \s+ (\d+) /; 21:21
camelia The number is 42
El_Che sjn: I saw your talk
COMBORICO m: say if "abab" ~~ / (a || b)+ /; 21:23
camelia 5===SORRY!5=== Error while compiling <tmp>
Unsupported use of bare "say"; in Perl 6 please use .say if you meant to call it as a method on $_, or use an explicit invocant or argument, or use &say to refer to the function as a noun
at <tmp>:1…
COMBORICO The only thing I don't like about this Android IRC program is that you can't copy text. 21:24
21:27 Guest15573 left
eugene_barsky COMBORICO: / (a || b)+ / will match any line with a or b (e.g. addd), because + can mean one letter a or b and the regex has no anchors. 21:28
El_Che Native call is still causing non deterministic fails on the native call tests: gist.github.com/nxadm/cd7559b6611f...test-L2936 . I thought AlexDaniel told me it was supposed to be fixed (Rakudo 2017.10) 21:29
COMBORICO m: my $str = 'number 42'; say "The number is $/" if $str ~~ / number \s+ (\d+) /; 21:30
camelia The number is number 42
El_Che (maybe it was someone else)
COMBORICO Thanks!
21:42 Cabanossi left 21:44 Cabanossi joined, niceperl joined 21:49 Ven joined 21:50 Ven is now known as Guest26819 21:54 eugene_barsky left
tbrowder n: 21:55
nqp: say
camelia ( no output )
tbrowder nqp: sub ch(){}; c(); 21:56
camelia Cannot invoke this object (REPR: Null; VMNull)
at <tmp>:1 (<ephemeral file>:<mainline>)
from gen/moar/stage2/NQPHLL.nqp:1542 (/home/camelia/rakudo-m-inst-1/share/nqp/lib/NQPHLL.moarvm:eval)
from gen/moar/stage2/NQPHLL.nqp:1779 (/home/camelia/rakudo…
tbrowder lizmat: hi 21:57
lizmat tbrowder o/
tbrowder that looks like an LTA response to me, what do you think? 21:58
geekosaur arguably once you're in nqp-land LTA is no longer a consideration 21:59
unless you'd really like to slow down the higher levels
21:59 colomon left
lizmat tbrowder: yes, in NQP, error messaging has not been a priority 21:59
22:01 colomon joined
tbrowder argh! i’ve been blindly searching for the cause of a msg like that and FINALLY figured out i had misspelled the name of a sub. s 22:02
22:03 colomon left
tbrowder somethink like “unknown object” would have clued me in faster for sure. shoulf 22:03
masak nqp: c()
camelia Cannot invoke this object (REPR: Null; VMNull)
at <tmp>:1 (<ephemeral file>:<mainline>)
from gen/moar/stage2/NQPHLL.nqp:1542 (/home/camelia/rakudo-m-inst-1/share/nqp/lib/NQPHLL.moarvm:eval)
from gen/moar/stage2/NQPHLL.nqp:1779 (/home/camelia/rakudo…
masak tbrowder: golfed it for you :)
22:03 colomon joined
tbrowder should i file a bug report? 22:03
thnk
thnx, masak 22:04
masak pzh
lizmat masak o/
any thoughts on the Telemetry work ?
masak as geekosaur and lizmat point out, nqp is not very user-facing
lizmat: haven't been following closely, sorry 22:05
lizmat no pb
masak lizmat: I can take a look later, hopefully
tbrowder true, but the school of hards knocks gets tiring for
anyhoo, i’ll file the issue 22:06
22:06 setty1 left 22:07 BloomingAzaleas joined
BloomingAzaleas FYI - smoke.perl6.org/report page throwing Error 500 @ 6:08PM EDT US 22:08
22:10 BloomingAzaleas left
AlexDaniel hm 22:12
22:12 mcmillhj joined
AlexDaniel was that automated? 22:12
22:13 Thrush joined 22:15 kyan left
Thrush I have a question about the Perl6 REPL (interactive mode). In python and ruby's REPL I can use "_" to get the last value. I notice that "_" doesn't do the same in Perl6's REPL. Is there a way to get the value evaluated value in Perl6's REPL? 22:15
22:16 mcmillhj left
Thrush In Perl6's REPL, is there a special variable to access the last output value? (I'm looking for something similar to '_' in Python's and Ruby's REPL.) 22:24
22:25 Piotr_ left
AlexDaniel Thrush: I don't think you can do it right now, but here's a relevant discussion: github.com/perl6/user-experience/i...-243891189 22:26
22:28 mcmillhj joined 22:30 imcsk8 joined, Merfont joined 22:33 Mrofnet left, mcmillhj left
Thrush Thanks, AlexDaniel. 22:34
22:34 Morfent joined 22:35 mcmillhj joined 22:36 Merfont left 22:39 mcmillhj left 22:41 niceperl left, Cabanossi left 22:44 Cabanossi joined 22:51 mcmillhj joined 22:53 Thrush left 22:55 mcmillhj left 22:57 Guest26819 left 23:06 troys_ is now known as troys 23:07 mcmillhj joined 23:11 mcmillhj left 23:14 mson left 23:15 mson joined, knight__ joined 23:19 nightfrog left 23:23 mcmillhj joined, rindolf left 23:27 mcmillhj left 23:29 pmurias left 23:39 mcmillhj joined 23:47 mcmillhj left 23:48 espadrine left 23:52 sergot joined