🦋 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.
tbrowder happy indepence day for any americans in the room! 22:32
tbrowder i need to represent a hex number with fractional parts. so far i can only do that as a string, e.g., "0x10.1" 22:34
m: my $x = '0x10.1'; say $x.^name 22:35
camelia Str
tbrowder m: my $x=0x10.1
camelia 5===SORRY!5=== Error while compiling <tmp>
Malformed postfix call
at <tmp>:1
------> 3my $x=0x10.7⏏051
tbrowder m: my $s='0x10.1'; my $x = $s.Num; say $x 22:37
camelia 16.0625
tbrowder m: my $x=(0x10.1); $x.^name 22:38
camelia 5===SORRY!5=== Error while compiling <tmp>
Malformed postfix call
at <tmp>:1
------> 3my $x=(0x10.7⏏051); $x.^name
tbrowder is there any way with fancy quotes to assign the real hex number without its string representation? 22:39
m: my $x=<<0x10.1>> 22:41
camelia ( no output )
tbrowder m: my $x=<<0x10.1>>; say $x.^name 22:42
camelia RatStr
tbrowder aha! 22:43
elcaro m: say :16<10.1> 22:44
camelia 16.0625
rassoc was about to write that; saw it here: github.com/Raku/roast/blob/master/...ls/radix.t
m: say "ab cd ef".split(/<ws>/) 22:46
camelia ( ab cd ef )
rassoc m: say "ab cd ef".split(/<ws>+/)
is this supposed to hang?
camelia MoarVM panic: Memory allocation failed; could not allocate 104187424 bytes
elcaro that MoarVM looks like a panic. will need to be traced with gdb or something. but the correct way to do what you want is... 22:47
m: say "aa cc ed".words
camelia (aa cc ed)
rassoc sure, know that, just stumbled upon the above in a unrelated situation 22:48
tbrowder elcaro: i'm trying something a bit different. i'm trying to create a list of numbers for testing representing various formats they might appear as in the wild 23:19
the only ones that cause a bit of trouble so far are the hex, binary, and octal representations. i'm trying to avoid using a pure string repr 23:21
rassoc m: :16<10.1>.WHAT 23:27
camelia ( no output )
rassoc m: :16<10.1>.WHAT.say
camelia (Rat)
melezhik weekly: www.reddit.com/r/rakulang/comments..._and_raku/ 23:46
notable6 melezhik, Noted! (weekly)
rassoc removed already? 23:50