rakudo Questions

0

I don't know if this is a bug, or I just don't understand what's happening. If I have a run statement as the last statement in a try block, any error in the run statement is not caught. If it is no...
Noble asked 2/10, 2024 at 4:32

2

Is it possible to write a META6.json file that prints a message that the operating system is not supported and does not try to install the module if the operating system is Windows?
Itinerary asked 29/5, 2024 at 14:58

5

Solved

Does perl6/Rakudo have something equivalent to perl5's __DATA__ or __END__ sections?
Asexual asked 24/11, 2010 at 16:34

0

Raku provides a number of exception types that, on a conceptual level, are subtypes of each other. For example, X::Bind::Slice is conceptually a sub-category of X::Bind. But at an object-hierarchy ...
Delciedelcina asked 14/10, 2023 at 14:27

1

Should &set, Set, and Set.new have different semantics? If so, why? Consider the following code: my @array = 1, 2; my @other-array = ([3, 4],); dd set(@array, @other-array); #OUTPUT: Set.new(1...
Pairoar asked 10/10, 2023 at 17:17

2

Solved

I am looking for testing output of my function (which returns array) with the expected output array. Example: use Test; sub myoutput($n) { (1..$n)>>.sqrt } is myoutput(3), (1, 1.41421356237...
Habitation asked 30/9, 2023 at 9:20

2

I have a function that accepts an array of positive values only. Dies when any negative value is given. # Consider edge cases # First check if all elements are > 0, if not throw informative erro...
Humiliate asked 10/9, 2023 at 16:20

1

Solved

Description There is an example: #!/bin/env raku run 'raku', '-e', 'say "ok"'; exit 0; my $*SCHEDULER = ThreadPoolScheduler.new(max_threads => 128); On linux output is: ok Unhandled e...
Balmacaan asked 12/8, 2023 at 20:6

1

Solved

I have this program: class Foo { has $.first; } my $a = Attribute.new( :name('$!second'), :type(Int), :package('Foo'), :has_accessor(True) ); Foo.^add_attribute($a); Foo.^compose; Foo.^attr...
Parham asked 10/8, 2023 at 9:19

1

I looked at the documentation, but I didn't quite understand how to debug. I use the raku-debug command, but it reports an error: Could not find Debugger::UI::CommandLine. When I tried to search ...
Digestive asked 23/7, 2023 at 16:18

2

I'm trying to install Raku on a Debian 11 x64. I never installed it before (perl5 too) It's a server with some Perl5 scripts, and I want to "use" it in Raku with the Inline::Perl5 (also I...
Tinderbox asked 11/1, 2023 at 16:21

2

While finalizing my upcoming Raku Advent Calendar post on sigils, I decided to double-check my understanding of the type constraints that sigils create. The docs describe sigil type constraints wit...
Interviewer asked 19/12, 2022 at 4:12

2

Solved

I need to construct following flow: Accept list of file names Extract multiple lines from those files Process those lines However I have no idea how to properly inject gather-take into map: sub M...
Vassalize asked 15/12, 2022 at 16:51

3

Solved

I'm learning asynchronous programming in JS and I couldn't help but noticed both JS and Raku has some construct for asynchronous programming with the same name, however I'm uncertain to what extent...
Uncork asked 17/11, 2022 at 15:31

2

Solved

I'm trying to return struct from shared library written in C. This is simple code, for testing of returning structure and simple int32, libstruct.c, compiled by gcc -shared -Wl,-soname,libstruct.so...
Earthshaker asked 5/11, 2022 at 11:57

1

Solved

That is, variables like $*scalar, @*array and %*hash. I'm asking this question mainly because I want to have an idea of how much of a burden they are on the overall performance of the grammar/regex...
Suzerainty asked 19/9, 2022 at 21:49

1

Recently I've been trying to learn the Raku language, and I tried to make a simple Snake Game. The code starts with this : use SDL2::Raw; use Cairo; But when I compile using rakudo raku.raku, I ge...
Eclampsia asked 3/8, 2022 at 14:39

1

Solved

I am trying to use multi in my Raku code that wraps a function in C. Here I am calling lchoose function in shared libray Rmath. This is my code which works: use NativeCall; constant RMATH = "...
Occasion asked 2/6, 2022 at 19:1

1

Solved

I'm a bit confused about how Cro handles client requests and, specifically, why some requests seem to cause Cro's memory usage to balloon. A minimal example of this shows up in the literal "He...
Haunt asked 10/5, 2022 at 5:9

1

Solved

The documentation says that the comma operator has higher precedence than the assignment = operator, and this is specifically different than in Perl, so that we are allowed to remove parentheses in...
Nematic asked 2/5, 2022 at 1:31

3

Solved

I'm struggling to understand why the zip-add Z+ operator does not work on some cases. I have some 2-element lists that I'd like to sum. These work as expected whether I use lists or arrays: say (1,...
Bianchi asked 15/12, 2020 at 10:35

4

Solved

I'm trying to sort a list/array of strings: > my @e = Q (list_regex_files json_file_to_ref write_2d_array_to_tex_tabular dir get_sample_ID density_scatterplot violin_plot multiline_plot ref_to_j...
Pythoness asked 30/8, 2021 at 16:5

2

Solved

This is my folder structure: C:\USERS\SUMAN\OPENMP_CMAKE │ shlib.pl │ shlib.raku │ └───resources └───libraries the shlib.raku contains this line move "shlib.pl", "resources/librari...
Educated asked 18/4, 2022 at 8:49

2

Solved

I am trying to run a code containing srand function: srand(1); my @x = (1..1000).roll(100); my @y = (200..7000).roll(100); say sum(@x); say sum(@y); say $*KERNEL From the docs its pretty clear tha...
Lectra asked 26/3, 2022 at 12:17

1

Solved

It has been almost a year since I saw Jonathan Worthington presenting the new RakuAST in the YouTube video A Raku API to Raku programs the journey so far from TRC 2021. In the video, he showed that...
Dag asked 8/3, 2022 at 9:5

© 2022 - 2025 — McMap. All rights reserved.