diff options
author | Damien Doligez <damien.doligez-inria.fr> | 2003-07-02 14:06:05 +0000 |
---|---|---|
committer | Damien Doligez <damien.doligez-inria.fr> | 2003-07-02 14:06:05 +0000 |
commit | 0a1f0f864b3b67fe9e3d6ff151de0f810328be5d (patch) | |
tree | e0a3ba34095812e29dadc76a5f42039fd577200e /stdlib | |
parent | 3e4bf9252b89c156d6d89cbd61e932bdc1a91781 (diff) |
desactivation du format %$
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@5644 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
Diffstat (limited to 'stdlib')
-rw-r--r-- | stdlib/printf.ml | 8 | ||||
-rw-r--r-- | stdlib/printf.mli | 7 |
2 files changed, 0 insertions, 15 deletions
diff --git a/stdlib/printf.ml b/stdlib/printf.ml index b57ed3652..62841fe12 100644 --- a/stdlib/printf.ml +++ b/stdlib/printf.ml @@ -113,11 +113,6 @@ let extract_format fmt start stop widths = Buffer.add_char b c; fill_format (succ i) w in fill_format start (List.rev widths) -let substitute_string f s = - let b = Buffer.create (2 * String.length s) in - Buffer.add_substitute b f s; - Buffer.contents b;; - let format_int_with_conv conv fmt i = match conv with | 'b' -> format_binary_int fmt i @@ -219,9 +214,6 @@ let scan_format fmt pos cont_s cont_a cont_t cont_f = end | '!' -> Obj.magic (cont_f (succ i)) - | '$' -> - Obj.magic (fun f s -> - cont_s (substitute_string f s) (succ i)) | _ -> bad_format fmt pos in scan_flags [] (pos + 1) diff --git a/stdlib/printf.mli b/stdlib/printf.mli index e64a684ce..697fd0e66 100644 --- a/stdlib/printf.mli +++ b/stdlib/printf.mli @@ -64,13 +64,6 @@ val fprintf : out_channel -> ('a, out_channel, unit, unit) format -> 'a in the output of [fprintf] at the current point. - [t]: same as [%a], but takes only one argument (with type [out_channel -> unit]) and apply it to [outchan]. - - [$]: variable substitution in strings. Takes two arguments: a - function mapping from variable names to string values and a - string pattern where any identifier following a dollar sign is - considered a variable name. Each variable name is replaced by its - value as specified by the mapping, and the resulting string - pattern is inserted in the output. See {!Buffer.add_substitute} for - details on variable syntax. - [!]: take no argument and flush the output. - [%]: take no argument and output one [%] character. |