diff options
| author | Philipp Stephani | 2019-04-23 16:48:49 +0200 |
|---|---|---|
| committer | Philipp Stephani | 2019-04-23 16:51:10 +0200 |
| commit | eaea40b33721513d4c0228af92d5c32400fda0e7 (patch) | |
| tree | 5ec47decb427c43ce0f3a29674bb149336b648f8 /src | |
| parent | ecab8835a03fdeeea755fa222a326f1ea376ccc4 (diff) | |
| download | emacs-eaea40b33721513d4c0228af92d5c32400fda0e7.tar.gz emacs-eaea40b33721513d4c0228af92d5c32400fda0e7.zip | |
Use high-level integer conversion macro in a few cases.
INT_TO_INTEGER is more obviously correct and means we don’t have to
worry about data type sizes and signedness.
* src/json.c (json_parse_error): Use INT_TO_INTEGER. The tiny
performance gain of make_fixed_natnum isn’t worth the trouble then
signaling an error.
Diffstat (limited to 'src')
| -rw-r--r-- | src/json.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/json.c b/src/json.c index 7d6d5314270..03468e9f338 100644 --- a/src/json.c +++ b/src/json.c | |||
| @@ -304,8 +304,8 @@ json_parse_error (const json_error_t *error) | |||
| 304 | #endif | 304 | #endif |
| 305 | xsignal (symbol, | 305 | xsignal (symbol, |
| 306 | list5 (json_build_string (error->text), | 306 | list5 (json_build_string (error->text), |
| 307 | json_build_string (error->source), make_fixed_natnum (error->line), | 307 | json_build_string (error->source), INT_TO_INTEGER (error->line), |
| 308 | make_fixed_natnum (error->column), make_fixed_natnum (error->position))); | 308 | INT_TO_INTEGER (error->column), INT_TO_INTEGER (error->position))); |
| 309 | } | 309 | } |
| 310 | 310 | ||
| 311 | static void | 311 | static void |