Skip to content

Commit

Permalink
add regression test for #97589
Browse files Browse the repository at this point in the history
  • Loading branch information
dianne committed Sep 11, 2024
1 parent 9a7644e commit a187d0a
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
//@ error-pattern: circular modules
// Regression test for #97589: a doc-comment on a circular module bypassed cycle detection

#![crate_type = "lib"]

pub mod recursive;
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
error: circular modules: $DIR/recursive.rs -> $DIR/recursive.rs
--> $DIR/recursive.rs:6:1
|
LL | mod recursive;
| ^^^^^^^^^^^^^^

error: aborting due to 1 previous error

Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
//@ ignore-test: this is an auxiliary file for circular-module-with-doc-comment-issue-97589.rs

//! this comment caused the circular dependency checker to break
#[path = "recursive.rs"]
mod recursive;

0 comments on commit a187d0a

Please sign in to comment.