261 int execute(
const std::string &);
809 void message(
int level,
const char from[],
const char text[],
810 const char errorname[] =
"")
const;
817 void message(std::ostream& out,
const char levelname[],
818 const char from[],
const char text[],
819 const char errorname[] =
"")
const;
static SLIType Arraytype
Definition: interpret.h:206
void inc_call_depth()
Increment call depth level.
Definition: interpret.h:355
static SLIType Litproceduretype
Definition: interpret.h:208
void backtrace_off()
Switch stack backtrace off.
Definition: interpret.cc:968
unsigned long cycle_restriction
Definition: interpret.h:87
void debug_options() const
Show Debug options.
Definition: interpret.cc:1012
Name dstack_name
Definition: interpret.h:147
unsigned long code_accessed
Definition: interpret.h:98
Name StackUnderflowError
Definition: interpret.h:153
static const IforallarrayFunction iforallarrayfunction
Definition: interpret.h:238
void addlinkeddynmodule(DynModule *, nest::Network *)
Definition: interpret.cc:567
void addmodule(void)
Definition: interpret.h:869
const Name d("d")
Specific to Izhikevich 2003.
Definition: nest_names.h:83
static const int M_INFO
Predefined error level for informational messages.
Definition: interpret.h:178
void dec_call_depth()
Decrement call depth level.
Definition: interpret.h:368
Definition: slibuiltins.h:102
Name e_name
Definition: interpret.h:124
Name interpreter_name
Definition: interpret.h:149
Name ArgumentTypeError
Definition: interpret.h:152
Definition: slibuiltins.h:52
static char const *const M_WARNING_NAME
Definition: interpret.h:190
static SLIType Callbacktype
Definition: interpret.h:213
int verbosity(void) const
Retrieve the current verbosity level of the SLI messaging mechanism.
Definition: interpret.cc:786
void initexternals(void)
Definition: interpret.cc:227
static const IforallindexedarrayFunction iforallindexedarrayfunction
Definition: interpret.h:240
Name BadIOError
Definition: interpret.h:159
Exception to be thrown if an error occured while accessing the stack.
Definition: sliexceptions.h:303
Definition: sliactions.h:87
bool opt_tailrecursion_
Optimize tailing recursion.
Definition: interpret.h:80
FunctionDatum * Ilookup(void) const
Definition: interpret.cc:251
static NametypeFunction nametypefunction
Definition: interpret.h:223
Definition: sliactions.h:38
static const int M_ALL
Predefined error level for turning on the display of all messages; for use with verbosity(int).
Definition: interpret.h:174
Definition: sliactions.h:66
Name iforallstring_name
Definition: interpret.h:121
Name getcurrentname(void) const
Definition: interpret.cc:930
static CallbacktypeFunction callbacktypefunction
Definition: interpret.h:228
Definition: slibuiltins.h:110
void initdictionaries(void)
Definition: interpret.cc:185
Definition: slifunction.h:35
int max_call_depth_
Depth until which procedure calls are debugged.
Definition: interpret.h:82
void inittypes(void)
Definition: interpret.cc:141
Name iiterate_name
Definition: interpret.h:113
Name mark_name
Definition: interpret.h:134
Definition: slibuiltins.h:38
Token execbarrier_token
Definition: interpret.h:167
static const IforallstringFunction iforallstringfunction
Definition: interpret.h:242
Definition: tokenstack.h:38
void optimize_tailrecursion_on()
Enable tail-recursion optimization.
Definition: interpret.h:499
static const int M_WARNING
Predefined error level for warning messages.
Definition: interpret.h:179
Represent strings by ints to facilitate fast comparison.
Definition: name.h:53
Name signo_name
Definition: interpret.h:143
void terminate(int returnvalue=-1)
Definition: interpret.cc:791
Name errorname_name
Definition: interpret.h:141
bool debug_mode_
True, if SLI level debugging is enabled.
Definition: interpret.h:76
Name estack_name
Definition: interpret.h:145
void addmodule(SLIInterpreter &i)
Definition: interpret.h:863
SLIInterpreter(void)
Definition: interpret.cc:373
static const int M_FATAL
Predefined error level for failure messages.
Definition: interpret.h:181
void raiseagain(void)
Re-raise the last error.
Definition: interpret.cc:756
void undef(Name const &)
Unbind a previously bound Token from a Name.
Definition: interpret.cc:353
TokenStack OStack
Definition: interpret.h:249
Dictionary * errordict
Definition: interpret.h:103
void toggle_stack_display()
Switch stack display on or off in debug mode.
Definition: interpret.cc:952
static SLIType DoubleVectortype
Definition: interpret.h:218
static const IsetcallbackFunction isetcallbackfunction
Definition: interpret.h:233
bool show_stack_
Show stack in debug mode.
Definition: interpret.h:77
bool show_backtrace_
Show stack-backtrace on error.
Definition: interpret.h:78
Definition: sliactions.h:73
void raisesignal(int)
TO BE DOCUMENTED.
Definition: interpret.cc:772
static char const *const M_STATUS_NAME
Definition: interpret.h:188
bool step_mode() const
Returns true, if step mode is active.
Definition: interpret.h:430
std::list< SLIModule * > modules
Definition: interpret.h:71
void message(int level, const char from[], const char text[], const char errorname[]="") const
Display a message.
Definition: interpret.cc:805
void def_move(Name const &, Token &)
Bind a Token to a Name.
Definition: interpret.cc:363
bool known(const Name &n) const
Test for a name searching all dictionaries on the stack.
Definition: interpret.cc:338
Name pi_name
Definition: interpret.h:123
void set_max_call_depth(int d)
Set maximal call depth level to a specific value.
Definition: interpret.h:407
static SLIType Integertype
Definition: interpret.h:200
unsigned long Index
Definition: token.h:372
Name end_name
Definition: interpret.h:128
static const IiterateFunction iiteratefunction
Definition: interpret.h:234
static SLIType Literaltype
Definition: interpret.h:205
Name DivisionByZeroError
Definition: interpret.h:156
TokenStack EStack
Definition: interpret.h:250
void createdouble(Name const &, double)
Definition: interpret.cc:261
Name ostack_name
Definition: interpret.h:146
A class that associates names and tokens.
Definition: dict.h:45
void optimize_tailrecursion_off()
Disable tail-recursion optimization.
Definition: interpret.h:515
int verbositylevel
Definition: interpret.h:91
int startup()
Initialise the interpreter by reading in the startup files.
Definition: interpret.cc:1199
Name ilookup_name
Definition: interpret.h:110
void set_call_depth(int l)
Set call depth level to a specific value.
Definition: interpret.h:381
void install(std::ostream &, SLIInterpreter *)
Print installation message via interpreter message command.
Definition: slimodule.cc:26
static char const *const M_ALL_NAME
Definition: interpret.h:186
static const IforallindexedstringFunction iforallindexedstringfunction
Definition: interpret.h:241
void setcycleguard(Index)
Definition: interpret.cc:941
Name ifor_name
Definition: interpret.h:116
Definition: sliactions.h:59
bool baseknown(const Name &n) const
Test for a name in the bottom level dictionary.
Definition: interpret.cc:343
static DatatypeFunction datatypefunction
Definition: interpret.h:222
static SLIType Dictionarytype
Definition: interpret.h:209
Name isetcallback_name
Definition: interpret.h:112
~SLIInterpreter()
Definition: interpret.cc:583
int get_call_depth() const
Return current call depth level.
Definition: interpret.h:394
Name istopped_name
Definition: interpret.h:135
Name stop_name
Definition: interpret.h:127
void stack_backtrace(int n)
List the execution stack from level n-1 downwards to level 0.
Definition: interpret.cc:980
bool get_debug_mode() const
Returns true, if debug mode is turned on.
Definition: interpret.h:438
static FunctiontypeFunction functiontypefunction
Definition: interpret.h:226
bool cycle_guard
Definition: interpret.h:86
FunctionDatum * Iiterate(void) const
Definition: interpret.cc:256
DictionaryStack * DStack
Definition: interpret.h:105
static char const *const M_INFO_NAME
Definition: interpret.h:189
char debug_commandline(Token &)
Prompt user for commands during debug mode.
Definition: interpret.cc:1038
Name CycleGuardError
Definition: interpret.h:161
Name iforallarray_name
Definition: interpret.h:117
Name KernelError
Definition: interpret.h:164
Name newerror_name
Definition: interpret.h:140
void createcommand(Name const &, SLIFunction const *)
Define a function in the current dictionary.
Definition: interpret.cc:274
Definition: interpret.h:69
bool show_backtrace() const
True, if a stack backtrace should be shown on error.
Definition: interpret.h:531
const Token & lookup2(const Name &n) const
Lookup a name searching all dictionaries on the stack.
Definition: interpret.cc:328
void assert_stack_load(size_t n)
Throw StackUnderflow exception if too few elements on stack.
Definition: interpret.h:878
Main administrative interface to the network.
Definition: network.h:135
int execute_debug_(size_t exitlevel=0)
Definition: interpret.cc:1250
void raiseerror(const char *err)
Cause the SLI interpreter to raise an error.
Definition: interpret.h:620
Definition: dictstack.h:70
static TrietypeFunction trietypefunction
Definition: interpret.h:227
static SLIType IntVectortype
Definition: interpret.h:217
Parser * parse
Definition: interpret.h:106
Definition: slibuiltins.h:68
static char const *const M_DEBUG_NAME
Definition: interpret.h:187
Definition: functiondatum.h:42
Name userdict_name
Definition: interpret.h:137
static SLIType Booltype
Definition: interpret.h:204
static char const *const M_ERROR_NAME
Definition: interpret.h:191
int execute_(size_t exitlevel=0)
Run the interpreter with a prepared execution stack.
Definition: interpret.cc:1306
void print_error(Token cmd)
Print a description of a raised error.
Definition: interpret.cc:687
static SLIType Symboltype
Definition: interpret.h:210
static const int M_QUIET
An error level above all others. Use to turn off messages completely.
Definition: interpret.h:182
Definition: slibuiltins.h:60
void initbuiltins(void)
Definition: interpret.cc:205
bool catch_errors() const
Definition: interpret.h:564
static SLIType XIstreamtype
Definition: interpret.h:215
unsigned long cycles(void) const
Definition: interpret.h:826
static SLIType Iteratortype
Definition: interpret.h:219
Name BadErrorHandler
Definition: interpret.h:163
Definition: slibuiltins.h:118
static SLIType Stringtype
Definition: interpret.h:202
Name ipop_name
Definition: interpret.h:111
static const IloopFunction iloopfunction
Definition: interpret.h:235
void catch_errors_on()
Definition: interpret.h:569
void basedef(const Name &n, const Token &t)
Bind a Token to a Name in the bottom level dictionary.
Definition: interpret.cc:358
Name commandstring_name
Definition: interpret.h:148
Name iforallindexedarray_name
Definition: interpret.h:119
Name null_name
Definition: interpret.h:131
int get_max_call_depth() const
Return value of maximal call depth level.
Definition: interpret.h:420
const Token & baselookup(const Name &n) const
Lookup a name searching only the bottom level dictionary.
Definition: interpret.cc:333
static const int M_STATUS
Predefined error level for status messages.
Definition: interpret.h:177
Name iparse_name
Definition: interpret.h:126
Name errordict_name
Definition: interpret.h:138
Name iforalliter_name
Definition: interpret.h:118
Base class for dynamically loadable SLI interpreter modules.
Definition: dynmodule.h:39
void SLIthrowsignal(int s)
Name StringStreamExpectedError
Definition: interpret.h:160
void def(Name const &, Token const &)
Bind a Token to a Name.
Definition: interpret.cc:348
Definition: slibuiltins.h:77
void catch_errors_off()
Definition: interpret.h:574
Name iloop_name
Definition: interpret.h:114
static const IforFunction iforfunction
Definition: interpret.h:237
Name irepeat_name
Definition: interpret.h:115
Base class for all SLI Interpreter modules.
Definition: slimodule.h:34
const Name n("n")
Number of synaptic release sites (int >=0) (Tsodyks2_connection)
Definition: nest_names.h:202
static SLIType Proceduretype
Definition: interpret.h:207
Definition: booldatum.h:35
Definition: slibuiltins.h:93
int call_depth_
Current depth of procedure calls.
Definition: interpret.h:81
Index load(void) const
Definition: tokenstack.h:156
Definition: slibuiltins.h:85
static const IforalliterFunction iforalliterfunction
Definition: interpret.h:239
static LitproceduretypeFunction litproceduretypefunction
Definition: interpret.h:225
static SLIType Nametype
Definition: interpret.h:203
unsigned long code_executed
Definition: interpret.h:99
Name WriteProtectedError
Definition: interpret.h:155
bool optimize_tailrecursion() const
Returns true, if tailing recursion optimization is done.
Definition: interpret.h:483
Name commandname_name
Definition: interpret.h:142
bool catch_errors_
Enter debugger on error.
Definition: interpret.h:79
void debug_mode_off()
Turn debug mode off.
Definition: interpret.h:454
int execute(const std::string &)
Execute the supplied command string.
Definition: interpret.cc:1212
static const int M_ERROR
Predefined error level for error messages.
Definition: interpret.h:180
Definition: sliactions.h:45
Definition: sliactions.h:31
void createconstant(Name const &, const Token &)
Define a constant in the current dictionary.
Definition: interpret.cc:292
void removecycleguard(void)
Definition: interpret.cc:947
A type-independent container for C++-types.
Definition: token.h:68
static SLIType Ostreamtype
Definition: interpret.h:216
static const IlookupFunction ilookupfunction
Definition: interpret.h:232
Name quitbyerror_name
Definition: interpret.h:139
static SLIType Istreamtype
Definition: interpret.h:214
Name true_name
Definition: interpret.h:132
static SLIType Functiontype
Definition: interpret.h:211
const Token & lookup(const Name &n) const
Lookup a name searching all dictionaries on the stack.
Definition: interpret.cc:323
void debug_mode_on()
Turn debug mode on.
Definition: interpret.h:446
static SLIType Trietype
Definition: interpret.h:212
void basedef_move(const Name &n, Token &t)
Bind a Token to a Name in the bottom level dictionary.
Definition: interpret.cc:368
static XIstreamtypeFunction xistreamtypefunction
Definition: interpret.h:229
Name RangeCheckError
Definition: interpret.h:157
Name PositiveIntegerExpectedError
Definition: interpret.h:158
static ProceduretypeFunction proceduretypefunction
Definition: interpret.h:224
Name SystemSignal
Definition: interpret.h:162
void backtrace_on()
Switch stack backtrace on.
Definition: interpret.cc:960
static const IrepeatFunction irepeatfunction
Definition: interpret.h:236
Name iforallindexedstring_name
Definition: interpret.h:120
Definition: slibuiltins.h:45
Token ct
Definition: interpret.h:247
static char const *const M_QUIET_NAME
Definition: interpret.h:193
Name UndefinedNameError
Definition: interpret.h:154
Name false_name
Definition: interpret.h:133
Name InternalKernelError
Definition: interpret.h:165
Definition: sliactions.h:52
static const int M_DEBUG
Predefined error level for debugging messages.
Definition: interpret.h:176
static SLIType Doubletype
Definition: interpret.h:201
Name systemdict_name
Definition: interpret.h:136
Dictionary * statusdict
Definition: interpret.h:102
Name recordstacks_name
Definition: interpret.h:144
static char const *const M_FATAL_NAME
Definition: interpret.h:192
unsigned long cycle_count
Definition: interpret.h:85