From 68e30d7d52d84578fbe0f6f1c2041b150251e800 Mon Sep 17 00:00:00 2001 From: Araq Date: Sat, 27 Aug 2016 13:38:39 +0200 Subject: tester cleanup; enable some rod tests --- compiler/importer.nim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'compiler/importer.nim') diff --git a/compiler/importer.nim b/compiler/importer.nim index dd2c4d954..7e7130b85 100644 --- a/compiler/importer.nim +++ b/compiler/importer.nim @@ -163,7 +163,7 @@ proc myImportModule(c: PContext, n: PNode): PSym = var f = checkModuleName(n) if f != InvalidFileIDX: result = importModuleAs(n, gImportModule(c.module, f)) - if result.info.fileIndex == n.info.fileIndex: + if result.info.fileIndex == c.module.info.fileIndex: localError(n.info, errGenerated, "A module cannot import itself") if sfDeprecated in result.flags: message(n.info, warnDeprecated, result.name.s) -- cgit 1.4.1-2-gfad0