diff options
author | Alon Zakai <alonzakai@gmail.com> | 2013-01-01 11:03:10 -0800 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2013-01-01 11:03:10 -0800 |
commit | b42a90360ab918019e1824a1fd43966638a6faba (patch) | |
tree | 8cae1c6bff1d0f65b5a7d2976320649b9c0bef12 | |
parent | 6181442a104dd74fb2da8298e28c8a78f2195da5 (diff) |
deprecate EMSCRIPTEN_KEEPALIVE - add your functions to EXPORTED_FUNCTIONS instead
-rw-r--r-- | system/include/emscripten/emscripten.h | 7 | ||||
-rwxr-xr-x | tests/runner.py | 2 |
2 files changed, 5 insertions, 4 deletions
diff --git a/system/include/emscripten/emscripten.h b/system/include/emscripten/emscripten.h index 926fe2e5..70938fb0 100644 --- a/system/include/emscripten/emscripten.h +++ b/system/include/emscripten/emscripten.h @@ -20,10 +20,11 @@ extern "C" { * closure may still eliminate it at the JS level, for which you * should use EXPORTED_FUNCTIONS (see settings.js). * - * Example usage: - * void EMSCRIPTEN_KEEPALIVE my_function() { .. } + * **DEPRECATED**: Use EXPORTED_FUNCTIONS instead, which will work + * with closure, asm.js, etc. For example + * -s EXPORTED_FUNCTIONS=["_main", "myfunc"] */ -#define EMSCRIPTEN_KEEPALIVE __attribute__((used)) +/* #define EMSCRIPTEN_KEEPALIVE __attribute__((used)) */ /* * Interface to the underlying JS engine. This function will diff --git a/tests/runner.py b/tests/runner.py index 177b795c..97ec3b94 100755 --- a/tests/runner.py +++ b/tests/runner.py @@ -3119,7 +3119,7 @@ Exiting setjmp function, level: 0, prev_jmp: -1 #include "emscripten.h" extern "C" { - void EMSCRIPTEN_KEEPALIVE save_me_aimee() { printf("mann\n"); } + void save_me_aimee() { printf("mann\n"); } } int main() { |