Support captured CRDT changes in compound transaction contracts
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
import { isStorableType } from "./generics.js";
|
||||
import { validateInitialization } from "./initialization.js";
|
||||
import { validateExecutionContracts } from "./execution.js";
|
||||
import { resolveForwardedBinding, type ConcreteBinding } from "./forwarding.js";
|
||||
@@ -244,6 +245,15 @@ const validateValueType = (
|
||||
requireText(issues, type.descriptorId, `${path}.descriptorId`, "Message descriptor identity");
|
||||
return;
|
||||
case "change":
|
||||
if (!isStorableType(type.value))
|
||||
issue(
|
||||
issues,
|
||||
"invalid-value-type",
|
||||
path,
|
||||
"change<T> requires a storable materialized type, not references or nested changes",
|
||||
);
|
||||
validateValueType(issues, type.value, path + ".value", indexes);
|
||||
return;
|
||||
case "optional":
|
||||
case "list":
|
||||
validateValueType(issues, type.value, `${path}.value`, indexes);
|
||||
|
||||
Reference in New Issue
Block a user