Add CToPtr special case

This commit is contained in:
Peter Rugg
2020-04-21 13:52:33 +01:00
parent 1773530c72
commit 8a4fa786dd

View File

@@ -206,7 +206,7 @@ function Data capInspect(CapPipe a, CapPipe b, CapInspectFunc func);
tagged GetType :
signExtend(getType(a));
tagged ToPtr :
(getAddr(a) - getBase(b));
(isValidCap(a) ? (getAddr(a) - getBase(b)) : 0);
default: ?;
endcase);
return res;