Tweak redundant brackets warning for constraints?
amesgen opened this issue · 1 comments
Consider
foo :: (A) => ()
bar :: (A a) => ()
where current (3.5) HLint warns about redundant brackets for foo
, but not for bar
. This feels slightly inconsistent, is this intentional?
Context: Recently, Ormolu started to always put brackets around constraints (see tweag/ormolu#264). This means that when using something like foo
above, it is impossible to please both Ormolu and HLint (without locally disabling either of them), see tweag/ormolu#1003.
This issue would be resolved if HLint would not warn about foo
(which seems plausible as it does not warn about bar
), or alternatively, if it could warn about foo
with a different message, such that Ormolu users can choose to ignore just that lint in their HLint config file while still getting the redundant brackets warnings in all other cases. WDYT?
This is indeed inconsistent. We can disable it for both cases. Unsure whether or not it is intentional.