Browse Source

patched procedure list outside of object / pointer to record

git-svn-id: https://svn.inf.ethz.ch/svn/lecturers/a2/trunk@8422 8c9fc860-2736-0410-a75d-ab315db34111
felixf 6 years ago
parent
commit
3135a95edc
1 changed files with 1 additions and 1 deletions
  1. 1 1
      source/FoxPrintout.Mod

+ 1 - 1
source/FoxPrintout.Mod

@@ -380,8 +380,8 @@ TYPE
 				IF x.recordScope.procedures # NIL THEN w.Ln; ProcedureList(x.recordScope.procedures) END;
 				IF x.recordScope.procedures # NIL THEN w.Ln; ProcedureList(x.recordScope.procedures) END;
 				currentScope := prevScope;
 				currentScope := prevScope;
 				Indent; Keyword("END" );
 				Indent; Keyword("END" );
+				IF (x.pointerType = NIL) & (x.recordScope.procedures # NIL) THEN w.Ln; ProcedureList(x.recordScope.procedures) END;
 			END;
 			END;
-			IF x.recordScope.procedures # NIL THEN w.Ln; ProcedureList(x.recordScope.procedures) END;
 		END VisitRecordType;
 		END VisitRecordType;
 
 
 		PROCEDURE Flag(identifier: SyntaxTree.Identifier; VAR first: BOOLEAN);
 		PROCEDURE Flag(identifier: SyntaxTree.Identifier; VAR first: BOOLEAN);