🦋 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:01
mowcat joined
00:06
xelxebar left
00:12
Doc_Holliwood left
00:18
Xliff joined
|
|||
Xliff | m: my @a = do $_ * 2 for ^6; @a.say; | 00:19 | |
camelia | [0 2 4 6 8 10] | ||
00:22
vike left
|
|||
rypervenche | m: my @a = do $_ * 2 for 0..^6; @a.say; | 00:23 | |
camelia | [0 2 4 6 8 10] | ||
rypervenche | :) | ||
00:40
cpan-raku left,
cpan-raku joined,
cpan-raku left,
cpan-raku joined
|
|||
japhb | m: my @a = ^6 .map: * * 2; @a.say | 00:55 | |
camelia | [0 2 4 6 8 10] | ||
japhb | I mean, if you're going to play around, best to go farther afield, right? | ||
m: my@a=^6 .map: * * 2;@a.say # Whitespace golf | 00:57 | ||
camelia | [0 2 4 6 8 10] | ||
japhb | m: (my@a=^6 »*»2).say # OK, now I'm just being silly | 01:01 | |
camelia | [0 2 4 6 8 10] | ||
01:03
MasterDuke left
01:22
sena_kun joined
01:24
Altai-man_ left
01:37
wildtrees left
01:52
markong left,
Redfoxmoon_ left
01:53
tobs left
01:54
Redfoxmoon joined
|
|||
rypervenche | How do you represent a null character in Raku? \0 ? I'm trying to find it on the site. | 01:55 | |
elcaro | m: say "\0".uniname | 02:02 | |
camelia | <control-0000> | ||
elcaro | i'm not sure it's documented explicity anywhere. see this issue: github.com/Raku/doc/issues/2313 | 02:03 | |
02:04
Xanozoid joined
|
|||
Xanozoid | hi | 02:04 | |
rypervenche | elcaro: Thank you. | 02:05 | |
02:05
tobs joined
|
|||
Xliff | m: my $f = sub { $^a * 2 }; my @a = ^5 » $f(*); @a.say | 02:07 | |
camelia | 5===SORRY!5=== Error while compiling <tmp> Missing infix inside hyper at <tmp>:1 ------> 3my $f = sub { $^a * 2 }; my @a = ^5 »7⏏5 $f(*); @a.say expecting any of: infix infix stopper |
||
Xliff | m: my $f = sub { $^a * 2 }; my @a = (^5).map: $f(*); @a.say | ||
camelia | Cannot resolve caller Numeric(Whatever:D: ); none of these signatures match: (Mu:U \v: *%_) in sub at <tmp> line 1 in block <unit> at <tmp> line 1 |
||
Xliff | m: my $f = sub { $^a * 2 }; my @a = (^5).map({ $f($_) }); @a.say | ||
camelia | [0 2 4 6 8] | ||
Xanozoid | can Raku be ran client-side in a website? | 02:08 | |
Xliff | Actually, it can with rakudo-js | ||
Xanozoid | is that the official name for it? or is that a supported target via Rakudo? I can't really seem to find much on the web about that | 02:09 | |
Thanks Xliff | |||
Xliff | blogs.perl.org/users/pawel_murias/2...arcel.html | 02:10 | |
Xanozoid | I'm getting a feeling it's not really completely supported . . . dead link and very small example - and the most recent update is 2018? | 02:12 | |
02:12
molaf left
|
|||
Xliff | github.com/rakudo/rakudo/tree/master/src/vm/js | 02:13 | |
It's still around. See above | 02:14 | ||
pilne | anyone know off the top of their head how to use this under win32? my ($h, $w) = qx/stty size/.words>>.Int; I have tried a quick google, but nothing i'm finding is very direct. | 02:16 | |
i know the problem lies in the qx/stty size/ part | |||
Xanozoid | Xliff looking at it right now - good to see that it exists! | 02:17 | |
02:19
vike joined
02:24
molaf joined
02:27
leont left
02:49
Doc_Holliwood joined
03:21
Altai-man_ joined
03:24
sena_kun left
|
|||
Xliff | m: .say for 0, 2 .. 10 | 03:37 | |
camelia | 0 2..10 |
||
Xliff | m: .say for 0, 2 ... 10 | ||
camelia | 0 2 4 6 8 10 |
||
Xliff | m: .say for ^10.rotor(2) | ||
camelia | Potential difficulties: Precedence of ^ is looser than method call; please parenthesize at <tmp>:1 ------> 3.say for ^107⏏5.rotor(2) |
||
Xliff | m: .say for (^10).rotor(2) | ||
camelia | (0 1) (2 3) (4 5) (6 7) (8 9) |
||
Xliff | m: "φ".uniname.say | 03:51 | |
camelia | GREEK SMALL LETTER PHI | ||
pilne | is there a cheat sheet somewhere that has the non-unicode version of the popular/all unicode commands? | 03:52 | |
04:06
reach_satori left
04:07
reach_satori joined
04:08
Xanozoid left
04:27
Xliff left
04:39
mowcat left
04:46
pilne left
04:58
Doc_Holliwood left
05:23
sena_kun joined
05:24
Altai-man_ left
|
|||
holyghost | I revived Game-Markov in github.com/theholyghost2/p6-Game-Markov | 05:41 | |
I will be implementing more Markov strategies in that package e.g. Markov Chain Monte Carlo methods, samplers | 05:42 | ||
06:03
lizmat left
06:06
reach_satori left
06:08
aborazmeh left
06:18
aborazmeh joined,
aborazmeh left,
aborazmeh joined
06:20
HarmtH left
06:22
reach_satori joined,
aborazmeh left
06:23
jmerelo joined
06:28
Redfoxmoon left,
Redfoxmoon joined
06:29
sauvin joined
06:38
Xliff joined,
aborazmeh joined,
aborazmeh left,
aborazmeh joined
|
|||
Xliff | m: $a; ($a = $_ for 1...5).map({ $_ / 2 }).gist.say | 06:39 | |
camelia | 5===SORRY!5=== Error while compiling <tmp> Variable '$a' is not declared at <tmp>:1 ------> 3<BOL>7⏏5$a; ($a = $_ for 1...5).map({ $_ / 2 }). |
||
Xliff | m: my $a; ($a = $_ for 1...5).map({ $_ / 2 }).gist.say | ||
camelia | (2.5 2.5 2.5 2.5 2.5) | ||
Xliff | m: my %a; (%a{$_} = $_ for 1...5).map({ $_ / 2 }).gist.say | ||
camelia | (0.5 1 1.5 2 2.5) | ||
06:40
ZzZombo left
06:42
ZzZombo joined
|
|||
holyghost | I've put in a Metropolis-Hastings algorithm in p6-Game-Markov on github | 06:46 | |
It's the most known Markov algorithm | 06:47 | ||
06:47
stoned75 joined
06:48
ZzZombo left
06:50
ZzZombo joined
06:52
aborazmeh left
07:01
HarmtH joined,
wamba joined
07:06
Xliff left
07:09
lizmat joined
07:10
rindolf joined
07:16
stoned75 left
07:20
stoned75 joined
07:21
Altai-man_ joined
07:22
sno left
07:24
sena_kun left
07:25
rindolf left
07:26
rindolf joined,
ZzZombo left
07:29
ZzZombo joined
07:31
jmerelo left
07:36
lizmat left
07:54
ZzZombo left,
ZzZombo joined
08:00
sno joined
08:01
stoned75 left
08:02
kent\n left
08:06
lizmat joined,
dakkar joined
08:07
kent\n joined
08:28
wamba left,
wamba joined
08:45
wamba left
08:52
lizmat left
08:55
wamba joined
09:00
reach_satori left
09:01
lizmat joined
09:06
wamba left,
wamba joined
09:07
jhill left,
rypervenche left,
awwaiid left,
CIAvash left,
rba[m] left,
Kaiepi left,
finsternis left,
Celelibi left,
APic left,
Hotbees left,
unicodable6 left,
greppable6 left,
sourceable6 left,
nativecallable6 left,
shareable6 left,
bloatable6 left,
committable6 left,
coverable6 left,
mtj_ left,
ssm left
09:09
hacktor left
09:11
Doc_Holliwood joined
09:22
sena_kun joined
09:24
Altai-man_ left
09:27
bdju left,
bdju joined
09:28
markong joined
09:39
lizmat left
09:43
NODE left,
jhill joined,
rypervenche joined,
CIAvash joined,
rba[m] joined,
awwaiid joined,
Kaiepi joined,
finsternis joined,
Celelibi joined,
APic joined,
Hotbees joined,
unicodable6 joined,
greppable6 joined,
nativecallable6 joined,
sourceable6 joined,
shareable6 joined,
bloatable6 joined,
committable6 joined,
coverable6 joined,
mtj_ joined,
ssm joined,
APic left,
jhill left
09:44
NODE joined
09:45
jhill joined
09:49
APic joined
09:52
pecastro joined
09:54
margeas joined
09:56
lizmat joined
09:58
markong left
10:16
reach_satori joined
10:42
wamba left
10:45
mowcat joined
11:14
Black_Ribbon left
11:21
Altai-man_ joined
11:24
sena_kun left
11:25
xinming_ left
11:26
xinming_ joined,
NODE left
11:28
NODE joined
11:33
_jrjsmrtn left
11:39
lizmat left
11:45
reach_satori left
11:46
aborazmeh joined,
aborazmeh left,
aborazmeh joined
11:57
wamba joined
12:05
NODE left
12:07
NODE joined
12:14
chloekek joined
12:15
regreg joined
12:16
leont joined
12:20
lizmat joined
12:34
__jrjsmrtn__ joined
12:50
ZzZombo_ joined
12:51
__jrjsmrtn__ left
12:53
Doc_Holliwood left,
ZzZombo left,
ZzZombo_ is now known as ZzZombo
12:58
wamba left
13:03
wamba joined
13:11
aborazmeh left
13:22
sena_kun joined
13:24
Altai-man_ left
13:30
margeas left,
TheAthlete joined
13:31
wamba1 joined,
wamba left
|
|||
nine | pmurias: do you remember anything at all about how one can use Perl's pluggable keyword mechanism to detect the end of a Perl 5 block in the surrounding Raku code? I did have the same idea once but can't for the life of mine remeber how to pull that off. | 13:31 | |
tellable6 | nine, I'll pass your message to pmurias | ||
13:50
NODE left
13:52
NODE joined
13:54
xinming_ left
13:56
xinming_ joined
14:00
wamba1 left
14:11
wamba joined
14:16
lucasb joined
14:19
xinming_ left
14:20
xinming_ joined
14:30
__jrjsmrtn__ joined
14:35
_jrjsmrtn joined,
__jrjsmrtn__ left
14:39
wamba left
14:41
ccamel joined
14:42
camelCaser left
14:44
dansolo42 left
14:45
mowcat left
14:52
dansolo42 joined
|
|||
lucs | Can I have raku and zef run using other directories than ~/.raku and ~/.zef? | 14:54 | |
(Want to play with different versions of raku and make absolutely sure that there are no interferences with whatever raku is already installed on my system) | 14:55 | ||
regreg | is anyone here familiar with moarvm? | 14:56 | |
where can i read more about moarvm? | |||
i want to know what kind of ISA it uses | |||
lucs | (I think I know how to fix the PATH for this, but not ~/.raku and ~/.zef) | ||
regreg | and what are it's limitations | ||
leont | There is a #moarvm channel | 14:59 | |
14:59
xinming_ left
|
|||
regreg | thanks | 14:59 | |
15:01
xinming_ joined,
erdic left
15:02
erdic joined
|
|||
chloekek | I recall somebody was interested in packaging Rakudo and Raku packages for Nix, but I don’t recall their name. | 15:04 | |
Thing is, for doing that I was working on this index of packages called CRAI and I’m not sure if I want to continue running it. | 15:06 | ||
Right now it is not all that useful; it indexes all archives from CPAN and p6c every hour and displays metadata about them on a website. This includes the URL and the hash, which are very useful for package managers. | 15:07 | ||
Considering I’m not using Raku all that much I’d like to not run that server anymore as I currently pay for hosting it every month and I don’t think anyone is using it, but the software may still have potential. | 15:08 | ||
regreg | chloekek, how much does it costs to run the server? and what about time sunk? | 15:09 | |
chloekek | Oh lol it’s only 6 EUR apparently. | 15:10 | |
rba | chloekek: what is this used for exactly? | ||
regreg | i could pay for it if it has any use for the community but i don't know how to manage it | 15:11 | |
chloekek | rba: There are currently two places where you can find Raku library archives: CPAN and the ecosystem repository. CPAN provides an easy way to download specific versions (archives) of libraries, but the ecosystem does not as it just points to Git repositories’ master branch. | ||
rba | If there is common community usage, I might take it over under the umbrella of raku infra. | ||
regreg | but it will have to wait until i receive next disability payment (which will about around 12 march) | ||
chloekek | rba: So I wrote a cronjob that periodically downloads all those libraries though stable tarball URLs, and computes their hashes. This information could be useful if exposed in a machine readable format, but I don’t really have the time to work on that. | 15:12 | |
It generates a SQLite database that has a table in it with (tarball URL, tarball hash, META6 extract) | |||
rba | Does it overlap with modules.raku.org or zef? | ||
chloekek | modules.raku.org only seems to index latest version of each library, and does not provide hashes. | 15:13 | |
Without hashes, you don’t really know what you are downloading. | |||
The problem is really with ecosystem repository, it just points to Git repositories, but those don’t tell you how to get a specific version of each library. | |||
rba | Got it. I will take over hosting. Who is taking over the development? | ||
chloekek | Say you want Foo::Bar v1.0. You would need to clone its git repository and search the git commits for the one that bumps the version to v1.0 in META6.json, except for the rare case of libraries using Git tags. | 15:14 | |
And even then, the author could release v1.0, then update the repository to include malicious code, and change the tag to refer to the new commit, and people would suddenly be deploying that. | 15:15 | ||
rba | May we look into details later today. 20:00 CET or later, or this sunday? | 15:17 | |
chloekek | Sure. | ||
May open an issue on problem-solving about archiving and version discovery. | 15:18 | ||
jmerelo: was also interested in this. | |||
tellable6 | chloekek, I'll pass your message to jmerelo | ||
chloekek | Here’s an example of what it indexes: crai.foldr.nl/archive?url=https://...e8c.tar.gz | 15:21 | |
rba | Chloekek: problem-solving makes sense. | ||
15:21
Altai-man_ joined
15:22
_jrjsmrtn left
|
|||
chloekek | I suppose integrating the cronjob into modules.raku.org would make sense, but we’ll discuss this on/after the problem-solving issue. :) | 15:24 | |
15:24
sena_kun left
15:26
__jrjsmrtn__ joined
15:34
TheAthlete left
15:38
Chatty joined,
Chatty left
15:41
mensvaga joined
15:50
aborazmeh joined,
aborazmeh left,
aborazmeh joined
15:52
wamba joined
15:56
NODE left
15:58
NODE joined
16:07
dakkar left,
dakkar joined
16:23
lizmat left
16:25
wamba left
16:26
wamba joined
16:39
aborazmeh left
16:55
chloekek left
17:01
jmerelo joined
17:02
benlittle joined
17:22
sena_kun joined
17:24
Altai-man_ left
17:33
leont left
17:34
Xliff joined
|
|||
Xliff | m: sub a { say $*ROUTINE.name }; a; | 17:34 | |
camelia | Dynamic variable $*ROUTINE not found in sub a at <tmp> line 1 in block <unit> at <tmp> line 1 |
||
Xliff | m: sub a { say $?ROUTINE.name }; a; | ||
camelia | 5===SORRY!5=== Error while compiling <tmp> Variable '$?ROUTINE' is not declared. Did you mean 'Routine'? at <tmp>:1 ------> 3sub a { say 7⏏5$?ROUTINE.name }; a; |
||
Xliff | m: sub a { say &?ROUTINE.name }; a; | 17:35 | |
camelia | a | ||
Xliff | m: sub a ('one', 'two', 'three') { say &?ROUTINE.signature.params.map( *.type ).join(', ').say-route }; a('one', 'two', 'three'); | 17:38 | |
camelia | Use of uninitialized value of type Str in string context. Methods .^name, .raku, .gist, or .say can be used to stringify it to something meaningful. in sub a at <tmp> line 1 Use of uninitialized value of type Str in string context. Methods .… |
||
Xliff | m: sub a ('one', 'two', 'three') { say &?ROUTINE.signature.params.map( *.name ).join(', ').say-route }; a('one', 'two', 'three'); | ||
camelia | Use of Nil in string context in sub a at <tmp> line 1 Use of Nil in string context in sub a at <tmp> line 1 Use of Nil in string context in sub a at <tmp> line 1 No such method 'say-route' for invocant of type 'Str' in sub a at <… |
||
Xliff | m: sub a ('one', 'two', 'three') { say &?ROUTINE.signature.params.map( *.name ).join(', ').say }; a('one', 'two', 'three'); | ||
camelia | Use of Nil in string context , , True in sub a at <tmp> line 1 Use of Nil in string context in sub a at <tmp> line 1 Use of Nil in string context in sub a at <tmp> line 1 |
||
17:39
dakkar left
17:40
benlittle left
|
|||
Xliff | The hell... these are constants. How can I get their value from the signature? | 17:43 | |
17:47
pecastro left
17:49
leont joined
17:53
MasterDuke joined
17:54
molaf left
17:56
mensvaga left
18:07
TheAthlete joined
18:12
PavelB joined
18:14
sno left
18:18
sivoais left
18:21
chloekek joined
18:26
xinming_ left,
TheAthlete left
18:27
xinming_ joined,
sivoais joined
18:46
mensvaga joined
18:55
veesh left,
Doc_Holliwood joined
18:56
wamba left
19:08
veesh joined,
mowcat joined
19:10
MasterDuke left
19:15
wildtrees joined
19:21
Altai-man_ joined
19:24
sena_kun left
19:26
sauvin left
|
|||
Xliff | Any Cro ppl here? | 19:27 | |
19:32
cpage joined
19:33
sno joined
19:37
jmerelo left
|
|||
cpan-raku | New module released to CPAN! Date::Calendar::FrenchRevolutionary (0.0.4) by 03JFORGET | 19:37 | |
19:37
cpage left
19:41
cpage joined
19:53
caterfxo left
19:54
caterfxo joined,
molaf joined
20:14
aborazmeh joined,
aborazmeh left,
aborazmeh joined
20:21
caterfxo left
20:24
MasterDuke joined
20:27
caterfxo joined
20:35
rindolf left
20:37
Xliff left
20:55
Black_Ribbon joined
20:58
regreg left
21:03
aborazmeh left
21:09
regreg joined
21:14
TreyHarris left
21:23
sena_kun joined
21:24
Altai-man_ left
21:30
chloekek left
21:38
Jose86 joined
21:39
vike left
|
|||
Jose86 | Quick question when using zef to install a module, in this case Cro, it didnt get added to the Path variable. Does zef currently not do this? | 21:40 | |
rypervenche | Jose86: Not that I've seen. I set my PATH for my zef-installed modules to be usable (for the executables) | 21:41 | |
Jose86 | Thank you rypervenche | ||
21:42
Jose86 is now known as codernic
21:46
codernic left,
wildtrees left
|
|||
cpan-raku | New module released to CPAN! Gnome::N (0.15.7) by 03MARTIMM | 21:51 | |
Geth | doc: 89fd872197 | (Tom Browder)++ (committed using GitHub Web editor) | doc/Language/quoting.pod6 correct typo |
21:52 | |
linkable6 | Link: docs.raku.org/language/quoting | ||
22:21
cpan-raku left
22:22
cpan-raku joined,
cpan-raku left,
cpan-raku joined
22:23
margeas joined
22:31
lizmat joined
22:42
vike joined,
markoong joined
22:46
margeas left
22:49
san_goku_ssj_10 joined
|
|||
san_goku_ssj_10 | Hi. Is Rakudo free of malwares ? | 22:50 | |
22:56
lucasb left
23:06
wildtrees joined
23:08
MasterDuke left
23:11
wildtrees left,
wildtrees joined
|
|||
san_goku_ssj_10 | HELP | 23:17 | |
How could I change the the value of an argument passed to a routine ? | 23:18 | ||
The variable is immuable, and i don't know how to override this feature | 23:19 | ||
SORRY, I'M A BIG NOOB | |||
23:22
Altai-man_ joined
|
|||
san_goku_ssj_10 | Altai-man_ Hi | 23:23 | |
Altai-man_ | san_goku_ssj_10, o/ | ||
oh | |||
san_goku_ssj_10, can you provide some code? a couple of lines showing what do you want to do. | 23:24 | ||
as for argument passed, you can e.g. set it as `is rw`: | |||
m: sub foo($a is rw) { $a = 42 }; my $b = 50; say $b; foo($b); say $b; | |||
camelia | 50 42 |
||
23:25
sena_kun left
|
|||
Altai-man_ | san_goku_ssj_10, is ^ close to what you want? | 23:25 | |
lizmat | there's also "is copy" | ||
sleep& | |||
Altai-man_ | lizmat, good night, rest well. o/ | 23:26 | |
23:28
pecastro joined
23:32
PavelB left
23:37
caterfxo left
|
|||
san_goku_ssj_10 | lizmat help | 23:41 | |
please | |||
23:41
markong joined
|
|||
rypervenche | Du calme, there's no rush here :) | 23:42 | |
san_goku_ssj_10 | please | 23:43 | |
pastebin.com/raw/Gg0bMDix | |||
this code does not work | |||
please help me | |||
I'm a super noob | |||
and new to Raku | |||
I don't understand | |||
please help ! | |||
rypervenche | san_goku_ssj_10: I believe you should make the default value in the signature. | 23:44 | |
23:44
pecastro left
|
|||
san_goku_ssj_10 | rypervenche could you please post a sample ? | 23:45 | |
23:45
markoong left
|
|||
rypervenche | san_goku_ssj_10: pastebin.com/raw/9yBNackX | 23:45 | |
That is one way, if you want the default $message to have a certain value. | 23:46 | ||
23:48
aborazmeh joined,
aborazmeh left,
aborazmeh joined
|
|||
san_goku_ssj_10 | rypervenche thanks. It's impossible to change the value of the variable inside the routine ? | 23:48 | |
rypervenche | san_goku_ssj_10: As others have said, you can add "is rw" or "is copy" after Str $message in the signature. | 23:49 | |
san_goku_ssj_10 | I have try it | 23:50 | |
but I have this error message | |||
Parameter '$message' expected a writable container, but got Str value in sub message at main.pl line 3 in block <unit> at main.pl line 10 | |||
rypervenche | Ah yes, I'm wrong there. | 23:51 | |
Try "is copy" instead. | 23:52 | ||
That works. | |||
san_goku_ssj_10 | thanks | ||
Perl6 is a lot functionnal | 23:53 | ||
i think | |||
rypervenche | That's the idea :) | ||
san_goku_ssj_10 | thanks | 23:55 | |
23:55
san_goku_ssj_10 left
|