You need to sign in to do that
Don't have an account?
cropzim
Winter 13 break? APEX mySet.remove(null)
I just reran my regression scripts on Winter 13 and oops, existing APEX code no longer works. Anyone else seeing this?
Specific scenario is this code:
Set<String> aSet = new Set<String> {null, 'abc','def'}; System.debug(LoggingLevel.INFO,'aSet before remove <abc>:' + aSet); aSet.remove('abc'); System.debug(LoggingLevel.INFO,'aSet after remove <abc>:' + aSet); aSet.remove(null); System.debug(LoggingLevel.INFO,'aSet after remove <null>:' + aSet);
First debug statement displays {null,'abc','def'} as expected
Second debug statement, after removing element 'abc' displays {null,'def'} as expected
BUT...
We never get to the tihrd debug statement because a runtime error is thrown on aSet.remove(null) - "Argument 1 may not be null"
This used to work in Summer 12. I don't see anything in the release notes indicating this functionality has been changed
see https://sites.secure.force.com/success/issues_view?id=a1p30000000SThrAAG