php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #71338 Call to undefined method Thread::detach()
Submitted: 2016-01-11 15:15 UTC Modified: 2017-04-01 21:45 UTC
From: ts_9 at hotmail dot fr Assigned: tpunt (profile)
Status: Closed Package: pthreads (PECL)
PHP Version: 7.0.2 OS: Ubuntu
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: ts_9 at hotmail dot fr
New email:
PHP Version: OS:

 

 [2016-01-11 15:15 UTC] ts_9 at hotmail dot fr
Description:
------------
---
From manual page: http://www.php.net/thread.detach
---

Although threads are working the static method Thread::detach appears not even exists with a fatal error “Call to undefined method Thread::detach()”.


Test script:
---------------
<?php
class NotificationRecorder extends Thread{
        function run(){
                echo "run";
        }
}
$fork = new NotificationRecorder();
$fork->start();
$fork->detach();
?>


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2017-04-01 21:45 UTC] tpunt@php.net
-Status: Open +Status: Closed -Package: threads +Package: pthreads -Assigned To: +Assigned To: tpunt
 [2017-04-01 21:45 UTC] tpunt@php.net
The Thread::detach method was removed in pthreads v3 (targeting PHP 7). I have documented this on its manual page.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Mar 19 03:01:29 2024 UTC