Dan Sugalski (via RT) wrote:

When parrot runs it doesn't strip out the switches that it eats from the command line. So if, for example, you invoke parrot as:


    ./parrot foo.pbc

then argv[0] is foo.pbc. On the other hand, if you invoke it as:

   ./parrot -t foo.pbc

argv[0] is -t. Not good.

I can't reproduce that:

[EMAIL PROTECTED] cat argv.imc
.sub test::main @MAIN
    .param pmc argv
    $S0 = argv[0]
    print $S0
    print "\n"
.end


[EMAIL PROTECTED] parrot -j argv.imc argv.imc [EMAIL PROTECTED] parrot -o argv.pbc -r argv.imc argv.imc [EMAIL PROTECTED] parrot -j argv.pbc argv.pbc [EMAIL PROTECTED] parrot -t argv.pbc 0 set S30, P5[0] - , P5=SArray=PMC(0x40e0b010), 4 print S30 - S30="argv.pbc" 6 print "\n" argv.pbc 8 end

leo



Reply via email to