diff options
Diffstat (limited to 'regen/regcharclass.pl')
-rwxr-xr-x | regen/regcharclass.pl | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/regen/regcharclass.pl b/regen/regcharclass.pl index b7dddd2efc..944f61b976 100755 --- a/regen/regcharclass.pl +++ b/regen/regcharclass.pl @@ -1076,8 +1076,13 @@ sub _combine { $gtv= sprintf "$self->{val_fmt}", $item; } if ( @cond ) { - return "( $cstr || ( $gtv < $test &&\n" - . $self->_combine( $test, @cond ) . " ) )"; + my $combine= $self->_combine( $test, @cond ); + if (@cond >1) { + return "( $cstr || ( $gtv < $test &&\n" + . $combine . " ) )"; + } else { + return "( $cstr || $combine )"; + } } else { return $cstr; } |