From: Basile STARYNKEVITCH <basile@starynkevitch.net>
To: caml-list@yquem.inria.fr
Subject: printf & scanf oddity
Date: Fri, 27 Jan 2006 15:26:22 +0100 [thread overview]
Message-ID: <20060127142622.GA8216@ours.starynkevitch.net> (raw)
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
next reply other threads:[~2006-01-27 14:26 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-01-27 14:26 Basile STARYNKEVITCH [this message]
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
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20060127142622.GA8216@ours.starynkevitch.net \
--to=basile@starynkevitch.net \
--cc=caml-list@yquem.inria.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox