File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -1061,7 +1061,8 @@ Expression Result (without optional fields)
1061
1061
```
1062
1062
1063
1063
A struct may define constraints that apply to fields that are added when unified
1064
- with another struct using pattern or default constraints.
1064
+ with another struct using pattern or default constraints (_ Note_ : default
1065
+ constraints are not yet implemented).
1065
1066
1066
1067
A _ pattern constraint_ , denoted ` [pattern]: value ` , defines a pattern, which
1067
1068
is a value of type string, and a value to unify with fields whose label
@@ -1086,14 +1087,15 @@ whose label does not unify with any of the patterns of the pattern
1086
1087
constraints defined for ` a ` _ and_ for which there exists no field in ` a `
1087
1088
with that label.
1088
1089
The token ` ... ` is a shorthand for ` ..._ ` .
1090
+ _ Note_ : default constraints are not yet implemented.
1089
1091
1090
1092
1091
1093
```
1092
1094
a: {
1093
1095
foo: string // foo is a string
1094
1096
[=~"^i"]: int // all other fields starting with i are integers
1095
1097
[=~"^b"]: bool // all other fields starting with b are booleans
1096
- ...string // all other fields must be a string
1098
+ ...string // all other fields must be a string. Note: default constraints are not yet implemented.
1097
1099
}
1098
1100
1099
1101
b: a & {
You can’t perform that action at this time.
0 commit comments