Files
rust/tests
许杰友 Jieyou Xu (Joe) 772f42b5b7 Rollup merge of #156450 - Zalathar:colon-or-not, r=jieyouxu
compiletest: Enforce that directives are consistently used with or without a colon

With the notable exception of `//@ pp-exact`, all directives expect to either always be used *with* a colon, or always be used *without* a colon. For example:

- `//@ uses-colon: value`
- `//@ no-colon` or `//@ no-colon (remark)`

Currently we just silently discard directives that use the wrong syntax, which is not great.

This PR therefore makes `parse_name_directive` and `parse_name_value_directive` panic if the wrong syntax is encountered.

The parser for `pp-exact` has been adjusted to check for the colon before deciding which parse method to call.

r? jieyouxu
2026-05-14 13:24:33 +08:00
..