Commit 9ec4062
committed
Add a concrete Optional[T] = undef example to the style guide
Illustrate the "Optional parameters" guidance with chrony's smoothtime
parameter: declared Optional[String] = undef, and emitted in the config
template only when a value is set, so undef genuinely means the optional
feature is off.
Signed-off-by: Michael Harp <mike@mikeharp.com>1 parent 020f8a0 commit 9ec4062
1 file changed
Lines changed: 16 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
963 | 963 | | |
964 | 964 | | |
965 | 965 | | |
| 966 | + | |
| 967 | + | |
| 968 | + | |
| 969 | + | |
| 970 | + | |
| 971 | + | |
| 972 | + | |
| 973 | + | |
| 974 | + | |
| 975 | + | |
| 976 | + | |
| 977 | + | |
| 978 | + | |
| 979 | + | |
| 980 | + | |
| 981 | + | |
966 | 982 | | |
967 | 983 | | |
968 | 984 | | |
| |||
0 commit comments