File 8911-Remove-and-or-in-parsetools.patch of Package erlang

From bf5c85559bbcca64106b88caee6bb464f183c39a Mon Sep 17 00:00:00 2001
From: Maria Scott <maria-12648430@hnc-agency.org>
Date: Tue, 17 Feb 2026 10:16:05 +0100
Subject: [PATCH] Remove and/or in parsetools

---
 lib/parsetools/src/leex.erl | 8 +++-----
 lib/parsetools/src/yecc.erl | 4 +---
 2 files changed, 4 insertions(+), 8 deletions(-)

diff --git a/lib/parsetools/src/leex.erl b/lib/parsetools/src/leex.erl
index dcf44e9d63..760632ecd0 100644
--- a/lib/parsetools/src/leex.erl
+++ b/lib/parsetools/src/leex.erl
@@ -1582,7 +1582,7 @@ prep_out_actions(As) ->
                       {TokenLen,"TokenLen"},
                       {TokenLine,"TokenLine"},
                       {TokenChars,"YYtcs"},
-                      {TokenLen or TokenChars,"TokenLen"}],
+                      {TokenLen orelse TokenChars,"TokenLen"}],
                 Vars = [if F -> S; true -> "_" end || {F,S} <- Vs],
                 Name = list_to_atom(lists:concat([yyaction_,A])),
                 [Chars,Len,Line,_,_] = Vars,
diff --git a/lib/parsetools/src/yecc.erl b/lib/parsetools/src/yecc.erl
index c9d2b681af..98c01229fa 100644
--- a/lib/parsetools/src/yecc.erl
+++ b/lib/parsetools/src/yecc.erl
@@ -1489,7 +1487,7 @@ check_expected(St0) ->
           end,
     NStates = NStates0 + 1,
     if
-        (not Done) or (ExpStates =:= []) or (NStates =:= ExpStates) ->
+        not Done; ExpStates =:= []; NStates =:= ExpStates ->
             St1;
         true ->
             add_warning(none, {n_states, ExpStates, NStates}, St1)
-- 
2.51.0

openSUSE Build Service is sponsored by