diff options
Diffstat (limited to '')
-rw-r--r-- | src/test/ui/issues/issue-26472.stderr | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/test/ui/issues/issue-26472.stderr b/src/test/ui/issues/issue-26472.stderr new file mode 100644 index 000000000..d7134bff1 --- /dev/null +++ b/src/test/ui/issues/issue-26472.stderr @@ -0,0 +1,20 @@ +error[E0616]: field `len` of struct `S` is private + --> $DIR/issue-26472.rs:11:15 + | +LL | let v = s.len; + | ^^^ private field + | +help: a method `len` also exists, call it with parentheses + | +LL | let v = s.len(); + | ++ + +error[E0616]: field `len` of struct `S` is private + --> $DIR/issue-26472.rs:12:7 + | +LL | s.len = v; + | ^^^ private field + +error: aborting due to 2 previous errors + +For more information about this error, try `rustc --explain E0616`. |