summaryrefslogtreecommitdiff
path: root/src/emacs-module.c
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2017-06-14 11:01:02 -0700
committerPaul Eggert <eggert@cs.ucla.edu>2017-06-14 11:01:41 -0700
commitd715e6d8c6a7f3507f4faca0961ac87d58fbfab8 (patch)
treefac2105d5874ebf6cbd93bd1f7e349a98d499a7f /src/emacs-module.c
parentb657de7f7a9917ed82a0fd9b540db837ac1a02c5 (diff)
downloademacs-d715e6d8c6a7f3507f4faca0961ac87d58fbfab8.tar.gz
Port cleanup check to Oracle Studio 12.5
* src/conf_post.h (__has_attribute_cleanup): Resurrect. * src/emacs-module.c: Verify __has_attribute (cleanup), but in an #if this time.
Diffstat (limited to 'src/emacs-module.c')
-rw-r--r--src/emacs-module.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/emacs-module.c b/src/emacs-module.c
index de62329b3b8..5c413ee0556 100644
--- a/src/emacs-module.c
+++ b/src/emacs-module.c
@@ -170,6 +170,10 @@ static struct emacs_env_private global_env_private;
internal_handler_##handlertype, \
internal_cleanup_##handlertype)
+#if !__has_attribute (cleanup)
+ #error "__attribute__ ((cleanup)) not supported by this compiler; try GCC"
+#endif
+
/* It is very important that pushing the handler doesn't itself raise
a signal. Install the cleanup only after the handler has been
pushed. Use __attribute__ ((cleanup)) to avoid