On Oct-26, Leopold Toetsch wrote:
> Steve Fink <[EMAIL PROTECTED]> wrote:
> > I am getting a seg fault when doing a very simple subroutine call with
> > IMCC:
> 
> >     .sub _main
> >             newsub $P4, .Sub, _two_of
> >             $P6 = new PerlHash
> >             .pcc_begin prototyped
>                          ^^^^^^^^^^
> >     .pcc_sub _two_of non_prototyped
>                        ^^^^^^^^^^^^^^
> 
> You are stating explicitely conflicting call types. That can't work.
> When you remove "non_prototyped" in the sub, its prepared to be called
> either way and it works.

Doh! Thanks, I definitely should have noticed that.

Although this does bring up another issue -- should parrot really be
seg faulting when it gets a uninitialized (null) PMC? It happens to me
quite often. In a way, the current behavior is rather nice, since the
errors tend to be more obvious. Then again, that's only because all my
test programs die early enough that no incorrect but non-null values
have snuck into my registers yet. Also, I wouldn't expect a VM to fall
flat on its face from something like this.

Reply via email to