about summary refs log tree commit diff
path: root/src/test/rustdoc/struct-arg-pattern.rs
diff options
context:
space:
mode:
authorAliƩnore Bouttefeux <77335613+ABouttefeux@users.noreply.github.com>2021-04-05 21:13:29 +0200
committerGitHub <noreply@github.com>2021-04-05 21:13:29 +0200
commitb08b4848c3653818b47fa8cc0a613455c8b4d255 (patch)
treea9162fd1698833dc8cf9ef55af102be906df22d5 /src/test/rustdoc/struct-arg-pattern.rs
parent72f534aae1c6cca58b97957d6c225885fcdb4d1b (diff)
parent5a7a0ac51eefbdacc5b1763f8d49a787407afb34 (diff)
Merge branch 'master' into master
Diffstat (limited to 'src/test/rustdoc/struct-arg-pattern.rs')
-rw-r--r--src/test/rustdoc/struct-arg-pattern.rs10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/test/rustdoc/struct-arg-pattern.rs b/src/test/rustdoc/struct-arg-pattern.rs
new file mode 100644
index 00000000000..3c0369e3d34
--- /dev/null
+++ b/src/test/rustdoc/struct-arg-pattern.rs
@@ -0,0 +1,10 @@
+#![crate_name = "foo"]
+
+struct BodyId {
+    hir_id: usize,
+}
+
+// @has 'foo/fn.body_owner.html' '//*[@class="rust fn"]' 'pub fn body_owner(_: BodyId)'
+pub fn body_owner(BodyId { hir_id }: BodyId) {
+    // ...
+}