return barr.asBinary();
}
private static void collectList(EObject list, ECons iol, OutputStream barr) throws IOException {
EObject tail;
ECons cons;
for (tail=iol; (cons = tail.testNonEmptyList()) != null; tail = cons.tail()) {
EObject hd = cons.head();
ESmall sm;
EBinary bi;
ECons co;
if ((sm = hd.testSmall()) != null) {
if (sm.value < 0 || sm.value > 255)
throw ERT.badarg(list);
barr.write(sm.value);
} else if ((bi = hd.testBinary()) != null) {
bi.writeTo(barr);
} else if ((co = hd.testNonEmptyList()) != null) {
collectList(list, co, barr);
} else if (hd.isNil()) {
} else {
throw ERT.badarg(list);
}
}