about summary refs log tree commit diff
path: root/src/librustdoc
diff options
context:
space:
mode:
authorStuart Cook <Zalathar@users.noreply.github.com>2025-09-25 20:31:53 +1000
committerGitHub <noreply@github.com>2025-09-25 20:31:53 +1000
commitfab06469ee33664739620ede53ed18b8c3c40644 (patch)
tree5f85a5e611ced8d3b35ad3498d8359e2e2df44c5 /src/librustdoc
parent0a34928ad840f9d66d673a8cb6cf293e83efb987 (diff)
parent60548ffaa3dafec019e52f39ab7a075d3f11e24e (diff)
downloadrust-fab06469ee33664739620ede53ed18b8c3c40644.tar.gz
rust-fab06469ee33664739620ede53ed18b8c3c40644.zip
Rollup merge of #146667 - calebzulawski:simd-mono-lane-limit, r=lcnr,RalfJung
Add an attribute to check the number of lanes in a SIMD vector after monomorphization

Allows std::simd to drop the `LaneCount<N>: SupportedLaneCount` trait and maintain good error messages.

Also, extends rust-lang/rust#145967 by including spans in layout errors for all ADTs.

r? ``@RalfJung``

cc ``@workingjubilee`` ``@programmerjake``
Diffstat (limited to 'src/librustdoc')
-rw-r--r--src/librustdoc/html/templates/type_layout.html5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/librustdoc/html/templates/type_layout.html b/src/librustdoc/html/templates/type_layout.html
index 0034552bdd3..49153d58fe9 100644
--- a/src/librustdoc/html/templates/type_layout.html
+++ b/src/librustdoc/html/templates/type_layout.html
@@ -65,5 +65,10 @@
             <strong>Note:</strong> Encountered an error during type layout; {#+ #}
             the type's layout depended on the type's layout itself. {# #}
         </p>
+        {% when Err(LayoutError::InvalidSimd {..}) %}
+        <p> {# #}
+            <strong>Note:</strong> Encountered an error during type layout; {#+ #}
+            the vector type had zero elements or too many elements. {# #}
+        </p>
         {% endmatch %}
 </div> {# #}