/* Routines to deal with "quick" variables */
#include "evalint.h"

int create_quick(v)
variable *v;
{
    value storage;

    if (create_var(v))
    {
	if (ALLOC_VALUE(storage))
	{
	    storage->type = cste;
	    set_var(v, storage);
	    return(TRUE);
	}
	free_var_name(v->name);
    }
    return(FALSE);
}

void free_quick(v)
variable *v;
{
    FREE_VALUE(get_var(v));
    free_var(v);
}

double get_quick(v)
variable *v;
{
    return(get_var(v)->cte);
}

void set_quick(v, nb)
variable *v;
double nb;
{
    get_var(v)->cte = nb;
}

