encode method
ABI-encode value as a 32-byte-aligned Uint8List.
For dynamic types, returns the tail; the caller places the offset in the head.
Implementation
@override
Uint8List encode(dynamic value) {
if (value is! bool) {
throw ArgumentError('Expected bool, got ${value.runtimeType}');
}
final out = Uint8List(32);
out[31] = value ? 1 : 0;
return out;
}