diff options
author | Arnold D. Robbins <arnold@skeeve.com> | 2010-07-16 12:57:07 +0300 |
---|---|---|
committer | Arnold D. Robbins <arnold@skeeve.com> | 2010-07-16 12:57:07 +0300 |
commit | 3ca7f0b16d0a5c105380b284a81c6a1b2c210908 (patch) | |
tree | c2153d226b9cba3ebca0c3556b19bf3e52cd20dd /node.c | |
parent | f20ab7c3039a4023f41372bfe4bde3b16d481df7 (diff) | |
download | egawk-3ca7f0b16d0a5c105380b284a81c6a1b2c210908.tar.gz egawk-3ca7f0b16d0a5c105380b284a81c6a1b2c210908.tar.bz2 egawk-3ca7f0b16d0a5c105380b284a81c6a1b2c210908.zip |
Move to gawk-3.0.5.
Diffstat (limited to 'node.c')
-rw-r--r-- | node.c | 18 |
1 files changed, 16 insertions, 2 deletions
@@ -3,7 +3,7 @@ */ /* - * Copyright (C) 1986, 1988, 1989, 1991-1999 the Free Software Foundation, Inc. + * Copyright (C) 1986, 1988, 1989, 1991-2000 the Free Software Foundation, Inc. * * This file is part of GAWK, the GNU implementation of the * AWK Programming Language. @@ -203,8 +203,10 @@ register NODE *s; cant_happen(); if (s->type != Node_val) cant_happen(); +/* if ((s->flags & NUM) == 0) cant_happen(); +*/ if (s->stref <= 0) cant_happen(); if ((s->flags & STR) != 0 @@ -239,7 +241,7 @@ NODE *n; } getnode(r); *r = *n; - r->flags &= ~(PERM|TEMP); + r->flags &= ~(PERM|TEMP|FIELD); r->flags |= MALLOC; if (n->type == Node_val && (n->flags & STR) != 0) { r->stref = 1; @@ -511,6 +513,18 @@ char **string_ptr; } return i; default: + if (do_lint) { + static short warned[256]; + unsigned char uc = (unsigned char) c; + + /* N.B.: use unsigned char here to avoid Latin-1 problems */ + + if (! warned[uc]) { + warned[uc] = TRUE; + + warning("escape sequence `\\%c' treated as plain `%c'", uc, uc); + } + } return c; } } |