NEURON
oc_ansi.h File Reference

HOC interpreter function declarations (included by hocdec.h) More...

#include "neuron/container/data_handle.hpp"
#include "neuron/container/generic_data_handle.hpp"
#include <cstdio>
#include <functional>
#include <memory>
#include <stdexcept>
#include <string>
#include <string_view>
#include "memory.hpp"

Go to the source code of this file.

Classes

struct  neuron::oc::runtime_error
 
struct  neuron::oc::detail::hoc_get_arg_helper< neuron::container::generic_data_handle >
 
struct  neuron::oc::detail::hoc_get_arg_helper< neuron::container::data_handle< T > >
 
struct  neuron::oc::detail::hoc_pop_helper< neuron::container::generic_data_handle >
 
struct  neuron::oc::detail::hoc_pop_helper< neuron::container::data_handle< T > >
 
struct  TmpObjectDeleter
 

Namespaces

 neuron
 In mechanism libraries, cannot use auto const token = nrn_ensure_model_data_are_sorted(); because the return type is incomplete (from include/neuron/model_data.hpp).
 
 neuron::oc
 
 neuron::oc::detail
 

Typedefs

using TmpObject = std::unique_ptr< Object, TmpObjectDeleter >
 

Functions

Symbolhoc_get_symbol (const char *var)
 
void hoc_register_var (DoubScal *, DoubVec *, VoidFunc *)
 
void ivoc_help (const char *)
 
Symbolhoc_lookup (const char *)
 
void hoc_execerror (const char *, const char *)
 
void hoc_execerr_ext (const char *fmt,...)
 printf style specification of hoc_execerror message. More...
 
char * hoc_object_name (Object *)
 
void hoc_retpushx (double)
 
template<typename Callable , typename... Args>
decltype(auto) neuron::oc::invoke_method_that_may_throw (Callable message_prefix, Args &&... args)
 Execute C++ code that may throw and propagate HOC information. More...
 
double * hoc_getarg (int)
 
int ifarg (int)
 
int vector_instance_px (void *, double **)
 
void install_vector_method (const char *, double(*)(void *))
 
int vector_arg_px (int i, double **p)
 
double hoc_Exp (double)
 
double hoc_pow (double, double)
 
int hoc_is_tempobj_arg (int narg)
 
std::FILE * hoc_obj_file_arg (int i)
 
void hoc_reg_nmodl_text (int type, const char *txt)
 
void hoc_reg_nmodl_filename (int type, const char *filename)
 
std::size_t nrn_mallinfo (int item)
 
int nrn_mlh_gsort (double *vec, int *base_ptr, int total_elems, int(*cmp)(double, double))
 
void state_discontinuity (int i, double *pd, double d)
 
IvocVectvector_arg (int)
 
int vector_buffer_size (IvocVect *)
 
int vector_capacity (IvocVect *)
 
IvocVectvector_new (int, Object *=nullptr)
 
IvocVectvector_new0 ()
 
IvocVectvector_new1 (int)
 
IvocVectvector_new2 (IvocVect *)
 
Object ** vector_pobj (IvocVect *)
 
void vector_resize (IvocVect *, int)
 
double * vector_vec (IvocVect *)
 
int vector_buffer_size (void *)
 
int vector_capacity (void *)
 
Object ** vector_pobj (void *)
 
void vector_resize (void *, int)
 
double * vector_vec (void *)
 
int hoc_obj_run (const char *, Object *)
 Brief explanation of hoc_obj_run. More...
 
void hoc_prstack ()
 Print up to the 10 most-recently-pushed elements on the stack. More...
 
int hoc_argtype (int)
 
int hoc_is_double_arg (int)
 
int hoc_is_pdouble_arg (int)
 
int hoc_is_str_arg (int)
 
int hoc_is_object_arg (int)
 
char * hoc_gargstr (int)
 
char ** hoc_pgargstr (int)
 
Object ** hoc_objgetarg (int)
 
Objecthoc_name2obj (const char *name, int index)
 
char ** hoc_temp_charptr ()
 
int hoc_is_temp_charptr (char **cpp)
 
void hoc_assign_str (char **pstr, const char *buf)
 
double chkarg (int, double low, double high)
 
double hoc_call_func (Symbol *, int narg)
 
void hoc_call_func_result_on_stack (Symbol *s, int narg)
 
double hoc_call_objfunc (Symbol *, int narg, Object *)
 
int hoc_set_color (int)
 
void hoc_plt (int, double, double)
 
void hoc_plprint (const char *)
 
void hoc_ret ()
 
void hoc_push (neuron::container::generic_data_handle handle)
 
template<typename T >
void hoc_push (neuron::container::data_handle< T > const &handle)
 
void hoc_pushx (double)
 
void hoc_pushstr (char **)
 
void hoc_pushobj (Object **)
 
void hoc_push_object (Object *)
 
void hoc_pushpx (double *)
 
void hoc_pushs (Symbol *)
 
void hoc_pushi (int)
 
void hoc_push_ndim (int)
 
int hoc_pop_ndim ()
 
int hoc_stack_type ()
 Get the type of the top entry. More...
 
bool hoc_stack_type_is_ndim ()
 
template<typename T >
hoc_pop ()
 Pop an object of type T from the HOC stack. More...
 
template<typename T >
hoc_get_arg (std::size_t narg)
 Get the nth (1..N) argument on the stack. More...
 
double * hoc_pgetarg (int narg)
 
double hoc_xpop ()
 
Symbolhoc_spop ()
 
double * hoc_pxpop ()
 
Object ** hoc_objpop ()
 Pop pointer to object pointer and return top elem from stack. More...
 
TmpObject hoc_pop_object ()
 
char ** hoc_strpop ()
 
int hoc_ipop ()
 
void hoc_nopop ()
 
template<typename T >
neuron::container::data_handle< T > hoc_pop_handle ()
 Shorthand for hoc_pop<data_handle<T>>(). More...
 
template<typename T >
neuron::container::data_handle< T > hoc_hgetarg (int narg)
 Shorthand for hoc_get_arg<data_handle<T>>(narg). More...
 
void hoc_execerror_mes (const char *, const char *, int)
 
void hoc_warning (const char *, const char *)
 
double * hoc_val_pointer (const char *)
 
neuron::container::data_handle< double > hoc_val_handle (std::string_view)
 
Symbolhoc_table_lookup (const char *, Symlist *)
 
Symbolhoc_install (const char *, int, double, Symlist **)
 
template<typename T >
T const & hoc_look_inside_stack (int i)
 Get the stack entry at depth i. More...
 
Objecthoc_obj_look_inside_stack (int)
 
void hoc_stkobj_unref (Object *, int stkindex)
 
size_t hoc_total_array_data (const Symbol *, Objectdata *)
 
char * hoc_araystr (Symbol *, int, Objectdata *)
 
char * hoc_object_pathname (Object *)
 
const char * expand_env_var (const char *)
 
void check_obj_type (Object *, const char *)
 
int is_obj_type (Object *, const char *)
 
void hoc_obj_ref (Object *)
 
void hoc_obj_unref (Object *)
 
void hoc_dec_refcount (Object **)
 
Object ** hoc_temp_objvar (Symbol *template_symbol, void *cpp_object)
 
Object ** hoc_temp_objptr (Object *)
 
Objecthoc_new_object (Symbol *symtemp, void *v)
 
void hoc_new_object_asgn (Object **obp, Symbol *template_symbol, void *cpp_object)
 
Objectnrn_pntproc_nmodlrandom_wrap (void *pnt, Symbol *sym)
 
Objectnrn_nmodlrandom_wrap (Prop *prop, Symbol *sym)
 
HocSymExtensionhoc_var_extra (const char *)
 
double check_domain_limits (float *, double)
 
Objecthoc_obj_get (int i)
 
void hoc_obj_set (int i, Object *)
 
void nrn_hoc_lock ()
 
void nrn_hoc_unlock ()
 
void nrn_exit (int)
 
void hoc_free_list (Symlist **)
 
int hoc_errno_check ()
 
Symbolhoc_parse_stmt (const char *, Symlist **)
 
void hoc_run_stmt (Symbol *)
 
Symbolhoc_parse_expr (const char *, Symlist **)
 
double hoc_run_expr (Symbol *)
 
void hoc_free_string (char *)
 
int hoc_xopen1 (const char *, const char *)
 
int hoc_xopen_run (Symbol *, const char *)
 
void hoc_symbol_limits (Symbol *, float, float)
 
void sym_extra_alloc (Symbol *)
 
int hoc_chdir (const char *path)
 
void hoc_final_exit ()
 
void hoc_sprint1 (char **, int)
 
double hoc_scan (std::FILE *)
 
char * hoc_symbol_units (Symbol *sym, const char *units)
 
void hoc_fake_call (Symbol *)
 
void hoc_last_init ()
 
void hoc_obj_notify (Object *)
 
int ivoc_list_count (Object *)
 
Objectivoc_list_item (Object *, int)
 
double hoc_func_table (void *vpft, int n, double *args)
 
void hoc_spec_table (void **pfunctable, int n)
 
void * hoc_sec_internal_name2ptr (const char *s, int eflag)
 
void * hoc_pysec_name2ptr (const char *s, int eflag)
 
void vector_append (IvocVect *, double)
 
void vector_delete (IvocVect *)
 
Object ** vector_temp_objvar (IvocVect *)
 
int is_vector_arg (int)
 
char * vector_get_label (IvocVect *)
 
void vector_set_label (IvocVect *, char *)
 
Symbolhoc_install_var (const char *, double *)
 
void hoc_class_registration ()
 
void hoc_spinit ()
 
void hoc_freearay (Symbol *)
 
int hoc_arayinfo_install (Symbol *, int)
 
void hoc_free_arrayinfo (Arrayinfo *)
 
void hoc_free_val_array (double *, std::size_t)
 
std::size_t hoc_total_array (Symbol *)
 
void frame_debug ()
 
void hoc_oop_initaftererror ()
 
void hoc_init ()
 
void initplot ()
 
void hoc_audit_command (const char *)
 
void hoc_audit_from_hoc_main1 (int, const char **, const char **)
 
void hoc_audit_from_final_exit ()
 
void hoc_audit_from_xopen1 (const char *, const char *)
 
void hoc_xopen_from_audit (const char *fname)
 
int hoc_retrieving_audit ()
 
int hoc_retrieve_audit (int id)
 
int hoc_saveaudit ()
 
void hoc_close_plot ()
 
void ivoc_cleanup ()
 
void ivoc_final_exit ()
 
int hoc_oc (const char *)
 
int hoc_oc (const char *, std::ostream &os)
 
void hoc_initcode ()
 
int hoc_ParseExec (int)
 
int hoc_get_line ()
 
int hoc_araypt (Symbol *, int)
 
double hoc_opasgn (int op, double dest, double src)
 
void hoc_install_object_data_index (Symbol *)
 
void hoc_template_notify (Object *, int)
 
void hoc_construct_point (Object *, int)
 
void hoc_call_ob_proc (Object *ob, Symbol *sym, int narg)
 
void hoc_push_frame (Symbol *, int)
 
void hoc_pop_frame ()
 
int hoc_argindex ()
 
void hoc_pop_defer ()
 
void hoc_tobj_unref (Object **)
 
int hoc_stacktype ()
 
int hoc_inside_stacktype (int)
 
void hoc_link_symbol (Symbol *, Symlist *)
 
void hoc_unlink_symbol (Symbol *, Symlist *)
 
void notify_freed (void *)
 
void notify_pointer_freed (void *)
 
int ivoc_list_look (Object *, Object *, char *, int)
 
void ivoc_free_alias (Object *)
 
Symbolivoc_alias_lookup (const char *, Object *)
 
void hoc_obj_disconnect (Object *)
 
void hoc_free_object (Object *)
 
void hoc_free_pstring (char **)
 
void hoc_on_init_register (void(*)())
 
int hoc_pid ()
 
int hoc_ired (const char *, int, int, int)
 
double hoc_xred (const char *, double, double, double)
 
int hoc_sred (const char *, char *, char *)
 
void nrnpy_pass ()
 
void hoc_free_allobjects (cTemplate *, Symlist *, Objectdata *)
 
int nrn_is_cable ()
 
void * nrn_opaque_obj2pyobj (Object *)
 
void bbs_done (void)
 
int hoc_main1 (int, const char **, const char **)
 
char * cxx_char_alloc (std::size_t size)
 

Variables

int nrnignore
 
double hoc_ac_
 
double hoc_epsilon
 
int nrn_inpython_
 
int hoc_color
 
Objectdatahoc_objectdata
 
void * nrn_parsing_pysec_
 
int hoc_returning
 
int stoprun
 
int nrn_mpiabort_on_error_
 

Detailed Description

HOC interpreter function declarations (included by hocdec.h)

Definition in file oc_ansi.h.