]> git.llucax.com Git - z.facultad/75.42/calculadora.git/blobdiff - parser_equation.c
Bugfixes. El parser de variables parece andar.
[z.facultad/75.42/calculadora.git] / parser_equation.c
index a84925ee90b7eacd53b9419a48439423e35c4803..d76bd1dff577d8f3049541b4b72fb86b65578311 100644 (file)
@@ -47,6 +47,15 @@ size_t DLList_equation_print(DLList* l, FILE* fp) {
     return cant;
 }
 
+void DLList_equation_delete(DLList* l) {
+    if (l) {
+        while (!DLList_empty(l)) {
+            Equation_delete((Equation*)DLList_pop(l));
+        }
+    }
+    DLList_delete(l);
+}
+
 #define PARSE_ERROR(str) ParseError_set_pos_message(error, str, i + 1, c)
 
 bool parser_equation(const char* line, size_t len, DLList* equation_list,