You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@martinlippert this seems to work. I've discovered that ITypeBinding.getKey() returning binding key string is computed once and then cached proves to be very useful as it eliminates costly getQualifiedName() calls and delivers something that can be used as annotation's FQN as for annotation types it easy to convert FQN <-> Binding key (i.e. foo.bar.A <-> Lfoo/bar/A), JavaUtils class has methods for simple conversions. Therefore, I'd go even further and put binding keys in AnnotationTypeInformation as we seem to only care about whether binding is annotated with annotation given by its FQN and all annotations as an Iterator/Collection of IAnnotationBinding. We can still have the method taking FQN as a parameter but it'd delegate to the method taking binding key as a parameter (since we can convert FQN to binding key). In addition I'd also switch AnnotationHierarchyAwareLookup.bindings map to have keys as binding keys rather than FQN - this will greatly decrease the number of ITypeBinding.getQualifiedName() calls. This would be the last thing I'd do on this topic.
Merging what I have a the moment and then working on switching to binding key under the hood instead of FQN without changing the API that accepts FQN parameter.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Addresse #1288