bugfix: tester should compile again

This commit is contained in:
Araq 2012-01-03 01:20:47 +01:00
commit 20843b7c1a

View file

@ -788,7 +788,7 @@ proc semGenericConstraints(c: PContext, n: PNode, result: PType) =
else: else:
var x = semTypeNode(c, n, nil) var x = semTypeNode(c, n, nil)
if x.kind in StructuralEquivTypes and ( if x.kind in StructuralEquivTypes and (
sonsLen(x) == 0 or x.sons[0].kind == tyEmpty): sonsLen(x) == 0 or x.sons[0].kind in {tyGenericParam, tyEmpty}):
x = newConstraint(c, x.kind) x = newConstraint(c, x.kind)
result.addSon(x) result.addSon(x)