3
0
mirror of https://github.com/pragma-/pbot.git synced 2024-10-03 01:48:38 +02:00

CGrammar: Do not use "result of the expression" for single terms

This commit is contained in:
Pragmatic Software 2014-07-10 01:23:19 +00:00
parent 4520be1a2c
commit fab1986a3e
2 changed files with 4 additions and 3 deletions

View File

@ -13,7 +13,7 @@ use warnings;
# These are set automatically by the build/commit script # These are set automatically by the build/commit script
use constant { use constant {
BUILD_NAME => "PBot", BUILD_NAME => "PBot",
BUILD_REVISION => 722, BUILD_REVISION => 723,
BUILD_DATE => "2014-07-09", BUILD_DATE => "2014-07-09",
}; };

View File

@ -623,10 +623,11 @@ rel_add_mul_shift_expression:
{ $return = $item{cast_expression}; } { $return = $item{cast_expression}; }
| <leftop: cast_expression rel_mul_add_ex_op cast_expression> | <leftop: cast_expression rel_mul_add_ex_op cast_expression>
{ {
if($arg{context} =~ /expression/) { my $expression = join('', @{$item[1]});
if($arg{context} =~ /expression/ and $expression =~ / /) {
$return = 'the result of the expression '; $return = 'the result of the expression ';
} }
$return .= join('' , @{$item[1]}); $return .= $expression;
} }
closure: closure: