Re: Fwd: Working with a regex using positional captures stored in a variableperl6-us...@perl.org

2021-03-11 Thread Moritz Lenz
Hi there, On 11.03.21 17:43, William Michels wrote: > Hi Moritz your book is mentioned below. Care to chime in? Reply to > perl6-users . > > Thx, Bill. > W. Michels, Ph.D. > > -- Forwarded message - > From: Joseph Brenner > Date: Thu, Mar 11,

Re: Where is "Subject"?

2017-02-23 Thread Moritz Lenz
contains both the headers and the body ($email in the README), and the subject is part of the headers. The only reason that $from and @to have a separate interface is that SMTP handles them separately. Cheers, Moritz -- Moritz Lenz https://deploybook.com/ -- https://perlgeek.de/ -- https://perl6.org/

Re: per 5 converter?

2017-02-12 Thread Moritz Lenz
ry to stay away from it. Cheers, Moritz On 12.02.2017 07:47, ToddAndMargo wrote: > Hi All, > > I know I asked this once before and I had though I'd written it > down, but do you have any favorite Perl5 to Per6 converters? > > Many thanks, > -T > -- Morit

Re: mocking $*OUT

2017-01-24 Thread Moritz Lenz
y > the code above doesn't work. Any ideas? Because say() is a high-level function that uses the lower-level $*OUT.print under the hood. >From rakudo's src/core/io_operators.pm: multi sub say(Str:D \x) { my $out := $*OUT; $out.print(nqp::concat(nqp::unbox_s(x),$out.nl-out)); }

Re: A stricter typed variable

2017-01-07 Thread Moritz Lenz
onstraint, ask yourself: could there be an object from another type that my could would also work with? Maybe I'm just calling a method that's implemented in type Str, but a user-supplied object could implement the same method as well. If it walks like a duck, and quacks like a duck, d

Re: A stricter typed variable

2017-01-07 Thread Moritz Lenz
= 'gzip', 'uuencode'; or even test format => 'gnutar', filter => my Str @ = ; My general advise is to not exaggerate the usage of container types. Think of Perl 6 as a dynamically typed language, and only add types where they make life easier for everybody involved. Cheers, Moritz -- Moritz Lenz https://deploybook.com/ -- https://perlgeek.de/ -- https://perl6.org/

Re: Need some help to understand how modify an AST.

2016-12-05 Thread Moritz Lenz
e for the toto environment > variable. > > > > _Program2:_ > > __cat test052.pl6 > > grammar TEST { > rule TOP { :i \s*} > token varenv {'$' } > token mot { <[a..z A..Z 0..9 =\-_!~'():@&+$,\']>+ } > } > > class

Re: What is rakudo-star?

2016-11-18 Thread Moritz Lenz
On 19.11.2016 03:14, _ ifdog wrote: > So why there is not a star release of 2016.10 for windows ? Because nobody one yet. I'm happy to upload it for you if you provide it. Cheers, Moritz -- Moritz Lenz https://deploybook.com/ -- https://perlgeek.de/ -- https://perl6.org/

Re: Where to start?

2016-11-18 Thread Moritz Lenz
rogram in Linux. #!/usr/bin/env /path/to/your/rakudo/inst/bin/perl6 use v6; > Also, do I need to run perl6 through a compiler or > does it compile on the fly like perl 5? There's no separate compilation step. Cheers, Moritz -- Moritz Lenz https://deploybook.com/ -- https://perlgeek.de/ -- https://perl6.org/

Re: What's involved in the creation of a new Rakudo * version?

2016-10-16 Thread Moritz Lenz
e is: https://github.com/rakudo/star/blob/master/tools/star/release-guide.pod Cheers, Moritz -- Moritz Lenz https://deploybook.com/ -- https://perlgeek.de/ -- https://perl6.org/

Re: think I found a bug in the doc's

2016-10-04 Thread Moritz Lenz
$mod)returns Int:D it needs > three parameters Yes, that's right. If you tell me your github username, I can give you access so that you can change it directly on https://github.com/perl6/doc/. Otherwise a pull request would be very welcome. Cheers, Moritz -- Moritz Lenz https://deploybook.com/ -- https://perlgeek.de/ -- https://perl6.org/

Re: What are variables/parameters that start with a pipe | char

2016-10-01 Thread Moritz Lenz
ot;| (parameter)", which points to relevant documentation. Cheers, Moritz -- Moritz Lenz https://deploybook.com/ -- https://perlgeek.de/ -- https://perl6.org/

Re: Sorting Multidimentional Arrays

2016-10-01 Thread Moritz Lenz
For the record, you can simplify this a bit: @opposite = @opposite.sort(*[3]); > for @opposite -> $line { say $line; } > --- > > I have adapted this from: > http://www.wellho.net/resources/ex.php?item=p600/mapper > > I wanted to ask about the syntax, buy I have understood

Re: grammars and indentation of input

2016-09-13 Thread Moritz Lenz
t that has gone into it. Cheers, Moritz -- Moritz Lenz https://deploybook.com/ -- https://perlgeek.de/ -- https://perl6.org/

Re: NativeCall interface for a char ** argument

2016-05-27 Thread Moritz Lenz
use CArray[Str] for the parameters, see for example https://github.com/perl6/DBIish/blob/master/lib/DBDish/Pg/Native.pm6#L83-92 Cheers, Moritz

Re: How to capture an div 0 exception

2016-05-18 Thread Moritz Lenz
.WHAT.say; when X::Numeric::DivideByZero { $r = 65; .resume; } default { $r = 55; .resume; } If you want to only catch exceptions of type X::Numeric::DivideByZero, don't supply a default block. Cheers, Moritz

Re: Fwd: perl6 INC

2016-05-11 Thread Moritz Lenz
ust a temporary hack until a mature solution is hammered out. We'd love it to be temporary, but until all target platforms (Linux, Mac OS X, Windows) can offer fully Unicode-capable, case sensitive file systems, we *have* make our own workarounds. Cheers, Moritz

Re: Work around to "unwanted fail"

2016-05-11 Thread Moritz Lenz
paths "at the same time" (no extra threading involved, just notionally). You really want to use || instead, which is "first try the first path, and if it doesn't work, try the second path". Cheers, Moritz

Re: DBIish: Why can't I interpolate variable holding database name?

2016-05-01 Thread Moritz Lenz
x27;, :$database); (and it's a feature I miss surprisingly often when back in perl 5 or python land). Cheers, Moritz

Re: question about Supply.act()

2016-04-28 Thread Moritz Lenz
might still be running and do other things. Cheers, Moritz

Re: Perl 6 pod-handling code seems widely scattered

2016-04-27 Thread Moritz Lenz
on for that chunk? Yes, that's the module that turns Pod AST into HTML. That's what you're looking for :) It's a document tree, not really an AST. The AST is an intermediate format inside the compiler that user-space modules don't see. Cheers, Moritz :-)

Re: Confused about rakudobrew and Rakudo Star

2016-02-08 Thread Moritz Lenz
ldn't specify a Rakudo by version. Which means Rakudo releases are still quite relevant. Cheers, Moritz

Re: Installing both from rakudobrew and Rakudo Star

2016-02-05 Thread Moritz Lenz
o that. Cheers, Moritz

Re: Confused about rakudobrew and Rakudo Star

2016-02-04 Thread Moritz Lenz
le to do something like "panda install Task::Star=2016.01" and get the exact same thing. I see Moritz replied to this also saying that the tarball is the way to go. I'd love to know what I'm missing out on by doing it this way. Exactly what you speculated above. The correct

Re: Confused about rakudobrew and Rakudo Star

2016-02-04 Thread Moritz Lenz
On 02/04/2016 01:26 PM, James E Keenan wrote: On 02/03/2016 10:48 PM, Brandon Allbery wrote: On Wed, Feb 3, 2016 at 10:30 PM, James E Keenan wrote: I am evidently confused as to the relationship, if any, between the 'rakudobrew' utility and the Rakudo::Star distribution. In short: rakudo

Re: Is there another way to define a regex?

2016-01-17 Thread Moritz Lenz
it actually contains a Str, it is always taken to match literally, so my $dir1 = '/home/user/.cpan'; my $dir2 = '/home/tbowde/.emacs'; my regex ignore_dirs { $dir1 | $dir2 } does what you want. If you want the interpolated string to be treated as a regex, you have to use it as my regex dirs { <$dir1> }. Cheers, Moritz

Re: Jonathan's "Perl 6 Introductory course"

2015-12-31 Thread Moritz Lenz
ert from >> the generated html to pdf but can't say for sure yet, but it is the >> good looks of his slides that I'm primarily interested in. > > Looks like Beamer (latex+beamer). The meta data of the PDF agrees, it says "LaTeX with Beamer class version 3.10" in the "creator" field. Cheers, Moritz

Re: Constants as members of a class

2015-12-18 Thread Moritz Lenz
to be a waste for a constant. Just do class MyClass { method TheConstant { 42 } } Then you can use it both on the class: say MyClass.TheConstant or on an instance: say MyClass.new.TheConstant Cheers, Moritz

Re: Gather/take & return, PHP7-style

2015-12-10 Thread Moritz Lenz
s with the list. Cheers, Moritz

Announce: Rakudo Star Release 2015.11

2015-11-28 Thread Moritz Lenz
On behalf of the Rakudo and Perl 6 development teams, I'm happy to announce the November 2015 release of "Rakudo Star", a useful and usable distribution of Perl 6. The tarball for the November 2015 release is available from . This Rakudo Star release comes with s

Re: &MAIN signature to preserve @*ARGFILES ?

2015-11-28 Thread Moritz Lenz
ing. Since $*ARGFILES (the thing behind lines() for example) uses @*ARGS to determine what files to open, you can say sub MAIN(*@*ARGS, Bool :$mean) { ... } Cheers, Moritz

Re: combine hashes

2015-11-07 Thread Moritz Lenz
On 11/07/2015 10:17 AM, Marc Chantreux wrote: > hello Moritz, > > On Sat, Nov 07, 2015 at 08:17:21AM +0100, Moritz Lenz wrote: >> my %x = < login jdoe first john last doe >; >> my %y = flat (:enable, %x< login first >:p); > > i tried :p but the thing is i

Re: combine hashes

2015-11-06 Thread Moritz Lenz
is point you have lost the keys, and .kv helpfully supplies the integer indexes of the list as keys. What you really want is %x< login first >:p This works for me: my %x = < login jdoe first john last doe >; my %y = flat (:enable, %x< login first >:p); say %y.perl;# {:enable, :first("john"), :login("jdoe")} Cheers, Moritz

Re: Ecosystem problems

2015-11-02 Thread Moritz Lenz
, one open github issues, since all modules are also gibhut repos, and msot have issues enabled. > or for the ecosystem maintainer to remove them? You open a pull request that removes them from the META.list in perl6/ecosystem. Cheers, Moritz

Re: Missing documentation

2015-10-29 Thread Moritz Lenz
On 10/29/2015 09:14 AM, Steve Mynott wrote: > I renamed it to 5to6-nutshell.html. ... and I created a redirect from 5to6 to 5to6-nutshell: https://github.com/perl6/doc/commit/df1b189dec Cheers, Moritz

Re: How to call a super class method?

2015-10-28 Thread Moritz Lenz
rg is meant for users; this has consequences on the number of examples, language, information density etc.) Cheers, Moritz

Re: How to profile Perl 6 applications?

2015-10-24 Thread Moritz Lenz
Hi, On 10/24/2015 09:52 AM, Timo Paulssen wrote: > On 24/10/15 09:40, Moritz Lenz wrote: >> Hi Gabor, >> >> On 10/24/2015 09:26 AM, Gabor Szabo wrote: >>> The Devel::NYTProf helped me a lot locating the source of slowness on >>> the Perl Maven site. >>

Re: Forking or running external process in background

2015-10-24 Thread Moritz Lenz
uot;, :out); There's a shell() function that might be closer to what you want, if you don't want to pass each argument separately. There's also Proc::Async: http://doc.perl6.org/type/Proc::Async But to me, it also looks like a perfect use case for threads. Have you tried that? Cheers, Moritz

Re: How to profile Perl 6 applications?

2015-10-24 Thread Moritz Lenz
line option, which generates a HTML file containing a single-page JS app that presents the profiling data. But you should take care to only profile short program executions that way (a few seconds at most), otherwise the result will be unusable in the browser. Cheers, Moritz

Announce: Rakudo Star Release 2015.09

2015-09-26 Thread Moritz Lenz
On behalf of the Rakudo and Perl 6 development teams, I'm excited to announce the September 2015 release of "Rakudo Star", a useful and usable distribution of Perl 6. The tarball for the September 2015 release is available from . This Rakudo Star release comes wi

Re: require on string stopped working in rakudo 2015.09

2015-09-26 Thread Moritz Lenz
se rakudobug it so that it doesn’t fall through the cracks? > This change did not fire any spectest alarm either, so maybe we need a test > for it as well :-) I've opened https://rt.perl.org/Ticket/Display.html?id=126096 and later rejcted it when learning about the desired behavior. Cheers, Moritz

Re: Method 'send' not found for invocant of class 'IO::Socket::INET'

2015-09-26 Thread Moritz Lenz
Hi, method .send was deprecated in favor of .print (for strings) and .write (with bufs/blobs) Maybe Bailador or one of its dependencies needs updating. Cheers, Moritz

Re: How to push a hash on an array without flattening it to Pairs?

2015-09-26 Thread Moritz Lenz
re than one list item from a .map call, for example. Cheers, Moritz

Re: require on string stopped working in rakudo 2015.09

2015-09-26 Thread Moritz Lenz
old that the proper way to require a module name (and not a file name) is require ::($name); which does work in 2015.09. I guess there's no deprecation, because it was only an accident that the string form worked before. Cheers, Moritz

Re: How to push a hash on an array without flattening it to Pairs?

2015-09-26 Thread Moritz Lenz
# 2 > say @c[0]; # x => 6 I would have expected the traiing comma to help here too: my @b; @b.push: %h, ; say @b.perl;# [:a(1), :b(2)] but alas, not. I wonder if this is a bug. This works: my @b; @b.push: $%h; say @b.perl;# [{:a(1), :b(2)},] Cheers, Moritz

Re: What are Perl 6's killer advantages over Perl 5?

2015-08-26 Thread Moritz Lenz
Perl 5 are still stuck in the past, with no good way forward. Cheers, Moritz

Re: Is < > creating and Array or Parcel ?

2015-08-02 Thread Moritz Lenz
Hi, On 02.08.2015 06:43, Gabor Szabo wrote: On Fri, Jul 31, 2015 at 4:16 PM, Moritz Lenz mailto:mor...@faui2k3.org>> wrote: On 07/31/2015 03:02 PM, Gabor Szabo wrote: The following code (with comments) is confusing me. Can someone give some explanation

Re: Is < > creating and Array or Parcel ?

2015-07-31 Thread Moritz Lenz
r %. It just wraps things into a Scalar, which is normally invisible. But, you can observe the difference still> my @a = ; my $s = @a' for @a { } # two iterations for $s { } # one iteration Cheers, Moritz

Announce: Rakudo Star Release 2015.07

2015-07-27 Thread Moritz Lenz
A useful, usable, "early adopter" distribution of Perl 6 On behalf of the Rakudo and Perl 6 development teams, I'm happy to announce the July 2015 release of "Rakudo Star", a useful and usable distribution of Perl 6. The tarball for the July 2015 release is available from

Re: perl6/book fonts: why Adobe commercial fonts?

2015-07-22 Thread Moritz Lenz
some parts. (There are plenty of free and handsome fonts to be had.) Some other questions: 1. Are there plans for a table of contents? 2. Are there plans for page numbering? No and no. perl6/book is a dead project, only good for salvaging pieces of it for perl6/doc. Cheers, Moritz

Re: Passing a hash to a subroutine: best method?

2015-07-03 Thread Moritz Lenz
ch element is an Int. This interpretation (which is explicitly not what the design docs state right now, nor what rakudo implements) would also make sense with slurpies (Int *@a) and/or coercion types (Int() *@a). Unfortunately, I have no idea how that could be realized, since binding to a parameter binds the caller's object unchanged, pretty much by definition. yours ranting, Moritz

Re: Sub args: choose one of two?

2015-06-28 Thread Moritz Lenz
sage: ./door open ./door close $ ./door open Opening door Cheers, Moritz

Re: Perl 5's $0 vs. Perl 6's $*EXECUTABLE_NAME

2015-05-30 Thread Moritz Lenz
.org/build-log/ building the docs alone takes ~17min; the cron job runs every 5 minutes, so it's more likely 17-22min before it becomes available :-) And thanks for adding $*PROGRAM to the docs! Cheers, Moritz

Re: Can a user "cheat" and call a class's private method?

2015-05-12 Thread Moritz Lenz
Hi, On 05/12/2015 09:40 PM, R. Ransbottom wrote: > On Mon, May 11, 2015 at 03:22:46PM -0700, Darren Duncan wrote: > >> you can use "trusts". Also having to do this may indicate bad code >> design. -- Darren Duncan > > I saw Moritz' and Carl's

Re: class/object variables

2015-04-23 Thread Moritz Lenz
e only attributes in a class and use our variables to share between objects? If you want per-object local storage, use attributes, yes. Cheers, Moritz

Re: Fancy sub arg handling: ability to expand error message?

2015-03-28 Thread Moritz Lenz
rs, not for user errors; and programmers should be able to understand the error message (or we need to improve the error messages, if that's not the case). Also it makes it harder for others to extend your API by providing additional multi candidates. Cheers, Moritz -BEGIN PGP

Re: Example module and its use

2015-03-28 Thread Moritz Lenz
ls, because the parens of the subroutine call disambiguate subs from constants, types and other sigilless terms, but I'm pretty sure we can't get away with this imprecision. And if I remember correctly, that error in S11 confused me enough not to implement 'use Module ' correctly w

Re: Can a user "cheat" and call a class's private method?

2015-03-26 Thread Moritz Lenz
but it is rather questionable use of the MOP. Cheers, Moritz

Re: How to get indirect access to a class attribute?

2015-03-25 Thread Moritz Lenz
refer to the attributes in a method? The > above doesn't work (with or without the '()'). the indirect method call syntax is the right approach, you just got too many other details wrong to make it work. Cheers, Moritz

Re: Object Introspection for Existence of Methods: How?

2015-03-23 Thread Moritz Lenz
why tests need introspection at all. I mean, you test by doing example calls and comparing to expected example return values. (If those are generated methods, IMHO there is no point in testing all generated instances). Cheers, Moritz

Announce: Rakudo Star Release 2015.03

2015-03-21 Thread Moritz Lenz
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 ## A useful, usable, "early adopter" distribution of Perl 6 On behalf of the Rakudo and Perl 6 development teams, I'm happy to announce the March 2015 release of "Rakudo Star", a useful and usable distribution of Perl 6. The tarball for the March 2015

Re: Need help with: Cannot find method 'postcircumfix:<( )>'...

2015-03-20 Thread Moritz Lenz
rt for $(self.elem); if you want direct access to the variable you'd write $!elem. Also, an "indirect method call" would be self."$elem", small correction: self."$elem"(). self."$elem" is an error, which is useful to catch p5 programmers who use . for string concatenation. Cheers, Moritz

Re: Passing arrays to subroutines

2015-03-19 Thread Moritz Lenz
@a, @b; 2. Can I flatten the arrays into elements inside the foo call? foo(|@combined) Cheers, Moritz

Re: Can a class have an attribute and a method with the same name?

2015-03-19 Thread Moritz Lenz
e 'x'. See also http://doc.perl6.org/language/objects#Attributes So, you can have an attribute $!x and a method x, but if you write class A { has $.x; method x() {... } } then the method will prevent the automatic accessor from being generated. Cheers, Moritz

Re: Object Contruction

2015-03-18 Thread Moritz Lenz
ing one is BUILDALL with a callsame; see the last example (or example skeleton) in that section. Cheers, Moritz

Re: Perl 6 Debugging

2015-03-14 Thread Moritz Lenz
ment. When I run your code with perl6-m (Rakudo with the MoarVM backend), I get ===SORRY!=== Error while compiling /home/moritz/Ellipsoid.pm6 Variable '$class' is not declared at /home/moritz/Ellipsoid.pm6:154 --> my( $class⏏, %args ) = @_; expecting any of: postf

Announce: Rakudo Star Release 2015.01

2015-02-07 Thread Moritz Lenz
# Announce: Rakudo Star Release 2015.01 ## A useful, usable, "early adopter" distribution of Perl 6 On behalf of the Rakudo and Perl 6 development teams, I'm happy to announce the January 2015 release of "Rakudo Star", a useful and usable distribution of Perl 6. The tarball for the January 2015 r

Re: time and now showing different time?

2015-01-12 Thread Moritz Lenz
o X-ray the patient for an extra second just because there's a leap second during the test. Cheers, Moritz

Re: Could method calls warn in void context?

2015-01-10 Thread Moritz Lenz
To elaborate a bit on the previous answer: On 10.01.2015 17:12, Tobias Leich wrote: In case we would know that certain methods had no side effects (and are not called because of their side effects), ... But at the moment we don't know and therefore we can't warn for every method. there are tw

Re: Rationale for a VM + compiler approach instead of an interpreter?

2014-12-06 Thread Moritz Lenz
loped (any(pugs, kp6 (now perlito), rakudo, niecza)), which lead to friendly competition, fresh ideas and generally lots of fun. Cheers, Moritz

Re: The next 100 Years

2014-11-17 Thread Moritz Lenz
ut again my understanding of Catalyst is limited. Cheers, Moritz

Re: Date truncated-to method argument?

2014-11-10 Thread Moritz Lenz
elds an object with the date of the last Monday +Arguments to C belong to the enum C, which encompasses +these values: + +second seconds +minute minutes +hourhours +day days +weekweeks +month months +yearyears + ... so looks like the docs are out of date. Patches to fix that would be awesome! Cheers, Moritz

Re: Orphaned module Form

2014-09-09 Thread Moritz Lenz
7;s now at https://github.com/mathw/form If anybody wants a commit bit for that repo, please speak up (and tell me your github user name). So far the "perl6" team has write access here, which is the same team that governs access to roast, specs, perl6.org and several other repos. Cheers, Moritz

Re: Orphaned module Form

2014-09-09 Thread Moritz Lenz
then forgot it. I hope I'll actually get around to it soon. Feel free to nag me if I forget it again :-) Cheers, Moritz On Mon, Sep 8, 2014 at 4:44 AM, Kamil Kułaga wrote: Hi, There is a https://github.com/mathw/form trying to implement http://search.cpan.org/~dconway/Perl6-Form-0.00

Re: match an empty string?

2014-07-13 Thread Moritz Lenz
t the rules of http://perlcabal.org/syn/S05.html#Simplified_lexical_parsing_of_patterns about what is and what isn't metacharacter don't apply inside character classes). Cheers, Moritz

Re: Code execution during compilation

2014-06-15 Thread Moritz Lenz
ompile time, so the two are roughly equivalent). Cheers, Moritz On 06/15/2014 02:31 AM, Kamil Kułaga wrote: > Hi, > > I got amazed little bit when this code: > class A { > method wow{say "I'm alive"} > } > > role Xx{ >

Re: Perl6 and wxwidgets

2014-06-08 Thread Moritz Lenz
Hallo Erik, On 08.06.2014 12:54, Erik Colson wrote: > Is it possible to use an external C-library like wxwidgets from perl6/moarvm ? > If so, is there any doc how this can be achieved ? It is, through the NativeCall library: https://github.com/jnthn/zavolaj/ Cheers, Moritz

Re: Regex: fail if ... present

2014-05-30 Thread Moritz Lenz
Hi Peter, On 30.05.2014 22:39, Peter Schwenn wrote: > Dear Moritz, > > $txt ~~ s:g/ \. Guid /.Moniker/; > > transforms (in $txt):System.Guid -> System.Moniker > > i.e. the match succeeds. So obviously I'm not understanding negative > look-ahead

Re: Regex: fail if ... present

2014-05-30 Thread Moritz Lenz
by a word that's not 'perl', you'd write / \d+ \w+ \d+ / So, you solve it with a negative look-ahead. Cheers, Moritz

Re: Does perl have ensue override?

2014-05-19 Thread Moritz Lenz
e role candidate. So far I haven't seen any method in the ParametricRoleGroupHOW that gives me a list of those candidates, or a of methods. So I don't know how to emulate .^can. I'll see if anybody in #perl6 (IRC) has a good idea... Cheers, Moritz On 19.05.2014 14:52, Kamil Kułaga

Re: Does perl have ensue override?

2014-05-16 Thread Moritz Lenz
https://gist.github.com/moritz/2c6ed01eef0029dabdeb Feel inspired :-) Cheers, Moritz

Re: perl 6 beginner: regex questions

2014-02-04 Thread Moritz Lenz
(i.e. a subpattern) then..." > > my $text = "foo:food fool\nbar:bard barb"; > # $0--- > # || > # | $0[0]$0[1]--- | > # | | || | | > $text ~~ m/ ( (\w+) \: (\w+ \h*)* \n ) ** 2..* /; > > The error seems that $text lacks a final \n. It works as expected > if you add it. You should also verify the diagram above, it may, > or not, contain an error. I just tried it thus instead and it seems to work: > > my $text = "foo:food fool\nbar:bard barb\n"; > # $0--- > # | | > # |($0[0][0],$0[0][1]) 1st iter. | > # |($0[1][0],$0[1][1]) 2nd iter. | > # || |||| > $text ~~ m/((\w+) \: (\w+ \h*)* \n) ** 2..*/; > say "$0[0][0]"; # foo > say "$0[0][1]"; # food fool > say "$0[1][0]"; # bar > say "$0[1][1]"; # bard barb Sorry, I currently don't have the time to look at this in detail; I hope somebody else does. Cheers, Moritz

Re: how to set constants from command line?

2013-12-14 Thread Moritz Lenz
ll. Note that in Perl 6, there is no guarantee that command line arguments are known at compile time, so mucking with @*ARGS in BEGIN seems like a very bad idea. Cheers, Moritz

Re: New behaviour of Rakudo*

2013-11-28 Thread Moritz Lenz
e who asked for a rename to avoid naming collisions, no? That said, the install process should still create a 'perl6' (or perl6.bat/perl6.exe on windows) binary/script for you. Cheers, Moritz

Rakudo Star 2013.11 released

2013-11-24 Thread Moritz Lenz
## A useful, usable, "early adopter" distribution of Perl 6 On behalf of the Rakudo and Perl 6 development teams, I'm happy to announce the November 2013 release of "Rakudo Star", a useful and usable distribution of Perl 6. The tarball for the November 2013 release is available from

Announce: Rakudo Star Release 2013.09

2013-09-26 Thread Moritz Lenz
## A useful, usable, "early adopter" distribution of Perl 6 On behalf of the Rakudo and Perl 6 development teams, I'm happy to announce the September 2013 release of "Rakudo Star", a useful and usable distribution of Perl 6. The tarball for the September 2013 release is available from

Rakudo Star 2013.08 released

2013-08-24 Thread Moritz Lenz
On behalf of the Rakudo and Perl 6 development teams, I'm happy to announce the August 2013 release of "Rakudo Star", a useful and usable distribution of Perl 6. The tarball for the August 2013 release is available from . A Windows .MSI version of Rakudo star will

Re: prove that the meaning of live is math

2013-05-26 Thread Moritz Lenz
reading the logs :-) If anybody has a good idea for removing that - 1, please tell me. (Using '`'.ord instead of 'a'.ord - 1 seems too obscure for my taste). Cheers, Moritz

Re: Packaging Perl 6 (or rather, Rakudo Star)

2013-03-05 Thread Moritz Lenz
it 'rakudo-star'. That's a bit of a bottom-up approach, which worked well in other areas of Perl 6 development. Cheers, Moritz

Announce: Rakudo Star 2013.02 released

2013-02-24 Thread Moritz Lenz
On behalf of the Rakudo and Perl 6 development teams, I'm happy to announce the February 2013 release of "Rakudo Star", a useful and usable distribution of Perl 6. The tarball for the February 2013 release is available from . A Windows .MSI version of Rakudo st

Re: Per-Object Roles..

2013-02-23 Thread Moritz Lenz
role or No, you cannot remove roles. > check to see if a role is attached to an object? With normal type checking: if $obj ~~ YourRole { ... } Cheers, Moritz

Rakudo Star 2013.01 released

2013-01-30 Thread Moritz Lenz
Announce: Rakudo Star - a useful, usable, "early adopter" distribution of Perl 6 On behalf of the Rakudo and Perl 6 development teams, I'm happy to announce the January 2013 release of "Rakudo Star", a useful and usable distribution of Perl 6. The tarball for the January 2013 release is availabl

Announce: Rakudo Star 2012.12 release

2012-12-27 Thread Moritz Lenz
Announce: Rakudo Star - a useful, usable, "early adopter" distribution of Perl 6 On behalf of the Rakudo and Perl 6 development teams, I'm happy to announce the December 2012 release of "Rakudo Star", a useful and usable distribution of Perl 6. The tarball for the December 2012 release is availa

Rakudo Star 2012.11 released

2012-11-28 Thread Moritz Lenz
On behalf of the Rakudo and Perl 6 development teams, I'm happy to announce the November 2012 release of "Rakudo Star", a useful and usable distribution of Perl 6. The tarball for the November 2012 release is available from . A Windows .MSI version of Rakud

Re: the nature of a scalar?

2012-10-24 Thread Moritz Lenz
s copy) { ... } Also if Bailador passes Match objects instead of strings into the function, $path evaluates to True in boolean context even if it matched the empty string. Cheers, Moritz

Re: perl6 spec tests results ?

2012-08-28 Thread Moritz Lenz
table (control flow, basic OO, variables, scoping). Then there are areas that don't seem to have moved a lot recently, but that have unresolved issues smoldering under the surface, and it's unclear how large the waves will be when those issues are resolved. Cheers, Moritz .oO( Never ask a 6er for completion estimates, for he will say both Yay and Nay )

Re: File content is not written if close not called

2012-07-17 Thread Moritz Lenz
jects are deallocated (except if the objects are in the life set again, which can be determined with write barriers). I'm CC'ing parrot-dev to ask about the current state of that project, and to volunteer rakudo testing against any such branches. Cheers, Moritz

Re: Capturing warning

2012-07-12 Thread Moritz Lenz
; } } say 'after'; prints: before caught: oh noes Where is 'between' and 'after' ? I've just added a .resume method to class Exception in Rakudo, along with a method .resumable, which checks if .resume may be called. Cheers, Moritz

Re: Perl6 grammars -- Parsing english

2012-07-11 Thread Moritz Lenz
Hi Lard, sorry for the late and incomplete answer. Am 04.07.2012 15:09, schrieb Lard Farnwell: Hi Moritz, Thanks that was interesting. My investigation into grammars took a while but here are the results thus far: Grammar rules and regexes are just methods… I hadn't thought about w

Re: Odd number of elements found where hash expected while bootstrapping Panda

2012-07-01 Thread Moritz Lenz
eb service. I'll also try to improve the error reporting. Cheers, Moritz On 07/01/2012 08:55 AM, Gabor Szabo wrote: > Hi, > > after updating Rakudo I started to get these errors so I updated (git > pull) Pand > removed ~/.perl6 and ~/.panda and tried to bootstrap Panda

  1   2   >