symbols.c
static Symbol *AddLocalSymbol(ParseContext *c, SymbolTable *table, const char *name, StorageClass storageClass, Type *type, VMVALUE value)
{
    size_t size = sizeof(Symbol) + strlen(name);
    Symbol *sym;
    
    /* allocate the symbol structure */
    sym = (Symbol *)AllocateHighMemory(c->sys, size);
    strcpy(sym->name, name);
    sym->placed = VMTRUE;
    sym->storageClass = storageClass;
    sym->type = type;
    sym->value = value;
    sym->next = NULL;

    /* add it to the symbol table */
    *table->pTail = sym;
    table->pTail = &sym->next;
    ++table->count;
    
    /* return the symbol */
    return sym;
}
/* AddLocalSymbol - add a symbol to a local symbol table */
add a symbol to a local symbol table
add a symbol to a local symbol table
static Symbol *AddLocalSymbol(ParseContext *c, SymbolTable *table, const char *name, StorageClass storageClass, Type *type, VMVALUE value)
{
    size_t size = sizeof(Symbol) + strlen(name);
    Symbol *sym;
    sym = (Symbol *)AllocateHighMemory(c->sys, size);
    strcpy(sym->name, name);
    sym->placed = VMTRUE;
    sym->storageClass = storageClass;
    sym->type = type;
    sym->value = value;
    sym->next = NULL;
    *table->pTail = sym;
    table->pTail = &sym->next;
    ++table->count;
    return sym;
}
static Symbol * AddLocalSymbol ( ParseContext * c , SymbolTable * table , const char * name , StorageClass storageClass , Type * type , VMVALUE value ) { size_t size = sizeof ( Symbol ) + strlen ( name ) ; Symbol * sym ; sym = ( Symbol * ) AllocateHighMemory ( c -> sys , size ) ; strcpy ( sym -> name , name ) ; sym -> placed = VMTRUE ; sym -> storageClass = storageClass ; sym -> type = type ; sym -> value = value ; sym -> next = NULL ; * table -> pTail = sym ; table -> pTail = & sym -> next ; ++ table -> count ; return sym ; }
AddLocalSymbol - add a symbol to a local symbol table
AddLocalSymbol - add a symbol to a local symbol table
/* allocate the symbol structure */ /* add it to the symbol table */ /* return the symbol */