From 5a5ba645039fcc9573e62f4c59d47be50dd3e366 Mon Sep 17 00:00:00 2001 From: Rudi Grinberg Date: Sat, 17 Mar 2018 11:32:23 +0800 Subject: [PATCH] Fix 4.02.3 compat in usexp Do not use Char.equal --- src/usexp/usexp.ml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/usexp/usexp.ml b/src/usexp/usexp.ml index 5fd0880e..b6b07c91 100644 --- a/src/usexp/usexp.ml +++ b/src/usexp/usexp.ml @@ -21,8 +21,8 @@ module Atom = struct let rec loop ix = match str.[ix] with | '"' | '(' | ')' | ';' | '\\' -> true - | '|' -> ix > 0 && let next = ix - 1 in Char.equal str.[next] '#' || loop next - | '#' -> ix > 0 && let next = ix - 1 in Char.equal str.[next] '|' || loop next + | '|' -> ix > 0 && let next = ix - 1 in str.[next] = '#' || loop next + | '#' -> ix > 0 && let next = ix - 1 in str.[next] = '|' || loop next | '\000' .. '\032' | '\127' .. '\255' -> true | _ -> ix > 0 && loop (ix - 1) in