mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* regex.c (mbc_startpos_func): shoud be static.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2265 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
6d182fc8bf
commit
76cdd41111
2 changed files with 6 additions and 2 deletions
|
@ -1,3 +1,7 @@
|
||||||
|
Mon Mar 25 10:04:59 2002 Nobuyoshi Nakada <nobu.nakada@nifty.ne.jp>
|
||||||
|
|
||||||
|
* regex.c (mbc_startpos_func): shoud be static.
|
||||||
|
|
||||||
Sun Mar 24 00:46:05 2002 WATANABE Hirofumi <eban@ruby-lang.org>
|
Sun Mar 24 00:46:05 2002 WATANABE Hirofumi <eban@ruby-lang.org>
|
||||||
|
|
||||||
* util.c (push_element): avoid warning for djgpp.
|
* util.c (push_element): avoid warning for djgpp.
|
||||||
|
|
4
regex.c
4
regex.c
|
@ -469,7 +469,7 @@ re_set_syntax(syntax)
|
||||||
((current_mbctype != MBCTYPE_UTF8) ? ((c<0x100) ? (c) : (((c)>>8)&0xff)) : utf8_firstbyte(c))
|
((current_mbctype != MBCTYPE_UTF8) ? ((c<0x100) ? (c) : (((c)>>8)&0xff)) : utf8_firstbyte(c))
|
||||||
|
|
||||||
typedef unsigned int (*mbc_startpos_func_t) _((const char *string, unsigned int pos));
|
typedef unsigned int (*mbc_startpos_func_t) _((const char *string, unsigned int pos));
|
||||||
const mbc_startpos_func_t mbc_startpos_func[];
|
static const mbc_startpos_func_t mbc_startpos_func[];
|
||||||
#define mbc_startpos(start, pos) (*mbc_startpos_func[current_mbctype])((start), (pos))
|
#define mbc_startpos(start, pos) (*mbc_startpos_func[current_mbctype])((start), (pos))
|
||||||
|
|
||||||
static unsigned int
|
static unsigned int
|
||||||
|
@ -4573,7 +4573,7 @@ utf8_startpos(string, pos)
|
||||||
return i + w;
|
return i + w;
|
||||||
}
|
}
|
||||||
|
|
||||||
const mbc_startpos_func_t mbc_startpos_func[4] = {
|
static const mbc_startpos_func_t mbc_startpos_func[4] = {
|
||||||
asc_startpos, euc_startpos, sjis_startpos, utf8_startpos
|
asc_startpos, euc_startpos, sjis_startpos, utf8_startpos
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue