26 #include "pips_config.h"
46 const char *struct_name,
53 pips_assert(
"Trying to create data for an already existing struct ?",
77 pips_assert(
"Trying to create lower bound but already existing ?",
99 printf(
"Creating allocatable struct for dim %d\n", ndim);
116 list dimensions = NULL;
117 for (
int dim = ndim; dim >= 1; dim--) {
149 return struct_entity;
value make_value_unknown(void)
type make_type_variable(variable _field_)
storage make_storage_rom(void)
type make_type_struct(list _field_)
basic make_basic_int(intptr_t _field_)
dimension make_dimension(expression a1, expression a2, list a3)
variable make_variable(basic a1, list a2, list a3)
#define NIL
The empty list (nil in Lisp)
#define CONS(_t_, _i_, _l_)
List element cell constructor (insert an element at the beginning of a list)
#define CAR(pcons)
Get the value of the first element of a list.
#define pips_assert(what, predicate)
common macros, two flavors depending on NDEBUG
#define TOP_LEVEL_MODULE_NAME
Module containing the global variables in Fortran and C.
#define MEMBER_SEP_STRING
string concatenate(const char *,...)
Return the concatenation of the given strings.
void * gen_find_tabulated(const char *, int)
struct _newgen_struct_data_ * data
static entity make_data_field(basic b, const char *struct_name, const char *name, list dimensions)
Helper for creating an allocatable structure.
entity find_or_create_allocatable_struct(basic b, string name, int ndim)
This function try to find the allocatable structure corresponding to the number of dimensions request...
static entity make_bound(const char *struct_name, const char *lname, int suffix)
list words_basic(basic obj, list *ppdl)
what about simple DOUBLE PRECISION, REAL, INTEGER...
#define ALLOCATABLE_UBOUND_PREFIX
#define ALLOCATABLE_PREFIX
#define ALLOCATABLE_LBOUND_PREFIX
entity FindEntity(const char *package, const char *name)
Retrieve an entity from its package/module name and its local name.
entity FindOrCreateTopLevelEntity(const char *name)
Return a top-level entity.
expression entity_to_expression(entity e)
if v is a constant, returns a constant call.
#define entity_storage(x)
#define entity_domain
newgen_syntax_domain_defined
#define entity_initial(x)
static int lname(char *s, int look_for_entry)
check for keywords for subprograms return 0 if comment card, 1 if found name and put in arg string.
The structure used to build lists in NewGen.