Skip to content
  • Ryan Scott's avatar
    Fix #14934 by including axSub0R in typeNatCoAxiomRules · c3aea396
    Ryan Scott authored
    For some reason, `axSub0R` was left out of `typeNatCoAxiomRules` in
    `TcTypeNats`, which led to disaster when trying to look up `Sub0R` from
    an interface file, as demonstrated in #14934.
    
    The fix is simple—just add `axSub0R` to that list. To help prevent
    an issue like this happening in the future, I added a
    `Note [Adding built-in type families]` to `TcTypeNats`, which
    contains a walkthrough of all the definitions in `TcTypeNats` you
    need to update when adding a new built-in type family.
    
    Test Plan: make test TEST=T14934
    
    Reviewers: bgamari, simonpj
    
    Reviewed By: simonpj
    
    Subscribers: simonpj, rwbarton, thomie, carter
    
    GHC Trac Issues: #14934
    
    Differential Revision: https://phabricator.haskell.org/D4508
    c3aea396