summaryrefslogtreecommitdiff
path: root/stdlib/arg.ml
diff options
context:
space:
mode:
authorXavier Leroy <xavier.leroy@inria.fr>2004-07-13 12:25:21 +0000
committerXavier Leroy <xavier.leroy@inria.fr>2004-07-13 12:25:21 +0000
commit63c1789b5edb177db6f5c0ae351815c584562cab (patch)
tree7fede3c61f74a6a228cffb11499ae6b222b0b67d /stdlib/arg.ml
parent237006931a8e0e1aa292b93c14a1ab60d4138d53 (diff)
downloadocaml-63c1789b5edb177db6f5c0ae351815c584562cab.tar.gz
Fusion des modifs faites sur la branche release jusqu'a la release 3.08.0
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@6553 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
Diffstat (limited to 'stdlib/arg.ml')
-rw-r--r--stdlib/arg.ml2
1 files changed, 1 insertions, 1 deletions
diff --git a/stdlib/arg.ml b/stdlib/arg.ml
index 9514b95576..dd6c517532 100644
--- a/stdlib/arg.ml
+++ b/stdlib/arg.ml
@@ -133,7 +133,7 @@ let parse_argv ?(current=current) argv speclist anonfun errmsg =
begin try
let rec treat_action = function
| Unit f -> f ();
- | Bool f ->
+ | Bool f when !current + 1 < l ->
let arg = argv.(!current + 1) in
begin try f (bool_of_string arg)
with Invalid_argument "bool_of_string" ->