|
| 1 | +<!DOCTYPE html> |
| 2 | +<!-- |
| 3 | +Welcome to a Clippy's lint list, at least the source code of it. If you are |
| 4 | +interested in contributing to this website checkout `util/gh-pages/index_template.html` |
| 5 | +inside the rust-clippy repository. |
| 6 | +
|
| 7 | +Otherwise, have a great day =^.^= |
| 8 | +--> |
| 9 | +<htmllang="en"> {# #} |
| 10 | +<head> {# #} |
| 11 | +<metacharset="UTF-8"/> {# #} |
| 12 | +<metaname="viewport" content="width=device-width, initial-scale=1"/> {# #} |
| 13 | +<metaname="description" content="A collection of lints to catch common mistakes and improve your Rust code."> {# #} |
| 14 | + |
| 15 | +<title>Clippy Lints</title> {# #} |
| 16 | + |
| 17 | +<linkrel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.6/css/bootstrap.min.css"/> {# #} |
| 18 | +<linkid="githubLightHighlight" rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.6.0/styles/github.min.css" disabled="true" /> {# #} |
| 19 | +<linkid="githubDarkHighlight" rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.6.0/styles/github-dark.min.css" disabled="true" /> {# #} |
| 20 | + |
| 21 | +<!-- The files are not copied over into the Clippy project since they use the MPL-2.0 License --> |
| 22 | +<linkrel="stylesheet" href="https://rust-lang.github.io/mdBook/css/variables.css"/> {# #} |
| 23 | +<linkid="styleHighlight" rel="stylesheet" href="https://rust-lang.github.io/mdBook/highlight.css"> {# #} |
| 24 | +<linkid="styleNight" rel="stylesheet" href="https://rust-lang.github.io/mdBook/tomorrow-night.css" disabled="true"> {# #} |
| 25 | +<linkid="styleAyu" rel="stylesheet" href="https://rust-lang.github.io/mdBook/ayu-highlight.css" disabled="true"> {# #} |
| 26 | +<linkrel="stylesheet" href="style.css"> {# #} |
| 27 | +</head> {# #} |
| 28 | +<body> {# #} |
| 29 | +<scriptsrc="theme.js"></script> {# #} |
| 30 | +<divid="settings-dropdown"> {# #} |
| 31 | +<buttonclass="settings-icon" tabindex="-1"></button> {# #} |
| 32 | +<divclass="settings-menu" tabindex="-1"> {# #} |
| 33 | +<divclass="setting-radio-name">Theme</div> {# #} |
| 34 | +<selectid="theme-choice" onchange="setTheme(this.value, true)"> {# #} |
| 35 | +<optionvalue="ayu">Ayu</option> {# #} |
| 36 | +<optionvalue="coal">Coal</option> {# #} |
| 37 | +<optionvalue="light">Light</option> {# #} |
| 38 | +<optionvalue="navy">Navy</option> {# #} |
| 39 | +<optionvalue="rust">Rust</option> {# #} |
| 40 | +</select> {# #} |
| 41 | +<label> {# #} |
| 42 | +<inputtype="checkbox" id="disable-shortcuts" onchange="changeSetting(this)"> {#+ #} |
| 43 | +<span>Disable keyboard shortcuts</span> {# #} |
| 44 | +</label> {# #} |
| 45 | +</div> {# #} |
| 46 | +</div> {# #} |
| 47 | + |
| 48 | +<divclass="container"> {# #} |
| 49 | +<divclass="page-header"> {# #} |
| 50 | +<h1>Clippy Lints</h1> {# #} |
| 51 | +</div> {# #} |
| 52 | + |
| 53 | +<noscript> {# #} |
| 54 | +<divclass="alert alert-danger" role="alert"> {# #} |
| 55 | + Sorry, this site only works with JavaScript! :( {# #} |
| 56 | +</div> {# #} |
| 57 | +</noscript> {# #} |
| 58 | + |
| 59 | +<div> {# #} |
| 60 | +<divclass="panel panel-default"> {# #} |
| 61 | +<divclass="panel-body row"> {# #} |
| 62 | +<divid="upper-filters" class="col-12 col-md-5"> {# #} |
| 63 | +<divclass="btn-group" id="lint-levels" tabindex="-1"> {# #} |
| 64 | +<buttontype="button" class="btn btn-default dropdown-toggle"> {# #} |
| 65 | + Lint levels <spanclass="badge">4</span><spanclass="caret"></span> {# #} |
| 66 | +</button> {# #} |
| 67 | +<ulclass="dropdown-menu" id="lint-levels-selector"> {# #} |
| 68 | +<liclass="checkbox"> {# #} |
| 69 | +<buttononclick="toggleElements('levels_filter', true)">All</button> {# #} |
| 70 | +</li> {# #} |
| 71 | +<liclass="checkbox"> {# #} |
| 72 | +<buttononclick="toggleElements('levels_filter', false)">None</button> {# #} |
| 73 | +</li> {# #} |
| 74 | +<lirole="separator" class="divider"></li> {# #} |
| 75 | +</ul> {# #} |
| 76 | +</div> {# #} |
| 77 | +<divclass="btn-group" id="lint-groups" tabindex="-1"> {# #} |
| 78 | +<buttontype="button" class="btn btn-default dropdown-toggle"> {# #} |
| 79 | + Lint groups <spanclass="badge">9</span><spanclass="caret"></span> {# #} |
| 80 | +</button> {# #} |
| 81 | +<ulclass="dropdown-menu" id="lint-groups-selector"> {# #} |
| 82 | +<liclass="checkbox"> {# #} |
| 83 | +<buttononclick="toggleElements('groups_filter', true)">All</button> {# #} |
| 84 | +</li> {# #} |
| 85 | +<liclass="checkbox"> {# #} |
| 86 | +<buttononclick="resetGroupsToDefault()">Default</button> {# #} |
| 87 | +</li> {# #} |
| 88 | +<liclass="checkbox"> {# #} |
| 89 | +<buttononclick="toggleElements('groups_filter', false)">None</button> {# #} |
| 90 | +</li> {# #} |
| 91 | +<lirole="separator" class="divider"></li> {# #} |
| 92 | +</ul> {# #} |
| 93 | +</div> {# #} |
| 94 | +<divclass="btn-group" id="version-filter" tabindex="-1"> {# #} |
| 95 | +<buttontype="button" class="btn btn-default dropdown-toggle"> {# #} |
| 96 | + Version {#+ #} |
| 97 | +<spanid="version-filter-count" class="badge">0</span> {#+ #} |
| 98 | +<spanclass="caret"></span> {# #} |
| 99 | +</button> {# #} |
| 100 | +<ulid="version-filter-selector" class="dropdown-menu"> {# #} |
| 101 | +<liclass="checkbox"> {# #} |
| 102 | +<buttononclick="clearVersionFilters()">Clear filters</button> {# #} |
| 103 | +</li> {# #} |
| 104 | +<lirole="separator" class="divider"></li> {# #} |
| 105 | +</ul> {# #} |
| 106 | +</div> {# #} |
| 107 | +<divclass="btn-group",id="lint-applicabilities" tabindex="-1"> {# #} |
| 108 | +<buttontype="button" class="btn btn-default dropdown-toggle"> {# #} |
| 109 | + Applicability {#+ #} |
| 110 | +<spanclass="badge">4</span> {#+ #} |
| 111 | +<spanclass="caret"></span> {# #} |
| 112 | +</button> {# #} |
| 113 | +<ulclass="dropdown-menu" id="lint-applicabilities-selector"> {# #} |
| 114 | +<liclass="checkbox"> {# #} |
| 115 | +<buttononclick="toggleElements('applicabilities_filter', true)">All</button> {# #} |
| 116 | +</li> {# #} |
| 117 | +<liclass="checkbox"> {# #} |
| 118 | +<buttononclick="toggleElements('applicabilities_filter', false)">None</button> {# #} |
| 119 | +</li> {# #} |
| 120 | +<lirole="separator" class="divider"></li> {# #} |
| 121 | +</ul> {# #} |
| 122 | +</div> {# #} |
| 123 | +</div> {# #} |
| 124 | +<divclass="col-12 col-md-5 search-control"> {# #} |
| 125 | +<divclass="input-group"> {# #} |
| 126 | +<labelclass="input-group-addon" id="filter-label" for="search-input">Filter:</label> {# #} |
| 127 | +<inputtype="text" class="form-control filter-input" placeholder="Keywords or search string (`S` or `/` to focus)" id="search-input" /> {# #} |
| 128 | +<spanclass="input-group-btn"> {# #} |
| 129 | +<buttonclass="filter-clear btn" type="button" onclick="searchState.clearInput(event)"> {# #} |
| 130 | + Clear {# #} |
| 131 | +</button> {# #} |
| 132 | +</span> {# #} |
| 133 | +</div> {# #} |
| 134 | +</div> {# #} |
| 135 | +<divclass="col-12 col-md-2 btn-group expansion-group"> {# #} |
| 136 | +<buttontitle="Collapse All" class="btn btn-default expansion-control" type="button" onclick="toggleExpansion(false)"> {# #} |
| 137 | +<spanclass="glyphicon glyphicon-collapse-up"></span> {# #} |
| 138 | +</button> {# #} |
| 139 | +<buttontitle="Expand All" class="btn btn-default expansion-control" type="button" onclick="toggleExpansion(true)"> {# #} |
| 140 | +<spanclass="glyphicon glyphicon-collapse-down"></span> {# #} |
| 141 | +</button> {# #} |
| 142 | +</div> {# #} |
| 143 | +</div> {# #} |
| 144 | +</div> |
| 145 | + {% for lint in lints %} |
| 146 | +<articleclass="panel panel-default collapsed" id="{{lint.id}}"> {# #} |
| 147 | +<headerclass="panel-heading" onclick="expandLint('{{lint.id}}')"> {# #} |
| 148 | +<h2class="panel-title"> {# #} |
| 149 | +<divclass="panel-title-name" id="lint-{{lint.id}}"> {# #} |
| 150 | +<span>{{lint.id}}</span> {#+ #} |
| 151 | +<ahref="#{{lint.id}}" class="anchor label label-default" onclick="openLint(event)">¶</a> {#+ #} |
| 152 | +<ahref="" class="anchor label label-default" onclick="copyToClipboard(event)"> {# #} |
| 153 | + 📋 {# #} |
| 154 | +</a> {# #} |
| 155 | +</div> {# #} |
| 156 | + |
| 157 | +<divclass="panel-title-addons"> {# #} |
| 158 | +<spanclass="label label-lint-group label-default label-group-{{lint.group}}">{{lint.group}}</span> {#+ #} |
| 159 | + |
| 160 | +<spanclass="label label-lint-level label-lint-level-{{lint.level}}">{{lint.level}}</span> {#+ #} |
| 161 | + |
| 162 | +<spanclass="label label-doc-folding">+</span> {# #} |
| 163 | +</div> {# #} |
| 164 | +</h2> {# #} |
| 165 | +</header> {# #} |
| 166 | + |
| 167 | +<divclass="list-group lint-docs"> {# #} |
| 168 | +<divclass="list-group-item lint-doc-md">{{Self::markdown(lint.docs)}}</div> {# #} |
| 169 | +<divclass="lint-additional-info-container"> |
| 170 | + {# Applicability #} |
| 171 | +<divclass="lint-additional-info-item"> {# #} |
| 172 | +<span> Applicability: </span> {# #} |
| 173 | +<spanclass="label label-default label-applicability">{{ lint.applicability_str() }}</span> {# #} |
| 174 | +<ahref="https://doc.rust-lang.org/nightly/nightly-rustc/rustc_lint_defs/enum.Applicability.html#variants">(?)</a> {# #} |
| 175 | +</div> |
| 176 | + {# Clippy version #} |
| 177 | +<divclass="lint-additional-info-item"> {# #} |
| 178 | +<span>{% if lint.group == "deprecated" %}Deprecated{% else %} Added{% endif +%} in: </span> {# #} |
| 179 | +<spanclass="label label-default label-version">{{lint.version}}</span> {# #} |
| 180 | +</div> |
| 181 | + {# Open related issues #} |
| 182 | +<divclass="lint-additional-info-item"> {# #} |
| 183 | +<ahref="https://github.com/rust-lang/rust-clippy/issues?q=is%3Aissue+{{lint.id}}">Related Issues</a> {# #} |
| 184 | +</div> |
| 185 | + |
| 186 | + {# Jump to source #} |
| 187 | + {% if let Some(id_location) = lint.id_location %} |
| 188 | +<divclass="lint-additional-info-item"> {# #} |
| 189 | +<ahref="https://github.com/rust-lang/rust-clippy/blob/master/clippy_lints/{{id_location}}">View Source</a> {# #} |
| 190 | +</div> |
| 191 | + {% endif %} |
| 192 | +</div> {# #} |
| 193 | +</div> {# #} |
| 194 | +</article> |
| 195 | + {% endfor %} |
| 196 | +</div> {# #} |
| 197 | +</div> {# #} |
| 198 | + |
| 199 | +<a{#+#} |
| 200 | +aria-label="View source on GitHub" {#+#} |
| 201 | +class="github-corner" {#+#} |
| 202 | +href="https://github.com/rust-lang/rust-clippy" {#+#} |
| 203 | +rel="noopener noreferrer" {#+#} |
| 204 | +target="_blank" {##} |
| 205 | +> {# #} |
| 206 | +<svg{#+#} |
| 207 | +width="80" {#+#} |
| 208 | +height="80" {#+#} |
| 209 | +viewBox="0 0 250 250" {#+#} |
| 210 | +style="position: absolute; top: 0; border: 0; right: 0" {#+#} |
| 211 | +aria-hidden="true" {##} |
| 212 | +> {# #} |
| 213 | +<pathd="M0,0 L115,115 L130,115 L142,142 L250,250 L250,0 Z" fill="var(--theme-color)"></path> {# #} |
| 214 | +<path{#+#} |
| 215 | +d="M128.3,109.0 C113.8,99.7 119.0,89.6 119.0,89.6 C122.0,82.7 120.5,78.6 120.5,78.6 C119.2,72.0 123.4,76.3 123.4,76.3 C127.3,80.9 125.5,87.3 125.5,87.3 C122.9,97.6 130.6,101.9 134.4,103.2" {#+#} |
| 216 | +fill="currentColor" {#+#} |
| 217 | +style="transform-origin: 130px 106px" {#+#} |
| 218 | +class="octo-arm" {##} |
| 219 | +></path> {# #} |
| 220 | +<path{#+#} |
| 221 | +d="M115.0,115.0 C114.9,115.1 118.7,116.5 119.8,115.4 L133.7,101.6 C136.9,99.2 139.9,98.4 142.2,98.6 C133.8,88.0 127.5,74.4 143.8,58.0 C148.5,53.4 154.0,51.2 159.7,51.0 C160.3,49.4 163.2,43.6 171.4,40.1 C171.4,40.1 176.1,42.5 178.8,56.2 C183.1,58.6 187.2,61.8 190.9,65.4 C194.5,69.0 197.7,73.2 200.1,77.6 C213.8,80.2 216.3,84.9 216.3,84.9 C212.7,93.1 206.9,96.0 205.4,96.6 C205.1,102.4 203.0,107.8 198.3,112.5 C181.9,128.9 168.3,122.5 157.7,114.1 C157.9,116.9 156.7,120.9 152.7,124.9 L141.0,136.5 C139.8,137.7 141.6,141.9 141.8,141.8 Z" {#+#} |
| 222 | +fill="currentColor" {#+#} |
| 223 | +class="octo-body" {##} |
| 224 | +></path> {# #} |
| 225 | +</svg> {# #} |
| 226 | +</a> {# #} |
| 227 | + |
| 228 | +<scriptsrc="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.6.0/highlight.min.js"></script> {# #} |
| 229 | +<scriptsrc="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.6.0/languages/rust.min.js"></script> {# #} |
| 230 | +<scriptsrc="script.js"></script> {# #} |
| 231 | +</body> {# #} |
| 232 | +</html> {# #} |
0 commit comments