Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 1.3.13

Bug #1274 Request NonStrict Option
Submitted: 2004-04-23 14:13 UTC Modified: 2004-04-30 22:19 UTC
From: ahundiak Assigned: alan_k
Status: Closed Package: HTML_Template_Flexy
PHP Version: Irrelevant OS: NA
Roadmaps: (Not assigned)    
Subscription  


 [2004-04-23 14:13 UTC] ahundiak at ingr dot com
Description: ------------ Request an option to suppress emitting code like: if (is_object($obj) and method_exists) then $obj->method(). With the current implementation, many errors will fail silently.

Comments

 [2004-04-23 21:31 UTC] alan_k
actually - that will be part of the strict option. (as the effect of running in strict mode is you see all the E_WARNINGS.. - which is what should happen here.. :) I guess ... something like if (is_ojb.....) { $obj->method } else { trigger_error("Unknown variable",E_NOTICE); } should fix this.
 [2004-04-25 09:17 UTC] ahundiak at ingr dot com
Instead of explicitly triggering warnings just leave the checks out completely. I think it does pretty much the same thing and makes the compiled code faster and easier to read. But either way would get the job done.
 [2004-04-30 22:19 UTC] alan_k
This bug has been fixed in CVS. In case this was a documentation problem, the fix will show up at the end of next Sunday (CET) on pear.php.net. In case this was a pear.php.net website problem, the change will show up on the website in short time. Thank you for the report, and for helping us make PEAR better.