🦋 Welcome to Raku! raku.org/ | evalbot usage: 'p6: say 3;' or /msg camelia p6: ... | irclog: colabti.org/irclogger/irclogger_log/raku
Set by ChanServ on 14 October 2019.
00:08 frost-lab joined 00:16 BenGoldberg joined 00:25 patrickb left 00:33 rindolf left 00:37 notagoodidea left 00:44 lucasb left 00:50 BenGoldberg left 01:06 pecastro left 01:09 ToddAndMargo joined
ToddAndMargo Anyone on newbie duty? A question on the "use" in a class declaration. In "is $.x". does the dot have a special meaning or is it just to make the value ($.x) easier to access ($objectname.x)? 01:13
typo. "is $.x" should have been "use $.x". :'( 01:14
Xliff m: my @a = (2).Set; @a.append: 3, 4; @a.^name.say 01:22
camelia Array
Xliff m: my $a = (2).Set; $a.append: 3, 4; $a.^name.say
camelia Cannot resolve caller append(Set:D: Int:D, Int:D); none of these signatures match:
(Any:U \SELF: |values)
in block <unit> at <tmp> line 1
Xliff m: my $a = (2).Set; $a.push: 3, 4; $a.^name.say
camelia Cannot resolve caller push(Set:D: Int:D, Int:D); none of these signatures match:
(Any:U \SELF: |values)
in block <unit> at <tmp> line 1
Xliff m: Set.^methods(*.^name).say 01:23
camelia Too many positionals passed; expected 2 arguments but got 3
in block <unit> at <tmp> line 1
Xliff m: Set.^methods(*.name).say
camelia Too many positionals passed; expected 2 arguments but got 3
in block <unit> at <tmp> line 1
ToddAndMargo Are you guys writing to me or to each other? 01:24
Grinnz camelia is a bot 01:32
frost-lab m: run 'date' 01:33
camelia Thu Dec 31 02:33:40 CET 2020
01:42 RaycatWhoDat joined
RaycatWhoDat Hello. Currently working on day 04 of Advent of Code (because I forgot about it). 01:43
I think something is wrong with my grammar but, for some reason, it says 181 or 189 passports are correct. 01:44
But the correct answer is neither of these.
Not sure where I went wrong.
<github.com/RayMPerry/advent-of-cod...4.raku> 01:45
guifa2 ToddAndMargo: Where did you see "use $.x"? 'use' is normally followed by a module name, and '$.x' would normally be preceeded by "has" 01:55
ToddAndMargo I shortened things too much. Here is an example of the whole thing: class Fruit { has Str $.location is rw; has UInt $.apples is rw; has UInt $.oranges is rw; has UInt $.bananas is rw; } 01:58
my $FruitStand = Fruit.new( location => "Cucamonga", apples => 400, oranges => 200, bananas => 50 );
print $FruitStand.location ~ "has " ~ $FruitStand.apples ~" apples in stock\n";
I am just wondering if the dot in $FruitStand.apples is there just to make it easier to access or does the dot have a special meaning 01:59
guifa2 The dot itself is technically an operator, it means "call the method 'apples' on the preceeding object". So $FruitStand.apples translates to "call the method 'apples' on the object $FruitStand" 02:06
02:06 cooper left
ToddAndMargo If I was to declare apples as "use $apples", instead of .apples, would it mess things up? 02:07
[Coke] has and use both have specific meanings, so yes. 02:10
guifa2 Yes, it would. $apples is not a module, which is what 'use' is for
[Coke] if you mean "has $apples", yes, attributes should be declared with a sigil and either a ! twigil (private) or . (public) 02:11
ToddAndMargo Okay, I think I understand now. Thank you! (And no wonder some examples I has seen did not work.) 02:12
guifa2 Is there any way to fake input to prompt for the purpose of testting? 02:35
I tried $*IN.say but that doesn't seem to work
02:38 rindolf joined 02:42 ToddAndMargo left
[Coke] Could probably define a simple class and replace $*IN to return data when asked. 02:46
02:46 BenGoldberg joined
[Coke] m: temp $*IN = class { method get( ) { 'eek' } } say prompt "what?"; 02:48
camelia 5===SORRY!5=== Error while compiling <tmp>
Strange text after block (missing semicolon or comma?)
at <tmp>:1
------> 3$*IN = class { method get( ) { 'eek' } }7⏏5 say prompt "what?";
expecting any of:
infix
inf…
[Coke] m: temp $*IN = class { method get( ) { 'eek' }; }; say prompt "what?";
camelia what?eek
[Coke] guifa2: ^^
guifa2 [Coke]+++ Perfect. I ended up with class FakeInput { has $.response is rw; method get { $!response } } so I can play around with it easily 02:52
Xliff [Coke]++ 02:55
m: sub a { once { say 'OHAi!' }; say 'Beep!' }; a xx 4 02:59
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared routine:
xx used at line 1
Xliff m: sub a { once { say 'OHAi!' }; say 'Beep!' }; a() xx 4
camelia OHAi!
Beep!
Beep!
Beep!
Beep!
Xliff Oh, that's niiice.
guifa2 [Coke]: unfortunately zef doesn't seem to like it 03:09
boo 03:11
Geth ecosystem/alabamenhu-patch-3: d13624305b | L'Alabameñu++ (committed using GitHub Web editor) | META.list
Add Intl::Prompt::YesNo to ecosystem

Let's see if we can get this one the first try
03:13
ecosystem: alabamenhu++ created pull request #574:
Add Intl::Prompt::YesNo to ecosystem
guifa2 [Coke]: the module it was gonna be used in: github.com/alabamenhu/IntlPromptYesNo 03:14
tony-o guifa2: password prompt?
guifa2 tony-o no, just a yes/no prompt 03:15
Xliff m: say Q(2+2) 03:16
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared name:
Q used at line 1
Xliff m: say Q (2+2) 03:18
camelia 2+2
03:29 Xliff left 03:39 dataangel joined, |Sno| joined 03:42 [Sno] left 03:45 RaycatWhoDat left 03:58 rindolf left 04:06 leont left 04:24 jmchael left
raku-bridge <sampersand> . 04:31
05:24 linkable6 left, evalable6 left 05:26 evalable6 joined 05:27 linkable6 joined 05:58 BenGoldberg left 06:00 Doc_Holliwood joined, agentzh left 06:34 agentzh joined, agentzh left, agentzh joined
Geth ecosystem: d13624305b | L'Alabameñu++ (committed using GitHub Web editor) | META.list
Add Intl::Prompt::YesNo to ecosystem

Let's see if we can get this one the first try
06:38
ecosystem: 048b85b9b8 | (Juan Julián Merelo Guervós)++ (committed using GitHub Web editor) | META.list
Merge pull request #574 from Raku/alabamenhu-patch-3

Add Intl::Prompt::YesNo to ecosystem
06:59 rindolf joined 07:01 brtastic joined 07:23 aborazmeh joined, aborazmeh left, aborazmeh joined 07:25 Doc_Holliwood left 07:46 parabolize left 07:52 sjm_uk joined 07:53 frost-lab left 07:55 jmerelo joined 08:00 aborazmeh left
jmerelo m: $FOO::bar = 33; say FOO::.^methods 08:02
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared name:
FOO used at line 1
jmerelo That works from the REPL... 08:03
m: $foo::bar = 33; say foo::.^name 08:07
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared routine:
foo used at line 1
jmerelo m: $FOO::bar = 33; say FOO::.^name 08:08
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared name:
FOO used at line 1
jmerelo Now this is weird
m: $Foo::bar = 33; say Foo::.^name
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared name:
Foo used at line 1
jmerelo m: $bar::baz = 33; say bar::.^name 08:13
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared routine:
bar used at line 1. Did you mean 'bag', 'VAR'?
jmerelo m: package foo {}; $bar::baz = 33; say bar::.^name 08:16
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared routine:
bar used at line 1. Did you mean 'VAR', 'bag'?
jmerelo m: my $bar = 33; package foo {}; $bar::baz = 33; say bar::.^name 08:17
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared routine:
bar used at line 1. Did you mean 'bag', 'VAR'?
08:20 Kaiepi left, Kaiepi joined
jmerelo m: $bar::baz = 33; say ::bar::.^name 08:21
camelia 5===SORRY!5=== Error while compiling <tmp>
No such symbol 'bar'
at <tmp>:1
------> 3$bar::baz = 33; say ::bar::7⏏5.^name
jmerelo m: $bar::baz = 33; say MY::bar::.^name 08:22
camelia Stash
jmerelo m: $bar::baz = 33; say ::bar::.^name
camelia 5===SORRY!5=== Error while compiling <tmp>
No such symbol 'bar'
at <tmp>:1
------> 3$bar::baz = 33; say ::bar::7⏏5.^name
jmerelo m: $bar::baz = 33; say MY::bar::.^name; say bar::.raku;
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared routine:
bar used at line 1. Did you mean 'VAR', 'bag'?
08:23 |Sno| left
jmerelo m: $bar::baz = 33; say MY::bar::.^name, MY::bar::.raku 08:23
camelia Stash{}
jmerelo m: $bar::baz = 33; say MY::bar::.^name, MY::zyyz::.raku
camelia Stash{}
jmerelo m: $bar::baz = 33; my $p-bar = bar::; say $p-bar.raku; 08:24
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared routine:
bar used at line 1. Did you mean 'VAR', 'bag'?
jmerelo m: $bar::baz = 33; say bar::.raku; 08:29
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared routine:
bar used at line 1. Did you mean 'bag', 'VAR'?
jmerelo m: $bar::baz = 33; package bar {}; say bar::.raku;
camelia {"\$baz" => 33}
jmerelo m: $bar::baz = 33; say MY::bar.raku; say bar::.raku; 08:33
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared routine:
bar used at line 1. Did you mean 'VAR', 'bag'?
jmerelo m: $bar::baz = 33; say MY::bar.^name; say bar::.raku; 08:36
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared routine:
bar used at line 1. Did you mean 'bag', 'VAR'?
jmerelo m: $bar::baz = 33; say bar::.raku;
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared routine:
bar used at line 1. Did you mean 'VAR', 'bag'?
08:36 Doc_Holliwood joined, wamba joined
jmerelo m: $bar::baz = 33; package bar {}; say bar::.raku; 08:37
camelia {"\$baz" => 33}
08:42 frost-lab joined
jmerelo m: $bar::baz = 33; package bar {}; say bar::.raku; 08:44
camelia {"\$baz" => 33}
jmerelo m: $bar::baz = 33; package bar {}; say bar::.raku; $baz::quux = 44; say baz::.raku
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared routine:
baz used at line 1. Did you mean 'bag'?
08:48 aluaces left
jmerelo m: role A { mutli method BUILD() { say "A" } }; class B does A { } } 09:04
camelia 5===SORRY!5=== Error while compiling <tmp>
Could not instantiate role 'A':
Cannot invoke this object (REPR: Null; VMNull)
at <tmp>:1
jmerelo m: macro FOO { 'say 1' }; FOO; 09:06
camelia 5===SORRY!5=== Error while compiling <tmp>
Use of macros is experimental; please 'use experimental :macros'
at <tmp>:1
------> 3macro7⏏5 FOO { 'say 1' }; FOO;
jmerelo m: use experimental :macros; macro FOO { 'say 1' }; FOO;
camelia 5===SORRY!5=== Error while compiling <tmp>
Type check failed in macro application; expected AST but got Str ("say 1")
at <tmp>:1
------> 3ntal :macros; macro FOO { 'say 1' }; FOO7⏏5;
expecting any of:
argument list
09:06 patrickb joined 09:08 Sgeo left 09:12 epony left 09:13 patrickb left 09:14 patrickb joined 09:15 aluaces joined, Doc_Holliwood left 09:22 Altai-man joined 09:52 epony joined 10:07 sno joined 10:18 wamba left 10:20 klapperl_ left 10:24 aborazmeh joined, aborazmeh left, aborazmeh joined 10:37 patrickb left 10:43 Doc_Holliwood joined 10:44 frost-lab left 10:47 aborazmeh left, Black_Ribbon left 10:54 sjm_uk left 10:58 sjm_uk joined 11:04 wamba joined
raku-bridge <frost> m:run 'date' 11:18
evalable6 Thu 31 Dec 2020 12:18:20 PM CET
11:23 Doc_Holliwood left 11:43 dotdotdot left 11:49 dotdotdot joined, sno left
Geth ¦ problem-solving: JJ assigned to codesections Issue Name (and release date) proposal for 6.e github.com/Raku/problem-solving/issues/254 11:53
11:54 sno joined 11:55 jmerelo left 11:57 sena_kun joined 11:59 Altai-man left 12:00 dataangel left 12:31 leont joined, pecastro joined
tib tony-o it is fixed for me 12:35
12:41 klapperl joined
Geth ¦ problem-solving: AlexDaniel self-unassigned There's a huge PR/issue deficit in the Rakudo repo github.com/Raku/problem-solving/issues/5 13:15
13:32 aborazmeh joined, aborazmeh left, aborazmeh joined 13:37 aborazmeh left 13:38 aborazmeh joined, aborazmeh left, aborazmeh joined 13:46 brtastic left 13:58 Doc_Holliwood joined, Manifest0 left 14:03 jmchael joined 14:12 aborazmeh left 14:20 leont left 14:46 wamba left 14:55 sena_kun left 14:58 Manifest0 joined 14:59 Sgeo joined 15:03 Manifest0 left 15:04 sena_kun joined 15:05 Manifest0 joined 15:06 Xliff joined 15:08 sena_kun left 15:39 sena_kun joined 15:46 brtastic joined 15:57 Altai-man joined, wamba joined 15:59 sena_kun left, sjm_uk left 16:00 parabolize joined 16:17 _jrjsmrtn joined 16:18 __jrjsmrtn__ left 16:48 cpan-raku left 16:49 cpan-raku joined, cpan-raku left, cpan-raku joined 16:54 mowcat joined 17:02 guifa2 left 17:31 wamba left 18:17 aluaces left, aluaces joined 18:24 finsternis joined 18:37 sjm_uk joined 18:44 sjm_uk left
m6locks anybody ever tried this? www.youtube.com/watch?v=6r7bNYVdUVw 19:11
Altai-man m6locks, it works, but is more buggy compared to moarvm, also is known to be much slower, due to less people actively maintaining it. 19:14
m6locks would have guessed it is faster because jvm 19:15
ok well they mention the speed issue right in the beginning 19:17
19:18 wamba joined
Altai-man m6locks, well, Java is a simple language and Raku is much more flexible, especially around its object model, but also a looot of other things. I mean, it all boils down to how nice you can project the abstractions from high-level to JVM level. More maintainers mean more speed. 19:18
m6locks aye 19:21
19:24 thundergnat left 19:34 dataangel joined 19:37 sftp left 19:38 sftp joined 19:47 Grinnz left, jcallen left 19:48 kini left 19:49 jcallen joined, kini joined 19:50 Grinnz joined, mowcat left 19:51 Altai-man left 19:59 Black_Ribbon joined 20:12 b2gills left 20:13 rindolf left 20:41 b2gills joined
MasterDuke m6locks: the jvm backend can be faster than moarvm, but only after lots of iterations or for long-running tasks. pmurias is working on a truffle implementation of the jvm backend. it's not complete, but on one or two things is faster than both normal jvm backend and moravm 20:52
20:53 mowcat joined 21:02 bigdata joined 22:07 bigdata left, benjif joined 22:38 sena_kun joined 22:44 wamba left 22:50 wamba joined 23:00 asymptotically left, asymptotically joined, asymptotically left 23:01 asymptotically joined
timotimo happy new year gmt+1folks 23:11
moritz same to you, timotimo! 23:12
23:26 Tirifto joined 23:34 brtastic left 23:54 sena_kun left 23:55 Xliff left