We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 07b27bb commit 43abad4Copy full SHA for 43abad4
src/librustdoc/html/format.rs
@@ -208,7 +208,9 @@ impl<'a> fmt::Display for WhereClause<'a> {
208
clause.push_str("</span>");
209
let plain = format!("{:#}", self);
210
if plain.len() + pad.len() > 80 {
211
- let padding = if pad.len() + 25 > 80 {
+ //break it onto its own line regardless, but make sure method impls and trait
212
+ //blocks keep their fixed padding (2 and 9, respectively)
213
+ let padding = if pad.len() > 10 {
214
clause = clause.replace("class='where'", "class='where fmt-newline'");
215
repeat(" ").take(8).collect::<String>()
216
} else {
0 commit comments