From d0dafffc8d33d1e5cba7921b4f833adc6e5c75f4 Mon Sep 17 00:00:00 2001 From: simonmar Date: Mon, 22 May 2000 11:39:08 +0000 Subject: [PATCH] [project @ 2000-05-22 11:39:08 by simonmar] Don't use a worker Id for the internal ccall worker; generate a new syslocal instead. This is to avoid a clash in the case where a real worker is generated later on. --- ghc/compiler/deSugar/DsForeign.lhs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ghc/compiler/deSugar/DsForeign.lhs b/ghc/compiler/deSugar/DsForeign.lhs index 7817c52..c501beb 100644 --- a/ghc/compiler/deSugar/DsForeign.lhs +++ b/ghc/compiler/deSugar/DsForeign.lhs @@ -22,7 +22,7 @@ import CallConv import TcHsSyn ( TypecheckedForeignDecl ) import CoreUtils ( exprType, mkInlineMe ) import DataCon ( DataCon, dataConWrapId ) -import Id ( Id, idType, idName, mkWildId, mkVanillaId ) +import Id ( Id, idType, idName, mkWildId, mkVanillaId, mkSysLocal ) import MkId ( mkWorkerId ) import Literal ( Literal(..) ) import Module ( Module, moduleUserString ) @@ -151,7 +151,7 @@ dsFImport fn_id ty may_not_gc ext_name cconv the_ccall = CCall lbl False (not may_not_gc) cconv the_ccall_app = mkCCall ccall_uniq the_ccall val_args ccall_result_ty work_rhs = mkLams tvs (mkLams work_arg_ids the_ccall_app) - work_id = mkWorkerId work_uniq fn_id worker_ty + work_id = mkSysLocal SLIT("$wccall") work_uniq worker_ty -- Build the wrapper work_app = mkApps (mkVarApps (Var work_id) tvs) val_args -- 1.7.10.4