»ö« 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.
comborico1611 Anyone around? 01:16
MasterDuke .seen Anyone 01:17
yoleaux I haven't seen Anyone around.
comborico1611 heh
MasterDuke sorry, doesn't look like it
comborico1611 I haven't seen you in here yet. 01:18
MasterDuke i'm usually only here in the evenings 01:19
comborico1611 Want to try to answer a question? 01:19
MasterDuke shoot 01:20
comborico1611 I'm wondering if the variable is the actual object, or the foo-class.new 01:21
Example:
my $variable = Foo-class.new( ); 01:22
geekosaur it's not lazy, if that's what you mean 01:23
MasterDuke not quite sure what you mean by your question 01:23
geekosaur if you dump it out, it'll show a Foo-class.new(...) because that's the only way it knows to create a new object
MasterDuke m: my $variable = Foo-class.new( ); say $variable.^name 01:24
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared name:
Foo-class used at line 1
MasterDuke m: class Foo-class { }; my $variable = Foo-class.new( ); say $variable.^name
camelia Foo-class
geekosaur m: class Foo-class { }; my $variable = Foo-class.new( ); say $variable.WHAT
camelia (Foo-class)
geekosaur um, not what I wanted
m: class Foo-class { }; my $variable = Foo-class.new( ); say $variable.WHICH 01:25
camelia Foo-class|81720992
comborico1611 Like is $variable the object or Foo-class?
geekosaur it should normally be the object. nothing stops some class from overriding .new in such a way as to return the class itself, but that would be somewhat odd
meanwhile that .WHICH I did shows a Foo-class object 01:26
m: class Foo-class {}; dd Foo-class.WHICH
camelia ObjAt.new("Foo-class|U62882856")
geekosaur hm, that wasn't what I intended 01:27
geekosaur oh, right, type object 01:28
(which is not the same thing as the class itself; it's the "undefined" value for the class, as indicated by the U)
geekosaur m: my $x = Int; say defined $x 01:29
camelia False
comborico1611 So normally $variable is the object, but you can make Foo-class the object if you wanted? 01:30
geekosaur as long as you understand that is not the class itself
(this is somewhat confusing_ 01:31
MasterDuke_ do you mean object in the non-programming language sense?
MasterDuke_ i.e., my $variable = Foo-class.new kind of maps to $variable = subject, Foo-class = object, .new = verb 01:32
comborico1611 Object in the sense of an instantiation of a class.
MasterDuke_ ah, then $variable would usually be the object/instantation, yes 01:33
comborico1611 Is $variable an alias for Foo-class object? 01:33
comborico1611 Is $variable ro, then? 01:34
MasterDuke_ kind of. could also say it's a container for a Foo-class object
geekosaur no
m: class Foo-class {}; my Foo-class $x .= new; dd $x.VAR 01:35
camelia Foo-class.new
comborico1611 Hmm. Alright. Thanks guys. Back to the book. I'm watching the screen, though.
geekosaur hm, wrong thinhg
comborico1611 I think container for the object is the most accurate description. 01:36
geekosaur well. $var is bound to a Scalar object, which is a container with something in it
the container is mutable
if you used := then you would be binding the object directly; that would be read-only, although you can re-bind with another :=
comborico1611 If $var gets assigned to something else, what happens to Foo-class instantiation? 01:37
geekosaur if there are no other references to the object, it will eventually get garbage-collected
comborico1611 Hmm. I see. Thanks, guys. 01:38
timotimo m: class Foo-class { submethod DESTROY { say "i got garbage collected!" } }; my $var = Foo-class.new(); for ^4 { my @a = rand xx 10000; } 01:41
camelia ( no output )
timotimo m: class Foo-class { submethod DESTROY { say "i got garbage collected!" } }; my $var = Foo-class.new(); for ^4 { my @a = rand xx 10000; say +@a }
camelia 10000
10000
10000
10000
timotimo m: class Foo-class { submethod DESTROY { say "i got garbage collected!" } }; my $var = Foo-class.new(); for ^4 { my @a = rand xx 1000000; say +@a } 01:42
camelia 1000000
1000000
1000000
1000000
timotimo that's not enough work?
... i forgot to re-assign :)
timotimo m: class Foo-class { submethod DESTROY { say "i got garbage collected!" } }; my $var = Foo-class.new(); dd $var; $var = 99; for ^4 { my @a = rand xx 10000; } 01:42
camelia Foo-class $var = Foo-class.new
timotimo m: class Foo-class { submethod DESTROY { say "i got garbage collected!" } }; my $var = Foo-class.new(); dd $var; $var = 99; for ^10 { my @a = rand xx 100000; }
camelia Foo-class $var = Foo-class.new
timotimo m: class Foo-class { submethod DESTROY { say "i got garbage collected!" } }; my $var = Foo-class.new(); dd $var; $var = 99; for ^10 { my @a = rand xx 100000; say +@a }
camelia Foo-class $var = Foo-class.new
100000
100000
100000
100000
100000
100000
100000
100000
100000
100000
timotimo *shrug*
comborico1611 I'm not sure what you're doing. Heh. 01:43
timotimo i'm trying to create lots of objects so that the garbage collector would run 01:44
i might be doing something wrong anyway
comborico1611 Welp. I'm going to rest now. Goodnight. 01:46
timotimo good nigth!
comborico1611 Thanks for trying!
timotimo er
MasterDuke_ m: use nqp; class Foo-class { submethod DESTROY { say "i got garbage collected!" } }; my $var = Foo-class.new(); dd $var; $var = 99; for ^100 { my @a = rand xx 100000; nqp::force_gc; nqp::force_gc } 02:07
camelia Foo-class $var = Foo-class.new
timotimo a heap snapshot seems to suggest dd is making it unhappy 02:08
m: class Foo-class { submethod DESTROY { say "i got garbage collected!" } }; my $var = Foo-class.new(); $var = 99; for ^10 { my @a = rand xx 100000; say +@a }
camelia i got garbage collected!
100000
100000
100000
100000
100000
100000
100000
100000
100000
100000
timotimo look, see?
somehow $*PERLSEEN or so is hanging on to it?
could it be things you dd and/or .perl will stick around forever 02:09
m: class Foo-class { submethod DESTROY { say "i got garbage collected!" } }; my $var = Foo-class.new(); dd $var; $var = 99; dd $var; for ^10 { my @a = rand xx 100000; say +@a } 02:10
camelia Foo-class $var = Foo-class.new
100000
100000
100000
100000
100000
100000
100000
100000
100000
100000
Int $var = 99
timotimo wait what :)
ah, stdout vs stderr i suppose?
MasterDuke_ i guess you aren't likely to see dd in production code / hot paths, so not terrible 02:12
MasterDuke_ but could throw off debugging 02:12
Geth Pod-To-HTML: 0ae43c1fd1 | W4anD0eR96++ | 2 files
fix html block now emit raw HTML

Inside html block, `=begin html #lines =end html`, we assume almost *everything* is raw HTML.
Because of the implementation, pod6 syntax will be removed. That is, `C<code> -> code`, `=item1 sth -> sth`. To write down ... (7 more lines)
05:20
Todd_ I think I may have foudn a booboo in the documentation. docs.perl6.org/syntax/qqx 06:58
my $output = qqx{grep $option $word $file};
I can not get qxx to work unless I put a space between the qxx and the { 06:59
The error message of `qxx{` is
Todd_ $ perl6 -e 'my $msg="help me!"; my $cmd="echo $msg | notify-send -u normal -t 2000 test \"$msg\""; qqx($cmd);' ===SORRY!=== Error while compiling -e Undeclared routine: qqx used at line 1. Did you mean 'QX'? 06:59
moritz Todd_: qqx is not a function, so you can't use () 07:00
Todd_: just use it as it is in the example (qqx{...}), and it works
Todd_ $ perl6 -e 'my $msg="help me!"; my $cmd="echo $msg | notify-send -u normal -t 2000 test \"$msg\""; qqx ($cmd);'
works
$ perl6 -e 'my $msg="help me!"; my $cmd="echo $msg | notify-send -u normal -t 2000 test \"$msg\""; qqx{$cmd};' 07:01
works too
What am I doing wrong with this code?
my $cmd = "cd /opt/Cimcor/CimTrak/CimTrakServer; CimTrakServer.exe -Diagnostics \"Level=255\""; 07:02
my $str = qxx { $cmd };
Undeclared routine: qxx used at line 465. Did you mean 'QX'?
same proble if I remove the space. 07:03
moritz Todd_: qxx is wrong 07:05
Todd_ I though qxx was for when I wanted to run a shell with a variable in it?
Todd_ Like this; 07:06
$ perl6 -e 'my $msg="help me!"; my $cmd="echo $msg | notify-send -u normal -t 2000 test \"$msg\""; qqx{$cmd};'
moritz Todd_: no, that's qqx
you wrote qxx
you can't just make stuff up, and expect it to work :-)
Todd_ mumble mumble mumble. Thank you for the second pair of eyes! 07:07
Why not! Forget I asked that.
Geth doc: 0f657e57d1 | W4anD0eR96++ | 3 files
Fix #641 Add hook of TypeGraph in each Type at TOC

Local build success.
Close #641
07:59
Todd_ Is there a way to slurp the stderr? 08:35
Todd_ With qqx{...} is there a way to pick up the both STDIN and STDERR? 09:02
samcv Todd_, you could use pipes since qqx uses the shell 09:05
Todd_ I am frustrated as this command works: 09:06
bash -c "cd /opt/Cimcor/CimTrak/CimTrakServer; CimTrakServer.exe -Diagnostics Level=255 > /opt/Cimcor/CimTrak/CimTrakServer/logs/cimtrakdiagnosticreport.stderr.txt 2>&1"
But this one does not catch the stderr 09:07
perl6 -e 'my $cmd="cd /opt/Cimcor/CimTrak/CimTrakServer; CimTrakServer.exe -Diagnostics Level=255 > /opt/Cimcor/CimTrak/CimTrakServer/logs/cimtrakdiagnosticreport.stderr.txt 2&>1"; my $str = qqx{$cmd}; say $str;'
cimtrakdiagnosticreport.stderr.txt exists but is zero lenght using qqx
holyghost I get an error : Cannot import symbol Sprite from Sprite, because it already exists in this lexical scope on pastebin.com/grgkSDKh 09:10
I don't know how to proceed
there's PERL6LIB=.
Todd_ Here is an easier way to reproduce this: 09:11
perl6 -e 'my $str=qqx{ls .kjf}.Supply; say "<$str>";'
ls: cannot access '.kjf': No such file or directory <Supply<448989002624>>
Todd_ And the stupid command has to be run from its own directory or it errors out ( the reason for the cd) 09:14
holyghost never mind, I found out 09:18
Todd_ If I do not incude the 2&>1 in teh qqx{}, the stderr splatter all over my terminal. But do use it in the qqx, I get nothing back. 09:19
holyghost timotimo are you there ? 09:20
tyil Todd_: shouldnt it be 2>&1
Todd_ will check
Yup, you are correct. Let me see it is helps anything 09:23
holyghost ok, I have gotten my Holly6Game module compiled, the meaning now is to put SDL2::Raw upon it, the code is at gomez.yellowcouch.org/holly6src-1.5.tar.gz
holyghost Then later on I will try to make games with it 09:23
It's a sublayer for 2D games, the 3D should not be that difficult if you understand something from meshes and materials. I chose SDL2 as it is up to date, I have written far too many SDL 1.2 derived programs 09:24
Todd_ It worked. Thank you for the second pair of eyes! I must have stared at that 200 times! 09:25
jast fwiw I didn't see it, either
tyil :> 09:26
jast didn't help that my client wrapped the line exactly before the 2&>1 so I kind of half-skipped over it
wander tyil: o/ 09:27
tyil I only noticed when he said the 2&>1 the second time
wander: hey!
I might write a new perl 6 related tutorial on my site later today or tomorrow 09:28
not sure if I should use GTK::Simple or GTK::Simpler
wander where is the site :P 09:29
tyil tyil.nl/ 09:30
ZzZombo1 I'm parsing an hierarchical data format. I want to add a special callback for then an element is parsed, but it 09:34
but I also need to have its parent available there.
How can it be done?
wander tyil: looking forward to it :) 09:36
Todd_ chuckle, I found a file called "1' and "2' with a ton of garbage in it. 09:46
jast sounds familiar
holyghost same here :-)
jast from back when I didn't have the redirection operators memorized 09:46
Todd_ I am calling it a night. Thank you guys for the help! 09:53
sproctor m: role logger { method do-log( $d ) { say "{self} : $d" } };my Int $n = 5;$n does logger; $n.do-log( "Test" ); 10:00
camelia 5 : Test
sproctor So. That works (which is cool) but I'm a bit confused about how.
I thought using does for composition won't work on immutable object and Int's are immutable.
(Still cool though) 10:01
tyil timotimo: modules.perl6.org says your JSON::Fast module is at 0.9.6, but zef says 0.9.5 is the latest
tyil .tell moritz the .git dir in App::MPD::Notify seems to be a bug thats fixed in App::Cpan6, I can't seem to reproduce it 10:09
yoleaux tyil: I'll pass your message to moritz.
moritz tyil: have you uploaded a version of App::MPD::Notify that does not contain the .git dir? 10:09
yoleaux 10:09Z <tyil> moritz: the .git dir in App::MPD::Notify seems to be a bug thats fixed in App::Cpan6, I can't seem to reproduce it
tyil moritz: not yet, I can bump the version and reupload if you wish 10:10
moritz tyil: that would be nice, though not strictly necessary 10:12
tyil I uploaded a App-MPD-Notify-0.1.0, should be coming around in a bit here 10:13
tyil seems like App::MPD::Notify was one of my earlier tests to get started with cpan, and I never fixed it to be a "good" upload there 10:14
moritz tyil++ 10:15
buggable New CPAN upload: App-MPD-Notify-0.1.0.tar.gz by TYIL cpan.metacpan.org/authors/id/T/TY/...1.0.tar.gz 10:23
AlexDaniel wander++ 10:58
wander \o 11:17
AlexDaniel: Where is "doc for method Str.val" in "docs.perl6.org/routine/Str"? 11:21
docs.perl6.org/routine/Str
AlexDaniel wander: Ah! wrong page!
AlexDaniel wander: docs.perl6.org/type/Str 11:21
wander: look in the ToC
wander: it says “Methods”
and then lists all methods… and “sub val”
wander see 11:22
in fact I found that we list all routines below "Methods" in every Type 11:23
docs.perl6.org/type/Any 11:24
docs.perl6.org/type/Channel 11:25
like these
meanwhile someone use "Subroutine" head
I will modify that issue, for 1. it's about /type/Str, not /routine/Str; 2. it's not build issue, but issue of doc conventions 11:27
azawawi good afternoon #perl6 12:03
gist.github.com/azawawi/6c57670d2e...8e8c3a44e6 # Latest MessagePack benchmark (Pure P6 vs Native P6 vs Inline::Perl5) 12:04
How can one create a Perl 6 structure in C and then return to Perl 6? 12:08
.tell nine it is passing all the tests on macOS and linux. Please take a look @ it when you're free. Thanks :) 12:11
azawawi nine: it is passing all the tests on macOS and linux. Please take a look @ it when you're free. Thanks :) # seems like .tell is down... 12:12
ZzZombo Can I the exact source fragment from this: 12:15
"Cannot look up attributes in a Grammar::VDF::Actions type object
in method root at I:\Developer\Perl\VDF\lib\.precomp\531476C94944C40F030060AEB60539343668769B.1500922671.09494\11\115941A6FC88ECE1A178278587E96C028C0B56B9 line 1"?
see*
raschipi ZzZombo: I'm not sure what you want... 12:16
ZzZombo I can't debug my program based on that, I want to know where exactly it trips on. 12:17
azawawi ZzZombo: i encountered a similar error a lot, most likely an undefined object.. (i.e. Any) 12:18
ZzZombo Yeah, and there are many places where an undefined object might be. 12:19
How can I know what line exactly is it at?
azawawi share the code? 12:24
azawawi m: my $a; say "Undefined" if $a.defined 12:25
camelia ( no output )
azawawi m: my $a; say "Undefined" unless $a.defined
camelia Undefined
azawawi ZzZombo: perl6-debug-m is your friend. 12:26
azawawi ZzZombo: also remember to `zef install Debugger::UI::CommandLine` for it to work 12:26
nine azawawi: so Data::MessagePack (via Inline::Perl5) is 2 orders of magnitude faster? 12:29
HoboWithAShotgun can i allow Any in a typed has statement? something like: has Int or Any $.foo;
azawawi nine: 4097 vs 11 iterations/sec ? 12:30
raschipi HoboWithAShotgun: "Int or Any" is just Any because Int is Any 12:31
"has Any $.foo;" will accept Int or Any
HoboWithAShotgun m: class Foo { has Int $.bar = Any }; 12:32
camelia ( no output )
HoboWithAShotgun m: class Foo { has Int $.bar = Any }; Foo.new
camelia Type check failed in assignment to $!bar; expected Int but got Any (Any)
in submethod BUILDALL at <tmp> line 1
in block <unit> at <tmp> line 1
nine azawawi: I've worked a lot on performance, but that difference surprises me :)
azawawi nine: let me commit the script then :) 12:33
HoboWithAShotgun see? i have a base class. i want to see if a subclass set attribute values over the initial values. any zero is allowed so i want it initialize to Any, 12:34
hang an, i could use "but" for that 12:35
*on
meh, doesnt work with ints. 12:36
HoboWithAShotgun "has Any $.foo;", yes but also accepts everything else 12:40
raschipi Could you cast to Int in the method where you're setting it?
HoboWithAShotgun i just want a constraint that says "of this type or undefined"
azawawi nine: github.com/azawawi/perl6-msgpack/b...sgpack.pl6 12:44
HoboWithAShotgun subset IntOrAny where * ~~ Int|Any; works
raschipi But will accept anything that fits into Any 12:45
raschipi "subset IntOrAny where * ~~ Int|Any;" is the same as Any 12:46
HoboWithAShotgun rev2: subset CoolOrAny where { !.defined || $_ ~~ Cool }; 12:47
bad name 12:48
lizmat m: subset IntOrAny where { .WHAT =:= Int || .WHAT =:= Any }; my IntOrAny $a = "foo"
camelia Type check failed in assignment to $a; expected IntOrAny but got Str ("foo")
in block <unit> at <tmp> line 1
lizmat m: subset IntOrAny where { .WHAT =:= Int || .WHAT =:= Any }; my IntOrAny $a = Any
camelia ( no output )
lizmat m: subset IntOrAny where { .WHAT =:= Int || .WHAT =:= Any }; my IntOrAny $a = 42
camelia ( no output )
lizmat m: subset IntOrAny where { .WHAT =:= Int:D || .WHAT =:= Any }; my IntOrAny $a = 42 # if you want to exclude Int type objects 12:50
camelia Type check failed in assignment to $a; expected IntOrAny but got Int (42)
in block <unit> at <tmp> line 1
lizmat HoboWithAShotgun: ^^^ 12:50
wander m: $[1].^name.say 12:59
camelia Array
wander m: $[1].[0].^name.say
camelia Int
HoboWithAShotgun it's all unneccesary anyway. 13:01
m: my Int $i; say $i 13:02
camelia (Int)
HoboWithAShotgun i expected zero.
old habits die hard
raschipi Only Any becomes zero when cast to numeric, doesn't apply to other type objects 13:04
Or not 13:05
m: my $i := Int; say +$i
camelia Use of uninitialized value of type Int in numeric context
0
in block <unit> at <tmp> line 1
raschipi m: my $i := Int; quietly say +$i 13:06
camelia 0
wander .ask lizmat we assume text inside Pod::Block::Table are all raw text, but someone uses FormattingCode inside it and think it'll be handled. so should we enable Table to handle nested pod6 code? 13:17
lizmat . 13:18
good question: I'm not sure I'm qualified to answer that question
wander examples: gist.github.com/W4anD0eR96/925d001...b2387ec700 13:19
lizmat you mean, using C<*INIT-INSTANT> ? 13:20
if that's it, then I would say: yes, one could expect that to be handled ? 13:21
wander yes 13:21
lizmat so, yes, I would assume that to be handled. Is that a problem ? 13:22
wander docs.perl6.org/language/variables#..._variables
Unexpected result here 13:23
To fix it outside rakudo, the problem is I cannot build object instanceof Pod without EVAL 13:24
===SORRY!=== Pod::Block::Code is a builtin type, not an external module
timotimo just means you're not supposed to "use" it 13:25
wander oh
wander m: use MONKEY-SEE-NO-EVAL; my $cell = "earlier than C<INIT now> or even C<BEGIN now> executed."; say my $local-pod = EVAL("=begin pod\n"~$cell ~ "\n=end pod\n\$=pod"); 13:27
camelia [Pod::Block::Named{:name("pod")}
Pod::Block::Para
earlier than
Pod::FormattingCode{:type("C")}
INIT now
or even
Pod::FormattingCode{:type("C")}
BEGIN now
executed.
]
wander ugly :(
wander by any other way I can parse string to build a Pod object(like something done above)? 13:29
lizmat not as far as *I* know, but in this case, that's not saying much 13:30
wander sorry, I don't know what "that's not saying much" literally means :P 13:32
alexk6 m: package A::B::A::B {}; say A::B::.keys; 13:33
camelia (A)
alexk6 package A { package B { package A::B {}}}; say A::B::.keys;
m: package A { package B { package A::B {}}}; say A::B::.keys;
camelia ()
alexk6 m: package A { package B { package C::B {}}}; say A::B::.keys; 13:34
camelia (C)
HoboWithAShotgun i broke something. "Method call must either supply a name or have a child node that evaluates to the name" 13:38
HoboWithAShotgun sighs and goes looking for a stray comma or something 13:39
timotimo oh, that's an internal error that no user should be seeing
it'd be nice if you could give us a golf
HoboWithAShotgun it would nice if i knew what i did 13:40
HoboWithAShotgun applies binary commenting out patterns 13:40
alexk6 m: package A { package B { package A::B {}}}; say A::B::A::B.WHAT; 13:47
camelia Could not find symbol '&B'
in block <unit> at <tmp> line 1
alexk6 m: package A { package B { package C::B {}}}; say A::B::C::B.WHAT;
camelia (B)
HoboWithAShotgun timotimo: i forgot to use a module 13:49
timotimo OK, but how did the error appear? o_O 13:50
HoboWithAShotgun basically, 13:52
m: module Foo { sub { SomeObjectThatExistsButIsNeither-use-dNorHasAnInstanceMethod.instance } 13:53
camelia 5===SORRY!5=== Error while compiling <tmp>
Missing block
at <tmp>:1
------> 3r-use-dNorHasAnInstanceMethod.instance }7⏏5<EOL>
expecting any of:
postfix
statement end
HoboWithAShotgun heres the offending code: hastebin.com/otujocorof.pl 13:54
timotimo m: module Foo { sub { SomeObjectThatExistsButIsNeither-use-dNorHasAnInstanceMethod.instance } } 13:55
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared name:
SomeObjectThatExistsButIsNeither-use-dNorHasAnInstanceMethod used at line 1
timotimo m: module Foo { sub { SomeObjectThatExistsButIsNeither-use-dNorHasAnInstanceMethod.instance.WHAT } }
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared name:
SomeObjectThatExistsButIsNeither-use-dNorHasAnInstanceMethod used at line 1
timotimo m: module Something::Blah { sub test { Something.lol } }
camelia ( no output )
timotimo m: module Something::Blah { sub test { Something.lol.what().WHAT.new } } 13:56
camelia ( no output )
timotimo m: module Something::Blah { sub test { return Something.lol.what().WHAT.new } }
camelia ( no output )
timotimo not sure how you got that error :(
HoboWithAShotgun want a tarball? 13:57
timotimo sure 13:58
i'll be afk soon, but maybe i'll find the time 13:59
wander timotimo: yes that means i cannot "use" Pod::To::Table, but how can I build an object of it without ugly EVAL? 14:05
from a string 14:06
HoboWithAShotgun i have a tarball ready timotimo. can send when u are ready 14:07
wander the procedure of parsing pod file is inside rakudo, isn't it?
timotimo wander: you cannot put "use Pod::To::Table" in your code, that's what i meant
wander ok >_< 14:08
raschipi wander: if you have a string and wants to treat it as code, you need EVAL. Or you could save it to a file and call rakudo on it. 14:10
wander 😝 14:14
wander yes, that can get thingd done, if I confirm EVAL doesn't do evil things, maybe I should use it bravely 14:16
ZzZombo How can I in my custom Positional class add support for custom subscript adverbs? 14:21
ugexe How would eval (or any method) be able to evaluate code in a ?safe way? 14:23
wander ugexe, in a very case 14:25
m: use MONKEY-SEE-NO-EVAL; my $cell = "earlier than C<INIT now> ."; say my $local-pod = EVAL("=begin pod\n"~$cell ~ "\n=end pod\n\$=pod") 14:26
camelia [Pod::Block::Named{:name("pod")}
Pod::Block::Para
earlier than
Pod::FormattingCode{:type("C")}
INIT now
.
]
census can someone please give me step by step directions on how to do perl6 on a mac for a novice? i only use windows. and in windows i put my code in a .txt file and then go into a cmd and type perl6 program.pl6 14:27
wander $cell supplied by user, but all put in =pod pod
ugexe So if $cell is malicious it runs anyway right
perlpilot census: you'd do the same thing on a Mac (first making sure that perl6 is in your path) 14:28
census a mac can do a cmd? 14:29
ugexe It’s not all out it pod if cell contains an end pod marker
census thanks perlpilot
also how do i open a .txt in a mac? i use notepad in windows
perlpilot census: well ... on a Mac you'd open a terminal
jast I believe textEdit is the default editor
perlpilot census: you can also use vi and other unix-y programs on a mac 14:30
census perlpilot in cmd with windows i use "cd" to get into the path.
perlpilot census: same in a terminal on a mac
census like "cd ..." or "cd desktop" to go ahead or back a path
wander ugexe, yes 14:38
wander that is what I worry about 14:39
wander the very purpose is to detect and parse pod6 code inside Pod::To::Table, however, out Table treats every item as raw text 14:40
instead of recursive parsing it
ugexe You can’t parse it without running it. 14:48
wander what does rakudo do when runs `perl6 --doc=Text main.p6`, I notice that codes except pod didn't execute 14:53
ilmari wander: put a 'BEGIN say "boom!";' in it 14:55
wander oops
geospeck Hi guys, I am reading the doc about Dynamic Vars from this(docs.perl6.org/language/variables#The_*_Twigil) and trying the code examples in the repl, but I am getting this error "Dynamic variable $*dynamic1 not found" 15:02
do I need to execute the code from a file and not from the repl? 15:03
ugexe PSA: don’t declare bin scripts in meta6.json ‘provides’ section for modules 15:09
wander geospeck: from a file works well 15:11
geospeck wander: yes, when I execute the script from a file there is no problem, only in repl. 15:13
wander At first I will set a note at that doc section, but to fix it, maybe you can open an issue of it 15:15
geospeck wander: is this the repo github.com/perl6/doc so I can open the issue 15:19
wander maybe better in github.com/rakudo/rakudo 15:20
wander .ask Zoffix do we have tickets that report the same issue (improperly handle $*variable in REPL)? 15:23
yoleaux wander: I'll pass your message to Zoffix.
comborico1611 m: my $test = test; say "my", $test; 15:25
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared routine:
test used at line 1
comborico1611 m: my $test = "test"; say "my", $test;
camelia mytest
comborico1611 m: my $test = " test"; say "my", $test; 15:26
camelia my test
comborico1611 m: my $test = " test"; say "my" $test;
camelia 5===SORRY!5=== Error while compiling <tmp>
Two terms in a row
at <tmp>:1
------> 3my $test = " test"; say "my"7⏏5 $test;
expecting any of:
infix
infix stopper
postfix
statement end
comborico1611 I see.
azawawi gist.github.com/azawawi/9c59b5f48b...2e19f91a4c # Better MsgPack::unpack performance (hash lookup) 15:31
Geth doc: 74f9310ac3 | (Alex Chen)++ (committed using GitHub Web editor) | doc/Language/variables.pod6
Dispel puzzle caused by rakudo REPL bug
15:32
synopsebot Link: doc.perl6.org/language/variables
Grimy Hi~ 15:36
p6: Bag.new.pick(1)
camelia (signal SEGV)
Grimy Is this already ticketed, or should I make one?
moritz I'm not aware of a ticket/issue 15:49
azawawi moritz: i noticed a performance problem... 0.5s difference on a 100_000 for loop 15:54
moritz: and hi :)
moritz: github.com/azawawi/perl6-msgpack/b...r.pm6#L103 15:55
moritz: apparently for range calculation is slow... if i put it in a variable it is faster by 0.5s. Is that normal? 15:56
timotimo Grimy: investigating
azawawi is the upper limit of a range evaluated everytime or once in a for loop? 15:57
i.e. cached or not
timotimo only once 15:58
you're creating the range object at which point it just becomes a single object (int, num, rat, Str, doesn't matter)
and then you get an iterator that goes from beginning to end 15:59
azawawi apparently that's not the case 16:01
timotimo have you considered --profile? 16:02
timotimo Grimy: i'm getting rid of the segfault and making it an exception inside moarvm, then the rakudo code can be changed to make sure Bag.new and friends get a valid hash inside them 16:02
or an empty hash being properly treated 16:03
azawawi timotimo: im already doing that
azawawi double checks
timotimo anyway, moarvm will no longer segfault there, rakudo ought to be patched, i need to rest my rists 16:06
Grimy good, good. no need to make a ticket, since it’s already being fixed, right? 16:07
ilmari m: say Bag.new(1).pick(1) 16:09
camelia P6opaque: get_boxed_ref could not unbox for the representation '20' of type Scalar
in block <unit> at <tmp> line 1
ufobat___ m: say so $*CWD.e == $*CWD.resolve.e 16:58
camelia True
ufobat___ thats False on windows, btw
azawawi so what does "MoarVM panic: Internal error: zeroed target thread ID in work pass" really mean? :)
HoboWithAShotgun it means your fans aren't working properly and your motherboard is about to melt 17:00
azawawi :) 17:01
azawawi built rakudobrew with debug3 opts for valgrind 17:02
comborico1611 Question: please fill in the blank. Defining a class creates a BLANK. a) type object b) type c) both, they mean the same thing 17:03
[Coke] m: my $a = class barf {}; say $a.WHAT; 17:06
camelia (barf)
[Coke] m: my $a = class :: {}; say $a.WHAT;
camelia (<anon|81859200>)
ilmari m: my $a = class :: {}; say $a.HOW 17:07
camelia Perl6::Metamodel::ClassHOW.new
comborico1611 or d) other :-) 17:08
comborico1611 I tried to look up :: , but there are too many of those and the docs. 17:10
IN the docs.
[Coke] comborico1611: docs.perl6.org/language/typesystem might be a good read. 17:11
comborico1611 K, thank you.
[Coke] your question seems to have two parts: is there a distinction between a type and a type object, and then which of those is a class. neh?
comborico1611 Nope, just the first one. 17:13
My understanding is a Class creates a Type. I've never heard of a Type Object. 17:14
[Coke] everything's an object, even a Type. :) 17:15
as i understand it, it's just one thing.
Geth doc: 01d36736ae | (Alex Chen)++ (committed using GitHub Web editor) | doc/Language/variables.pod6
fix typo, azawawi++
17:16
synopsebot Link: doc.perl6.org/language/variables
comborico1611 And last night on here, we determined that a variable assigned to The Constructor it's just a container not the object. Ex. my $point = Point2D.new( )
My understanding is that not everything is an object, but Pearl can internally treat everything as an object. And this is known as Auto boxing. 17:18
Perl*
Autoboxing*
If this is splitting hairs, I don't know. 17:19
comborico1611 Related to this topic is how to create an actual name for an object rather than just using ClassName.new and assigning that to a variable. 17:20
tyil comborico1611: what do you mean, an actual name for an object? can you give an example on how you want to use it? 17:21
mst I'm not sure how what you mean by 'an actual name for an object'
HoboWithAShotgun when i have a FALLBACK method and it's arguments are not something i want to handle, can i somehow raise the error that would have been raised without the callback?
[Coke] comborico1611: docs.perl6.org/language/mop
wander .tell lizmat "tbrowder" is working on Pod::To::Table parsing at rakudo PR#1240.
yoleaux wander: I'll pass your message to lizmat.
comborico1611 my $var = ActualNameOfObject ClassName.new( ) 17:22
mst yes, but what would that even do/mean ? 17:23
HoboWithAShotgun i know have multi method FALLBACK( $m ) { dosometinginteresting(); } multi method FALLBACK ( $m, *@_ ) { die "unknown mehod" }; 17:23
comborico1611 Or even better: ActualNameOfObject = ClassName.new( )
mst what is this name? why does it exist? what is it for? 17:24
HoboWithAShotgun but that is suboptimal,
tyil comborico1611: you can type your var, my Class $foo = Foo.new
if that's what you're aiming to do
you can also `my Class $foo .= new;`
tyil s/Foo.new/Class.new/ 17:25
mst comborico1611: random syntax doesn't help our confusion when we're trying to understand what the thing *means* - what semantics are you thinking of?
comborico1611 this may sound snobbish, but it's not the intent. The purpose of the name of the object is to know the name of the object.
tyil mst: I asked for an example to see the context he wants to use it in, to get a clearer case of what he means 17:26
mst yeah, that would also help
comborico1611 I'm just trying to figure out the name of the object is always the same as the class. Or if the object is anonymous. 17:26
mst I don't believe objects have names at all in the sense you're talking about, because an object is a value 17:27
perl6 is fairly clear about variables having names and values not having names
comborico1611 I'm coming from C++, where we have names for objects, not variables containing objects.
Hmm. The value of the object being the address in memory of the class? 17:28
mst if you try and understand perl6 via things like "address in memory" you will not end up understanding perl6 17:28
also I can't say I really feel like C++ has names for objects as such 17:29
tyil are you trying to achieve something in particular with these names? 17:30
comborico1611 No.
tyil then I can't say I quite understand what you mean, sorry
comborico1611 In C++ you create an object by two things, the name of the class (type) and the objects name. Ex. Time t; (Time is the class and t is the object.) 17:32
tyil in perl 6 you can do the same, my Time $t;
(also, that doesn't create the object, you'd need a `new` for that in c++, no?) 17:33
comborico1611 The constructor is called implicitly. 17:34
tyil afaik, there's no implicit constructor call in perl 6 17:34
the shortest you can get is `my Time $t .= new;`
comborico1611 I see. But $t is not the object, but a variable containing the object. 17:35
(Or so I was told last night.) 17:36
moritz most method calls ignore the container, and go right into the object
tyil that's probably going in deeper than I know of, you might want to ask a core rakudo dev for that
perlpilot comborico1611: have you read docs.perl6.org/language/containers ? 17:37
mst comborico1611: in C++ can't you still later do 't = new Time(...)' or whatever the syntax is? 17:38
comborico1611 The docs are confusing. 😯
tyil heh
comborico1611 Mst, yes. 17:38
perlpilot comborico1611: well ... at least they match life in that regard. ;) 17:39
comborico1611 Haha.
Geth doc: 397588b526 | (Ahmad M. Zawawi)++ (committed using GitHub Web editor) | doc/Language/variables.pod6
Fix spelling typo
synopsebot Link: doc.perl6.org/language/variables
mst comborico1611: right, so it's as I remembered - C++ is the same, effectively, and perl6 just makes the distinction more explicit
mst if you can change the value of the variable t to a different instance, then the C++ variable t isn't the object either 17:39
tyil moritz: now there's two App::MPD::Notify on modules.perl6, and they both show they were last updated last month, with the .git dir :( 17:40
mst it's a variable that happens to currently have a value of a particular unnamed object instance
comborico1611 But seriously I'm trying to get through this beginners book. And often when I go and read the docs, there are operators I'm not aware of. For example // or ===. Then, I have to go look those up. And I don't want to. I would rather focus on the book then go down the rabbit trail
tyil which beginner's book are you reading? 17:41
perlpilot
.oO( Perl 6 -- it's full of rabbits )
comborico1611 Think Perl
tyil does it not explain the examples in enough detail? 17:42
comborico1611 Mst, you could be correct. But I don't remember ever running into any code in my C++ book that would indicate that the 't' was rw.
mst comborico1611: but you just told me it was 17:43
comborico1611 No.
mst 't = new Time(...)' # you said yes to that, how is that not rw?
comborico1611 I'm actually a beginner programmer. I've only read one book on c++. I thought you were referring to another way of creating a object not reassigning it.
mst ok, so, if you don't understand C++ properly and I don't understand C++ properly, then we're probably best not trying to use C++ to try and understand anything else 17:44
comborico1611 lol. I I think I understand it properly. 17:45
perlpilot comborico1611: newbies always think they understand stuff when really they don't quite :)
mst if you can't tell me how variable assignment works, then I don't think it's going to be useful to us :)
tyil comborico1611: if you can supply us with a task you're trying to achieve, we might be able to assist you in getting you what you want 17:47
if the docs are unclear, that too would be appreciated to inform, then we can try to improve it
mst yeah, I've still not worked out what this mythical 'name of an object' would actually be useful for if it existed
comborico1611 Haha. Yes. Thanks for trying. 17:48
mst note: same "I'm not trying to sound snobbish/etc." caveat applies to my comments too
tyil we're all here to help eachother, so I think that's implied :> 17:49
mspo you mean like a $this ?
comborico1611 I'm not saying the docs are unclear as they are written for someone soley to use learn from. But from the perspective of someone using another's source, going and looking up a term only to see code they don't recognize, that is going to be unclear. 17:51
tyil I think that could be attributed to the source having unclear or incomplete examples 17:52
comborico1611 Roger that. Much appreciated.
mst I suspect at least in part the problem is that perl6's features interlock to an extent that makes it *really* hard to write an introduction that doesn't end up depending on things it hasn't had a chance to explain yet 17:52
comborico1611 Yeah, I don't expect the docs to line up with a book. 17:52
mst note that I've attempted to do a completely synthetic intro to perl5, and aaaaaaaaaaa 17:52
tyil comborico1611: I'd suggest you just read the book and ignore the parts that aren't quite clear, hope that everything will be explained in due time, and after that look up things as needed in the docs 17:53
comborico1611 Synthetic? Intro to p6 for p5 users?
tyil or ask around here to see if anyone might have a simple solution
perlpilot comborico1611: btw, when you figure this stuff out, maybe write a blog post or some docs or something to help the next guy :)
mst synthetic as in synthetic proof 17:54
mst where you don't rely on a concept until you've introduced it 17:54
comborico1611 Perlpilot, yes, I'm taking very detailed notes of my experience through the book.
mst think e.g. Euclid's Elements
tyil perlpilot++ more perl 6 blogs to help people realize its usable and help beginners understand it are always nice
comborico1611 I plan on submitting a review.
comborico1611 Mst, i see. 17:55
Alright guys. Off to lunch.
mst because basically that's what you sound like you want, and, well, I agree, but also I'm not good enough to make it happen for perl5 let alone perl6
perlpilot tyil: "ignore the parts that aren't quite clear" reminds me of reading LoTR. I read them when I was 8 or 9 then again as an adult. But as an adult I was incredulous that I read and understood some of the words Tolkien used. I'm pretty sure my 8 year old self just glossed over the big words (if they couldn't be figured out from context) and just kept on reading. 17:56
tyil its what I often do when I find something I don't quite understand, hoping for it to be explained shorty afterwards 17:58
then go back to see if the block I was reading is more clear now
stmuk when I read Tolkien at 11 I skipped the songs ... which I still did last time I read it! 18:01
teatime (^0x10FFFF).map({.chr}).grep({.unimatch: 'M'}) <-- this does not seem to make a lazy iterable 18:02
what am I missing 18:03
or is it because I am assigning it to a @-sigil'd variable
tadzik perlpilot: that's how I used to read books in english in general, as a non-native speaker :) 18:05
ilmari m: my $v = (^0x10FFFF).map({.chr}).grep({.unimatch: 'M'}) say $v.is-lazy; 18:07
camelia 5===SORRY!5=== Error while compiling <tmp>
Two terms in a row
at <tmp>:1
------> 3FFFF).map({.chr}).grep({.unimatch: 'M'})7⏏5 say $v.is-lazy;
expecting any of:
infix
infix stopper
postfix
s…
teatime (^0x10FFFF).lazy.map… seems to do what I want ...
ilmari m: my $v = (^0x10FFFF).map({.chr}).grep({.unimatch: 'M'}); say $v.is-lazy; 18:08
camelia False
ilmari huh, in my repl that hangs spinning on the CPU 18:08
but in -e '' it works fine 18:09
m: (^0x10FFFF).lazy.map({.chr}).grep({.unimatch: 'M'}).say
camelia (...)
ilmari m: (^0x10FFFF).lazy.map({.chr}).grep({.unimatch: 'M'}).is-lazy.say
camelia True
buggable New CPAN upload: MsgPack-0.0.7.tar.gz by AZAWAWI cpan.metacpan.org/authors/id/A/AZ/...0.7.tar.gz 18:23
HoboWithAShotgun m: class Units::MetrePerSecond² {} 19:14
camelia 5===SORRY!5=== Error while compiling <tmp>
Unable to parse class definition
at <tmp>:1
------> 3class Units::MetrePerSecond7⏏5² {}
expecting any of:
generic role
HoboWithAShotgun meh. :-)
ufobat___ is there a guide that explains how to compile rakudo on windows? e.g what compiler i could use ..and so one? 19:34
timotimo ufobat___: you can read the appveyor config for a working example 19:36
ufobat___ appvayor offers visual studio, this meens i would need to spend money, right? 19:39
timotimo no 19:39
El_Che ufobat: no,
timotimo you only need the "community edition"
ufobat okay :-) i am googling for that
El_Che ufobat: I use for an other opensource project
ufobat: you have open source accounts and the vms have lots of compilers and libs 19:40
ufobat i've created a win7 x64 vm today :-) i have no clue about windows and all the stuff 19:41
El_Che ufobat: on my todo list for some day far in the future :) 19:42
ufobat actually my "problem" is that resolve() of IO::Path doesn't work on windows. So i first looked at the rakudo code and I tryd to fix it: github.com/ufobat/rakudo/commit/db...f85bcc637a 19:44
most probably my fix is quite bad but, i wanted to try in on a windows box
El_Che ufobat: rakudo star has also windows instruction in their gh repo 19:52
ufobat: dunno how up to date it is
ufobat found it :) 19:54
HoboWithAShotgun is there an easy way to get the superscript of a given character? for instance 1 => \x[0xB9] 20:06
geekosaur probably not. and it wouldn't necessarily do you any good anyway: I tried scripting that and found that I didn;t have a font with all the superscripts/subscripts, or maybe my terminal was "correcting" them >.< 20:08
moritz HoboWithAShotgun: go through the unicode name?
what's the reverse of uniname? 20:10
lizmat c[] ?
moritz my $x = "SUPERSCRIPT ONE"; say "\c[$x]"
m: my $x = "SUPERSCRIPT ONE"; say "\c[$x]" 20:11
camelia 5===SORRY!5=== Error while compiling <tmp>
Unrecognized \c character
at <tmp>:1
------> 3my $x = "SUPERSCRIPT ONE"; say "\c[7⏏5$x]"
expecting any of:
argument list
double quotes
term
moritz lizmat: not at run time, it seems
lizmat :-(
I would have expected that to work
eugene_barsky hi 20:12
moritz hi eugene_barsky
eugene_barsky every time I write $a = $b if defined $b I feel I'm doing smth wrong, since $b needs to be evaluated twice. 20:13
Is there a better way?
HoboWithAShotgun i wonder why they didnt treat super and subscripts like diacritics you can just combine two characters 20:14
colomon eugene_barsky: $a = $b // $a # I think? it’s an odd question
moritz then you duplicate $a :-)
eugene_barsky Sorry for an odd question. :) 20:15
moritz HoboWithAShotgun: maybe they didn't want to turn Unicode into a markup language
lizmat: do you know where \c within quotes are resolved? 20:16
HoboWithAShotgun but defining a-z superscripts but ommiting the q is a sensible design choice
lizmat m: my $a = "LATIN CAPITAL LETTER A"; say $a.parse-names # samcv++ on #perl6-dev
camelia A
moritz nqp: say("\c[SUPERSCRIPT ONE]")
camelia ¹
HoboWithAShotgun nqp: say("\c[SUPERSCRIPT A]") 20:17
camelia Unrecognized character name 'SUPERSCRIPT A' at line 2, near "]\")"
at gen/moar/stage2/NQPHLL.nqp:707 (/home/camelia/rakudo-m-inst-1/share/nqp/lib/NQPHLL.moarvm:panic)
from gen/moar/stage2/NQPHLL.nqp:1332 (/home/camelia/rakudo-m-inst-1/share/nqp/lib/NQP…
colomon moritz: I don’t think $a R//= $b is going to do it? 20:18
moritz HoboWithAShotgun: uni SUPERSCRIPT|wc -l only gives me 25
colomon: no
lizmat m: my $a = "SUPERSCRIPT TWO"; say $a.parse-names
camelia ²
lizmat m: say "SUPERSCRIPT $_".parse-names for <ONE TWO THREE FOUR> 20:20
camelia ¹
²
³
Geth doc: b663b0428c | (Moritz Lenz)++ | doc/Type/Cool.pod6
Reference parse-names in the uniname(s) docs

this is where I went looking when I did not know the name of the method
20:23
synopsebot Link: doc.perl6.org/type/Cool
azawawi Caught where the pesky heap corruption bug happens at 100_000 elements (randomly) github.com/azawawi/perl6-msgpack/b...er.pm6#L25 20:30
CArray indexing has a serious bug... $sbuf.data[ ^$sbuf.size ] 20:32
Sometimes it works... sometimes it dies with either a rakudo heap corruption panic or internal error: MoarVM panic: Internal error: invalid thread ID \d+ in GC work pass... 20:33
rindolf azawawi: hi 20:33
azawawi rindolf: hey... how r u? 20:34
rindolf azawawi: I extracted a CPAN dist today
rindolf azawawi: this one - metacpan.org/pod/release/SHLOMIF/T...tedTags.pm 20:36
rindolf azawawi: and worked on freecell solver 20:37
azawawi cool
rindolf azawawi: you? 20:37
azawawi MsgPack heap corruption bug hunting :)
rindolf azawawi: ah, good luck 20:38
Geth ecosystem: 898d69601d | (Ahmad M. Zawawi)++ (committed using GitHub Web editor) | META.list
Move MsgPack to CPAN
20:52
comborico1611 Are there any other ways of creating an object besides new constructor? 21:01
And why does the constructor use => instead of using = ? 21:03
ufobat m: class Foo { method factory() { return self.bless() }}; say Foo.factory()
camelia Foo.new
comborico1611 What does bless method do? 21:04
ufobat bless actually creates an object of a class
docs.perl6.org/routine/bless 21:05
comborico1611 I see. Thank you. 21:05
ufobat have you read this: docs.perl6.org/language/objects#in...nstruction
comborico1611 Nope. I'll check it out. 21:06
geekosaur you aren't assigning, you are passing named parameters whose names are the fields to be initialized 21:06
if you tried to assign there, it would set values in the calling function, not inside the new object
comborico1611 This stuff is crazy. 21:08
geekosaur foo($a = 5) assigns 5 to $a and then calls foo($a) aka foo(5) 21:09
same would happen with new, except that it would probably throw errors about undefined names 21:10
comborico1611 I feel like C++ is a programming language, and Perl 6 is the thing that builds programming languages.
geekosaur => creates a key-value binding (a pair) in pair syntax. :name(value) does the same in a different and sometimes more convenient syntax 21:11
geekosaur m: dd (foo => 5) 21:11
camelia :foo(5)
comborico1611 Hmm.
I'll write your response in my book. 21:13
ufobat m: sub foo(:$a, :$b) { say "a is $a and b is $b" }; foo(a => 1, b => 2) 21:13
camelia a is 1 and b is 2
comborico1611 (that I'm reading)
ufobat thats basically the regular way of passing named parameters in perl6 21:14
comborico1611 Hmm.
comborico1611 geekosaur, in the expression foo.new( x => 1 ), we are passing the parameter x? 21:20
geekosaur you are passing a single parameyter that is a Pair 21:21
the key of the pair is the Str 'x', the value is the Int 1
comborico1611 Hmm. This is strange. 21:22
geekosaur => is the Pair constructor 21:22
comborico1611 Right.
geekosaur it can be also written as :x(1)
comborico1611 Can x be initialized any other way besides these two?
comborico1611 (Initialized by the conductor, that is.) 21:23
geekosaur not from outside the class definition
comborico1611 Hmm. Okay. I'll add these notes. Thank you. 21:24
ugexe clicks stackoverflow link on google for programming question. question is closed with the title 'This question is an exact duplicate of:' and the link text shown ends with [DUPLICATE] itself (also the link is a 404) 21:35
tabv Just discovered after much frustration that Buf has an append method. This isn't implied somewhere in the docs docs.perl6.org/type/Buf, is it? 22:52
jnthn tabv: It does indeed appear to be missing in the docs. 22:54
Ah, it's already filed in the issued tracker also: github.com/perl6/doc/issues/530 22:55
tabv feels like reading the sources is the best way to learn something like perl6 anyway
but it's a steep road
jnthn The sources of the built-ins are, at least, written in Perl 6 :) 22:56
jnthn m: say Buf.^methods # there's also introspection, btw 23:08
camelia (reallocate subbuf-rw)
jnthn m: say Buf.new.^methods # there's also introspection, btw
camelia (COMPARE unpack bytes of join allocate subbuf-rw Int encoding subbuf Numeric reverse Capture contents SAME decode chars reallocate WHICH Method+{is-nodal}.new Method+{is-nodal}.new Method+{is-nodal}.new pop shift splice Method+{is-nodal}.new Method+{i…
jnthn m: say Buf.new.^methods.map(*.name) 23:09
camelia (COMPARE unpack bytes of join allocate subbuf-rw Int encoding subbuf Numeric reverse Capture contents SAME decode chars reallocate WHICH AT-POS ASSIGN-POS list pop shift splice push append unshift prepend elems perl EXISTS-POS gist Bool Str new String…
jnthn Finally
tabv ah, right! 23:11
Geth doc: holli-holzer++ created pull request #1665:
Update 5to6-nutshell.pod6 (mentioned AUTOLOAD/FALLBACK)
23:24
HoboWithAShotgun letzte amtshandlung. good night ppl 23:25
b2gills m: my $a = 1; my $b = 3; $a [R//]= $b; say $a 23:29
camelia 3
colomon m: my $a = 1; my $b; $a [R//]= $b; say $a 23:32
camelia 1
colomon b2gills++ 23:33
eugene_barsky: ^^ 23:35
colomon though I don’t think I’d recommend using it instead of $a = $b if defined $b 23:36
b2gills m: my $a = 1; my $b = 3; [[[R[[[//]]]]=]] $a, $b; say $a # always remember you can always add [] around infix operators, and usually even as list reductions 23:37
camelia 3