Skip to content

Commit 2f1ecb9

Browse files
committed
doc UPDATE mention how to process default values
1 parent 4efd2d6 commit 2f1ecb9

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/tree_schema.h

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1635,7 +1635,7 @@ struct lysc_node_leaf {
16351635
struct lysc_type *type; /**< type of the leaf node (mandatory) */
16361636

16371637
const char *units; /**< units of the leaf's type */
1638-
struct lysc_value dflt; /**< default value */
1638+
struct lysc_value dflt; /**< default value, use ::lyd_value_validate_dflt() to get real type and canonical value */
16391639
};
16401640

16411641
struct lysc_node_leaflist {
@@ -1666,7 +1666,8 @@ struct lysc_node_leaflist {
16661666
struct lysc_type *type; /**< type of the leaf node (mandatory) */
16671667

16681668
const char *units; /**< units of the leaf's type */
1669-
struct lysc_value *dflts; /**< list ([sized array](@ref sizedarrays)) of default values */
1669+
struct lysc_value *dflts; /**< list ([sized array](@ref sizedarrays)) of default values, use
1670+
::lyd_value_validate_dflt() to get real type and canonical values */
16701671

16711672
uint32_t min; /**< min-elements constraint */
16721673
uint32_t max; /**< max-elements constraint */

0 commit comments

Comments
 (0)