Fix supervised credentials and declare typed RPC records for canvas placement
This commit is contained in:
@@ -319,6 +319,11 @@ const lowerValueType = (
|
||||
if (context.MESSAGE()) {
|
||||
return valueType.message(stringValue(context.stringLiteral()));
|
||||
}
|
||||
if (context.RECORD()) {
|
||||
const fields = context.recordField().map((field) => [identifier(field.identifier()), lowerValueType(state, field.valueType())] as const);
|
||||
if (new Set(fields.map(([name]) => name)).size !== fields.length) loweringIssue(state, context, "invalid-type", "Duplicate record field");
|
||||
return {kind: "record", fields: Object.fromEntries(fields)};
|
||||
}
|
||||
if (context.ATOM_REF()) {
|
||||
const name = identifier(context.identifier());
|
||||
const atomId = requireSymbol(state, state.atoms, name, context, "atom");
|
||||
|
||||
Reference in New Issue
Block a user