diff options
author | Arnold D. Robbins <arnold@skeeve.com> | 2021-01-08 11:05:32 +0200 |
---|---|---|
committer | Arnold D. Robbins <arnold@skeeve.com> | 2021-01-08 11:05:32 +0200 |
commit | d562eb482f3180dcd59a332edc91027ea3844d90 (patch) | |
tree | d90bb37b1c75a6429d961031b6a3ae08559408c0 /builtin.c | |
parent | b4dc5fb3dc57f7fc7eaba39c5814b8bae9403b77 (diff) | |
download | egawk-d562eb482f3180dcd59a332edc91027ea3844d90.tar.gz egawk-d562eb482f3180dcd59a332edc91027ea3844d90.tar.bz2 egawk-d562eb482f3180dcd59a332edc91027ea3844d90.zip |
Improve use of types throughout.
Diffstat (limited to 'builtin.c')
-rw-r--r-- | builtin.c | 5 |
1 files changed, 2 insertions, 3 deletions
@@ -29,7 +29,6 @@ #if defined(HAVE_FCNTL_H) #include <fcntl.h> #endif -#include <math.h> #include "random.h" #include "floatmagic.h" @@ -4053,7 +4052,7 @@ NODE * do_typeof(int nargs) { NODE *arg; - char *res = NULL; + const char *res = NULL; bool deref = true; NODE *dbg; @@ -4265,6 +4264,7 @@ char * format_nan_inf(NODE *n, char format) { static char buf[100]; + double val = n->numbr; #ifdef HAVE_MPFR if (is_mpg_integer(n)) @@ -4284,7 +4284,6 @@ format_nan_inf(NODE *n, char format) /* else fallthrough */ #endif - double val = n->numbr; if (isnan(val)) { strcpy(buf, signbit(val) != 0 ? "-nan" : "+nan"); |