php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #36511 Eval() returns also the last (or only) statement.
Submitted: 2006-02-24 11:47 UTC Modified: 2006-02-24 13:33 UTC
From: rb at ez dot no Assigned:
Status: Not a bug Package: Documentation problem
PHP Version: Irrelevant OS: -
Private report: No CVE-ID: None
 [2006-02-24 11:47 UTC] rb at ez dot no
Description:
------------
It seems that the eval() function returns the last  
executed statement, when no return statement is in the to 
eval'ed code. The documentation describes nothing about  
this behavior.   


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2006-02-24 13:33 UTC] rb at ez dot no
After testing the problem a bit more, the documentation 
was right and I was wrong.
 
PHP Copyright © 2001-2026 The PHP Group
All rights reserved.
Last updated: Fri Jun 19 19:00:02 2026 UTC