diff options
Diffstat (limited to 'test/data')
| -rw-r--r-- | test/data/emacs-module/mod-test.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/test/data/emacs-module/mod-test.c b/test/data/emacs-module/mod-test.c index 1a0a879a1bc..ec6948921f2 100644 --- a/test/data/emacs-module/mod-test.c +++ b/test/data/emacs-module/mod-test.c | |||
| @@ -24,6 +24,7 @@ along with GNU Emacs. If not, see <https://www.gnu.org/licenses/>. */ | |||
| 24 | 24 | ||
| 25 | #include <errno.h> | 25 | #include <errno.h> |
| 26 | #include <limits.h> | 26 | #include <limits.h> |
| 27 | #include <stdint.h> | ||
| 27 | #include <stdio.h> | 28 | #include <stdio.h> |
| 28 | #include <stdlib.h> | 29 | #include <stdlib.h> |
| 29 | #include <string.h> | 30 | #include <string.h> |
| @@ -86,6 +87,7 @@ static emacs_value | |||
| 86 | Fmod_test_sum (emacs_env *env, ptrdiff_t nargs, emacs_value args[], void *data) | 87 | Fmod_test_sum (emacs_env *env, ptrdiff_t nargs, emacs_value args[], void *data) |
| 87 | { | 88 | { |
| 88 | assert (nargs == 2); | 89 | assert (nargs == 2); |
| 90 | assert ((uintptr_t) data == 0x1234); | ||
| 89 | 91 | ||
| 90 | intmax_t a = env->extract_integer (env, args[0]); | 92 | intmax_t a = env->extract_integer (env, args[0]); |
| 91 | intmax_t b = env->extract_integer (env, args[1]); | 93 | intmax_t b = env->extract_integer (env, args[1]); |
| @@ -587,7 +589,8 @@ emacs_module_init (struct emacs_runtime *ert) | |||
| 587 | env->make_function (env, amin, amax, csym, doc, data)) | 589 | env->make_function (env, amin, amax, csym, doc, data)) |
| 588 | 590 | ||
| 589 | DEFUN ("mod-test-return-t", Fmod_test_return_t, 1, 1, NULL, NULL); | 591 | DEFUN ("mod-test-return-t", Fmod_test_return_t, 1, 1, NULL, NULL); |
| 590 | DEFUN ("mod-test-sum", Fmod_test_sum, 2, 2, "Return A + B\n\n(fn a b)", NULL); | 592 | DEFUN ("mod-test-sum", Fmod_test_sum, 2, 2, "Return A + B\n\n(fn a b)", |
| 593 | (void *) (uintptr_t) 0x1234); | ||
| 591 | DEFUN ("mod-test-signal", Fmod_test_signal, 0, 0, NULL, NULL); | 594 | DEFUN ("mod-test-signal", Fmod_test_signal, 0, 0, NULL, NULL); |
| 592 | DEFUN ("mod-test-throw", Fmod_test_throw, 0, 0, NULL, NULL); | 595 | DEFUN ("mod-test-throw", Fmod_test_throw, 0, 0, NULL, NULL); |
| 593 | DEFUN ("mod-test-non-local-exit-funcall", Fmod_test_non_local_exit_funcall, | 596 | DEFUN ("mod-test-non-local-exit-funcall", Fmod_test_non_local_exit_funcall, |