Skip to content

Commit b81c350

Browse files
authored
Fix for latest version of pkg:analyzer (#169)
Releasing v2.2.5 Fixes #168
1 parent 76d9a5b commit b81c350

File tree

3 files changed

+8
-4
lines changed

3 files changed

+8
-4
lines changed

build_cli/CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
## 2.2.5
2+
3+
- Fix issue with latest version of `package:analyzer`.
4+
15
## 2.2.4
26

37
- Support the latest `package:analyzer` and `package:source_gen`.

build_cli/lib/src/to_share.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,8 @@ Set<FieldElement> createSortedFieldSet(ClassElement element) {
4444
continue;
4545
}
4646

47-
if (v is PropertyAccessorElement && v.variable2 is FieldElement) {
48-
fieldsList.add(v.variable2 as FieldElement);
47+
if (v is PropertyAccessorElement && v.declaration is FieldElement) {
48+
fieldsList.add(v.declaration as FieldElement);
4949
}
5050
}
5151

build_cli/pubspec.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: build_cli
2-
version: 2.2.4
2+
version: 2.2.5
33
description: >-
44
Parse command line arguments directly into an annotation class
55
using the power of build_runner and source_gen.
@@ -18,7 +18,7 @@ dependencies:
1818
build_cli_annotations: '>=2.1.0 <2.2.0'
1919
build_config: ^1.1.0
2020
pub_semver: ^2.1.4
21-
source_gen: '>=1.4.0 <3.0.0'
21+
source_gen: ^2.0.0
2222
source_helper: ^1.3.4
2323
yaml: ^3.1.0
2424

0 commit comments

Comments
 (0)