summaryrefslogtreecommitdiffstats
path: root/src/test/ui/resolve/privacy-enum-ctor.stderr
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/ui/resolve/privacy-enum-ctor.stderr')
-rw-r--r--src/test/ui/resolve/privacy-enum-ctor.stderr90
1 files changed, 30 insertions, 60 deletions
diff --git a/src/test/ui/resolve/privacy-enum-ctor.stderr b/src/test/ui/resolve/privacy-enum-ctor.stderr
index 82a4211f0..d734fa76b 100644
--- a/src/test/ui/resolve/privacy-enum-ctor.stderr
+++ b/src/test/ui/resolve/privacy-enum-ctor.stderr
@@ -19,12 +19,10 @@ help: you might have meant to use the following enum variant
|
LL | m::Z::Unit;
| ~~~~~~~~~~
-help: alternatively, the following enum variants are also available
+help: alternatively, the following enum variant is available
|
LL | (m::Z::Fn(/* fields */));
| ~~~~~~~~~~~~~~~~~~~~~~~~
-LL | (m::Z::Struct { /* fields */ });
- | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
error[E0423]: expected value, found enum `Z`
--> $DIR/privacy-enum-ctor.rs:25:9
@@ -47,23 +45,10 @@ help: you might have meant to use the following enum variant
|
LL | m::Z::Unit;
| ~~~~~~~~~~
-help: alternatively, the following enum variants are also available
+help: alternatively, the following enum variant is available
|
LL | (m::Z::Fn(/* fields */));
| ~~~~~~~~~~~~~~~~~~~~~~~~
-LL | (m::Z::Struct { /* fields */ });
- | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
-error[E0423]: expected value, found struct variant `Z::Struct`
- --> $DIR/privacy-enum-ctor.rs:29:20
- |
-LL | / Struct {
-LL | | s: u8,
-LL | | },
- | |_____________- `Z::Struct` defined here
-...
-LL | let _: Z = Z::Struct;
- | ^^^^^^^^^ help: use struct literal syntax instead: `Z::Struct { s: val }`
error[E0423]: expected value, found enum `m::E`
--> $DIR/privacy-enum-ctor.rs:41:16
@@ -89,12 +74,10 @@ help: you might have meant to use the following enum variant
|
LL | let _: E = E::Unit;
| ~~~~~~~
-help: alternatively, the following enum variants are also available
+help: alternatively, the following enum variant is available
|
LL | let _: E = (E::Fn(/* fields */));
| ~~~~~~~~~~~~~~~~~~~~~
-LL | let _: E = (E::Struct { /* fields */ });
- | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
help: a function with a similar name exists
|
LL | let _: E = m::f;
@@ -111,17 +94,6 @@ LL - let _: E = m::E;
LL + let _: E = E;
|
-error[E0423]: expected value, found struct variant `m::E::Struct`
- --> $DIR/privacy-enum-ctor.rs:45:16
- |
-LL | / Struct {
-LL | | s: u8,
-LL | | },
- | |_________- `m::E::Struct` defined here
-...
-LL | let _: E = m::E::Struct;
- | ^^^^^^^^^^^^ help: use struct literal syntax instead: `m::E::Struct { s: val }`
-
error[E0423]: expected value, found enum `E`
--> $DIR/privacy-enum-ctor.rs:49:16
|
@@ -143,12 +115,10 @@ help: you might have meant to use the following enum variant
|
LL | let _: E = E::Unit;
| ~~~~~~~
-help: alternatively, the following enum variants are also available
+help: alternatively, the following enum variant is available
|
LL | let _: E = (E::Fn(/* fields */));
| ~~~~~~~~~~~~~~~~~~~~~
-LL | let _: E = (E::Struct { /* fields */ });
- | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
help: consider importing one of these items instead
|
LL | use std::f32::consts::E;
@@ -156,17 +126,6 @@ LL | use std::f32::consts::E;
LL | use std::f64::consts::E;
|
-error[E0423]: expected value, found struct variant `E::Struct`
- --> $DIR/privacy-enum-ctor.rs:53:16
- |
-LL | / Struct {
-LL | | s: u8,
-LL | | },
- | |_________- `E::Struct` defined here
-...
-LL | let _: E = E::Struct;
- | ^^^^^^^^^ help: use struct literal syntax instead: `E::Struct { s: val }`
-
error[E0412]: cannot find type `Z` in this scope
--> $DIR/privacy-enum-ctor.rs:57:12
|
@@ -203,12 +162,10 @@ help: you might have meant to use the following enum variant
|
LL | let _: Z = m::Z::Unit;
| ~~~~~~~~~~
-help: alternatively, the following enum variants are also available
+help: alternatively, the following enum variant is available
|
LL | let _: Z = (m::Z::Fn(/* fields */));
| ~~~~~~~~~~~~~~~~~~~~~~~~
-LL | let _: Z = (m::Z::Struct { /* fields */ });
- | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
error[E0412]: cannot find type `Z` in this scope
--> $DIR/privacy-enum-ctor.rs:61:12
@@ -240,17 +197,6 @@ note: enum `m::Z` exists but is inaccessible
LL | pub(in m) enum Z {
| ^^^^^^^^^^^^^^^^ not accessible
-error[E0423]: expected value, found struct variant `m::n::Z::Struct`
- --> $DIR/privacy-enum-ctor.rs:64:16
- |
-LL | / Struct {
-LL | | s: u8,
-LL | | },
- | |_____________- `m::n::Z::Struct` defined here
-...
-LL | let _: Z = m::n::Z::Struct;
- | ^^^^^^^^^^^^^^^ help: use struct literal syntax instead: `m::n::Z::Struct { s: val }`
-
error[E0412]: cannot find type `Z` in this scope
--> $DIR/privacy-enum-ctor.rs:68:12
|
@@ -332,6 +278,12 @@ help: use parentheses to construct this tuple variant
LL | let _: Z = Z::Fn(/* u8 */);
| ++++++++++
+error[E0533]: expected value, found struct variant `Z::Struct`
+ --> $DIR/privacy-enum-ctor.rs:29:20
+ |
+LL | let _: Z = Z::Struct;
+ | ^^^^^^^^^ not a value
+
error[E0618]: expected function, found enum variant `Z::Unit`
--> $DIR/privacy-enum-ctor.rs:31:17
|
@@ -367,6 +319,12 @@ help: use parentheses to construct this tuple variant
LL | let _: E = m::E::Fn(/* u8 */);
| ++++++++++
+error[E0533]: expected value, found struct variant `m::E::Struct`
+ --> $DIR/privacy-enum-ctor.rs:45:16
+ |
+LL | let _: E = m::E::Struct;
+ | ^^^^^^^^^^^^ not a value
+
error[E0618]: expected function, found enum variant `m::E::Unit`
--> $DIR/privacy-enum-ctor.rs:47:16
|
@@ -402,6 +360,12 @@ help: use parentheses to construct this tuple variant
LL | let _: E = E::Fn(/* u8 */);
| ++++++++++
+error[E0533]: expected value, found struct variant `E::Struct`
+ --> $DIR/privacy-enum-ctor.rs:53:16
+ |
+LL | let _: E = E::Struct;
+ | ^^^^^^^^^ not a value
+
error[E0618]: expected function, found enum variant `E::Unit`
--> $DIR/privacy-enum-ctor.rs:55:16
|
@@ -419,7 +383,13 @@ LL - let _: E = E::Unit();
LL + let _: E = E::Unit;
|
+error[E0533]: expected value, found struct variant `m::n::Z::Struct`
+ --> $DIR/privacy-enum-ctor.rs:64:16
+ |
+LL | let _: Z = m::n::Z::Struct;
+ | ^^^^^^^^^^^^^^^ not a value
+
error: aborting due to 23 previous errors
-Some errors have detailed explanations: E0308, E0412, E0423, E0603, E0618.
+Some errors have detailed explanations: E0308, E0412, E0423, E0533, E0603, E0618.
For more information about an error, try `rustc --explain E0308`.