Commit 7b2ff37d authored by Michael Hanus 's avatar Michael Hanus

Fixes ForallType bug by removing ForallType when translating to PAKCS

parent 7f21c90b
Subproject commit bb0d9ff0067e872705aae3447f268723d3840ce5
Subproject commit 04c8a083fcdc1f87c247d7ff475bee0ef8ad8b45
......@@ -1346,7 +1346,7 @@ writeFunc('Func'(Name,FArity,_,Type,'External'(ExtNameS))) :-
isIOAction(Type), !,
% generate standard external interface for I/O operations:
flatName2Atom(Name,FName),
length(Args,FArity),
length(Args,FArity),
rev(Args,RevArgs),
appendAtom(FName,'$WORLD',FNameWorld),
append(Args,[partcall(1,FNameWorld,RevArgs),E,E],PFArgs),
......
......@@ -372,7 +372,8 @@ readIdTerm(Id,_,S,_) :-
writeErr('ERROR in ReadShowTerm.readTerm: Unknown symbol: '),
writeErr(Id), nlErr,
writeErr('in remaining term string: '),
putChars(user_error,S), nlErr,
take(1000,S,ShortS),
putChars(user_error,ShortS), nlErr,
!, fail.
% try to add a qualifier to a unique unqualified constructor symbol
......
......@@ -69,15 +69,16 @@ fcy2flcTypeExpr('FuncType'(T1,T2),'FuncType'(FT1,FT2)) :-
fcy2flcTypeExpr('TCons'(TName,TEs),'TCons'(FTName,FTEs)) :-
fcy2flcQName(TName,FTName),
map2M(readFlcFromFcy:fcy2flcTypeExpr,TEs,FTEs).
fcy2flcTypeExpr('ForallType'(Is,TE),FAT) :-
fcy2flcForallTypeExpr(Is,TE,FAT).
%fcy2flcTypeExpr('ForallType'(Is,TE),FAT) :-
% fcy2flcForallTypeExpr(Is,TE,FAT).
% forall quantifiers in types are removed since they are not relevant for PAKCS
fcy2flcTypeExpr('ForallType'(_,TE),FTE) :-
fcy2flcTypeExpr(TE,FTE).
fcy2flcForallTypeExpr([],TE,FTE) :- !,
fcy2flcTypeExpr(TE,FTE).
%fcy2flcForallTypeExpr(['Prelude.(,)'(I,_)|Is],TE,
% 'TCons'("Prelude.Forall",['TVar'(I),FAT])) :- !,
% fcy2flcForallTypeExpr(Is,TE,FAT).
fcy2flcForallTypeExpr([_|Is],TE,FAT) :-
fcy2flcForallTypeExpr(['Prelude.(,)'(I,_)|Is],TE,
'TCons'("Prelude.Forall",['TVar'(I),FAT])) :- !,
fcy2flcForallTypeExpr(Is,TE,FAT).
fcy2flcFunc('Func'(FName,Arity,Vis,Type,Rule),
......
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