about summary refs log tree commit diff
path: root/tests/rustdoc-json
diff options
context:
space:
mode:
authorChris Denton <chris@chrisdenton.dev>2025-04-21 18:53:19 +0000
committerGitHub <noreply@github.com>2025-04-21 18:53:19 +0000
commitdf9e15e69f855b94776d5500e2f986952ed93f0a (patch)
tree5dc088d4fd92034517f75d8c78cc2dfe6892cad4 /tests/rustdoc-json
parenta37f4236cd5aa8bb8774aac1347efecb26388aa1 (diff)
parentfd4a093a4e9319fa1dc6603ea4ba5a5703ef5009 (diff)
downloadrust-df9e15e69f855b94776d5500e2f986952ed93f0a.tar.gz
rust-df9e15e69f855b94776d5500e2f986952ed93f0a.zip
Rollup merge of #140076 - aDotInTheVoid:jsondocline, r=GuillaumeGomez
jsondocck: Require command is at start of line

In one place we use `///``@``` instead of `//``@`.`` The test-runner allowed it, but it probably shouldn't. Ran into by ``@lolbinarycat`` in https://github.com/rust-lang/rust/pull/132748#issuecomment-2816469322:

```
error: unknown disambiguator `?(`
##[error] --> /checkout/tests/rustdoc-json/fns/return_type_alias.rs:3:25
  |
3 | ///@ set foo = "$.index[?(``@.name=='Foo')].id"``
  |                         ^^
  |
```

Maybe it's also worth erroring on this like we added in #137103

r? ``@GuillaumeGomez``
Diffstat (limited to 'tests/rustdoc-json')
-rw-r--r--tests/rustdoc-json/fns/return_type_alias.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/rustdoc-json/fns/return_type_alias.rs b/tests/rustdoc-json/fns/return_type_alias.rs
index 0aa1db47b7f..c39abc75894 100644
--- a/tests/rustdoc-json/fns/return_type_alias.rs
+++ b/tests/rustdoc-json/fns/return_type_alias.rs
@@ -1,6 +1,6 @@
 // Regression test for <https://github.com/rust-lang/rust/issues/104851>
 
-///@ set foo = "$.index[?(@.name=='Foo')].id"
+//@ set foo = "$.index[?(@.name=='Foo')].id"
 pub type Foo = i32;
 
 //@ is "$.index[?(@.name=='demo')].inner.function.sig.output.resolved_path.id" $foo