Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 4 additions & 15 deletions source_gen/lib/src/generator.dart
Original file line number Diff line number Diff line change
Expand Up @@ -62,23 +62,12 @@ class InvalidGenerationSource implements Exception {

InvalidGenerationSource(
this.message, {
Annotatable? annotatable,
this.todo = '',
// ignore: deprecated_member_use until analyzer 7 support is dropped.
Element2? element,
ElementDirective? elementDirective,
Fragment? fragment,
this.element,
this.elementDirective,
this.fragment,
this.node,
}) : element =
element ??
// ignore: deprecated_member_use until analyzer 7 support is dropped.
(annotatable is Element2 ? annotatable : null) as Element2?,
elementDirective =
elementDirective ??
(annotatable is ElementDirective ? annotatable : null),
fragment =
fragment ??
(annotatable is Fragment ? annotatable : null) as Fragment?;
});

@override
String toString() {
Expand Down
Loading