lambda-calc-1/expression/application/new.c
2025-01-13 20:36:07 -06:00

29 lines
563 B
C

#include <debug.h>
#include <expression/inc.h>
#include "../new.h"
#include "inheritance.h"
#include "struct.h"
#include "new.h"
struct expression* new_application_expression(
struct expression* left,
struct expression* right)
{
ENTER;
struct application_expression* this = (void*) new_expression(
/* inheritance: */ &application_expression_inheritance,
/* alloc size: */ sizeof(*this));
this->left = inc_expression(left);
this->right = inc_expression(right);
EXIT;
return (void*) this;
}