Patrick R. Michaud wrote:

To be consistent with Hash and some of the other aggregates, the
set opcode should return PMC null _only_ when fetching a PMC from
an aggregate, if fetching a string or number it should return
the empty string or zero.

    $P0 = new 'ResizablePMCArray'

    $P1 = $P0[5]                   # $P1 is null
    $I1 = $P0[5]                   # $I1 is 0
    $S1 = $P0[5]                   # $S1 is ""

Here's the code that is currently failing for me:

    .sub main :main
        $P0 = new 'ResizablePMCArray'
$I0 = $P0[0]
        print $I0
        print "\n"
$S0 = $P0[0]
        say $S0
    .end

The expected output would be "0\n\n" -- i.e., a zero followed by two
newlines.

Fixed in r21763.

Allison

Reply via email to