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.
Created attachment 152373 [details] Proposed patch It's impossible to reach the Only Global Default Lookup during Lookups.executeWith - in case one really needs to be independent of context switches. I propose a slight change to the Lookups.executeWith - see the attached patch. The system would remember the default Lookup, then use it whenever Lookup.executeWith() is called with null argument - the behaviour for such situation is currently undefined and would result in a NPE.
Looks like a simple change i am able to understand. Can you just note the fact about the global lookup in javadoc for Lookups.executeWith?
Created attachment 152386 [details] refined patch - javadoc added OV-1 (javadoc) added.
I agree with patch.
The patch seems fine to me.
... i agree, too
Will be implemented in jet-main#74aad6bdd167. Testcase added as jet-main#749204d0e21f
Integrated into 'main-silver', will be available in build *201503070001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-silver/rev/74aad6bdd167 User: Svata Dedic <sdedic@netbeans.org> Log: #250873: Lookups.executeWith() behaviour defined for null argument