🦋 Welcome to the former MAIN() IRC channel of the Raku Programming Language (raku.org). This channel has moved to Libera (irc.libera.chat #raku) Set by lizmat on 23 May 2021. |
|||
00:02
reportable6 left
00:46
Henry151 is now known as NotHenry151
00:47
NotHenry151 is now known as Henry151
00:50
frost joined
00:56
frost left
01:04
reportable6 joined
01:58
phogg left
02:39
frost joined
02:54
frost left
03:54
unicodable6 left,
reportable6 left,
bisectable6 left,
linkable6 left,
tellable6 left,
squashable6 left,
evalable6 left,
sourceable6 left,
greppable6 left,
releasable6 left,
bloatable6 left,
shareable6 left,
notable6 left,
nativecallable6 left,
coverable6 left,
quotable6 left,
statisfiable6 left,
benchable6 left,
committable6 left,
squashable6 joined,
unicodable6 joined,
reportable6 joined
03:55
quotable6 joined,
statisfiable6 joined,
notable6 joined,
greppable6 joined
03:56
tellable6 joined
04:46
Tirifto left
04:49
Tirifto joined
04:54
releasable6 joined
04:55
evalable6 joined,
sourceable6 joined,
linkable6 joined,
shareable6 joined
04:57
bloatable6 joined
05:20
Doc_Holliwood joined
05:54
coverable6 joined
05:55
benchable6 joined
05:56
committable6 joined,
bisectable6 joined
06:02
Sgeo left,
reportable6 left
06:05
reportable6 joined
06:19
Doc_Holliwood left
06:20
Eddward_ left,
Doc_Holliwood joined
|
|||
mykhal | gfldex: timtowdi, howewer requirement was rather to avid variables, than to have "this" | 06:21 | |
06:24
Doc_Holliwood left
|
|||
mykhal | .. s/avid/avoid/ | 06:26 | |
06:54
nativecallable6 joined
07:05
nahita joined
07:10
ufobat joined
07:50
dakkar joined
|
|||
nahita | hi! i wonder why `+flat $(12, 84)` gives 2 but not 1... | 08:11 | |
m: say +flat $(12, 84); | 08:12 | ||
camelia | 2 | ||
nahita | m: .say for flat $(12, 84) | 08:13 | |
camelia | 12 84 |
||
08:50
linkable6 left,
evalable6 left,
linkable6 joined
|
|||
mykhal | nahita: hi. i wonder why would you expect 1. List in numeric context gives its length | 08:50 | |
nahita | I expected it not to be flattened since it's itemized and therefore gave 1. | 08:56 | |
m: .say for flat ($(12, 84),) | 08:57 | ||
camelia | (12 84) | ||
nahita | `flat` respects it when in a list but why not above? | 08:58 | |
mykhal | i probably miss something | 09:01 | |
m: say $(12, 84).elems | |||
camelia | 2 | ||
nahita | m: .say for $(12, 84) | 09:02 | |
camelia | (12 84) | ||
nahita | m: .say for ($(12, 84),) | 09:04 | |
camelia | (12 84) | ||
mykhal | so you see | 09:05 | |
nahita | no :) | ||
mykhal | m: say ((1, 2), 3).flat | ||
camelia | (1 2 3) | ||
mykhal | m: say ($(1, 2), 3).flat | 09:07 | |
camelia | ((1 2) 3) | ||
mykhal | interesting. | 09:08 | |
m: say $(1, 2).^name eq (1, 2).^name | |||
camelia | True | ||
mykhal | well, ok, it's somewhat more complicated than i thoughtd, will comment no more :) | 09:09 | |
09:09
Manifest0 left
09:11
Manifest0 joined
|
|||
mykhal | .. only that i think its meant not to flatten being item, not a whole "container" | 09:15 | |
m: say ( +flat( [1, 2] ), +flat( [[1, 2], 3] ) ) | 09:19 | ||
camelia | (2 2) | ||
nahita | not sure I follow *"its meant not to flatten being item, not a whole "container"*; can you please elaborate? | 09:33 | |
mykhal | "When you have a list that contains sub-lists, but you only want one flat list, you may flatten the list to produce a sequence of values as if all parentheses were removed. This works no matter how many levels deep the parentheses are nested.", from docs. It's talking about sub-lists | 09:35 | |
nahita | I see; but itemized sublists are immune to flattening, right? But behaviour seems to change when passed directly to `flat` as `flat $(12, 84)` and I'm unable to see why... | 09:39 | |
09:52
evalable6 joined
|
|||
mykhal | it does not treat the same the outer list-ish, "Interprets the invocant as a list, flattens non-containerized Iterables into a flat list, and returns that list." | 09:54 | |
i wouldn't like/expect flatteing [[1, 2], 3] to ( [[1, 2], 3], ) | 09:55 | ||
but frankly i initially wouldn't expect different treatment of innter list vs arrays as well :) | 09:59 | ||
nahita | So it first calls `.List` on the argument and then flattens? | 10:12 | |
(or `.list`; i don't know the difference) | 10:13 | ||
10:22
Kaipi joined
10:24
Kaiepi left
|
|||
mykhal | nahita: something like that.. if it's an iterable, it iterates it, Iterable.pm6: method flat(Iterable:D:) { Seq.new(Rakudo::Iterator.Flat(self.iterator)) } | 10:30 | |
10:30
olve__ left
10:31
Olve_ left
|
|||
nahita | Thx; I also reached that and Rakudo::Iterator.Flat has some nqp stuff that I don't understand. What confuses me is: | 10:32 | |
m: .say for $(12, 84) | |||
camelia | (12 84) | ||
nahita | iterates once... | ||
mykhal | i can see 2 elems | 10:33 | |
lizmat | but they're in a container :-) | ||
m: .say for (12,84) | |||
camelia | 12 84 |
||
lizmat | m: .say for $(12,84) | ||
camelia | (12 84) | ||
lizmat | well, I should say, they're itemized | ||
mykhal | i thout we were talking about the outer iterable | 10:34 | |
these items ate treated different weay than the original iterable | 10:36 | ||
mykhal did not notice lizmat speaking now | 10:38 | ||
nahita | I understand/expect `.say for $(12, 84)` to iterate once. What I don't understand/expect is why `.say for flat $(12, 84)` iterates twice but not once? How can `flat` flattens an itemized list? | ||
lizmat | that's the idea of flat ? | 10:39 | |
nahita | But it respects when `$(12, 84)` is in a list | ||
m: .say for ($(12, 84),) | 10:40 | ||
camelia | (12 84) | ||
nahita | m: .say for flat ($(12, 84),) | 10:41 | |
camelia | (12 84) | ||
mykhal | m: say $(12, 84).raku; say ($(12, 84),).raku | 10:43 | |
camelia | $(12, 84) ($(12, 84),) |
||
mykhal | crap | 10:44 | |
m: say $(12, 84).flat.raku; say ($(12, 84),).flat.raku | |||
camelia | (12, 84).Seq ($(12, 84),).Seq |
||
mykhal | consistent, if one does not expect flat to be classical recursive function | 10:47 | |
nahita | it is recursive though, isn't it | ||
mykhal | yes, but starting in top of items, not the whole arg | 10:49 | |
.. but that is also misleading statement | |||
10:53
sena_kun joined
|
|||
mykhal | it does recursively flatten the items, but flat is not flatten | 11:10 | |
and Raku is not Haskell :) | 11:13 | ||
11:35
holyghost left
11:50
alex16 joined
|
|||
alex16 | Uploaded file: uploads.kiwiirc.com/files/232a733b...-13-16.png | 11:50 | |
Help brother | |||
MasterDuke | alex16: it looks like whatever os your phone is running doesn't have the dev package for openssl. i don't know if there's a way to exclude packages and/or modules with rstar, but you could always just install rakudo by itself, then manually install zef + modules | 11:55 | |
11:58
alex16 left
11:59
alex79 joined
|
|||
alex79 | Help me failed build | 12:00 | |
Uploaded file: uploads.kiwiirc.com/files/889fcc5d...pasted.txt | |||
MasterDuke | alex79: i'd suggest downloading rakudo.org/dl/rakudo/rakudo-2021.07.tar.gz instead of rakudo-star and trying that first | ||
alex79 | Android 6.0 aarch64 | ||
MasterDuke | people have built rakudo on other aarch64 systems (e.g., rpi4), so it's likely possible | 12:01 | |
you'll probably need something like `apt install build-essentials` first (i don't know what the actual package name is) | 12:02 | ||
12:02
reportable6 left
12:03
reportable6 joined
12:07
Doc_Holliwood joined
|
|||
alex79 | what is the command to install it, I have extracted the file? | 12:08 | |
MasterDuke | something like `perl Configure.pl --backends=moar --gen-moar --make-install` | 12:09 | |
you can add a `--prefix=path/to/somewhere` if you want to install it to a particular directory | 12:10 | ||
alex79 | fatal: not in a git directory | 12:16 | |
MasterDuke | but it should still start building, right? | 12:20 | |
alex79 | currently installing moarvm | 12:23 | |
12:23
Doc_Holliwood left
12:24
Doc_Holliwood joined
|
|||
alex79 | MasterDuke currently installing moarvm | 12:25 | |
MasterDuke | it'll probably take a while | 12:26 | |
alex79 | Updating submodules .................................... warning: Cannot protect .git/config on this file system - do not store sensitive information here. | ||
Uploaded file: uploads.kiwiirc.com/files/fc647552...pasted.txt | 12:27 | ||
How? | |||
Util | alex79: Sanity check - Are you able to create+compile+run a C program in the directories where you are trying to build Rakudo? | 12:31 | |
Good example to try: rosettacode.org/wiki/Hello_world/Newbie#C | |||
12:34
Eddward_ joined
12:38
rypervenche left
12:42
alex79 left
12:45
Eddward_ left,
alex67 joined
|
|||
alex67 | MasterDuke How? | 12:46 | |
12:47
alex67 left
12:49
alex80 joined
|
|||
alex80 | someone help me how to install rakudo in termux i've been trying since morning looking for a solution | 13:20 | |
13:35
alex80 left,
alex67 joined,
alex67 left
13:38
rypervenche joined,
justsomeguy joined
13:56
codesections left
14:03
Doc_Holliwood left
14:32
Doc_Holliwood joined
|
|||
tonyo | does your excellent termux have perl? | 14:35 | |
MasterDuke | i was helping them a bit, i believe their latest problem is that where they were trying to build was mounted noexec | 14:40 | |
14:50
codesections joined
14:51
Sgeo joined
14:56
RandalSchwartz joined
15:30
ufobat left
|
|||
nahita | mykhal: if it's already flat, `flat` doesn't flatten in effect yes. But `$(12, 84)` isn't flat on its own, right? And it also doesn't get flatten if it is an element of a list instead of directly supplying to `flat`. | 15:50 | |
s/isn't flat on its own/is flat on its own/ | 16:05 | ||
16:10
Doc_Holliwood left
16:16
gordonfish- joined,
nahita left,
Oshawott left,
gordonfish left
16:17
Oshawott joined
16:24
RandalSchwartz left
16:25
kylese joined
16:49
dakkar left
|
|||
mykhal | tonyo: my termux (not sure if excellent) has perl 5.34. after installing perl. | 16:58 | |
tonyo | what's the output of running the perl Configure.pl stuff in the readme? | 17:01 | |
17:28
m_athias left
17:34
kylese left
17:42
swaggboi left
18:02
reportable6 left
18:05
reportable6 joined
18:06
swaggboi joined
18:07
gordonfish- is now known as gordonfish
18:09
swaggboi left
18:11
sena_kun left
18:14
swaggboi joined
18:50
Doc_Holliwood joined
19:22
justsomeguy left
19:45
Summer joined
|
|||
Summer | is doing /<$userinput>/; equiv to doing an eval on user input, in terms of potential damage? | 19:46 | |
gfldex | m: my $input = '{ say "hello haxor!" }'; say 'ohai' ~~ /<$input>/; | 19:48 | |
camelia | 5===SORRY!5=== Error while compiling /home/camelia/EVAL_0 Prohibited regex interpolation (use the MONKEY-SEE-NO-EVAL pragma to override this error but only if you're VERY sure your data contains no injection attacks). at /home/camelia/EVAL… |
||
gfldex | Summer: not quite on its own | ||
19:49
tejr left
|
|||
Summer | thats fairly neato | 19:49 | |
19:49
tejr joined
20:23
polettix left,
polettix joined
|
|||
Geth | doc/py-nutshell-enumerate-patch: 1f990b6fed | (Trey Harris)++ (committed using GitHub Web editor) | doc/Language/py-nutshell.pod6 py-nutshell: Add how to enumerate in iteration Resolves #3924. Modified from suggestion in issue to include `kv()`’s other use case in maps, matching Python’s `dict.items()`. |
20:41 | |
doc: treyharris++ created pull request #3925: py-nutshell: Add how to enumerate in iteration |
20:42 | ||
21:25
evalable6 left
22:25
linkable6 left
22:28
linkable6 joined,
evalable6 joined
|
|||
japhb | tbrowder: JSON::Hjson added as a decoder-only module to github.com/japhb/serializer-perf -- it's a lot slower than JSON::Fast at decoding the JSON subset of Hjson, but that's to be expected from JSON::Hjson's idiomatic Grammar-driven design; probably would be more fair to compare to JSON::Tiny than JSON::Fast. | 23:22 | |
(Where "a lot slower" was 5-30x slower on my particular JSON test cases.) | 23:23 | ||
tbrowder | japhb: thanks, and i'm not surprised. i do find it useful for config files. | 23:26 | |
23:28
linkable6 left,
evalable6 left
23:29
linkable6 joined
|