//ww:error "sret receive into a tagged GLOBAL lvalue unwired" package main; type oops = !str; type nomem = !void; type wide = struct { xs: []u8, ys: []u8, n: i64 }; let g: (wide | oops | nomem); fn mk(b: []u8) (wide | oops | nomem) = { return wide { xs = b, ys = b, n = 1 }; }; export fn main() i32 = { let buf: [4]u8 = [1u8, 2u8, 3u8, 4u8]; g = mk(buf[0:4]); match (g) { case let w: wide => { if (w.n != 1) { return 1; }; }; case let e: oops => return 13; case nomem => return 14; }; return 0; };