|
84 | 84 | - Compat.HieBin
|
85 | 85 |
|
86 | 86 | # Partial functions
|
| 87 | + |
| 88 | + # For some reason we need to check fucntions which |
| 89 | + # are typically exported multiple ways under both names, |
| 90 | + # see https://github.com/ndmitchell/hlint/issues/1389 |
| 91 | + - name: Prelude.head |
| 92 | + within: |
| 93 | + - Main |
| 94 | + - Development.Benchmark.Rules |
| 95 | + - Development.IDE.Plugin.CodeAction |
| 96 | + - Development.IDE.Plugin.Completions |
| 97 | + - Development.IDE.Plugin.CodeAction.ExactPrint |
| 98 | + - Development.IDE.Spans.Documentation |
| 99 | + - Ide.Plugin.CallHierarchy.Internal |
| 100 | + - Ide.Plugin.Eval.Code |
| 101 | + - Ide.Plugin.Eval.Util |
| 102 | + - Ide.Plugin.Floskell |
| 103 | + - Ide.Plugin.ModuleName |
| 104 | + - Ide.Plugin.Rename |
| 105 | + - Ide.Plugin.Class.ExactPrint |
| 106 | + - TExpectedActual |
| 107 | + - TRigidType |
| 108 | + - RightToLeftFixities |
| 109 | + - Typeclass |
| 110 | + - Wingman.Judgements |
| 111 | + - Wingman.Machinery |
| 112 | + |
87 | 113 | - name: Data.List.head
|
88 | 114 | within:
|
89 | 115 | - Main
|
|
94 | 120 | - Development.IDE.Session
|
95 | 121 | - Development.IDE.Spans.Documentation
|
96 | 122 | - Ide.Plugin.CallHierarchy.Internal
|
97 |
| - - TExpectedActual |
98 |
| - - TRigidType |
99 |
| - - TRigidType |
100 | 123 | - Ide.Plugin.Class
|
101 | 124 | - Wingman.Tactics
|
| 125 | + - TExpectedActual |
| 126 | + - TRigidType |
| 127 | + |
| 128 | + - name: Prelude.tail |
| 129 | + within: |
| 130 | + - Main |
| 131 | + - Development.Benchmark.Rules |
| 132 | + - Development.IDE.Plugin.CodeAction |
| 133 | + - Development.IDE.Plugin.CodeAction.ExactPrint |
| 134 | + - UnificationSpec |
102 | 135 |
|
103 | 136 | - name: Data.List.tail
|
104 | 137 | within:
|
|
111 | 144 | - IDE.Plugin.Eval.Util
|
112 | 145 | - UnificationSpec
|
113 | 146 |
|
| 147 | + - name: Prelude.last |
| 148 | + within: |
| 149 | + - Main |
| 150 | + - Development.IDE.Plugin.CodeAction |
| 151 | + - Development.IDE.Plugin.CodeAction.ExactPrint |
| 152 | + - Development.IDE.Spans.Common |
| 153 | + - Development.IDE.Graph.Internal.Types |
| 154 | + - Ide.PluginUtils |
| 155 | + - Ide.Plugin.Eval.Parse.Comments |
| 156 | + - Ide.Plugin.Eval.CodeLens |
| 157 | + |
114 | 158 | - name: Data.List.last
|
115 | 159 | within:
|
116 | 160 | - GenChangelogs
|
117 | 161 | - Main
|
118 | 162 |
|
| 163 | + - name: Prelude.init |
| 164 | + within: |
| 165 | + - Main |
| 166 | + - Development.IDE.Spans.Common |
| 167 | + - Ide.PluginUtils |
| 168 | + - Wingman.Metaprogramming.Parser |
| 169 | + - Development.Benchmark.Rules |
| 170 | + - ErrorGivenPartialSignature |
| 171 | + |
119 | 172 | - name: Data.List.init
|
120 | 173 | within: []
|
121 | 174 |
|
|
125 | 178 | - name: Data.List.foldr1'
|
126 | 179 | within: []
|
127 | 180 |
|
| 181 | + - name: "Prelude.!!" |
| 182 | + within: |
| 183 | + - Main |
| 184 | + - Development.IDE.Plugin.CodeAction |
| 185 | + - Development.IDE.Plugin.Completions.Logic |
| 186 | + - Development.IDE.Spans.Documentation |
| 187 | + - TErrorGivenPartialSignature |
| 188 | + - Wingman.CaseSplit |
| 189 | + - Wingman.Simplify |
| 190 | + |
128 | 191 | - name: "Data.List.!!"
|
129 | 192 | within:
|
130 | 193 | - Main
|
|
178 | 241 | - name: "GHC.Arr.!"
|
179 | 242 | within: []
|
180 | 243 |
|
| 244 | + # Tracing functions |
| 245 | + # We ban an explicit list rather than the |
| 246 | + # Debug.Trace, because that module also |
| 247 | + # includes the eventlog tracing functions, |
| 248 | + # which are legitimate to use. |
| 249 | + - name: |
| 250 | + - Debug.Trace.trace |
| 251 | + - Debug.Trace.traceId |
| 252 | + - Debug.Trace.traceShow |
| 253 | + - Debug.Trace.traceShowId |
| 254 | + - Debug.Trace.traceStack |
| 255 | + - Debug.Trace.traceIO |
| 256 | + - Debug.Trace.traceM |
| 257 | + - Debug.Trace.traceShowM |
| 258 | + - Debug.Trace.putTraceMsg |
| 259 | + within: |
| 260 | + - Development.IDE.Core.Compile |
| 261 | + - Development.IDE.Graph.Internal.Database |
| 262 | + - Development.IDE.GHC.Util |
| 263 | + - Wingman.Debug |
| 264 | + |
181 | 265 | # We really do not want novel usages of restricted functions, and mere
|
182 | 266 | # Warning is not enough to prevent those consistently; you need a build failure.
|
183 | 267 | - error: {name: Avoid restricted function}
|
0 commit comments