fork/rust
git clone https://git.julia.blue/fork/rust
4560ea788cb
1.39.0
1error[E0423]: expected value, found enum `n::Z` 2 --> $DIR/privacy-enum-ctor.rs:23:9 3 | 4LL | n::Z; 5 | ^^^^ 6help: try using one of the enum's variants 7 | 8LL | m::Z::Fn; 9 | ^^^^^^^^ 10LL | m::Z::Struct; 11 | ^^^^^^^^^^^^ 12LL | m::Z::Unit; 13 | ^^^^^^^^^^ 14 15error[E0423]: expected value, found enum `Z` 16 --> $DIR/privacy-enum-ctor.rs:25:9 17 | 18LL | Z; 19 | ^ 20help: a function with a similar name exists 21 | 22LL | f; 23 | ^ 24help: try using one of the enum's variants 25 | 26LL | m::Z::Fn; 27 | ^^^^^^^^ 28LL | m::Z::Struct; 29 | ^^^^^^^^^^^^ 30LL | m::Z::Unit; 31 | ^^^^^^^^^^ 32 33error[E0423]: expected value, found struct variant `Z::Struct` 34 --> $DIR/privacy-enum-ctor.rs:29:20 35 | 36LL | let _: Z = Z::Struct; 37 | ^^^^^^^^^ did you mean `Z::Struct { /* fields */ }`? 38 39error[E0423]: expected value, found enum `m::E` 40 --> $DIR/privacy-enum-ctor.rs:41:16 41 | 42LL | let _: E = m::E; 43 | ^^^^ 44help: a function with a similar name exists 45 | 46LL | let _: E = m::f; 47 | ^ 48help: try using one of the enum's variants 49 | 50LL | let _: E = E::Fn; 51 | ^^^^^ 52LL | let _: E = E::Struct; 53 | ^^^^^^^^^ 54LL | let _: E = E::Unit; 55 | ^^^^^^^ 56help: possible better candidates are found in other modules, you can import them into scope 57 | 58LL | use std::f32::consts::E; 59 | 60LL | use std::f64::consts::E; 61 | 62 63error[E0423]: expected value, found struct variant `m::E::Struct` 64 --> $DIR/privacy-enum-ctor.rs:45:16 65 | 66LL | let _: E = m::E::Struct; 67 | ^^^^^^^^^^^^ did you mean `m::E::Struct { /* fields */ }`? 68 69error[E0423]: expected value, found enum `E` 70 --> $DIR/privacy-enum-ctor.rs:49:16 71 | 72LL | let _: E = E; 73 | ^ 74help: try using one of the enum's variants 75 | 76LL | let _: E = E::Fn; 77 | ^^^^^ 78LL | let _: E = E::Struct; 79 | ^^^^^^^^^ 80LL | let _: E = E::Unit; 81 | ^^^^^^^ 82help: possible better candidates are found in other modules, you can import them into scope 83 | 84LL | use std::f32::consts::E; 85 | 86LL | use std::f64::consts::E; 87 | 88 89error[E0423]: expected value, found struct variant `E::Struct` 90 --> $DIR/privacy-enum-ctor.rs:53:16 91 | 92LL | let _: E = E::Struct; 93 | ^^^^^^^^^ did you mean `E::Struct { /* fields */ }`? 94 95error[E0412]: cannot find type `Z` in this scope 96 --> $DIR/privacy-enum-ctor.rs:57:12 97 | 98LL | let _: Z = m::n::Z; 99 | ^ 100help: an enum with a similar name exists 101 | 102LL | let _: E = m::n::Z; 103 | ^ 104help: possible candidate is found in another module, you can import it into scope 105 | 106LL | use m::n::Z; 107 | 108 109error[E0423]: expected value, found enum `m::n::Z` 110 --> $DIR/privacy-enum-ctor.rs:57:16 111 | 112LL | let _: Z = m::n::Z; 113 | ^^^^^^^ 114help: try using one of the enum's variants 115 | 116LL | let _: Z = m::Z::Fn; 117 | ^^^^^^^^ 118LL | let _: Z = m::Z::Struct; 119 | ^^^^^^^^^^^^ 120LL | let _: Z = m::Z::Unit; 121 | ^^^^^^^^^^ 122 123error[E0412]: cannot find type `Z` in this scope 124 --> $DIR/privacy-enum-ctor.rs:61:12 125 | 126LL | let _: Z = m::n::Z::Fn; 127 | ^ 128help: an enum with a similar name exists 129 | 130LL | let _: E = m::n::Z::Fn; 131 | ^ 132help: possible candidate is found in another module, you can import it into scope 133 | 134LL | use m::n::Z; 135 | 136 137error[E0412]: cannot find type `Z` in this scope 138 --> $DIR/privacy-enum-ctor.rs:64:12 139 | 140LL | let _: Z = m::n::Z::Struct; 141 | ^ 142help: an enum with a similar name exists 143 | 144LL | let _: E = m::n::Z::Struct; 145 | ^ 146help: possible candidate is found in another module, you can import it into scope 147 | 148LL | use m::n::Z; 149 | 150 151error[E0423]: expected value, found struct variant `m::n::Z::Struct` 152 --> $DIR/privacy-enum-ctor.rs:64:16 153 | 154LL | let _: Z = m::n::Z::Struct; 155 | ^^^^^^^^^^^^^^^ did you mean `m::n::Z::Struct { /* fields */ }`? 156 157error[E0412]: cannot find type `Z` in this scope 158 --> $DIR/privacy-enum-ctor.rs:68:12 159 | 160LL | let _: Z = m::n::Z::Unit {}; 161 | ^ 162help: an enum with a similar name exists 163 | 164LL | let _: E = m::n::Z::Unit {}; 165 | ^ 166help: possible candidate is found in another module, you can import it into scope 167 | 168LL | use m::n::Z; 169 | 170 171error[E0603]: enum `Z` is private 172 --> $DIR/privacy-enum-ctor.rs:57:22 173 | 174LL | let _: Z = m::n::Z; 175 | ^ 176 177error[E0603]: enum `Z` is private 178 --> $DIR/privacy-enum-ctor.rs:61:22 179 | 180LL | let _: Z = m::n::Z::Fn; 181 | ^ 182 183error[E0603]: enum `Z` is private 184 --> $DIR/privacy-enum-ctor.rs:64:22 185 | 186LL | let _: Z = m::n::Z::Struct; 187 | ^ 188 189error[E0603]: enum `Z` is private 190 --> $DIR/privacy-enum-ctor.rs:68:22 191 | 192LL | let _: Z = m::n::Z::Unit {}; 193 | ^ 194 195error[E0308]: mismatched types 196 --> $DIR/privacy-enum-ctor.rs:27:20 197 | 198LL | Fn(u8), 199 | ------ fn(u8) -> m::n::Z {m::n::Z::Fn} defined here 200... 201LL | let _: Z = Z::Fn; 202 | ^^^^^ 203 | | 204 | expected enum `m::n::Z`, found fn item 205 | help: use parentheses to instantiate this tuple variant: `Z::Fn(_)` 206 | 207 = note: expected type `m::n::Z` 208 found type `fn(u8) -> m::n::Z {m::n::Z::Fn}` 209 210error[E0618]: expected function, found enum variant `Z::Unit` 211 --> $DIR/privacy-enum-ctor.rs:31:17 212 | 213LL | Unit, 214 | ---- `Z::Unit` defined here 215... 216LL | let _ = Z::Unit(); 217 | ^^^^^^^-- 218 | | 219 | call expression requires function 220help: `Z::Unit` is a unit variant, you need to write it without the parenthesis 221 | 222LL | let _ = Z::Unit; 223 | ^^^^^^^ 224 225error[E0308]: mismatched types 226 --> $DIR/privacy-enum-ctor.rs:43:16 227 | 228LL | Fn(u8), 229 | ------ fn(u8) -> m::E {m::E::Fn} defined here 230... 231LL | let _: E = m::E::Fn; 232 | ^^^^^^^^ 233 | | 234 | expected enum `m::E`, found fn item 235 | help: use parentheses to instantiate this tuple variant: `m::E::Fn(_)` 236 | 237 = note: expected type `m::E` 238 found type `fn(u8) -> m::E {m::E::Fn}` 239 240error[E0618]: expected function, found enum variant `m::E::Unit` 241 --> $DIR/privacy-enum-ctor.rs:47:16 242 | 243LL | Unit, 244 | ---- `m::E::Unit` defined here 245... 246LL | let _: E = m::E::Unit(); 247 | ^^^^^^^^^^-- 248 | | 249 | call expression requires function 250help: `m::E::Unit` is a unit variant, you need to write it without the parenthesis 251 | 252LL | let _: E = m::E::Unit; 253 | ^^^^^^^^^^ 254 255error[E0308]: mismatched types 256 --> $DIR/privacy-enum-ctor.rs:51:16 257 | 258LL | Fn(u8), 259 | ------ fn(u8) -> m::E {m::E::Fn} defined here 260... 261LL | let _: E = E::Fn; 262 | ^^^^^ 263 | | 264 | expected enum `m::E`, found fn item 265 | help: use parentheses to instantiate this tuple variant: `E::Fn(_)` 266 | 267 = note: expected type `m::E` 268 found type `fn(u8) -> m::E {m::E::Fn}` 269 270error[E0618]: expected function, found enum variant `E::Unit` 271 --> $DIR/privacy-enum-ctor.rs:55:16 272 | 273LL | Unit, 274 | ---- `E::Unit` defined here 275... 276LL | let _: E = E::Unit(); 277 | ^^^^^^^-- 278 | | 279 | call expression requires function 280help: `E::Unit` is a unit variant, you need to write it without the parenthesis 281 | 282LL | let _: E = E::Unit; 283 | ^^^^^^^ 284 285error: aborting due to 23 previous errors 286 287Some errors have detailed explanations: E0308, E0412, E0423, E0603, E0618. 288For more information about an error, try `rustc --explain E0308`.