Open
Description
TODO
- The dartdoc comment of
.address
should mention or show an example of using.cast()
. - The published
ADDRESS_POSITION
documentation should mention.cast()
.
Original bug report:
While trying to fix this,
I found the below code is
@Native<Void Function(Pointer<Void>)>(isLeaf: true)
external void myNative(Pointer<Void> buff);
void main() {
final buff = Int8List.fromList([2]);
myNative(buff.address.cc);
}
throws 2 errors by the analyzer
1. ERROR|COMPILE_TIME_ERROR|ADDRESS_POSITION|9|17|7|The '.address' expression can only be used as argument to a leaf native external call.
2. ERROR|COMPILE_TIME_ERROR|UNDEFINED_GETTER|9|25|2|The getter 'cc' isn't defined for the type 'Pointer<Int8>'.
But expected is only one error
1. ERROR|COMPILE_TIME_ERROR|UNDEFINED_GETTER|9|25|2|The getter 'cc' isn't defined for the type 'Pointer<Int8>'.
FYI @dcharkes