cached 3.0.0

Generic cache implementations and simplified function memoization
Documentation
1
2
3
4
5
6
7
error: unable to parse `key` as a type: unexpected token; `key` must be a Rust type, e.g. `key = "String"` or `key = "(u32, String)"`
 --> tests/ui/cached_key_unparseable.rs:3:1
  |
3 | #[cached(key = "not a type !!", convert = "{ k }")]
  | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  |
  = note: this error originates in the attribute macro `cached` (in Nightly builds, run with -Z macro-backtrace for more info)