Skip to content
This repository has been archived by the owner on Nov 18, 2023. It is now read-only.

GHC 8 warnings about REWRITE rules not firing #37

Open
istathar opened this issue Aug 14, 2016 · 1 comment
Open

GHC 8 warnings about REWRITE rules not firing #37

istathar opened this issue Aug 14, 2016 · 1 comment

Comments

@istathar
Copy link
Contributor

Noticed this when building matrix with resolver: nightly-2016-08-06:

Data/Matrix.hs:1330:1: warning: [-Winline-rule-shadowing]
    Rule "matrix/traceOfSum" may never fire
      because ‘trace’ might inline first
    Probable fix: add an INLINE[n] or NOINLINE[n] pragma for ‘trace’
Data/Matrix.hs:1330:1: warning: [-Winline-rule-shadowing]
    Rule "matrix/traceOfSum" may never fire
      because rule "Class op +" for ‘+’ might fire first
    Probable fix: add phase [n] or [~n] to the competing rule
Data/Matrix.hs:1333:1: warning: [-Winline-rule-shadowing]
    Rule "matrix/traceOfScale" may never fire
      because ‘trace’ might inline first
    Probable fix: add an INLINE[n] or NOINLINE[n] pragma for ‘trace’
Data/Matrix.hs:1333:1: warning: [-Winline-rule-shadowing]
    Rule "matrix/traceOfScale" may never fire
      because ‘scaleMatrix’ might inline first
    Probable fix: add an INLINE[n] or NOINLINE[n] pragma for ‘scaleMatrix’
Data/Matrix.hs:1358:1: warning: [-Winline-rule-shadowing]
    Rule "matrix/detLaplaceProduct" may never fire
      because ‘detLaplace’ might inline first
    Probable fix: add an INLINE[n] or NOINLINE[n] pragma for ‘detLaplace’
Data/Matrix.hs:1358:1: warning: [-Winline-rule-shadowing]
    Rule "matrix/detLaplaceProduct" may never fire
      because rule "Class op *" for ‘*’ might fire first
    Probable fix: add phase [n] or [~n] to the competing rule

Don't know if this is GHC 8 specific or whether this cropped up earlier, but fyi.

AfC

@Daniel-Diaz
Copy link
Owner

I think these started with GHC 8. Thanks for reporting.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants