@@ -77,17 +77,19 @@ use syn::{parse_quote, Error, Result};
77
77
/// }
78
78
/// ```
79
79
///
80
- /// # Disabling memoization
81
- /// If you want to disable memoization for a function, you can use the `enabled`
82
- /// attribute to conditionally enable or disable memoization. This is useful for
83
- /// situations where small calls are more expensive than recomputing the result.
84
- /// This allows you to bypass hashing and caching while still dealing with the
85
- /// same function signature. And allows saving memory and time.
86
- ///
87
- /// By default, all functions are memoized. To disable memoization, you must
88
- /// specify an `enabled = <expr>` attribute. The expression must evaluate to a
89
- /// boolean value. If the expression is `false`, the function will be executed
90
- /// without hashing and caching.
80
+ /// # Disabling memoization conditionally
81
+ /// If you want to enable or disable memoization for a function conditionally,
82
+ /// you can use the `enabled` attribute. This is useful for cheap function calls
83
+ /// where dealing with the caching is more expensive than recomputing the
84
+ /// result. This allows you to bypass hashing and constraint validation while
85
+ /// still dealing with the same function signature. And allows saving memory and
86
+ /// time.
87
+ ///
88
+ /// By default, all functions are unconditionally memoized. To disable
89
+ /// memoization conditionally, you must specify an `enabled = <expr>` attribute.
90
+ /// The expression can use the parameters and must evaluate to a boolean value.
91
+ /// If the expression is `false`, the function will be executed without hashing
92
+ /// and caching.
91
93
///
92
94
/// ## Example
93
95
/// ```
0 commit comments