diff options
| author | Laurenz <laurmaedje@gmail.com> | 2023-05-17 14:41:46 +0200 |
|---|---|---|
| committer | Laurenz <laurmaedje@gmail.com> | 2023-05-17 14:41:46 +0200 |
| commit | 551ea99d05166b0be50792f767ddd38b996e32fa (patch) | |
| tree | ec5e86a087e79e8c181c7d4b904216a775227e2d /src/eval/cast.rs | |
| parent | 46aace78ac4ac1c075b9b1670dbb7372df1a0a82 (diff) | |
Show default values in documentation
Fixes #169
Fixes #1102
Diffstat (limited to 'src/eval/cast.rs')
| -rw-r--r-- | src/eval/cast.rs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/eval/cast.rs b/src/eval/cast.rs index b85d6e76..7ef2f1d0 100644 --- a/src/eval/cast.rs +++ b/src/eval/cast.rs @@ -230,6 +230,12 @@ impl<T: Cast> Cast for Option<T> { } } +impl<T: Into<Value>> From<Spanned<T>> for Value { + fn from(spanned: Spanned<T>) -> Self { + spanned.v.into() + } +} + impl<T: Into<Value>> From<Option<T>> for Value { fn from(v: Option<T>) -> Self { match v { |
