NEURON
hocdec.h File Reference
#include <stdio.h>
#include "nrnapi.h"
#include "hocassrt.h"
#include "nrnassrt.h"
#include <string.h>
#include "oc_ansi.h"

Go to the source code of this file.

Classes

union  Inst
 
struct  Arrayinfo
 
struct  Proc
 
struct  Symlist
 
struct  HocSymExtension
 
struct  Symbol
 
union  Datum
 
struct  cTemplate
 
union  Objectdata
 
struct  Object
 
struct  VoidFunc
 
struct  DoubScal
 
struct  DoubVec
 
struct  HocParmLimits
 
struct  HocStateTolerance
 
struct  HocParmUnits
 

Macros

#define INCLUDEHOCH   1
 
#define OOP   1
 
#define gargstr   hoc_gargstr
 
#define getarg   hoc_getarg
 
#define HocStruct   struct
 
#define HocUnion   union
 
#define HocTypedef   typedef
 
#define STOP   (Inst*) 0
 
#define NOTUSER   0
 
#define USERINT   1 /* For subtype */
 
#define USERDOUBLE   2
 
#define USERPROPERTY   3 /* for newcable non-range variables */
 
#define USERFLOAT   4 /* John Miller's NEMO uses floats */
 
#define SYMBOL   7 /* for stack type */
 
#define OBJECTTMP   8 /* temporary object on stack */
 
#define STKOBJ_UNREF   9 /* already unreffed temporary object on stack */
 
#define DYNAMICUNITS   10 /* {modern, legacy} units pair */
 
#define CPLUSOBJECT   16 /* c++ registered class */
 
#define JAVAOBJECT   32 /* c++ registered class */
 
#define OBJECTALIAS   1
 
#define VARALIAS   2
 
#define ISARRAY(arg)   (arg->arayinfo != (Arrayinfo*) 0)
 
#define List   hoc_List
 
#define Item   hoc_Item
 
#define OPVAL(sym)   hoc_objectdata[sym->u.oboff].pval
 
#define OPSTR(sym)   hoc_objectdata[sym->u.oboff].ppstr
 
#define OPOBJ(sym)   hoc_objectdata[sym->u.oboff].pobj
 
#define OPSECITM(sym)   hoc_objectdata[sym->u.oboff].psecitm
 
#define OPLIST(sym)   hoc_objectdata[sym->u.oboff].plist
 
#define OPARINFO(sym)   hoc_objectdata[sym->u.oboff + 1].arayinfo
 
#define IGNORE(arg)   arg
 
#define LINTUSE(arg)
 
#define Strcat   strcat
 
#define Strncat   strncat
 
#define Strcpy   strcpy
 
#define Strncpy   strncpy
 
#define Sprintf   sprintf
 
#define Printf   nrnpy_pr
 
#define ERRCHK(c1)   c1
 
#define IFGUI   if (hoc_usegui) {
 
#define ENDGUI   }
 
#define NOT_PARALLEL_SUB(c1)
 

Typedefs

typedef int(* Pfri) (void)
 
typedef void(* Pfrv) (void)
 
typedef double(* Pfrd) (void)
 
typedef struct Object **(* Pfro) (void)
 
typedef const char **(* Pfrs) (void)
 
typedef int(* Pfri_vp) (void *)
 
typedef void(* Pfrv_vp) (void *)
 
typedef double(* Pfrd_vp) (void *)
 
typedef struct Object **(* Pfro_vp) (void *)
 
typedef const char **(* Pfrs_vp) (void *)
 
typedef union Inst Inst
 
typedef struct Arrayinfo Arrayinfo
 
typedef struct Proc Proc
 
typedef struct Symlist Symlist
 
typedef char * Upoint
 
typedef struct HocSymExtension HocSymExtension
 
typedef struct Symbol Symbol
 
typedef struct hoc_Item hoc_List
 
typedef union Datum Datum
 
typedef struct cTemplate cTemplate
 
typedef union Objectdata Objectdata
 
typedef struct Object Object
 

Functions

voidemalloc (size_t n)
 
voidecalloc (size_t n, size_t size)
 
voiderealloc (void *ptr, size_t n)
 
Objectdatahoc_objectdata_save (void)
 
Objectdatahoc_objectdata_restore (Objectdata *)
 

Variables

Insthoc_progp
 
Insthoc_progbase
 
Insthoc_prog
 
Insthoc_prog_parse_recover
 
Insthoc_pc
 
Objectdatahoc_objectdata
 
Objectdatahoc_top_level_data
 
Objecthoc_thisobject
 
Symlisthoc_symlist
 
Symlisthoc_top_level_symlist
 
Symlisthoc_built_in_symlist
 
int hoc_usegui
 
int nrn_istty_
 
int parallel_sub
 

Macro Definition Documentation

◆ CPLUSOBJECT

#define CPLUSOBJECT   16 /* c++ registered class */

Definition at line 104 of file hocdec.h.

◆ DYNAMICUNITS

#define DYNAMICUNITS   10 /* {modern, legacy} units pair */

Definition at line 103 of file hocdec.h.

◆ ENDGUI

#define ENDGUI   }

Definition at line 373 of file hocdec.h.

◆ ERRCHK

#define ERRCHK (   c1)    c1

Definition at line 369 of file hocdec.h.

◆ gargstr

#define gargstr   hoc_gargstr

Definition at line 14 of file hocdec.h.

◆ getarg

#define getarg   hoc_getarg

Definition at line 15 of file hocdec.h.

◆ HocStruct

#define HocStruct   struct

Definition at line 34 of file hocdec.h.

◆ HocTypedef

#define HocTypedef   typedef

Definition at line 36 of file hocdec.h.

◆ HocUnion

#define HocUnion   union

Definition at line 35 of file hocdec.h.

◆ IFGUI

#define IFGUI   if (hoc_usegui) {

Definition at line 372 of file hocdec.h.

◆ IGNORE

#define IGNORE (   arg)    arg

Definition at line 345 of file hocdec.h.

◆ INCLUDEHOCH

#define INCLUDEHOCH   1

Definition at line 4 of file hocdec.h.

◆ ISARRAY

#define ISARRAY (   arg)    (arg->arayinfo != (Arrayinfo*) 0)

Definition at line 164 of file hocdec.h.

◆ Item

#define Item   hoc_Item

Definition at line 173 of file hocdec.h.

◆ JAVAOBJECT

#define JAVAOBJECT   32 /* c++ registered class */

Definition at line 105 of file hocdec.h.

◆ LINTUSE

#define LINTUSE (   arg)

Definition at line 347 of file hocdec.h.

◆ List

#define List   hoc_List

Definition at line 172 of file hocdec.h.

◆ NOT_PARALLEL_SUB

#define NOT_PARALLEL_SUB (   c1)
Value:
{ \
if (!parallel_sub) \
c1 \
}
int parallel_sub
Definition: parallel.cpp:30

Definition at line 379 of file hocdec.h.

◆ NOTUSER

#define NOTUSER   0

Definition at line 91 of file hocdec.h.

◆ OBJECTALIAS

#define OBJECTALIAS   1

Definition at line 107 of file hocdec.h.

◆ OBJECTTMP

#define OBJECTTMP   8 /* temporary object on stack */

Definition at line 101 of file hocdec.h.

◆ OOP

#define OOP   1

Definition at line 5 of file hocdec.h.

◆ OPARINFO

#define OPARINFO (   sym)    hoc_objectdata[sym->u.oboff + 1].arayinfo

Definition at line 311 of file hocdec.h.

◆ OPLIST

#define OPLIST (   sym)    hoc_objectdata[sym->u.oboff].plist

Definition at line 310 of file hocdec.h.

◆ OPOBJ

#define OPOBJ (   sym)    hoc_objectdata[sym->u.oboff].pobj

Definition at line 308 of file hocdec.h.

◆ OPSECITM

#define OPSECITM (   sym)    hoc_objectdata[sym->u.oboff].psecitm

Definition at line 309 of file hocdec.h.

◆ OPSTR

#define OPSTR (   sym)    hoc_objectdata[sym->u.oboff].ppstr

Definition at line 307 of file hocdec.h.

◆ OPVAL

#define OPVAL (   sym)    hoc_objectdata[sym->u.oboff].pval

Definition at line 306 of file hocdec.h.

◆ Printf

#define Printf   nrnpy_pr

Definition at line 353 of file hocdec.h.

◆ Sprintf

#define Sprintf   sprintf

Definition at line 352 of file hocdec.h.

◆ STKOBJ_UNREF

#define STKOBJ_UNREF   9 /* already unreffed temporary object on stack */

Definition at line 102 of file hocdec.h.

◆ STOP

#define STOP   (Inst*) 0

Definition at line 66 of file hocdec.h.

◆ Strcat

#define Strcat   strcat

Definition at line 348 of file hocdec.h.

◆ Strcpy

#define Strcpy   strcpy

Definition at line 350 of file hocdec.h.

◆ Strncat

#define Strncat   strncat

Definition at line 349 of file hocdec.h.

◆ Strncpy

#define Strncpy   strncpy

Definition at line 351 of file hocdec.h.

◆ SYMBOL

#define SYMBOL   7 /* for stack type */

Definition at line 100 of file hocdec.h.

◆ USERDOUBLE

#define USERDOUBLE   2

Definition at line 93 of file hocdec.h.

◆ USERFLOAT

#define USERFLOAT   4 /* John Miller's NEMO uses floats */

Definition at line 95 of file hocdec.h.

◆ USERINT

#define USERINT   1 /* For subtype */

Definition at line 92 of file hocdec.h.

◆ USERPROPERTY

#define USERPROPERTY   3 /* for newcable non-range variables */

Definition at line 94 of file hocdec.h.

◆ VARALIAS

#define VARALIAS   2

Definition at line 108 of file hocdec.h.

Typedef Documentation

◆ Arrayinfo

typedef struct Arrayinfo Arrayinfo

◆ cTemplate

typedef struct cTemplate cTemplate

◆ Datum

typedef union Datum Datum

◆ hoc_List

typedef struct hoc_Item hoc_List

Definition at line 89 of file hocdec.h.

◆ HocSymExtension

◆ Inst

typedef union Inst Inst

◆ Object

typedef struct Object Object

◆ Objectdata

typedef union Objectdata Objectdata

◆ Pfrd

typedef double(* Pfrd) (void)

Definition at line 41 of file hocdec.h.

◆ Pfrd_vp

typedef double(* Pfrd_vp) (void *)

Definition at line 47 of file hocdec.h.

◆ Pfri

typedef int(* Pfri) (void)

Definition at line 39 of file hocdec.h.

◆ Pfri_vp

typedef int(* Pfri_vp) (void *)

Definition at line 45 of file hocdec.h.

◆ Pfro

typedef struct Object**(* Pfro) (void)

Definition at line 41 of file hocdec.h.

◆ Pfro_vp

typedef struct Object**(* Pfro_vp) (void *)

Definition at line 47 of file hocdec.h.

◆ Pfrs

typedef const char**(* Pfrs) (void)

Definition at line 43 of file hocdec.h.

◆ Pfrs_vp

typedef const char**(* Pfrs_vp) (void *)

Definition at line 49 of file hocdec.h.

◆ Pfrv

typedef void(* Pfrv) (void)

Definition at line 40 of file hocdec.h.

◆ Pfrv_vp

typedef void(* Pfrv_vp) (void *)

Definition at line 46 of file hocdec.h.

◆ Proc

typedef struct Proc Proc

◆ Symbol

typedef struct Symbol Symbol

◆ Symlist

typedef struct Symlist Symlist

◆ Upoint

typedef char* Upoint

Definition at line 89 of file hocdec.h.

Function Documentation

◆ ecalloc()

void* ecalloc ( size_t  n,
size_t  size 
)

Definition at line 215 of file symbol.cpp.

◆ emalloc()

void* emalloc ( size_t  n)

Definition at line 197 of file symbol.cpp.

◆ erealloc()

void* erealloc ( void ptr,
size_t  n 
)

Definition at line 263 of file symbol.cpp.

◆ hoc_objectdata_restore()

Objectdata* hoc_objectdata_restore ( Objectdata obdsav)

Definition at line 143 of file hoc_oop.cpp.

◆ hoc_objectdata_save()

Objectdata* hoc_objectdata_save ( void  )

Definition at line 133 of file hoc_oop.cpp.

Variable Documentation

◆ hoc_built_in_symlist

Symlist* hoc_built_in_symlist
extern

Definition at line 76 of file ivocmac.cpp.

◆ hoc_objectdata

Objectdata* hoc_objectdata
extern

Definition at line 123 of file hoc_oop.cpp.

◆ hoc_pc

Inst* hoc_pc
extern

◆ hoc_prog

Inst * hoc_prog

Definition at line 295 of file hocdec.h.

◆ hoc_prog_parse_recover

Inst * hoc_prog_parse_recover

Definition at line 295 of file hocdec.h.

◆ hoc_progbase

Inst * hoc_progbase

Definition at line 295 of file hocdec.h.

◆ hoc_progp

Inst* hoc_progp
extern

◆ hoc_symlist

Symlist* hoc_symlist
extern

◆ hoc_thisobject

Object* hoc_thisobject
extern

Definition at line 122 of file hoc_oop.cpp.

◆ hoc_top_level_data

Objectdata* hoc_top_level_data
extern

Definition at line 124 of file hoc_oop.cpp.

◆ hoc_top_level_symlist

Symlist* hoc_top_level_symlist
extern

Definition at line 23 of file symdir.cpp.

◆ hoc_usegui

int hoc_usegui
extern

Definition at line 148 of file hoc.cpp.

◆ nrn_istty_

int nrn_istty_
extern

Definition at line 882 of file hoc.cpp.

◆ parallel_sub

int parallel_sub
extern

OCSMALL

Definition at line 30 of file parallel.cpp.