aboutsummaryrefslogtreecommitdiff
path: root/parsing
diff options
context:
space:
mode:
authorGuillaume Melquiond2015-04-23 14:55:11 +0200
committerGuillaume Melquiond2015-04-23 16:02:45 +0200
commit16d301bab5b7dec53be4786b3b6815bca54ae539 (patch)
treec595fc1fafd00a08cb91e53002610df867cf5eed /parsing
parent915c8f15965fe8e7ee9d02a663fd890ef80539ad (diff)
Remove almost all the uses of string concatenation when building error messages.
Since error messages are ultimately passed to Format, which has its own buffers for concatenating strings, using concatenation for preparing error messages just doubles the workload and increases memory pressure.
Diffstat (limited to 'parsing')
-rw-r--r--parsing/g_xml.ml42
1 files changed, 1 insertions, 1 deletions
diff --git a/parsing/g_xml.ml4 b/parsing/g_xml.ml4
index 84e4a5732e..992f9c59af 100644
--- a/parsing/g_xml.ml4
+++ b/parsing/g_xml.ml4
@@ -58,7 +58,7 @@ END
let error_bad_arity loc n =
let s = match n with 0 -> "none" | 1 -> "one" | 2 -> "two" | _ -> "many" in
- user_err_loc (loc,"",str ("wrong number of arguments (expect "^s^")."))
+ user_err_loc (loc,"",str "wrong number of arguments (expect " ++ str s ++ str ").")
(* Interpreting attributes *)