php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #74248 Missing migration gotcha in regards to declare(ticks=1);
Submitted: 2017-03-14 23:02 UTC Modified: 2019-04-17 14:53 UTC
Votes:1
Avg. Score:4.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:1 (100.0%)
Same OS:0 (0.0%)
From: matt dot minix at gmail dot com Assigned: cmb (profile)
Status: Closed Package: Documentation problem
PHP Version: Irrelevant OS:
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: matt dot minix at gmail dot com
New email:
PHP Version: OS:

 

 [2017-03-14 23:02 UTC] matt dot minix at gmail dot com
Description:
------------
---
From manual page: http://www.php.net/migration70
---
declare(ticks=1); in versions of php prior to 7 had a global effect, all code after it in any file were affected, this is apparently due to an implementation bug (see: nikic@php.net's resolution comment here - https://bugs.php.net/bug.php?id=71448), with that bug being fixed this now has a different behavior (of only being in affect in the file it's in), which can cause problems in applications that assume the old behavior.

In addition, I think the change is worth a mention on this page - http://php.net/manual/en/control-structures.declare.php




Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2019-04-17 14:53 UTC] girgias@php.net
-Status: Open +Status: Closed -Operating System: Irrelevant +Operating System: -Assigned To: +Assigned To: cmb
 [2019-04-17 14:53 UTC] girgias@php.net
This seems to fixed by this SVN commit: https://svn.php.net/viewvc?view=revision&revision=347260
As this bug seems related to #77901
 
PHP Copyright © 2001-2026 The PHP Group
All rights reserved.
Last updated: Tue Oct 06 17:00:01 2026 UTC