diff options
| author | Mattias EngdegÄrd | 2023-07-25 12:16:30 +0200 |
|---|---|---|
| committer | Mattias EngdegÄrd | 2023-07-26 17:34:03 +0200 |
| commit | 82f5f3b8a26249db0679bb7dc38c44352e8fbdf5 (patch) | |
| tree | 5890c3bec8dd65921695dd52949545cf21e92707 /src/data.c | |
| parent | c50f6538cfc43d856b361347c945f6348c6f2dc9 (diff) | |
| download | emacs-82f5f3b8a26249db0679bb7dc38c44352e8fbdf5.tar.gz emacs-82f5f3b8a26249db0679bb7dc38c44352e8fbdf5.zip | |
Provide backtrace for byte-ops aref and aset
Produce synthetic backtrace entries for `aref` and `aset` byte-ops
when the index is non-fixnum, or is out of range for vector or record
arguments (bug#64613).
* src/bytecode.c (exec_byte_code): Detect type and range errors
in-line for aref and aset.
* src/data.c (syms_of_data): Declare symbols Qaref and Qaset.
* test/lisp/emacs-lisp/bytecomp-tests.el
(bytecomp-tests--byte-op-error-cases): Add test cases.
Diffstat (limited to 'src/data.c')
| -rw-r--r-- | src/data.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/data.c b/src/data.c index 108ed97d1f6..619ab8fde64 100644 --- a/src/data.c +++ b/src/data.c | |||
| @@ -4116,6 +4116,8 @@ syms_of_data (void) | |||
| 4116 | DEFSYM (Qelt, "elt"); | 4116 | DEFSYM (Qelt, "elt"); |
| 4117 | DEFSYM (Qsetcar, "setcar"); | 4117 | DEFSYM (Qsetcar, "setcar"); |
| 4118 | DEFSYM (Qsetcdr, "setcdr"); | 4118 | DEFSYM (Qsetcdr, "setcdr"); |
| 4119 | DEFSYM (Qaref, "aref"); | ||
| 4120 | DEFSYM (Qaset, "aset"); | ||
| 4119 | 4121 | ||
| 4120 | error_tail = pure_cons (Qerror, Qnil); | 4122 | error_tail = pure_cons (Qerror, Qnil); |
| 4121 | 4123 | ||