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.
As seen by the fix in #3f95d8ec59de, the current Debugger Core API does not do a good job of preventing type errors in Lookup. The interface lacks the correct generic signature, and the implementation does insufficient runtime type checking. Also there is an interface ContextProvider which surely ought to be implemented by all the API classes which provide that signature, yet currently only Lookup actually implements it.
Created attachment 57139 [details] Proposed patch
b181c17b8a6b
I found I also needed to add a method DebuggerManager.join to merge two context providers. Formerly this was done with a copied and pasted block of code everywhere which appended one list to the other. Since the lists are now List<? extends T>, it is impermissible to destructively insert the second into the first. And furthermore it seems that the actual List returned was in fact a java.beans.Customizer (though this was nowhere documented) and code relied on this. The new method takes care of these details and makes the code shorter too. #00a4dfe6689f
Verified ... and Closing all issues resolved into NetBeans 6.7 and earlier.