inject allow(unused_variables)

This commit is contained in:
steveklabnik 2017-03-10 09:46:11 -05:00
parent c5f9625feb
commit b120ce7397
1 changed files with 3 additions and 1 deletions

View File

@ -307,7 +307,9 @@ fn add_playpen_pre(html: String) -> String {
format!("<pre class=\"playpen\">{}</pre>", text)
} else {
// we need to inject our own main
format!("<pre class=\"playpen\"><code class=\"{}\">#fn main() {{
format!("<pre class=\"playpen\"><code class=\"{}\"># #![allow(unused_variables)]
#
#fn main() {{
{}
#}}</code></pre>", classes, code)
}