This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
When writing a 'throw new \Exception' statement, the code completion can take up to 30 seconds to provide a match. Very often the IDE will produce a popup asking if I want to report the problem. Elsewhere code completion is very fast, the slowness only occurs after the 'throw' keyword. To make this even weirder, it only happens on a newly typed 'throw'. If I open a file and replace only an exception class, it is fast. Delete the whole line and retype 'throw' it is slow again.
(In reply to waldermort from comment #0) > Very often the IDE will produce a > popup asking if I want to report the problem. Weird, this should create an issue automatically with all required information. Never mind, please, we need a profiler snapshot [1]. Simply start profiling, reproduce your problem and then (after ~30 seconds) stop profiling. Then reopen this issue and attach the profiler snapshot here. Thanks for your cooperation. [1] http://wiki.netbeans.org/FaqProfileMeNow
Created attachment 153099 [details] Profiler snapshot The requested profiler snapshot
Time is spent in PHP editor, please evaluate. Thanks.
@tzezula: Tome, I can see this: org.apache.lucene.index.TermBuffer.read () 8 285 ms (14%) 9 620 ms (0,9%) Please, is it OK? It could be caused by deep PHP type hierarchy perhaps? Thanks.
Reading terms is OK. Mostly caused by high amount of ineffective small queries.
(In reply to Tomas Zezula from comment #5) > Mostly caused by high amount of ineffective small queries. I see. This is caused by deep class hierarchy, NetBeans tries to find all Exception classes. Unfortunately, currently no way (I know of) how to improve/fix it, sorry. Thanks for reporting.
Two years later, and this issue still annoys the hell out of me. I guess it was pushed back and forgot about. I've got to the point where I make my exception classes implement a static method: class SomeException extends \RuntimeException { public static function create($message) { return new self($message); } } Now when throwing an exception I can: throw SomeException::create('foo'); The autocomplete works as expected.