testsuite for %_[nNlL]

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14824 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
introduce type aliases for simple padding and precision types

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14825 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
typecore.ml: fix format's expected-type mistake

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14826 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
parse the ignore flag before all others

The legacy implementation doesn't support "%+_", "%-_" etc. which were
accepted by Benoît's patches. This creates a discrepancy (though not
a regression) that is not necessarily desirable (and in any case makes
fuzz-testing for difference return non-bugs). Long-term, I think that
we're good with the previous, simpler structure where "_" must always
be the first flag.

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14827 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
fix printing bug: (Printf.printf "% 04d" 3) => "00 3"

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14828 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
allow incompatible or unsupported numeric formatting flags

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14829 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
accept and ignore '+' and '-' before precision integers

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14830 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
some characters were not allowed in charsets

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14831 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
minor strengthening of the typing of %{...%} formats

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14832 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
printf behavior of %{..%}

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14833 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
implement (^^) correctly wrt. string_of_format (Thanks to Pierre Weis)

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14834 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
charset-parsing: require that '%' be written '%%' in charsets, as per the documentation

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14835 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
simplification in bprint_char_set

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14836 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
move code from pervasives.ml to camlinternalFormat.ml

This simplifies the charset-handling code, as camlinternalFormat is
allowed to depend on Bytes and String instead of re-importing the
needed primitives.

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14837 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
boostrap (same steps as the last one)

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14838 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
testsuite Makefile fix

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14839 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
For %{..%}, restore Pierre's semantics

(printf {%foo%} bar) will print the string representation of the
format type of both `foo` and `bar`, instead of printing `bar`
(for this purpose one can just use %s). `bar` content is ignored, but
the typer should check that its type is compatible with the one of
`foo`.

This semantics allows to use (printf %{..%}) for testing/debugging the
use of %(...%): put in the brackets what you believe to be the format
type you want to use, and as argument the format you wish to pass, and
you'll get type-checking confidence and the "canonical" representation
of the format string which you can use in the %(...%) -- note that
using the canonical format type is not mandatory.

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14840 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
formats: enable the legacy mode by default

Given that there still remains a small incompatibility (typing of
%(..%)), I decided to keep the legacy mode enabled for now. This means
that any failure related to format can be traced to this
incompatiblity (or unknown regressions), which will simplify the
monitoring and handling of changes considerably. As soon as the %(..%)
typing is generalized, we can turn the legacy mode off (or maybe
simply add warnings for ignored formats).

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14841 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
fix a regression in Format formatting printing routines

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14842 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
final bootstrap (make partialclean core coreboot)

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14843 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02