Merge pull request #2991 from shyouhei/ruby.h
[ruby.git] / include / ruby / 3 / intern / signal.h
blobf4fa08732e1e517c4f8e9b0ef2f728be6582bc09
1 /** \noop-*-C++-*-vi:ft=cpp
2 * @file
3 * @author Ruby developers <ruby-core@ruby-lang.org>
4 * @copyright This file is a part of the programming language Ruby.
5 * Permission is hereby granted, to either redistribute and/or
6 * modify this file, provided that the conditions mentioned in the
7 * file COPYING are met. Consult the file for details.
8 * @warning Symbols prefixed with either `RUBY3` or `ruby3` are
9 * implementation details. Don't take them as canon. They could
10 * rapidly appear then vanish. The name (path) of this header file
11 * is also an implementation detail. Do not expect it to persist
12 * at the place it is now. Developers are free to move it anywhere
13 * anytime at will.
14 * @note To ruby-core: remember that this header can be possibly
15 * recursively included from extension libraries written in C++.
16 * Do not expect for instance `__VA_ARGS__` is always available.
17 * We assume C99 for ruby itself but we don't assume languages of
18 * extension libraries. They could be written in C++98.
19 * @brief Signal handling APIs.
21 #ifndef RUBY3_INTERN_SIGNAL_H
22 #define RUBY3_INTERN_SIGNAL_H
23 #include "ruby/3/config.h" /* POSIX_SIGNAL / RETSIGTYPE */
24 #include "ruby/3/dllexport.h"
25 #include "ruby/3/value.h"
27 RUBY3_SYMBOL_EXPORT_BEGIN()
29 /* signal.c */
30 VALUE rb_f_kill(int, const VALUE*);
31 #ifdef POSIX_SIGNAL
32 #define posix_signal ruby_posix_signal
33 RETSIGTYPE (*posix_signal(int, RETSIGTYPE (*)(int)))(int);
34 #endif
35 const char *ruby_signal_name(int);
36 void ruby_default_signal(int);
38 RUBY3_SYMBOL_EXPORT_END()
40 #endif /* RUBY3_INTERN_SIGNAL_H */