Macro. Issue 55756. Include the name of the unresolved identifier.

Bug: https://github.com/dart-lang/sdk/issues/55756
Change-Id: Ia1eab2bdf8900843151386f7dc31423e5f62805a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/366966
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
diff --git a/pkg/analyzer/lib/src/summary2/macro_declarations.dart b/pkg/analyzer/lib/src/summary2/macro_declarations.dart
index df93b6c..6a9272e 100644
--- a/pkg/analyzer/lib/src/summary2/macro_declarations.dart
+++ b/pkg/analyzer/lib/src/summary2/macro_declarations.dart
@@ -304,6 +304,8 @@
           uri: null,
           staticScope: null,
         );
+      case null:
+        throw ArgumentError('Unresolved identifier: ${identifier.name}');
       default:
         throw UnimplementedError('${element.runtimeType}');
     }