summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDamien Doligez <damien.doligez-inria.fr>2010-01-29 15:02:52 +0000
committerDamien Doligez <damien.doligez-inria.fr>2010-01-29 15:02:52 +0000
commit4065bfe6e105f0e1344f6322bed067e6c33febe9 (patch)
tree9cf9ef48f66bf4633ae7c2d4949d018ba0ebc882
parentfbd12a6f6878a5f3d8150fede1a9ead6bf44c209 (diff)
downloadocaml-4065bfe6e105f0e1344f6322bed067e6c33febe9.tar.gz
updated warnings
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@9607 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
-rw-r--r--man/ocamlc.m15
-rw-r--r--man/ocamlopt.m208
2 files changed, 15 insertions, 208 deletions
diff --git a/man/ocamlc.m b/man/ocamlc.m
index 545794a933..8ef3ddfc96 100644
--- a/man/ocamlc.m
+++ b/man/ocamlc.m
@@ -499,7 +499,7 @@ If a warning is disabled, it isn't displayed and doesn't affect
compilation in any way (even if it is marked). If a warning is enabled,
it is displayed normally by the compiler whenever the source code
triggers it. If it is enabled and marked, the compiler will stop with
-an error after displaying that warning if the source code triggers it.
+an error after displaying the warnings if the source code triggers it.
The
.I warning\-list
@@ -636,6 +636,15 @@ and doesn't start with an underscore (_) character.
.BR let \ nor \ as ,
and doesn't start with an underscore (_) character.
+28
+\ \ A pattern contains a constant constructor applied to the underscore (_)
+pattern.
+
+29
+\ \ A non-escaped end-of-line was found in a string constant. This may
+
+cause portability problems between Unix and Windows.
+
The letters stand for the following sets of warnings. Any letter not
mentioned here corresponds to the empty set.
@@ -686,9 +695,7 @@ mentioned here corresponds to the empty set.
.IP
The default setting is
-.BR \-w\ +a\-4\-6\-9\-27 ,
-enabling all warnings except fragile pattern matchings, omitted labels,
-missing fields in record patterns, and innocuous unused variables.
+.BR \-w\ +a\-4\-6\-9\-27\-28\-29 .
Note that warnings
.BR 5 \ and \ 10
are not always triggered, depending on the internals of the type checker.
diff --git a/man/ocamlopt.m b/man/ocamlopt.m
index 5807943e19..831f30d0d4 100644
--- a/man/ocamlopt.m
+++ b/man/ocamlopt.m
@@ -464,210 +464,10 @@ then exit.
.BI \-w \ warning\-list
Enable, disable, or mark as errors the warnings specified by the argument
.IR warning\-list .
-
-Each warning can be
-.IR enabled \ or\ disabled ,
-and each warning can be
-.I marked
-(as error) or
-.IR unmarked .
-If a warning is disabled, it isn't displayed and doesn't affect
-compilation in any way (even if it is marked). If a warning is enabled,
-it is displayed normally by the compiler whenever the source code
-triggers it. If it is enabled and marked, the compiler will stop with
-an error after displaying that warning.
-
-The
-.I warning\-list
-argument is a sequence of warning specifiers, with no separators
-between them. A warning specifier is one of the following:
-
-.BI + num
-\ \ Enable warning number
-.IR num .
-
-.BI \- num
-\ \ Disable warning number
-.IR num .
-
-.BI @ num
-\ \ Enable and mark warning number
-.IR num .
-
-.BI + letter
-\ \ Enable the set of warnings corresponding to
-.IR letter .
-The letter may be uppercase or lowercase.
-
-.BI \- letter
-\ \ Disable the set of warnings corresponding to
-.IR letter .
-The letter may be uppercase or lowercase.
-
-.BI @ letter
-\ \ Enable and mark the set of warnings corresponding to
-.IR letter .
-The letter may be uppercase or lowercase.
-
-.I uppercase\-letter
-\ \ Enable the set of warnings corresponding to
-.IR uppercase\-letter .
-
-.I lowercase\-letter
-\ \ Disable the set of warnings corresponding to
-.IR lowercase\-letter .
-
-The warning numbers are as follows.
-
-1
-\ \ \ Suspicious-looking start-of-comment mark.
-
-2
-\ \ \ Suspicious-looking end-of-comment mark.
-
-3
-\ \ \ Deprecated syntax.
-
-4
-\ \ \ Fragile pattern matching: matching that will remain
-complete even if additional constructors are added to one of the
-variant types matched.
-
-5
-\ \ \ Partially applied function: expression whose result has
-function type and is ignored.
-
-6
-\ \ \ Label omitted in function application.
-
-7
-\ \ \ Some methods are overriden in the class where they are defined.
-
-8
-\ \ \ Partial match: missing cases in pattern-matching.
-
-9
-\ \ \ Missing fields in a record pattern.
-
-10
-\ \ Expression on the left-hand side of a sequence that doesn't
-have type
-.B unit
-(and that is not a function, see warning number 5).
-
-11
-\ \ Redundant case in a pattern matching (unused match case).
-
-12
-\ \ Redundant sub-pattern in a pattern-matching.
-
-13
-\ \ Override of an instance variable.
-
-14
-\ \ Illegal backslash escape in a string constant.
-
-15
-\ \ Private method made public implicitly.
-
-16
-\ \ Unerasable optional argument.
-
-17
-\ \ Undeclared virtual method.
-
-18
-\ \ Non-principal type.
-
-19
-\ \ Type without principality.
-
-20
-\ \ Unused function argument.
-
-21
-\ \ Non-returning statement.
-
-22
-\ \ Camlp4 warning.
-
-23
-\ \ Useless record
-.B with
-clause.
-
-24
-\ \ Bad module name: the source file name is not a valid OCaml module name.
-
-25
-\ \ Pattern-matching with all clauses guarded.
-
-26
-\ \ Suspicious unused variable: unused variable that is bound with
-.BR let \ or \ as ,
-and doesn't start with an underscore (_) character.
-
-27
-\ \ Innocuous unused variable: unused variable that is not bound with
-.BR let \ nor \ as ,
-and doesn't start with an underscore (_) character.
-
-The letters stand for the following sets of warnings. Any letter not
-mentioned here corresponds to the empty set.
-
-.B A
-\ all warnings
-
-.B C
-\ 1, 2
-
-.B D
-\ 3
-
-.B E
-\ 4
-
-.B F
-\ 5
-
-.B L
-\ 6
-
-.B M
-\ 7
-
-.B P
-\ 8
-
-.B R
-\ 9
-
-.B S
-\ 10
-
-.B U
-\ 11, 12
-
-.B V
-\ 13
-
-.B X
-\ 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25
-
-.B Y
-\ 26
-
-.B Z
-\ 27
-
-.IP
-The default setting is
-.BR \-w\ +a\-4\-6\-9\-27 ,
-enabling all warnings except fragile pattern matchings, omitted labels,
-missing fields in record patterns, and innocuous unused variables.
-Note that warnings
-.BR 5 \ and \ 10
-are not always triggered, depending on the internals of the type checker.
+See
+.BR ocamlc (1)
+for the syntax of
+.IR warning-list .
.TP
.BI \-warn\-error \ warning\-list
Mark as errors the warnings specified in the argument