summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-11-02 23:08:26 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-11-02 23:08:26 +0000
commitb907c6e925d82ad2903acd77edcf97635a7c6515 ()
tree91ab17c496a1c303478997817bb01521e9acf922
parentb147b5a3b8f6c5cac5444f6b75152ec8b69af4fb (diff)
keywords: make name singed
* defs/keywords (kwtable::name): turn into singed int, as gperf fills invalid slots with -1. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52429 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--Makefile.in2
-rw-r--r--defs/keywords2
-rw-r--r--defs/lex.c.src2
-rw-r--r--lex.c.blt2
4 files changed, 4 insertions, 4 deletions
@@ -328,7 +328,7 @@ lex.c: defs/keywords
else \
[ $(Q) ] && echo generating $@ || set -x; \
gperf -C -P -p -j1 -i 1 -g -o -t -N rb_reserved_word -k1,3,$$ $? \
- | sed 's/(int)(long)&((\(struct stringpool_t\) *\*)0)->\(stringpool_[a-z0-9]*\)/offsetof(\1, \2)/g' \
$(MV) [email protected] $@ && \
$(CP) $? $(srcdir)/defs/lex.c.src && \
@@ -1,5 +1,5 @@
%{
-struct kwtable {unsigned int name, id[2], state;};
const struct kwtable *rb_reserved_word(const char *, unsigned int);
#ifndef RIPPER
static const struct kwtable *reserved_word(const char *, unsigned int);
@@ -1,5 +1,5 @@
%{
-struct kwtable {unsigned int name, id[2], state;};
const struct kwtable *rb_reserved_word(const char *, unsigned int);
#ifndef RIPPER
static const struct kwtable *reserved_word(const char *, unsigned int);
@@ -30,7 +30,7 @@ error "gperf generated tables don't work with this execution character set. Plea
#line 1 "defs/keywords"
-struct kwtable {unsigned int name, id[2], state;};
const struct kwtable *rb_reserved_word(const char *, unsigned int);
#ifndef RIPPER
static const struct kwtable *reserved_word(const char *, unsigned int);