aboutsummaryrefslogtreecommitdiff
path: root/plugins/extraction/common.ml
diff options
context:
space:
mode:
authorMaxime Dénès2017-03-21 15:26:17 +0100
committerMaxime Dénès2017-03-21 15:33:20 +0100
commit28d3bb3c8bddc63d038d8d55a34c928675fa9f7b (patch)
tree1eb3fd20c42622c9a1ca7f9349068f7301274038 /plugins/extraction/common.ml
parentbecc6ef43a0f838d1f6388e8c7373c13f26082bc (diff)
parentd25b1431eb73a04bdfc0f1ad2922819b69bba93a (diff)
Merge PR#134: Enable `-safe-string`
Diffstat (limited to 'plugins/extraction/common.ml')
-rw-r--r--plugins/extraction/common.ml5
1 files changed, 1 insertions, 4 deletions
diff --git a/plugins/extraction/common.ml b/plugins/extraction/common.ml
index de97ba97c3..0a591e786f 100644
--- a/plugins/extraction/common.ml
+++ b/plugins/extraction/common.ml
@@ -91,10 +91,7 @@ let begins_with_CoqXX s =
let unquote s =
if lang () != Scheme then s
- else
- let s = String.copy s in
- for i=0 to String.length s - 1 do if s.[i] == '\'' then s.[i] <- '~' done;
- s
+ else String.map (fun c -> if c == '\'' then '~' else c) s
let rec qualify delim = function
| [] -> assert false