diff options
author | Arnold D. Robbins <arnold@skeeve.com> | 2014-09-27 22:33:01 +0300 |
---|---|---|
committer | Arnold D. Robbins <arnold@skeeve.com> | 2014-09-27 22:33:01 +0300 |
commit | 9701514d4ad1152da564ebf6690c514becd4339a (patch) | |
tree | 69cf8c9a9991cb4f9fed6fbc2415f0605c52578e /awkgram.c | |
parent | 6b1b9c16a1b55804df36457de0650414ab3f017d (diff) | |
parent | e71e74ac9af232d58e6c672e37ddf7e8737d68b1 (diff) | |
download | egawk-9701514d4ad1152da564ebf6690c514becd4339a.tar.gz egawk-9701514d4ad1152da564ebf6690c514becd4339a.tar.bz2 egawk-9701514d4ad1152da564ebf6690c514becd4339a.zip |
Merge branch 'master' into comment
Diffstat (limited to 'awkgram.c')
-rw-r--r-- | awkgram.c | 18 |
1 files changed, 16 insertions, 2 deletions
@@ -5225,7 +5225,7 @@ check_bad_char(int c) } if (iscntrl(c) && ! isspace(c)) - fatal(_("PEBKAC error: invalid character '\\%03o' in source code"), c); + fatal(_("PEBKAC error: invalid character '\\%03o' in source code"), c & 0xFF); } /* nextc --- get the next input character */ @@ -5895,7 +5895,11 @@ retry: case '"': string: esc_seen = false; - while ((c = nextc(true)) != '"') { + /* + * Allow any kind of junk in quoted string, + * so pass false to nextc(). + */ + while ((c = nextc(false)) != '"') { if (c == '\n') { pushback(); yyerror(_("unterminated string")); @@ -8261,6 +8265,16 @@ install_builtins(void) /* is_alpha --- return true if c is an English letter */ +/* + * The scene of the murder was grisly to look upon. When the inspector + * arrived, the sergeant turned to him and said, "Another programmer stabbed + * in the back. He never knew what happened." + * + * The inspector replied, "Looks like the MO of isalpha, and his even meaner + * big brother, isalnum. The Locale brothers." The sergeant merely + * shuddered in horror. + */ + bool is_alpha(int c) { |