Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Open sidebar
Shayne Fletcher
Glasgow Haskell Compiler
Commits
5d2a1e65
Commit
5d2a1e65
authored
Jul 25, 2012
by
Ian Lynagh
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of darcs.haskell.org:/srv/darcs//ghc
parents
55881ff8
c9733e26
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
2 deletions
+8
-2
compiler/deSugar/Desugar.lhs
compiler/deSugar/Desugar.lhs
+3
-1
compiler/main/DynFlags.hs
compiler/main/DynFlags.hs
+3
-1
mk/validate-settings.mk
mk/validate-settings.mk
+2
-0
No files found.
compiler/deSugar/Desugar.lhs
View file @
5d2a1e65
...
...
@@ -364,6 +364,7 @@ dsRule (L loc (HsRule name act vars lhs _tv_lhs rhs _fv_rhs))
dsLExpr lhs -- Note [Desugaring RULE left hand sides]
; rhs' <- dsLExpr rhs
; dflags <- getDynFlags
-- Substitute the dict bindings eagerly,
-- and take the body apart into a (f args) form
...
...
@@ -381,6 +382,7 @@ dsRule (L loc (HsRule name act vars lhs _tv_lhs rhs _fv_rhs))
name act fn_name final_bndrs args final_rhs
inline_shadows_rule -- Function can be inlined before rule fires
| wopt Opt_WarnInlineRuleShadowing dflags
= case (idInlineActivation fn_id, act) of
(NeverActive, _) -> False
(AlwaysActive, _) -> True
...
...
@@ -389,7 +391,7 @@ dsRule (L loc (HsRule name act vars lhs _tv_lhs rhs _fv_rhs))
(ActiveAfter n, ActiveAfter r) -> r < n -- Rule active strictly first
(ActiveAfter {}, AlwaysActive) -> False
(ActiveAfter {}, ActiveBefore {}) -> False
| otherwise = False
; when inline_shadows_rule $
warnDs (vcat [ hang (ptext (sLit "Rule") <+> doubleQuotes (ftext name)
...
...
compiler/main/DynFlags.hs
View file @
5d2a1e65
...
...
@@ -384,6 +384,7 @@ data WarningFlag =
|
Opt_WarnSafe
|
Opt_WarnPointlessPragmas
|
Opt_WarnUnsupportedCallingConventions
|
Opt_WarnInlineRuleShadowing
deriving
(
Eq
,
Show
,
Enum
)
data
Language
=
Haskell98
|
Haskell2010
...
...
@@ -1982,7 +1983,8 @@ fWarningFlags = [
(
"warn-unsafe"
,
Opt_WarnUnsafe
,
setWarnUnsafe
),
(
"warn-safe"
,
Opt_WarnSafe
,
setWarnSafe
),
(
"warn-pointless-pragmas"
,
Opt_WarnPointlessPragmas
,
nop
),
(
"warn-unsupported-calling-conventions"
,
Opt_WarnUnsupportedCallingConventions
,
nop
)
]
(
"warn-unsupported-calling-conventions"
,
Opt_WarnUnsupportedCallingConventions
,
nop
),
(
"warn-inline-rule-shadowing"
,
Opt_WarnInlineRuleShadowing
,
nop
)
]
-- | These @-\<blah\>@ flags can all be reversed with @-no-\<blah\>@
negatableFlags
::
[
FlagSpec
DynFlag
]
...
...
mk/validate-settings.mk
View file @
5d2a1e65
...
...
@@ -114,3 +114,5 @@ libraries/binary/src/Data/Binary/Get_HC_OPTS += -fno-warn-warnings-deprecations
GhcLibHcOpts
+=
-fno-warn-deprecated-flags
GhcBootLibHcOpts
+=
-fno-warn-deprecated-flags
# Temporarely disable rule shadowing warning
GhcLibHcOpts
+=
-fno-warn-inline-rule-shadowing
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment