>>>>> "Autrijus" == Autrijus Tang <[EMAIL PROTECTED]> writes:
Autrijus> On Tue, May 17, 2005 at 03:00:14PM +0100, Colin Paul Autrijus> Adams wrote: >> But when I look at http://www.parrotcode.org/docs/embed.html, I >> can see no way of getting information back from the script - >> not even an exit code. Is there anyway of doing this that I >> have missed? Autrijus> You may wish to use Parrot_call_sub's "SS" form, where Autrijus> you pass in a string and get back a string. Something Autrijus> like this: Autrijus> my $interp = Parrot_new(undef); Autrijus> # ... load a .pir file or some other code into Autrijus> $interp ... Autrijus> my $code_pmc = Parrot_find_global( $interp, Autrijus> const_string("Namespace"), const_string("sub_name"), ); Autrijus> my $return_str = Parrot_call_sub( $interp, Autrijus> $code_pmc, const_string("SS"), Autrijus> const_string("Your_input_string_here"), ); I'm confused by this - what language is it written in? Perl? And will: Parrot_PackFile Parrot_readbc(Parrot_Interp, char *filename) Reads in a bytecode file and returns a packfile structure for it. accept a .pir file? -- Colin Adams Preston Lancashire