[svn:PHP-Sandwich] rev 1034 - in PHP-Sandwich/trunk: . PHP t
[email protected] 29 Apr 2005 02:06:12 -0000
| Newsgroups | perl.php.sandwich.dev |
|---|---|
| Message-ID | <[email protected]> |
Author: gschlossnagle
Date: Thu Apr 28 19:06:12 2005
New Revision: 1034
Modified:
PHP-Sandwich/trunk/PHP/Interpreter.pm
PHP-Sandwich/trunk/phpfuncs.c
PHP-Sandwich/trunk/t/12.t
Log:
fixes for 12
Modified: PHP-Sandwich/trunk/PHP/Interpreter.pm
==============================================================================
--- PHP-Sandwich/trunk/PHP/Interpreter.pm (original)
+++ PHP-Sandwich/trunk/PHP/Interpreter.pm Thu Apr 28 19:06:12 2005
@@ -11,7 +11,9 @@
my $self = shift;
my $sub = $AUTOLOAD;
$sub =~ s/.*:://;
- return $self->call($sub, @_);
+ unshift @_, $sub;
+ unshift @_, $self;
+ goto &call;
}
1;
Modified: PHP-Sandwich/trunk/phpfuncs.c
==============================================================================
--- PHP-Sandwich/trunk/phpfuncs.c (original)
+++ PHP-Sandwich/trunk/phpfuncs.c Thu Apr 28 19:06:12 2005
@@ -68,9 +68,7 @@
static SV *sandwich_perl_eval(pTHX_ char *command_in) {
SV *retval;
SV *command;
- fprintf(stderr, "calling %s\n", command_in);
command = newSVpv(command_in, 0);
- //command = sv_2mortal(newSVpv(command_in, 0));
retval = my_eval_sv(aTHX_ command, FALSE);
return retval;
}
Modified: PHP-Sandwich/trunk/t/12.t
==============================================================================
--- PHP-Sandwich/trunk/t/12.t (original)
+++ PHP-Sandwich/trunk/t/12.t Thu Apr 28 19:06:12 2005
@@ -17,9 +17,8 @@
function callme2() {
$pl = Perl::getInstance();
$rv = $pl->eval('return "hello";');
- print "returning $rv\n";
return $rv;
}
!),
'Add a "callme2" wrapper';
-is $p->callme2(), "hello";
+is my $arg = $p->callme2(), "hello";