31aa8e26df
Instead of a very slow .inDeclarationContext() method which determines whether a given identifier is in a use position or not, we just create a different subclass at parse time that encodes that fact directly. Also, remove an unnecessary _validateElement() method. On my Mac laptop, this takes benchmark/errors_in_all_libraries.dart From: 0:00:05.673849 To: 0:00:05.193563 (91.53%) R=brianwilkerson@google.com Review URL: https://codereview.chromium.org/1833573006 .