Fix regression in type checking of extensible records
This commit is contained in:
parent
1cbd2e8a23
commit
9f6fe70f38
1 changed files with 2 additions and 2 deletions
|
@ -2120,14 +2120,14 @@ export class Checker {
|
|||
{
|
||||
const fieldType = this.createTypeVar();
|
||||
this.inferBindings(member.pattern, fieldType, typeVars, constraints);
|
||||
structType = new TField(member.name.text, new TPresent(fieldType), fieldType, pattern);
|
||||
structType = new TField(member.name.text, new TPresent(fieldType), structType, pattern);
|
||||
break;
|
||||
}
|
||||
case SyntaxKind.PunnedStructPatternField:
|
||||
{
|
||||
const fieldType = this.createTypeVar();
|
||||
this.addBinding(member.name.text, Forall.mono(fieldType), Symkind.Var);
|
||||
structType = new TField(member.name.text, new TPresent(fieldType), fieldType, pattern);
|
||||
structType = new TField(member.name.text, new TPresent(fieldType), structType, pattern);
|
||||
break;
|
||||
}
|
||||
case SyntaxKind.VariadicStructPatternElement:
|
||||
|
|
Loading…
Reference in a new issue