mirror of
https://github.com/Noratrieb/riverdelta.git
synced 2026-01-15 00:45:04 +01:00
Add I32, mirroring Wasm i32
This commit is contained in:
parent
89dbb50add
commit
50e82066c9
5 changed files with 28 additions and 3 deletions
|
|
@ -15,6 +15,7 @@ import {
|
|||
Resolution,
|
||||
Ty,
|
||||
TY_BOOL,
|
||||
TY_I32,
|
||||
TY_INT,
|
||||
TY_NEVER,
|
||||
TY_STRING,
|
||||
|
|
@ -34,6 +35,9 @@ function builtinAsTy(name: string, span: Span): Ty {
|
|||
case "Int": {
|
||||
return TY_INT;
|
||||
}
|
||||
case "I32": {
|
||||
return TY_I32;
|
||||
}
|
||||
case "Bool": {
|
||||
return TY_BOOL;
|
||||
}
|
||||
|
|
@ -355,6 +359,10 @@ export class InferContext {
|
|||
if (rhs.kind === "int") return;
|
||||
break;
|
||||
}
|
||||
case "i32": {
|
||||
if (rhs.kind === "i32") return;
|
||||
break;
|
||||
}
|
||||
case "bool": {
|
||||
if (rhs.kind === "bool") return;
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue