3

Hey I am facing this error

error[E0658]: let...else statements are unstable
   --> /home/asus/.cargo/registry/src/github.com-1ecc6299db9ec823/solana-frozen-abi-macro-1.16.0/src/lib.rs:422:5
    |
422 | /     let Some(expected_digest) = expected_digest else {
423 | |         return Error::new_spanned(
424 | |             TokenStream2::from(item),
425 | |             "the required \"digest\" = ... attribute is missing.",
...   |
428 | |         .into()
429 | |     };
    | |______^
    |
    = note: see issue #87335 <https://github.com/rust-lang/rust/issues/87335> for more information
    = help: add #![feature(let_else)] to the crate attributes to enable

For more information about this error, try rustc --explain E0658.
error: could not compile solana-frozen-abi-macro due to previous error
warning: build failed, waiting for other jobs to finish...

While running to build my program using 'cargo build-bpf'

3
  • I have fixed this error.
    – Pankaj
    Commented Jun 12, 2023 at 9:01
  • 1
    Would you mind putting your solution as an answer to the question? Stackexchange allows you to answer your own question + mark it as the answer. Then if anyone comes across this post in future they'll be able to see how you fixed it :)
    – Callum M
    Commented Jun 12, 2023 at 10:06
  • 1
    @Pankaj I'm having the same error, would you mind sharing the fix?
    – beeman
    Commented Jun 13, 2023 at 5:02

1 Answer 1

6

This will be fixed if you update your solana-cli version.

Update to 1.16.0 by running:

solana-install init 1.16.0
2
  • 1
    Thanks! That fixes it for me!
    – beeman
    Commented Jun 13, 2023 at 12:19
  • Doesn't work for me at either 1.16.0 or 1.16.1 Commented Jun 20, 2023 at 17:25

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.