google / google/reflectable.dart
Unsupported operation: location
- Dominant language
- Dart
- Stars
- 386
- Forks
- 67
- PR merge metrics
- No merged PRs in 30d
Description
Hi! Very nice work on this library. Unfortunately it looks like it is not able to get the source code location of classes in the same library.
Example Reflector code:
```
class Reflector extends Reflectable {
const Reflector() : super(typeCapability, typingCapability);
}
const reflector = Reflector();
@reflector
class Solver {
...
}
```
Code crashing with error `Unsupported operation: location`:
```
TypeMirror aMirror = reflector.reflectType(Solver);
var srcUri = aMirror.location.sourceUri;
```
As both Reflector and `Solver` class are in the same library, I would expect it to be able to get the source code location of the `Solver` class.
Contributor guide
Assessment
This issue has not been assessed yet.