1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

This commit was generated by cvs2svn to compensate for changes in r6227,

which included commits to RCS files with non-trunk default branches.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@6228 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
ksaito 2004-04-27 16:04:30 +00:00
parent 653fbad628
commit aa1fe3248f
3 changed files with 25 additions and 44 deletions

View file

@ -3950,17 +3950,22 @@ optimize_node_left(Node* node, NodeOptInfo* opt, OptEnv* env)
}
}
if (! ONIGENC_IS_SINGLEBYTE(env->enc)) {
if (! IS_NULL(cc->mbuf) ||
(cc->not != 0 && found != 0)) {
for (i = 0; i < SINGLE_BYTE_SIZE; i++) {
z = ONIGENC_IS_MBC_HEAD(env->enc, i);
if (z) {
mb_found = 1;
add_char_opt_map_info(&opt->map, i);
}
}
}
if (IS_NULL(cc->mbuf)) {
if (cc->not) {
for (i = 0; i < SINGLE_BYTE_SIZE; i++) {
add_char_opt_map_info(&opt->map, i);
}
mb_found = 1;
}
}
else {
for (i = 0; i < SINGLE_BYTE_SIZE; i++) {
z = ONIGENC_IS_MBC_HEAD(env->enc, i);
if (z) {
mb_found = 1;
add_char_opt_map_info(&opt->map, i);
}
}
}
if (mb_found) {