on master help sign in
Resolve two TODOs in docs error messages
1c54fcdEvan Czaplicki
src/Reporting/Error/Docs.hs+9−2
@@ -88,7 +88,9 @@ toReport source err =
88 "I do not see `" <> N.toString name
88 "I do not see `" <> N.toString name
89 <> "` in the `exposing` list, but it is in your module documentation:"
89 <> "` in the `exposing` list, but it is in your module documentation:"
90 ,
90 ,
91− error "TODO OnlyInDocs"
91+ H.reflow $
92+ "Does it need to be added to the `exposing` list as well? Or maybe you removed `"
93+ <> N.toString name <> "` and forgot to delete it here?"
92 )
94 )
93
95
94 OnlyInExports name region ->
96 OnlyInExports name region ->
@@ -99,7 +101,12 @@ toReport source err =
99 "I do not see `" <> N.toString name
101 "I do not see `" <> N.toString name
100 <> "` in your module documentation, but it is in your `exposing` list:"
102 <> "` in your module documentation, but it is in your `exposing` list:"
101 ,
103 ,
102− error "TODO OnlyInExports"
104+ H.stack
105+ [ H.reflow $
106+ "Add a line like `@docs " <> N.toString name
107+ <> "` to your module documentation!"
108+ , H.link "Note" "See" "docs" "for more guidance on writing high quality docs."
109+ ]
103 )
110 )
104
111
105 NoComment name region ->
112 NoComment name region ->