visualize type unification substitutions

This commit is contained in:
Joeri Exelmans 2025-05-27 11:17:32 +02:00
parent 4a4cee6ee9
commit 7edf44f107
7 changed files with 45 additions and 40 deletions

View file

@ -4,7 +4,7 @@ import { EnvContext } from "../../context/EnvContext";
import { GlobalContext } from "../../context/GlobalContext";
import { type TypeInfoLet } from "../../eval/infer_type";
import { Input } from "../other/Input";
import { Type } from "../other/Type";
import { Type, TypeInfoBlock } from "../other/Type";
import { ExprBlock, type ExprBlockState, type State2Props } from "./ExprBlock";
import "./LetInBlock.css";
@ -50,7 +50,7 @@ function DeclColumns({state, setState, score, typeInfo}) {
onTextChange={name => setState(state => ({...state, name}))}
extraHandlers={{}}
/>
:: <Type type={typeInfo.value.type} />
:: <TypeInfoBlock typeInfo={typeInfo.value} />
</span>
<span className="keyword column">&nbsp;=&nbsp;</span>
<span className="column">