Skip to content

In test suite, strange error-pattern behavior on lines with a * #2395

Closed
@catamorphism

Description

@catamorphism
// error-pattern: type cat cannot be dereferenced
class cat { new() {} }

fn main() {
  let kitty : cat = cat();
  log (error, *kitty);
}

This test fails correctly as is, but if I move the error pattern to be a //! ERROR comment on the same line with log (error, *kitty);, the test runner complains it didn't find the expected error pattern. As rustc reports the error on the correct line, I can only guess this has something to do with the asterisk in *kitty, but I'm not totally sure.

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-testsuiteArea: The testsuite used to check the correctness of rustc

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions