aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_hir_ty/src/tests/traits.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_hir_ty/src/tests/traits.rs')
-rw-r--r--crates/ra_hir_ty/src/tests/traits.rs17
1 files changed, 17 insertions, 0 deletions
diff --git a/crates/ra_hir_ty/src/tests/traits.rs b/crates/ra_hir_ty/src/tests/traits.rs
index 08d1bf044..0bc72644a 100644
--- a/crates/ra_hir_ty/src/tests/traits.rs
+++ b/crates/ra_hir_ty/src/tests/traits.rs
@@ -1016,6 +1016,23 @@ fn test() {
1016} 1016}
1017 1017
1018#[test] 1018#[test]
1019fn error_bound_chalk() {
1020 let t = type_at(
1021 r#"
1022//- /main.rs
1023trait Trait {
1024 fn foo(&self) -> u32 {}
1025}
1026
1027fn test(x: (impl Trait + UnknownTrait)) {
1028 x.foo()<|>;
1029}
1030"#,
1031 );
1032 assert_eq!(t, "u32");
1033}
1034
1035#[test]
1019fn assoc_type_bindings() { 1036fn assoc_type_bindings() {
1020 assert_snapshot!( 1037 assert_snapshot!(
1021 infer(r#" 1038 infer(r#"