assertPositive static method
Asserts that size is positive, throwing ArgumentError if not.
Implementation
static void assertPositive(ByteConverter size, [String? name]) {
if (size.bytes <= 0) {
throw ArgumentError.value(
size.bytes,
name ?? 'size',
'must be positive',
);
}
}