php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #32428 The @ warning error supression operator is broken
Submitted: 2005-03-23 13:46 UTC Modified: 2005-06-06 13:21 UTC
From: jason at amp-design dot net Assigned:
Status: Closed Package: Scripting Engine problem
PHP Version: 5CVS-2005-03-23 (dev) OS: Cent OS 3
Private report: No CVE-ID: None
 [2005-03-23 13:46 UTC] jason at amp-design dot net
Description:
------------
The @ operator that is used to supress errors about warnings and other non critical errors such as notices seems to be broken in this mornings snapshot of 5.1.0. This is quite fustrating as it's handy to use the @ operator when you want pass NULL when the variable doesn't exist.



Reproduce code:
---------------
<?php $data = @$not_exists; ?>

Expected result:
----------------
$data is assigned with NULL without an error message

Actual result:
--------------
Notice: Undefined variable: not_exists in /data/web/tools/iq_framework/test.php on line 1

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-03-23 16:46 UTC] tony2001@php.net
I can confirm this issue.
(reproducible in HEAD only) 
 [2005-06-06 13:21 UTC] dmitry@php.net
Fixed in CVS HEAD.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun Dec 22 05:01:30 2024 UTC