X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=docs%2Fusers_guide%2Fusing.xml;h=a4c673cbe4965318e450b9ce4a5f82ba581312c5;hb=56aaa78a63ab27c40a6834ed28ff3f32d1ede214;hp=7e9b3a4a14d1ec758c912e1e7fc1cd9428d28a16;hpb=ceb5840878cd876f8425293fa3c8d56e9cbf3a2e;p=ghc-hetmet.git diff --git a/docs/users_guide/using.xml b/docs/users_guide/using.xml index 7e9b3a4..a4c673c 100644 --- a/docs/users_guide/using.xml +++ b/docs/users_guide/using.xml @@ -268,6 +268,22 @@ module X where + .ll + + An llvm-intermediate-language source file, usually + produced by the compiler. + + + + + .bc + + An llvm-intermediate-language bitcode file, usually + produced by the compiler. + + + + .s An assembly-language source file, usually produced by @@ -973,7 +989,6 @@ ghc -c Foo.hs suspicious code. The warnings that are not enabled by are - , , , , @@ -1123,7 +1138,7 @@ foreign import "&f" f :: FunPtr t is bound in a way that looks lazy, e.g. where (I# x) = .... Use where !(I# x) = ... instead. This will be an - error, rather than a warning, in GHC 6.14. + error, rather than a warning, in GHC 7.2. @@ -1160,6 +1175,21 @@ foreign import "&f" f :: FunPtr t + : + + + Causes the compiler to emit a warning when a Prelude numeric + conversion converts a type T to the same type T; such calls + are probably no-ops and can be omitted. The functions checked for + are: toInteger, + toRational, + fromIntegral, + and realToFrac. + + + + + : @@ -1191,14 +1221,15 @@ foreign import "&f" f :: FunPtr t incomplete patterns, warning patterns, incomplete - Similarly for incomplete patterns, the function - g below will fail when applied to + Similarly for incomplete patterns, the functions + g and h below will fail when applied to non-empty lists, so the compiler will emit a warning about this when is enabled. g [] = 2 +h = \[] -> 2 This option isn't enabled by default because it can be @@ -1360,28 +1391,6 @@ f "2" = 2 - : - - - - Causes the compiler to warn about lambda-bound - patterns that can fail, eg. \(x:xs)->.... - Normally, these aren't treated as incomplete patterns by - . - “Lambda-bound patterns” includes all places where there is a single pattern, - including list comprehensions and do-notation. In these cases, a pattern-match - failure is quite legitimate, and triggers filtering (list comprehensions) or - the monad fail operation (monads). For example: - - f :: [Maybe a] -> [a] - f xs = [y | Just y <- xs] - - Switching on will elicit warnings about - these probably-innocent cases, which is why the flag is off by default. - - - - : @@ -1405,6 +1414,7 @@ f "2" = 2 e.g., the ‘default default’ for Haskell 1.4 caused the otherwise unconstrained value 1 to be given the type Int, whereas Haskell 98 + and later defaults it to Integer. This may lead to differences in performance and behaviour, hence the usefulness of being non-silent about this. @@ -1637,31 +1647,6 @@ f "2" = 2 . - - - - : - -Ofile <file> option - optimising, customised - - - (NOTE: not supported since GHC 4.x. Please ask if - you're interested in this.) - - For those who need absolute - control over exactly what options are - used (e.g., compiler writers, sometimes :-), a list of - options can be put in a file and then slurped in with - . - - In that file, comments are of the - #-to-end-of-line variety; blank - lines and most whitespace is ignored. - - Please ask if you are baffled and would like an - example of ! - - We don't use a flag for day-to-day @@ -2174,7 +2159,7 @@ f "2" = 2 : - (x86 only, added in GHC 6.14.1) Use the SSE2 registers and + (x86 only, added in GHC 7.0.1) Use the SSE2 registers and instruction set to implement floating point operations when using the native code generator. This gives a substantial performance improvement for floating point,