Ticket #3482 (assigned defect)

Opened 2 years ago

Last modified 11 months ago

Function return error between compiled and interpreted scripts

Reported by: dinu Assigned to: weyrick (accepted)
Priority: immediate Milestone: 3.0.0 release
Component: Core Version: trunk
Severity: block Keywords:
Cc:

Description

# test.php <?php

$include='test2.php'; include($include); class c{

function d($pp){

return $pp->b();

}

} $y=new c(); echo $y->d($x);

?>

#test2.php <?php

class a{

function b(){

return 'qq';

}

}

$x=new a();

?>

pcc test.php ./test Runtime error in file test.php on line 6: Type pair' expected, bstring' provided

pcc test.php test2.php ./test qq

If you replace in test2.php return 'qq'; with $x='qq';return $x; it works. So it all comes down to constant return values not being returned properly from a runtime interpreted class to a compiled class.

Change History

(in reply to: ↑ description ) 03/27/07 11:36:43 changed by anonymous

Dang, I forgot to set the category and other details straight.

04/15/07 08:53:05 changed by weyrick

  • owner changed from anonymous to tim.
  • component changed from Apache 1 to Core.
  • milestone set to 2.9.x beta.

12/31/07 10:24:33 changed by weyrick

  • owner changed from tim to weyrick.
  • status changed from new to assigned.