tree REFACTOR basic adjustments based on new strict ordering

Redundant functions removed, it is no longer
needed to search data siblings without hashes,
ever. But a macro was added for easier iterating
over all instances of a schema node.
diff --git a/src/tree.h b/src/tree.h
index 11df43d..0fe7264 100644
--- a/src/tree.h
+++ b/src/tree.h
@@ -134,6 +134,31 @@
          (ELEM) = (NEXT))
 
 /**
+ * @brief Macro to iterate via all schema node data instances in data siblings.
+ *
+ * @param START Pointer to the starting sibling. Even if it is not first, all the siblings are searched.
+ * @param SCHEMA Schema node of the searched instances.
+ * @param ELEM Iterator.
+ */
+#define LYD_LIST_FOR_INST(START, SCHEMA, ELEM) \
+    for (lyd_find_sibling_val(START, SCHEMA, NULL, 0, &(ELEM)); \
+         (ELEM) && ((ELEM)->schema == (SCHEMA)); \
+         (ELEM) = (ELEM)->next)
+
+/**
+ * @brief Macro to iterate via all schema node data instances in data siblings allowing to modify the list itself.
+ *
+ * @param START Pointer to the starting sibling. Even if it is not first, all the siblings are searched.
+ * @param SCHEMA Schema node of the searched instances.
+ * @param NEXT Temporary storage to allow removing of the current iterator content.
+ * @param ELEM Iterator.
+ */
+#define LYD_LIST_FOR_INST_SAFE(START, SCHEMA, NEXT, ELEM) \
+    for (lyd_find_sibling_val(START, SCHEMA, NULL, 0, &(ELEM)); \
+         (ELEM) && ((ELEM)->schema == (SCHEMA)) ? ((NEXT) = (ELEM)->next, 1) : 0; \
+         (ELEM) = (NEXT))
+
+/**
  * @brief YANG built-in types
  */
 typedef enum