better-looking parameters
This commit is contained in:
parent
9afaa41fbb
commit
95eb8aef84
10 changed files with 306 additions and 229 deletions
|
|
@ -32,7 +32,7 @@ export function Value({dynamic}) {
|
|||
// case symbolSet:
|
||||
// return <UnaryType type={type} cssClass="setType" prefix="{" suffix="}" />;
|
||||
case symbolList:
|
||||
return <List val={inst} elemType={type.params[0](type)} />;
|
||||
return <ValueList val={inst} elemType={type.params[0](type)} />;
|
||||
|
||||
default:
|
||||
return <>don't know how to show value</>;
|
||||
|
|
@ -51,8 +51,8 @@ function ValueFunction() {
|
|||
// function Sum({val, elemType}) {
|
||||
// return
|
||||
// }
|
||||
function List({val, elemType}) {
|
||||
return <span className="listType">[{val.map((v, i) => <Value dynamic={{i:v, t:elemType}}/>)}]</span>;
|
||||
function ValueList({val, elemType}) {
|
||||
return <span className="listType">[{val.map((v, i) => <Value key={i} dynamic={{i:v, t:elemType}}/>)}]</span>;
|
||||
}
|
||||
function ValueSum({val, leftType, rightType}) {
|
||||
return match(val)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue