File tree Expand file tree Collapse file tree 2 files changed +15
-0
lines changed Expand file tree Collapse file tree 2 files changed +15
-0
lines changed Original file line number Diff line number Diff line change @@ -19,4 +19,15 @@ class MultiplierGenerator extends GeneratorForAnnotation<Multiplier> {
19
19
20
20
return 'num ${element .name3 }Multiplied() => ${element .name3 } * $numValue ;' ;
21
21
}
22
+
23
+ // Override this method to respond to annotations on directives: `import`,
24
+ // `export`, `library` and/or `part`.
25
+ //
26
+ // This generator doesn't respond to such annotations, so do nothing.
27
+ @override
28
+ dynamic generateForAnnotatedDirective (
29
+ ElementDirective directive,
30
+ ConstantReader annotation,
31
+ BuildStep buildStep,
32
+ );
22
33
}
Original file line number Diff line number Diff line change 4
4
do resolution need to switch to the new API, see
5
5
https://github.com/dart-lang/sdk/blob/main/pkg/analyzer/doc/element_model_migration_guide.md .
6
6
For questions please use https://github.com/dart-lang/build/discussions .
7
+ - ** Breaking Change** : annotations are now reported separately for elements
8
+ and directives. If you use ` TypeChecker().annotatedWith() ` , see also
9
+ the new ` TypeChecker().libraryDirectivesAnnotatedWith() ` . If you use
10
+ ` GeneratorForAnnotation ` see the new ` generateForAnnotatedDirective ` .
7
11
- Require ` build: ^3.0.0 `
8
12
- Updated the minimum package versions for a number of dependencies.
9
13
- Require Dart 3.7.0
You can’t perform that action at this time.
0 commit comments