Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/hir-ty/src/tests/regression.rs')
-rw-r--r--crates/hir-ty/src/tests/regression.rs29
1 files changed, 29 insertions, 0 deletions
diff --git a/crates/hir-ty/src/tests/regression.rs b/crates/hir-ty/src/tests/regression.rs
index 4f1480c393..f6736905b8 100644
--- a/crates/hir-ty/src/tests/regression.rs
+++ b/crates/hir-ty/src/tests/regression.rs
@@ -2645,3 +2645,32 @@ where
"#,
);
}
+
+#[test]
+fn issue_21560() {
+ check_no_mismatches(
+ r#"
+mod bindings {
+ use super::*;
+ pub type HRESULT = i32;
+}
+use bindings::*;
+
+
+mod error {
+ use super::*;
+ pub fn nonzero_hresult(hr: HRESULT) -> crate::HRESULT {
+ hr
+ }
+}
+pub use error::*;
+
+mod hresult {
+ use super::*;
+ pub struct HRESULT(pub i32);
+}
+pub use hresult::HRESULT;
+
+ "#,
+ );
+}