Skip to content

Commit

Permalink
Update the markdown hints
Browse files Browse the repository at this point in the history
  • Loading branch information
ndmitchell committed Jan 14, 2024
1 parent c42d874 commit 5d7e561
Showing 1 changed file with 83 additions and 3 deletions.
86 changes: 83 additions & 3 deletions hints.md
Original file line number Diff line number Diff line change
Expand Up @@ -3559,6 +3559,22 @@ maybe [] (concatMap f) x
<td>Suggestion</td>
</tr>
<tr>
<td>Use maybe</td>
<td>
LHS:
<code>
concat (fromMaybe [] x)
</code>
<br>
RHS:
<code>
maybe [] concat x
</code>
<br>
</td>
<td>Suggestion</td>
</tr>
<tr>
<td>Use notElem</td>
<td>
LHS:
Expand Down Expand Up @@ -9979,6 +9995,22 @@ RHS:
<td>Suggestion</td>
</tr>
<tr>
<td>Avoid NonEmpty.unzip</td>
<td>
LHS:
<code>
Data.List.NonEmpty.unzip
</code>
<br>
RHS:
<code>
Data.Functor.unzip
</code>
<br>
</td>
<td>Warning</td>
</tr>
<tr>
<td>Use fromMaybe</td>
<td>
LHS:
Expand Down Expand Up @@ -12758,7 +12790,7 @@ foldMap (foldMap f . g) x
<td>Warning</td>
</tr>
<tr>
<td>Move concatMap out</td>
<td>Move catMaybes</td>
<td>
LHS:
<code>
Expand All @@ -12774,7 +12806,23 @@ concatMap (catMaybes . f) x
<td>Warning</td>
</tr>
<tr>
<td>Move concatMap out</td>
<td>Move catMaybes</td>
<td>
LHS:
<code>
catMaybes (concat x)
</code>
<br>
RHS:
<code>
concatMap catMaybes x
</code>
<br>
</td>
<td>Warning</td>
</tr>
<tr>
<td>Move filter</td>
<td>
LHS:
<code>
Expand All @@ -12790,7 +12838,23 @@ concatMap (filter f . g) x
<td>Suggestion</td>
</tr>
<tr>
<td>Move concatMap out</td>
<td>Move filter</td>
<td>
LHS:
<code>
filter f (concat x)
</code>
<br>
RHS:
<code>
concatMap (filter f) x
</code>
<br>
</td>
<td>Suggestion</td>
</tr>
<tr>
<td>Move mapMaybe</td>
<td>
LHS:
<code>
Expand All @@ -12806,6 +12870,22 @@ concatMap (mapMaybe f . g) x
<td>Warning</td>
</tr>
<tr>
<td>Move mapMaybe</td>
<td>
LHS:
<code>
mapMaybe f (concat x)
</code>
<br>
RHS:
<code>
concatMap (mapMaybe f) x
</code>
<br>
</td>
<td>Warning</td>
</tr>
<tr>
<td>Use any</td>
<td>
LHS:
Expand Down

0 comments on commit 5d7e561

Please sign in to comment.