34 lines
594 B
C
34 lines
594 B
C
|
|
#include <debug.h>
|
|
|
|
#include <environment/inc.h>
|
|
|
|
#include <expression/inc.h>
|
|
|
|
#include "../new.h"
|
|
|
|
#include "inheritance.h"
|
|
#include "struct.h"
|
|
#include "new.h"
|
|
|
|
struct value* new_lazy_value(
|
|
struct environment* environment,
|
|
struct expression* expression)
|
|
{
|
|
ENTER;
|
|
|
|
struct lazy_value* this = (void*) new_value(
|
|
vk_lazy,
|
|
&lazy_value_inheritance,
|
|
sizeof(*this));
|
|
|
|
this->environment = inc_environment(environment);
|
|
|
|
this->expression = inc_expression(expression);
|
|
|
|
this->value = NULL;
|
|
|
|
EXIT;
|
|
return (void*) this;
|
|
}
|
|
|