caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* printf & scanf oddity
@ 2006-01-27 14:26 Basile STARYNKEVITCH
  2006-01-27 14:57 ` [Caml-list] " Jean-Christophe Filliatre
  2006-01-27 15:03 ` Virgile Prevosto
  0 siblings, 2 replies; 4+ messages in thread
From: Basile STARYNKEVITCH @ 2006-01-27 14:26 UTC (permalink / raw)
  To: caml-list

Dear All

I find the following quite strange:

% ocaml
        Objective Caml version 3.09.1

# Printf.sprintf "_a%d_f%d" 1 2;;
- : string = "_a1_f2"
# Scanf.sscanf "_a1_f2" "_a%d_f%d" (fun x y -> x,y);;
Exception:
Scanf.Scan_failure
 "scanf: bad input at char number 5: looking for '_', found 'f'".


Is it a bug, or did I misunderstood something?

Regards.
-- 
Basile STARYNKEVITCH         http://starynkevitch.net/Basile/ 
email: basile<at>starynkevitch<dot>net 
aliases: basile<at>tunes<dot>org = bstarynk<at>nerim<dot>net
8, rue de la Faïencerie, 92340 Bourg La Reine, France


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2006-01-27 15:47 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-01-27 14:26 printf & scanf oddity Basile STARYNKEVITCH
2006-01-27 14:57 ` [Caml-list] " Jean-Christophe Filliatre
2006-01-27 15:48   ` William D. Neumann
2006-01-27 15:03 ` Virgile Prevosto

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).