Commit 107e3692 authored by sewardj's avatar sewardj
Browse files

[project @ 2000-01-07 15:31:12 by sewardj]

finishGHCModule: correctly create export list entries for non-Names
importEntity: allow TUPLE as a kind of TYCON (am dubious about this)
parent 9ac5c76c
......@@ -7,8 +7,8 @@
* Hugs version 1.4, December 1997
*
* $RCSfile: interface.c,v $
* $Revision: 1.21 $
* $Date: 2000/01/07 10:29:59 $
* $Revision: 1.22 $
* $Date: 2000/01/07 15:31:12 $
* ------------------------------------------------------------------------*/
#include "prelude.h"
......@@ -1066,7 +1066,7 @@ Void finishGHCModule ( Cell root )
c = findQualTyconWithoutConsultingExportList ( q );
if (isNull(c)) goto notfound;
fprintf(stderr, " type %s\n", textToStr(textOf(ex)) );
module(mod).exports = cons(c, module(mod).exports);
module(mod).exports = cons(pair(c,NIL), module(mod).exports);
addTycon(c);
break;
......@@ -1087,7 +1087,7 @@ Void finishGHCModule ( Cell root )
original (defining) module.
*/
if (abstract) {
module(mod).exports = cons(c, module(mod).exports);
module(mod).exports = cons(pair(c,NIL), module(mod).exports);
addTycon(c);
fprintf ( stderr, "(abstract) ");
} else {
......@@ -1101,7 +1101,7 @@ Void finishGHCModule ( Cell root )
c = findQualNameWithoutConsultingExportList ( q );
fprintf(stderr, "%s ", textToStr(name(c).text));
assert(nonNull(c));
module(mod).exports = cons(c, module(mod).exports);
/* module(mod).exports = cons(c, module(mod).exports); */
addName(c);
}
}
......@@ -1120,7 +1120,7 @@ Void finishGHCModule ( Cell root )
c = findQualNameWithoutConsultingExportList ( q );
fprintf(stderr, "%s ", textToStr(name(c).text));
if (isNull(c)) goto notfound;
module(mod).exports = cons(c, module(mod).exports);
/* module(mod).exports = cons(c, module(mod).exports); */
addName(c);
}
fprintf(stderr, "}\n" );
......
......@@ -9,8 +9,8 @@
* included in the distribution.
*
* $RCSfile: static.c,v $
* $Revision: 1.20 $
* $Date: 1999/12/10 15:59:50 $
* $Revision: 1.21 $
* $Date: 2000/01/07 15:31:12 $
* ------------------------------------------------------------------------*/
#include "prelude.h"
......@@ -469,6 +469,7 @@ Pair importSpec; {
} else {
imports = resolveImportList(m, impList);
}
for(; nonNull(imports); imports=tl(imports)) {
Cell e = hd(imports);
if (!cellIsMember(e,hidden))
......@@ -485,6 +486,7 @@ Cell e; {
switch (whatIs(e)) {
case NAME : importName(source,e);
break;
case TUPLE:
case TYCON : importTycon(source,e);
break;
case CLASS : importClass(source,e);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment