libyang REFACTOR use freeing context

Fixes compiled extension memory leaks.
Refactoring included.
diff --git a/src/schema_compile_amend.h b/src/schema_compile_amend.h
index 9fe5c65..581dfae 100644
--- a/src/schema_compile_amend.h
+++ b/src/schema_compile_amend.h
@@ -115,7 +115,7 @@
  * @param[in] ctx libyang context.
  * @param[in] dev_pnode Parsed node to free.
  */
-void lysp_dev_node_free(const struct ly_ctx *ctx, struct lysp_node *dev_pnode);
+void lysp_dev_node_free(struct lysc_ctx *cctx, struct lysp_node *dev_pnode);
 
 /**
  * @brief Compile and apply any precompiled deviations and refines targeting a node.