about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorGiles Cope <gilescope@gmail.com>2019-07-18 07:30:51 +0100
committerGiles Cope <gilescope@gmail.com>2019-07-18 07:30:51 +0100
commitc56c5a861a83cd72ceda6590194506daa91fad33 (patch)
treec97c8c89b1e07be2135b5a76070d27847a7a8f0b /src
parent387b6c3e782e61f979083ff960e6e18fcaa1fe2c (diff)
downloadrust-c56c5a861a83cd72ceda6590194506daa91fad33.tar.gz
rust-c56c5a861a83cd72ceda6590194506daa91fad33.zip
Self-referencial type renamed to recursive type.
Diffstat (limited to 'src')
-rw-r--r--src/librustc_typeck/check/mod.rs2
-rw-r--r--src/test/ui/async-await/recursive-async-impl-trait-type.stderr2
-rw-r--r--src/test/ui/impl-trait/issues/infinite-impl-trait-issue-38064.stderr4
-rw-r--r--src/test/ui/impl-trait/recursive-impl-trait-type.stderr28
4 files changed, 18 insertions, 18 deletions
diff --git a/src/librustc_typeck/check/mod.rs b/src/librustc_typeck/check/mod.rs
index d578a894add..ededcf9f83f 100644
--- a/src/librustc_typeck/check/mod.rs
+++ b/src/librustc_typeck/check/mod.rs
@@ -1320,7 +1320,7 @@ fn check_opaque<'tcx>(tcx: TyCtxt<'tcx>, def_id: DefId, substs: SubstsRef<'tcx>,
             tcx.sess, span, E0720,
             "opaque type expands to a recursive type",
         );
-        err.span_label(span, "expands to self-referential type");
+        err.span_label(span, "expands to a recursive type");
         if let ty::Opaque(..) = partially_expanded_type.sty {
             err.note("type resolves to itself");
         } else {
diff --git a/src/test/ui/async-await/recursive-async-impl-trait-type.stderr b/src/test/ui/async-await/recursive-async-impl-trait-type.stderr
index abc9ff54bde..69914b6a791 100644
--- a/src/test/ui/async-await/recursive-async-impl-trait-type.stderr
+++ b/src/test/ui/async-await/recursive-async-impl-trait-type.stderr
@@ -2,7 +2,7 @@ error[E0720]: opaque type expands to a recursive type
   --> $DIR/recursive-async-impl-trait-type.rs:7:40
    |
 LL | async fn recursive_async_function() -> () {
-   |                                        ^^ expands to self-referential type
+   |                                        ^^ expands to a recursive type
    |
    = note: expanded type is `std::future::GenFuture<[static generator@$DIR/recursive-async-impl-trait-type.rs:7:43: 9:2 {impl std::future::Future, ()}]>`
 
diff --git a/src/test/ui/impl-trait/issues/infinite-impl-trait-issue-38064.stderr b/src/test/ui/impl-trait/issues/infinite-impl-trait-issue-38064.stderr
index fb48ecd12b6..d10001e8a8e 100644
--- a/src/test/ui/impl-trait/issues/infinite-impl-trait-issue-38064.stderr
+++ b/src/test/ui/impl-trait/issues/infinite-impl-trait-issue-38064.stderr
@@ -2,7 +2,7 @@ error[E0720]: opaque type expands to a recursive type
   --> $DIR/infinite-impl-trait-issue-38064.rs:8:13
    |
 LL | fn foo() -> impl Quux {
-   |             ^^^^^^^^^ expands to self-referential type
+   |             ^^^^^^^^^ expands to a recursive type
    |
    = note: expanded type is `foo::Foo<bar::Bar<impl Quux>>`
 
@@ -10,7 +10,7 @@ error[E0720]: opaque type expands to a recursive type
   --> $DIR/infinite-impl-trait-issue-38064.rs:14:13
    |
 LL | fn bar() -> impl Quux {
-   |             ^^^^^^^^^ expands to self-referential type
+   |             ^^^^^^^^^ expands to a recursive type
    |
    = note: expanded type is `bar::Bar<foo::Foo<impl Quux>>`
 
diff --git a/src/test/ui/impl-trait/recursive-impl-trait-type.stderr b/src/test/ui/impl-trait/recursive-impl-trait-type.stderr
index fce234eb87c..324607117dc 100644
--- a/src/test/ui/impl-trait/recursive-impl-trait-type.stderr
+++ b/src/test/ui/impl-trait/recursive-impl-trait-type.stderr
@@ -2,7 +2,7 @@ error[E0720]: opaque type expands to a recursive type
   --> $DIR/recursive-impl-trait-type.rs:6:22
    |
 LL | fn option(i: i32) -> impl Sized {
-   |                      ^^^^^^^^^^ expands to self-referential type
+   |                      ^^^^^^^^^^ expands to a recursive type
    |
    = note: expanded type is `std::option::Option<(impl Sized, i32)>`
 
@@ -10,7 +10,7 @@ error[E0720]: opaque type expands to a recursive type
   --> $DIR/recursive-impl-trait-type.rs:14:15
    |
 LL | fn tuple() -> impl Sized {
-   |               ^^^^^^^^^^ expands to self-referential type
+   |               ^^^^^^^^^^ expands to a recursive type
    |
    = note: expanded type is `(impl Sized,)`
 
@@ -18,7 +18,7 @@ error[E0720]: opaque type expands to a recursive type
   --> $DIR/recursive-impl-trait-type.rs:18:15
    |
 LL | fn array() -> impl Sized {
-   |               ^^^^^^^^^^ expands to self-referential type
+   |               ^^^^^^^^^^ expands to a recursive type
    |
    = note: expanded type is `[impl Sized; 1]`
 
@@ -26,7 +26,7 @@ error[E0720]: opaque type expands to a recursive type
   --> $DIR/recursive-impl-trait-type.rs:22:13
    |
 LL | fn ptr() -> impl Sized {
-   |             ^^^^^^^^^^ expands to self-referential type
+   |             ^^^^^^^^^^ expands to a recursive type
    |
    = note: expanded type is `*const impl Sized`
 
@@ -34,7 +34,7 @@ error[E0720]: opaque type expands to a recursive type
   --> $DIR/recursive-impl-trait-type.rs:26:16
    |
 LL | fn fn_ptr() -> impl Sized {
-   |                ^^^^^^^^^^ expands to self-referential type
+   |                ^^^^^^^^^^ expands to a recursive type
    |
    = note: expanded type is `fn() -> impl Sized`
 
@@ -42,7 +42,7 @@ error[E0720]: opaque type expands to a recursive type
   --> $DIR/recursive-impl-trait-type.rs:30:25
    |
 LL | fn closure_capture() -> impl Sized {
-   |                         ^^^^^^^^^^ expands to self-referential type
+   |                         ^^^^^^^^^^ expands to a recursive type
    |
    = note: expanded type is `[closure@$DIR/recursive-impl-trait-type.rs:32:5: 32:19 x:impl Sized]`
 
@@ -50,7 +50,7 @@ error[E0720]: opaque type expands to a recursive type
   --> $DIR/recursive-impl-trait-type.rs:35:29
    |
 LL | fn closure_ref_capture() -> impl Sized {
-   |                             ^^^^^^^^^^ expands to self-referential type
+   |                             ^^^^^^^^^^ expands to a recursive type
    |
    = note: expanded type is `[closure@$DIR/recursive-impl-trait-type.rs:37:5: 37:20 x:impl Sized]`
 
@@ -58,7 +58,7 @@ error[E0720]: opaque type expands to a recursive type
   --> $DIR/recursive-impl-trait-type.rs:40:21
    |
 LL | fn closure_sig() -> impl Sized {
-   |                     ^^^^^^^^^^ expands to self-referential type
+   |                     ^^^^^^^^^^ expands to a recursive type
    |
    = note: expanded type is `[closure@$DIR/recursive-impl-trait-type.rs:41:5: 41:21]`
 
@@ -66,7 +66,7 @@ error[E0720]: opaque type expands to a recursive type
   --> $DIR/recursive-impl-trait-type.rs:44:23
    |
 LL | fn generator_sig() -> impl Sized {
-   |                       ^^^^^^^^^^ expands to self-referential type
+   |                       ^^^^^^^^^^ expands to a recursive type
    |
    = note: expanded type is `[closure@$DIR/recursive-impl-trait-type.rs:45:5: 45:23]`
 
@@ -74,7 +74,7 @@ error[E0720]: opaque type expands to a recursive type
   --> $DIR/recursive-impl-trait-type.rs:48:27
    |
 LL | fn generator_capture() -> impl Sized {
-   |                           ^^^^^^^^^^ expands to self-referential type
+   |                           ^^^^^^^^^^ expands to a recursive type
    |
    = note: expanded type is `[generator@$DIR/recursive-impl-trait-type.rs:50:5: 50:26 x:impl Sized {()}]`
 
@@ -82,7 +82,7 @@ error[E0720]: opaque type expands to a recursive type
   --> $DIR/recursive-impl-trait-type.rs:53:26
    |
 LL | fn substs_change<T>() -> impl Sized {
-   |                          ^^^^^^^^^^ expands to self-referential type
+   |                          ^^^^^^^^^^ expands to a recursive type
    |
    = note: expanded type is `(impl Sized,)`
 
@@ -90,7 +90,7 @@ error[E0720]: opaque type expands to a recursive type
   --> $DIR/recursive-impl-trait-type.rs:57:24
    |
 LL | fn generator_hold() -> impl Sized {
-   |                        ^^^^^^^^^^ expands to self-referential type
+   |                        ^^^^^^^^^^ expands to a recursive type
    |
    = note: expanded type is `[generator@$DIR/recursive-impl-trait-type.rs:58:5: 62:6 {impl Sized, ()}]`
 
@@ -98,7 +98,7 @@ error[E0720]: opaque type expands to a recursive type
   --> $DIR/recursive-impl-trait-type.rs:69:26
    |
 LL | fn mutual_recursion() -> impl Sync {
-   |                          ^^^^^^^^^ expands to self-referential type
+   |                          ^^^^^^^^^ expands to a recursive type
    |
    = note: type resolves to itself
 
@@ -106,7 +106,7 @@ error[E0720]: opaque type expands to a recursive type
   --> $DIR/recursive-impl-trait-type.rs:73:28
    |
 LL | fn mutual_recursion_b() -> impl Sized {
-   |                            ^^^^^^^^^^ expands to self-referential type
+   |                            ^^^^^^^^^^ expands to a recursive type
    |
    = note: type resolves to itself