From d4c8198d236035324c6ebf07deb79e73bb062af9 Mon Sep 17 00:00:00 2001 From: DeaDDooMER Date: Sun, 13 Aug 2017 16:25:44 +0300 Subject: [PATCH] =?utf8?q?=D0=A3=D0=BD=D0=B0=D1=80=D0=BD=D1=8B=D0=B9=20?= =?utf8?q?=D0=BC=D0=B8=D0=BD=D1=83=D1=81=20=D1=80=D0=B0=D0=B1=D0=BE=D1=82?= =?utf8?q?=D0=B0=D0=B5=D1=82=20=D0=BA=D0=B0=D0=BA=20=D0=BE=D0=BF=D0=B8?= =?utf8?q?=D1=81=D0=B0=D0=BD=D0=BE=D0=B2=20=D0=B2=20=D0=94=D1=83=D0=B1?= =?utf8?q?=D0=BE=D0=B2=D1=8B=D1=85=20=D1=82=D1=80=D0=B5=D0=B1=D0=BE=D0=B2?= =?utf8?q?=D0=B0=D0=BD=D0=B8=D1=8F=D1=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- notes | 1 - src/oberon.c | 10 +++++----- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/notes b/notes index 03a10c9..b09a685 100644 --- a/notes +++ b/notes @@ -17,7 +17,6 @@ 3.5 Interfacing to External Libraries 3.6 Underscores in Identifiers 3.7 In-line Exponentiation - 5.10 Monadic ‘-’: -5 MOD 3 is equivalent to -(5 MOD 3) 5.13 Read only VAR Parameters 1.2.5 Module Files 1.2.6 Module Strings diff --git a/src/oberon.c b/src/oberon.c index 8b94271..830844a 100644 --- a/src/oberon.c +++ b/src/oberon.c @@ -1958,11 +1958,6 @@ oberon_simple_expr(oberon_context_t * ctx) expr = oberon_term_expr(ctx); - if(minus) - { - expr = oberon_make_unary_op(ctx, MINUS, expr); - } - while(ISADDOP(ctx -> token)) { int token = ctx -> token; @@ -1972,6 +1967,11 @@ oberon_simple_expr(oberon_context_t * ctx) expr = oberon_make_bin_op(ctx, token, expr, inter); } + if(minus) + { + expr = oberon_make_unary_op(ctx, MINUS, expr); + } + return expr; } -- 2.29.2