Skip to content

Commit fee6175

Browse files
committed
schema tree OPTIMIZE refactor enum to start at 0 instead of -1
Then it can be optimized with PACKED attribute.
1 parent 101658e commit fee6175

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/tree_schema.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -814,7 +814,6 @@ struct lys_submodule {
814814
* @brief YANG built-in types
815815
*/
816816
typedef enum {
817-
LY_TYPE_UNKNOWN = -1, /**< Unknown type (used in edit-config leaves) */
818817
LY_TYPE_DER = 0, /**< Derived type */
819818
LY_TYPE_BINARY, /**< Any binary data ([RFC 6020 sec 9.8](http://tools.ietf.org/html/rfc6020#section-9.8)) */
820819
LY_TYPE_BITS, /**< A set of bits or flags ([RFC 6020 sec 9.7](http://tools.ietf.org/html/rfc6020#section-9.7)) */
@@ -835,6 +834,7 @@ typedef enum {
835834
LY_TYPE_UINT32, /**< 32-bit unsigned integer ([RFC 6020 sec 9.2](http://tools.ietf.org/html/rfc6020#section-9.2)) */
836835
LY_TYPE_INT64, /**< 64-bit signed integer ([RFC 6020 sec 9.2](http://tools.ietf.org/html/rfc6020#section-9.2)) */
837836
LY_TYPE_UINT64, /**< 64-bit unsigned integer ([RFC 6020 sec 9.2](http://tools.ietf.org/html/rfc6020#section-9.2)) */
837+
LY_TYPE_UNKNOWN, /**< Unknown type (used in edit-config leaves) */
838838
} LY_DATA_TYPE;
839839
#define LY_DATA_TYPE_COUNT 20 /**< Number of different types */
840840

0 commit comments

Comments
 (0)