aboutsummaryrefslogtreecommitdiff
path: root/toplevel
diff options
context:
space:
mode:
authorxclerc2013-09-19 12:59:04 +0000
committerxclerc2013-09-19 12:59:04 +0000
commit826eb7c6d11007dfd747d49852e71a22e0a3850a (patch)
tree25dce16a7107de4e0d3903e2808fb8f083d1f9ea /toplevel
parent33eea163c72c70eaa3bf76506c1d07a8cde911fd (diff)
Get rid of the uses of deprecated OCaml elements (still remaining compatible with OCaml 3.12.1).
git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@16787 85f007b7-540e-0410-9357-904b9bb8a0f7
Diffstat (limited to 'toplevel')
-rw-r--r--toplevel/toplevel.ml4
-rw-r--r--toplevel/whelp.ml44
2 files changed, 4 insertions, 4 deletions
diff --git a/toplevel/toplevel.ml b/toplevel/toplevel.ml
index ee28156a37..0ca024ccb1 100644
--- a/toplevel/toplevel.ml
+++ b/toplevel/toplevel.ml
@@ -86,7 +86,7 @@ let reset_input_buffer ic ibuf =
let get_bols_of_loc ibuf (bp,ep) =
let add_line (b,e) lines =
- if b < 0 or e < b then anomaly (Pp.str "Bad location");
+ if b < 0 || e < b then anomaly (Pp.str "Bad location");
match lines with
| ([],None) -> ([], Some (b,e))
| (fl,oe) -> ((b,e)::fl, oe)
@@ -181,7 +181,7 @@ let print_location_in_file {outer=s;inner=fname} loc =
let valid_buffer_loc ib loc =
not (Loc.is_ghost loc) &&
- let (b,e) = Loc.unloc loc in b-ib.start >= 0 & e-ib.start < ib.len && b<=e
+ let (b,e) = Loc.unloc loc in b-ib.start >= 0 && e-ib.start < ib.len && b<=e
(*s The Coq prompt is the name of the focused proof, if any, and "Coq"
otherwise. We trap all exceptions to prevent the error message printing
diff --git a/toplevel/whelp.ml4 b/toplevel/whelp.ml4
index 7508ffaab2..8870254182 100644
--- a/toplevel/whelp.ml4
+++ b/toplevel/whelp.ml4
@@ -57,8 +57,8 @@ let make_whelp_request req c =
let b = Buffer.create 16
let url_char c =
- if 'A' <= c & c <= 'Z' or 'a' <= c & c <= 'z' or
- '0' <= c & c <= '9' or c ='.'
+ if 'A' <= c && c <= 'Z' || 'a' <= c && c <= 'z' ||
+ '0' <= c && c <= '9' || c ='.'
then Buffer.add_char b c
else Buffer.add_string b (Printf.sprintf "%%%2X" (Char.code c))