Update documentation
https://github.com/pmd/pmd/actions/runs/1376042153
fb731c257e...494520bb03
This commit is contained in:
4
feed.xml
4
feed.xml
@ -5,8 +5,8 @@
|
||||
<description>Intended as a documentation theme based on Jekyll for technical writers documenting software and other technical products, this theme has all the elements you would need to handle multiple products with both multi-level sidebar navigation, tags, and other documentation features.</description>
|
||||
<link>https://pmd.github.io/pmd/</link>
|
||||
<atom:link href="https://pmd.github.io/pmd/feed.xml" rel="self" type="application/rss+xml"/>
|
||||
<pubDate>Sat, 23 Oct 2021 18:31:48 +0000</pubDate>
|
||||
<lastBuildDate>Sat, 23 Oct 2021 18:31:48 +0000</lastBuildDate>
|
||||
<pubDate>Sat, 23 Oct 2021 18:35:18 +0000</pubDate>
|
||||
<lastBuildDate>Sat, 23 Oct 2021 18:35:18 +0000</lastBuildDate>
|
||||
<generator>Jekyll v3.9.0</generator>
|
||||
|
||||
</channel>
|
||||
|
@ -1700,9 +1700,7 @@ In most circumstances, this swallows an exception which should either be acted o
|
||||
or reported.</p>
|
||||
|
||||
<p><strong>This rule is defined by the following XPath expression:</strong></p>
|
||||
<div class="language-xpath highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="o">//</span><span class="nt">CatchBlockStatement</span><span class="p">[.</span><span class="o">/</span><span class="nt">BlockStatement</span><span class="p">[</span><span class="nf">count</span><span class="p">(</span><span class="err">*</span><span class="p">)</span><span class="w"> </span><span class="err">=</span><span class="w"> </span><span class="m">0</span><span class="p">]</span><span class="w"> </span><span class="ow">and</span><span class="w">
|
||||
</span><span class="ow">not</span><span class="p">(</span><span class="nf">matches</span><span class="p">(</span><span class="na">@VariableName</span><span class="p">,</span><span class="w"> </span><span class="nv">$allowExceptionNameRegex</span><span class="p">))</span><span class="w"> </span><span class="ow">and</span><span class="w">
|
||||
</span><span class="p">(</span><span class="nv">$allowCommentedBlocks</span><span class="w"> </span><span class="err">=</span><span class="w"> </span><span class="nf">false</span><span class="p">()</span><span class="w"> </span><span class="ow">or</span><span class="w"> </span><span class="na">@ContainsComment</span><span class="w"> </span><span class="err">=</span><span class="w"> </span><span class="nf">false</span><span class="p">())]</span><span class="w">
|
||||
<div class="language-xpath highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="o">//</span><span class="nt">CatchBlockStatement</span><span class="p">[.</span><span class="o">/</span><span class="nt">BlockStatement</span><span class="p">[</span><span class="nf">count</span><span class="p">(</span><span class="err">*</span><span class="p">)</span><span class="w"> </span><span class="err">=</span><span class="w"> </span><span class="m">0</span><span class="p">]]</span><span class="w">
|
||||
</span></code></pre></div></div>
|
||||
|
||||
<p><strong>Example(s):</strong></p>
|
||||
@ -1747,18 +1745,6 @@ or reported.</p>
|
||||
<td><span style="border-radius: 0.25em; color: #fff; padding: 0.2em 0.6em 0.3em; display: inline; background-color: #d9534f; font-size: 75%;">Deprecated</span> Code Climate Block Highlighting</td>
|
||||
<td>no</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>allowCommentedBlocks</td>
|
||||
<td>false</td>
|
||||
<td>Empty blocks containing comments will be skipped</td>
|
||||
<td>no</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>allowExceptionNameRegex</td>
|
||||
<td>^(ignored|expected)$</td>
|
||||
<td>Empty blocks catching exceptions with names matching this regular expression will be skipped</td>
|
||||
<td>no</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
@ -1766,15 +1752,6 @@ or reported.</p>
|
||||
<div class="language-xml highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="nt"><rule</span> <span class="na">ref=</span><span class="s">"category/apex/errorprone.xml/EmptyCatchBlock"</span> <span class="nt">/></span>
|
||||
</code></pre></div></div>
|
||||
|
||||
<p><strong>Use this rule and customize it:</strong></p>
|
||||
<div class="language-xml highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="nt"><rule</span> <span class="na">ref=</span><span class="s">"category/apex/errorprone.xml/EmptyCatchBlock"</span><span class="nt">></span>
|
||||
<span class="nt"><properties></span>
|
||||
<span class="nt"><property</span> <span class="na">name=</span><span class="s">"allowCommentedBlocks"</span> <span class="na">value=</span><span class="s">"false"</span> <span class="nt">/></span>
|
||||
<span class="nt"><property</span> <span class="na">name=</span><span class="s">"allowExceptionNameRegex"</span> <span class="na">value=</span><span class="s">"^(ignored|expected)$"</span> <span class="nt">/></span>
|
||||
<span class="nt"></properties></span>
|
||||
<span class="nt"></rule></span>
|
||||
</code></pre></div></div>
|
||||
|
||||
<h2 id="emptyifstmt">EmptyIfStmt</h2>
|
||||
|
||||
<p><strong>Since:</strong> PMD 6.0.0</p>
|
||||
|
Reference in New Issue
Block a user