summaryrefslogtreecommitdiff
path: root/includes/RtsAPI.h
diff options
context:
space:
mode:
authorEdward Z. Yang <ezyang@mit.edu>2013-08-26 15:23:15 -0700
committerEdward Z. Yang <ezyang@cs.stanford.edu>2014-10-01 22:26:39 -0700
commit35672072b4091d6f0031417bc160c568f22d0469 (patch)
tree243925bae6f8869cca1df8595c17c0467b9d5998 /includes/RtsAPI.h
parent178eb9060f369b216f3f401196e28eab4af5624d (diff)
downloadhaskell-35672072b4091d6f0031417bc160c568f22d0469.tar.gz
Rename _closure to _static_closure, apply naming consistently.
Summary: In preparation for indirecting all references to closures, we rename _closure to _static_closure to ensure any old code will get an undefined symbol error. In order to reference a closure foobar_closure (which is now undefined), you should instead use STATIC_CLOSURE(foobar). For convenience, a number of these old identifiers are macro'd. Across C-- and C (Windows and otherwise), there were differing conventions on whether or not foobar_closure or &foobar_closure was the address of the closure. Now, all foobar_closure references are addresses, and no & is necessary. CHARLIKE/INTLIKE were not changed, simply alpha-renamed. Part of remove HEAP_ALLOCED patch set (#8199) Depends on D265 Signed-off-by: Edward Z. Yang <ezyang@mit.edu> Test Plan: validate Reviewers: simonmar, austin Subscribers: simonmar, ezyang, carter, thomie Differential Revision: https://phabricator.haskell.org/D267 GHC Trac Issues: #8199
Diffstat (limited to 'includes/RtsAPI.h')
-rw-r--r--includes/RtsAPI.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/includes/RtsAPI.h b/includes/RtsAPI.h
index 0ba16714e9..fc7eb26d37 100644
--- a/includes/RtsAPI.h
+++ b/includes/RtsAPI.h
@@ -249,15 +249,15 @@ void rts_done (void);
// the base package itself.
//
#if defined(COMPILING_WINDOWS_DLL) && !defined(COMPILING_BASE_PACKAGE)
-__declspec(dllimport) extern StgWord base_GHCziTopHandler_runIO_closure[];
-__declspec(dllimport) extern StgWord base_GHCziTopHandler_runNonIO_closure[];
+__declspec(dllimport) extern StgWord base_GHCziTopHandler_runIO_static_closure[];
+__declspec(dllimport) extern StgWord base_GHCziTopHandler_runNonIO_static_closure[];
#else
-extern StgWord base_GHCziTopHandler_runIO_closure[];
-extern StgWord base_GHCziTopHandler_runNonIO_closure[];
+extern StgWord base_GHCziTopHandler_runIO_static_closure[];
+extern StgWord base_GHCziTopHandler_runNonIO_static_closure[];
#endif
-#define runIO_closure base_GHCziTopHandler_runIO_closure
-#define runNonIO_closure base_GHCziTopHandler_runNonIO_closure
+#define runIO_closure STATIC_CLOSURE(base_GHCziTopHandler_runIO)
+#define runNonIO_closure STATIC_CLOSURE(base_GHCziTopHandler_runNonIO)
/* ------------------------------------------------------------------------ */