salvo-rs/salvo

0.71.1: cannot call non-const fn `Identity::new` in constant functions

Closed this issue · 2 comments

Describe the bug
when compiling I get error (rustc 1.80.1, cargo 1.80.1):

cannot call non-const fn `Identity::new` in constant functions
src\index.crates.io-6f17d22bba15001f\tower-0.5.0\src\builder\mod.rs:120:20

To Reproduce
Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior
to compile with

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: win 11
  • Browser [e.g. chrome, safari]
  • Version [e.g. 22]

Additional context
working with salvo 0.6

Try to run cargo update will fix it.

@chrislearn thx, it works