summaryrefslogtreecommitdiff
path: root/compiler/nset.pas
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/nset.pas')
-rw-r--r--compiler/nset.pas8
1 files changed, 8 insertions, 0 deletions
diff --git a/compiler/nset.pas b/compiler/nset.pas
index 3f38ac8a5d..afb3362b27 100644
--- a/compiler/nset.pas
+++ b/compiler/nset.pas
@@ -250,6 +250,7 @@ implementation
begin
result:=nil;
+
resultdef:=pasbool1type;
typecheckpass(right);
set_varstate(right,vs_read,[vsf_must_be_valid]);
@@ -272,6 +273,13 @@ implementation
if not assigned(left.resultdef) then
internalerror(20021126);
+ { avoid any problems with type parameters later on }
+ if is_typeparam(left.resultdef) or is_typeparam(right.resultdef) then
+ begin
+ resultdef:=cundefinedtype;
+ exit;
+ end;
+
t:=self;
if isbinaryoverloaded(t,[]) then
begin