23 lines
417 B
C
23 lines
417 B
C
#include "scirpt/ast.h"
|
|
#include <stdlib.h>
|
|
|
|
void scirpt_ast_expr_delete(ScirptAstExpr* expr)
|
|
{
|
|
switch (expr->type) {
|
|
case ScirptAstExprTypeEof:
|
|
break;
|
|
case ScirptAstExprTypeError:
|
|
break;
|
|
case ScirptAstExprTypeId:
|
|
free(expr->id_value);
|
|
break;
|
|
case ScirptAstExprTypeInt:
|
|
break;
|
|
case ScirptAstExprTypeString:
|
|
free(expr->string_value);
|
|
break;
|
|
case ScirptAstExprTypeBool:
|
|
break;
|
|
}
|
|
}
|