#466: PAST::Val.new( :value( ~$/ ), :returns('Complex')) generates incorrect pir
--------------------+-------------------------------------------------------
Reporter: bsdz | Owner: pmichaud
Type: bug | Status: new
Priority: major | Milestone:
Component: PCT | Version: trunk
Severity: medium | Keywords:
Lang: | Patch:
Platform: all |
--------------------+-------------------------------------------------------
When trying to assigned capture string to a Complex type the generated PIR
does not quote the string token so one ends up with something like: -
{{{
new $P14, "Complex"
assign $P14, 10i
}}}
When you really want: -
{{{
assign $P14, "10j"
}}}
This can be fixed by adding the a valflag option in src/PAST/Compiler.pir
similar to String's settings.
valflags['Complex'] = 's~*:e'
However, this might break some future intended usage.
It would be something useful to control from NQP.
--
Ticket URL: <https://trac.parrot.org/parrot/ticket/466>
Parrot <https://trac.parrot.org/parrot/>
Parrot Development
_______________________________________________
parrot-tickets mailing list
[email protected]
http://lists.parrot.org/mailman/listinfo/parrot-tickets