diff options
| author | Paul Eggert | 2017-02-02 09:52:20 -0800 |
|---|---|---|
| committer | Paul Eggert | 2017-02-02 09:52:37 -0800 |
| commit | eee537267f8d6a2f5a48f0c26c14546ac922936c (patch) | |
| tree | 8afd768a3c89aa979d88c09e50f9bf6fd4d6b24b /src/lisp.h | |
| parent | f5372d411d149e8a34def18074891454ebc47730 (diff) | |
| download | emacs-eee537267f8d6a2f5a48f0c26c14546ac922936c.tar.gz emacs-eee537267f8d6a2f5a48f0c26c14546ac922936c.zip | |
Fix lisp.h underparenthesization
* src/lisp.h (STACK_CONS, AUTO_STRING_WITH_LEN):
Parenthesize compound literals that are function call args.
Although this does not fix any bugs, it is the proper style for
macro parenthesization as it means this code will continue to
work even if make_lisp_ptr is changed to a macro.
Diffstat (limited to 'src/lisp.h')
| -rw-r--r-- | src/lisp.h | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/lisp.h b/src/lisp.h index 1ac38164c27..a9011b4a8be 100644 --- a/src/lisp.h +++ b/src/lisp.h | |||
| @@ -4535,7 +4535,7 @@ enum | |||
| 4535 | use these only in macros like AUTO_CONS that declare a local | 4535 | use these only in macros like AUTO_CONS that declare a local |
| 4536 | variable whose lifetime will be clear to the programmer. */ | 4536 | variable whose lifetime will be clear to the programmer. */ |
| 4537 | #define STACK_CONS(a, b) \ | 4537 | #define STACK_CONS(a, b) \ |
| 4538 | make_lisp_ptr (&(union Aligned_Cons) { { a, { b } } }.s, Lisp_Cons) | 4538 | make_lisp_ptr (&((union Aligned_Cons) { { a, { b } } }).s, Lisp_Cons) |
| 4539 | #define AUTO_CONS_EXPR(a, b) \ | 4539 | #define AUTO_CONS_EXPR(a, b) \ |
| 4540 | (USE_STACK_CONS ? STACK_CONS (a, b) : Fcons (a, b)) | 4540 | (USE_STACK_CONS ? STACK_CONS (a, b) : Fcons (a, b)) |
| 4541 | 4541 | ||
| @@ -4581,8 +4581,7 @@ enum | |||
| 4581 | Lisp_Object name = \ | 4581 | Lisp_Object name = \ |
| 4582 | (USE_STACK_STRING \ | 4582 | (USE_STACK_STRING \ |
| 4583 | ? (make_lisp_ptr \ | 4583 | ? (make_lisp_ptr \ |
| 4584 | ((&(union Aligned_String) \ | 4584 | ((&((union Aligned_String) {{len, -1, 0, (unsigned char *) (str)}}).s), \ |
| 4585 | {{len, -1, 0, (unsigned char *) (str)}}.s), \ | ||
| 4586 | Lisp_String)) \ | 4585 | Lisp_String)) \ |
| 4587 | : make_unibyte_string (str, len)) | 4586 | : make_unibyte_string (str, len)) |
| 4588 | 4587 | ||