Skip to content
Merged
Changes from 1 commit
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
08f204e
rustdoc: migrate `document_type_layout` to askama
notriddle Apr 4, 2023
5f9746b
rustdoc: use a separate template for type layout size
notriddle Apr 18, 2023
3a16db1
rustdoc: create variants list outside of template
notriddle Apr 18, 2023
e26ae95
rustdoc: format type layout template with newline after `<p>`
notriddle Apr 18, 2023
4375af5
Derive `HashStable` on `GenericArgKind` instead of implementing it by…
WaffleLapkin Apr 20, 2023
b0692a6
compiler/rustc_target: Raise m68k-linux-gnu baseline to 68020
glaubitz Apr 21, 2023
99e1cdb
rustdoc: get rid of redundant, nested `let` lines
notriddle Apr 21, 2023
2b728c1
rustdoc: factor `document_type_layout` into its own module
notriddle Apr 21, 2023
e6664c0
rustdoc: remove unnecessary binding
notriddle Apr 21, 2023
6f29a3c
nit: consistent naming for SimplifyConstCondition
miguelraz Apr 21, 2023
994dd69
rustdoc: use Set for ignored crates, instead of string matching
notriddle Apr 21, 2023
9d69ee0
rustdoc: lift constant string manipulation out of loop
notriddle Apr 21, 2023
0cd3874
rustdoc: clean up redundant search hiding results code
notriddle Apr 21, 2023
56613f8
More `IS_ZST` in `library`
scottmcm Apr 21, 2023
1d7a247
Print ty placeholders pretty
compiler-errors Apr 20, 2023
684bdf8
Rollup merge of #109949 - notriddle:notriddle/type-layout, r=jsha
JohnTitor Apr 22, 2023
9a798e4
Rollup merge of #110622 - WaffleLapkin:hashtag#, r=compiler-errors
JohnTitor Apr 22, 2023
581e741
Rollup merge of #110635 - scottmcm:zst-checks, r=the8472
JohnTitor Apr 22, 2023
18c16b5
Rollup merge of #110640 - glaubitz:m68k-baseline, r=oli-obk
JohnTitor Apr 22, 2023
617ecd2
Rollup merge of #110657 - miguelraz:cleanup-simplifycfg-refactor, r=c…
JohnTitor Apr 22, 2023
c8a3239
Rollup merge of #110659 - notriddle:notriddle/js-cleanup-20230421, r=…
JohnTitor Apr 22, 2023
16e2096
Rollup merge of #110660 - compiler-errors:placeholders-pretty, r=wesl…
JohnTitor Apr 22, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
rustdoc: format type layout template with newline after <p>
  • Loading branch information
notriddle committed Apr 18, 2023
commit e26ae9530b21288ea6f9ca73d8c8d895c47807c3
24 changes: 16 additions & 8 deletions src/librustdoc/html/templates/type_layout.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@ <h2 id="layout" class="small-section-header"> {# #}
</div> {# #}
<p><strong>Size:</strong> {{ type_layout_size|safe }}</p> {# #}
{% if !variants.is_empty() %}
<p><strong>Size for each variant:</strong></p> {# #}
<p> {# #}
<strong>Size for each variant:</strong> {# #}
</p> {# #}
<ul> {# #}
{% for (name, layout_size) in variants %}
<li> {# #}
Expand All @@ -29,17 +31,23 @@ <h2 id="layout" class="small-section-header"> {# #}
{# This kind of layout error can occur with valid code, e.g. if you try to
get the layout of a generic type such as `Vec<T>`. #}
{% when Err(LayoutError::Unknown(_)) %}
<p><strong>Note:</strong> Unable to compute type layout, {#+ #}
possibly due to this type having generic parameters. {#+ #}
Layout can only be computed for concrete, fully-instantiated types.</p> {# #}
<p> {# #}
<strong>Note:</strong> Unable to compute type layout, {#+ #}
possibly due to this type having generic parameters. {#+ #}
Layout can only be computed for concrete, fully-instantiated types. {# #}
</p> {# #}
{# This kind of error probably can't happen with valid code, but we don't
want to panic and prevent the docs from building, so we just let the
user know that we couldn't compute the layout. #}
{% when Err(LayoutError::SizeOverflow(_)) %}
<p><strong>Note:</strong> Encountered an error during type layout; {#+ #}
the type was too big.</p> {# #}
<p> {# #}
<strong>Note:</strong> Encountered an error during type layout; {#+ #}
the type was too big. {# #}
</p> {# #}
{% when Err(LayoutError::NormalizationFailure(_, _)) %}
<p><strong>Note:</strong> Encountered an error during type layout; {#+ #}
the type failed to be normalized.</p> {# #}
<p> {# #}
<strong>Note:</strong> Encountered an error during type layout; {#+ #}
the type failed to be normalized. {# #}
</p> {# #}
{% endmatch %}
</div> {# #}