nxadm/SuperMAIN

arguments containing `=` confuse this module

Closed this issue · 3 comments

a minimal program:

use v6.d;
use SuperMAIN;

sub MAIN(:$thing) {
    say $thing;
}

notice the problem:

$ ./minimal --thing=ab
ab
$ ./minimal --thing=a=b
ab
$ ./minimal --thing a=b
ab

SuperMAIN is a bit too eager, maybe?

nxadm commented

Good catch. The problem is probably here:
https://github.com/nxadm/SuperMAIN/blob/master/lib/SuperMAIN.rakumod#L80

It should be straight forward to fix, thx.

nxadm commented

I'll also add your examples to the tests.