php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #70174 Infinite loop within Interfaces
Submitted: 2015-07-31 08:14 UTC Modified: 2015-07-31 12:02 UTC
Votes:1
Avg. Score:3.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:1 (100.0%)
Same OS:0 (0.0%)
From: sam dot swift at fifteendigital dot co dot uk Assigned:
Status: Not a bug Package: Class/Object related
PHP Version: Irrelevant OS: Windows 7 SP1 | WampServer
Private report: No CVE-ID: None
 [2015-07-31 08:14 UTC] sam dot swift at fifteendigital dot co dot uk
Description:
------------
I am using Visual Studio 2013/2015 and noticed that, following the code back to get an understanding, the is an infinite loop within the interface structure:

interface  Traversable extends IteratorAggregate
interface IteratorAggregate extends Traversable
interface  Traversable extends IteratorAggregate
interface IteratorAggregate extends Traversable
interface  Traversable extends IteratorAggregate
interface IteratorAggregate extends Traversable
interface  Traversable extends IteratorAggregate
interface IteratorAggregate extends Traversable

And so on, forever.


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2015-07-31 10:02 UTC] requinix@php.net
-Status: Open +Status: Feedback -Package: MySQLi related +Package: Class/Object related
 [2015-07-31 10:02 UTC] requinix@php.net
Where are you getting this information? php --rc shows IteratorAggregate extends Traversable but Traversable does not extend anything.
 [2015-07-31 10:04 UTC] sam dot swift at fifteendigital dot co dot uk
-Status: Feedback +Status: Open
 [2015-07-31 10:04 UTC] sam dot swift at fifteendigital dot co dot uk
The information comes from pressing F12 in Visual Studio 2013/15 with PHP tools, may it be possible then it's an error in the extension?
 [2015-07-31 10:07 UTC] requinix@php.net
-Status: Open +Status: Feedback
 [2015-07-31 10:07 UTC] requinix@php.net
PHP has the interfaces defined correctly but your "PHP tools" may not. Have you looked into that? Exactly what VS extension are you using?
 [2015-07-31 10:09 UTC] sam dot swift at fifteendigital dot co dot uk
It's PHP tools by Devsense: http://www.devsense.com/products/php-tools
 [2015-07-31 10:27 UTC] requinix@php.net
-Status: Feedback +Status: Not a bug
 [2015-07-31 10:27 UTC] requinix@php.net
Yeah, it's a problem with their extension.

I can keep looking into this to verify, but I need to know where they have the Traversable or IteratorAggregate classes defined (along with every other built-in class, no doubt). Can you use the Object Browser to find the DLL where those are located?
 [2015-07-31 10:29 UTC] sam dot swift at fifteendigital dot co dot uk
Unfortunately not, where I work does not grant me access and all I see when I hover over the instance tab in VS is "From metadata", I don't know if that will help?
 [2015-07-31 10:42 UTC] requinix@php.net
It's been a few years since I've used Visual Studio so my memory might be a bit off.

You should be able to go from the IteratorAggregate or Traversable name, in code (including in the code "from metadata"), into the Object Browser. Or open up the Object Browser directly and do a search for either of those classes. It'll then show the hierarchy of where those classes are, and at the "top" will be a library and a .dll file.

I think.
 [2015-07-31 11:05 UTC] sam dot swift at fifteendigital dot co dot uk
Can I upload images here or do I need to email you them?

I think it would be beneficial for you to see what I do.
 [2015-07-31 11:12 UTC] requinix@php.net
Email, please. Meanwhile I've discovered many of their DLLs are obfuscated so that's not helping.
 [2015-07-31 12:02 UTC] requinix@php.net
I just remembered I have a copy of VS 2010. And I had previously installed it. Oops.

The class definitions are stored somewhere but there's too much code for me to sift through, especially since I know nothing about the VS SDK. So while I can't point to the source of the problem, I can guarantee you it's something with their extension and does not affect PHP itself.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Mar 28 16:01:29 2024 UTC