Numworks Epsilon  1.4.1
Graphing Calculator Operating System
runtime.c File Reference
#include <stdio.h>
#include <string.h>
#include <assert.h>
#include "py/parsenum.h"
#include "py/compile.h"
#include "py/objstr.h"
#include "py/objtuple.h"
#include "py/objlist.h"
#include "py/objmodule.h"
#include "py/objgenerator.h"
#include "py/smallint.h"
#include "py/runtime.h"
#include "py/builtin.h"
#include "py/stackctrl.h"
#include "py/gc.h"

Go to the source code of this file.

Macros

#define DEBUG_printf(...)   (void)0
 
#define DEBUG_OP_printf(...)   (void)0
 

Functions

void mp_init (void)
 
void mp_deinit (void)
 
mp_obj_t mp_load_name (qstr qst)
 
mp_obj_t mp_load_global (qstr qst)
 
mp_obj_t mp_load_build_class (void)
 
void mp_store_name (qstr qst, mp_obj_t obj)
 
void mp_delete_name (qstr qst)
 
void mp_store_global (qstr qst, mp_obj_t obj)
 
void mp_delete_global (qstr qst)
 
mp_obj_t mp_unary_op (mp_unary_op_t op, mp_obj_t arg)
 
mp_obj_t mp_binary_op (mp_binary_op_t op, mp_obj_t lhs, mp_obj_t rhs)
 
mp_obj_t mp_call_function_0 (mp_obj_t fun)
 
mp_obj_t mp_call_function_1 (mp_obj_t fun, mp_obj_t arg)
 
mp_obj_t mp_call_function_2 (mp_obj_t fun, mp_obj_t arg1, mp_obj_t arg2)
 
mp_obj_t mp_call_function_n_kw (mp_obj_t fun_in, size_t n_args, size_t n_kw, const mp_obj_t *args)
 
mp_obj_t mp_call_method_n_kw (size_t n_args, size_t n_kw, const mp_obj_t *args)
 
STATIC void mp_call_prepare_args_n_kw_var (bool have_self, size_t n_args_n_kw, const mp_obj_t *args, mp_call_args_t *out_args)
 
mp_obj_t mp_call_method_n_kw_var (bool have_self, size_t n_args_n_kw, const mp_obj_t *args)
 
void mp_unpack_sequence (mp_obj_t seq_in, size_t num, mp_obj_t *items)
 
void mp_unpack_ex (mp_obj_t seq_in, size_t num_in, mp_obj_t *items)
 
mp_obj_t mp_load_attr (mp_obj_t base, qstr attr)
 
void mp_convert_member_lookup (mp_obj_t self, const mp_obj_type_t *type, mp_obj_t member, mp_obj_t *dest)
 
void mp_load_method_maybe (mp_obj_t obj, qstr attr, mp_obj_t *dest)
 
void mp_load_method (mp_obj_t base, qstr attr, mp_obj_t *dest)
 
void mp_store_attr (mp_obj_t base, qstr attr, mp_obj_t value)
 
mp_obj_t mp_getiter (mp_obj_t o_in, mp_obj_iter_buf_t *iter_buf)
 
mp_obj_t mp_iternext_allow_raise (mp_obj_t o_in)
 
mp_obj_t mp_iternext (mp_obj_t o_in)
 
mp_vm_return_kind_t mp_resume (mp_obj_t self_in, mp_obj_t send_value, mp_obj_t throw_value, mp_obj_t *ret_val)
 
mp_obj_t mp_make_raise_obj (mp_obj_t o)
 
mp_obj_t mp_import_name (qstr name, mp_obj_t fromlist, mp_obj_t level)
 
mp_obj_t mp_import_from (mp_obj_t module, qstr name)
 
void mp_import_all (mp_obj_t module)
 
NORETURN void m_malloc_fail (size_t num_bytes)
 
NORETURN void mp_raise_msg (const mp_obj_type_t *exc_type, const char *msg)
 
NORETURN void mp_raise_ValueError (const char *msg)
 
NORETURN void mp_raise_TypeError (const char *msg)
 
NORETURN void mp_raise_OSError (int errno_)
 
NORETURN void mp_raise_NotImplementedError (const char *msg)
 

Variables

const mp_obj_module_t mp_module___main__
 

Macro Definition Documentation

◆ DEBUG_OP_printf

#define DEBUG_OP_printf (   ...)    (void)0

Definition at line 50 of file runtime.c.

◆ DEBUG_printf

#define DEBUG_printf (   ...)    (void)0

Definition at line 49 of file runtime.c.

Function Documentation

◆ m_malloc_fail()

NORETURN void m_malloc_fail ( size_t  num_bytes)

Definition at line 1437 of file runtime.c.

◆ mp_binary_op()

mp_obj_t mp_binary_op ( mp_binary_op_t  op,
mp_obj_t  lhs,
mp_obj_t  rhs 
)

Definition at line 277 of file runtime.c.

◆ mp_call_function_0()

mp_obj_t mp_call_function_0 ( mp_obj_t  fun)

Definition at line 599 of file runtime.c.

◆ mp_call_function_1()

mp_obj_t mp_call_function_1 ( mp_obj_t  fun,
mp_obj_t  arg 
)

Definition at line 603 of file runtime.c.

◆ mp_call_function_2()

mp_obj_t mp_call_function_2 ( mp_obj_t  fun,
mp_obj_t  arg1,
mp_obj_t  arg2 
)

Definition at line 607 of file runtime.c.

◆ mp_call_function_n_kw()

mp_obj_t mp_call_function_n_kw ( mp_obj_t  fun_in,
size_t  n_args,
size_t  n_kw,
const mp_obj_t args 
)

Definition at line 615 of file runtime.c.

◆ mp_call_method_n_kw()

mp_obj_t mp_call_method_n_kw ( size_t  n_args,
size_t  n_kw,
const mp_obj_t args 
)

Definition at line 639 of file runtime.c.

◆ mp_call_method_n_kw_var()

mp_obj_t mp_call_method_n_kw_var ( bool  have_self,
size_t  n_args_n_kw,
const mp_obj_t args 
)

Definition at line 816 of file runtime.c.

◆ mp_call_prepare_args_n_kw_var()

STATIC void mp_call_prepare_args_n_kw_var ( bool  have_self,
size_t  n_args_n_kw,
const mp_obj_t args,
mp_call_args_t out_args 
)

Definition at line 649 of file runtime.c.

◆ mp_convert_member_lookup()

void mp_convert_member_lookup ( mp_obj_t  self,
const mp_obj_type_t type,
mp_obj_t  member,
mp_obj_t dest 
)

Definition at line 992 of file runtime.c.

◆ mp_deinit()

void mp_deinit ( void  )

Definition at line 130 of file runtime.c.

◆ mp_delete_global()

void mp_delete_global ( qstr  qst)

Definition at line 210 of file runtime.c.

◆ mp_delete_name()

void mp_delete_name ( qstr  qst)

Definition at line 199 of file runtime.c.

◆ mp_getiter()

mp_obj_t mp_getiter ( mp_obj_t  o_in,
mp_obj_iter_buf_t iter_buf 
)

Definition at line 1120 of file runtime.c.

◆ mp_import_all()

void mp_import_all ( mp_obj_t  module)

Definition at line 1380 of file runtime.c.

◆ mp_import_from()

mp_obj_t mp_import_from ( mp_obj_t  module,
qstr  name 
)

Definition at line 1336 of file runtime.c.

◆ mp_import_name()

mp_obj_t mp_import_name ( qstr  name,
mp_obj_t  fromlist,
mp_obj_t  level 
)

Definition at line 1321 of file runtime.c.

◆ mp_init()

void mp_init ( void  )

Definition at line 58 of file runtime.c.

◆ mp_iternext()

mp_obj_t mp_iternext ( mp_obj_t  o_in)

Definition at line 1186 of file runtime.c.

◆ mp_iternext_allow_raise()

mp_obj_t mp_iternext_allow_raise ( mp_obj_t  o_in)

Definition at line 1162 of file runtime.c.

◆ mp_load_attr()

mp_obj_t mp_load_attr ( mp_obj_t  base,
qstr  attr 
)

Definition at line 930 of file runtime.c.

◆ mp_load_build_class()

mp_obj_t mp_load_build_class ( void  )

Definition at line 180 of file runtime.c.

◆ mp_load_global()

mp_obj_t mp_load_global ( qstr  qst)

Definition at line 153 of file runtime.c.

◆ mp_load_method()

void mp_load_method ( mp_obj_t  base,
qstr  attr,
mp_obj_t dest 
)

Definition at line 1076 of file runtime.c.

◆ mp_load_method_maybe()

void mp_load_method_maybe ( mp_obj_t  obj,
qstr  attr,
mp_obj_t dest 
)

Definition at line 1040 of file runtime.c.

◆ mp_load_name()

mp_obj_t mp_load_name ( qstr  qst)

Definition at line 140 of file runtime.c.

◆ mp_make_raise_obj()

mp_obj_t mp_make_raise_obj ( mp_obj_t  o)

Definition at line 1304 of file runtime.c.

◆ mp_raise_msg()

NORETURN void mp_raise_msg ( const mp_obj_type_t exc_type,
const char *  msg 
)

Definition at line 1448 of file runtime.c.

◆ mp_raise_NotImplementedError()

NORETURN void mp_raise_NotImplementedError ( const char *  msg)

Definition at line 1468 of file runtime.c.

◆ mp_raise_OSError()

NORETURN void mp_raise_OSError ( int  errno_)

Definition at line 1464 of file runtime.c.

◆ mp_raise_TypeError()

NORETURN void mp_raise_TypeError ( const char *  msg)

Definition at line 1460 of file runtime.c.

◆ mp_raise_ValueError()

NORETURN void mp_raise_ValueError ( const char *  msg)

Definition at line 1456 of file runtime.c.

◆ mp_resume()

mp_vm_return_kind_t mp_resume ( mp_obj_t  self_in,
mp_obj_t  send_value,
mp_obj_t  throw_value,
mp_obj_t ret_val 
)

Definition at line 1221 of file runtime.c.

◆ mp_store_attr()

void mp_store_attr ( mp_obj_t  base,
qstr  attr,
mp_obj_t  value 
)

Definition at line 1100 of file runtime.c.

◆ mp_store_global()

void mp_store_global ( qstr  qst,
mp_obj_t  obj 
)

Definition at line 205 of file runtime.c.

◆ mp_store_name()

void mp_store_name ( qstr  qst,
mp_obj_t  obj 
)

Definition at line 194 of file runtime.c.

◆ mp_unary_op()

mp_obj_t mp_unary_op ( mp_unary_op_t  op,
mp_obj_t  arg 
)

Definition at line 216 of file runtime.c.

◆ mp_unpack_ex()

void mp_unpack_ex ( mp_obj_t  seq_in,
size_t  num_in,
mp_obj_t items 
)

Definition at line 874 of file runtime.c.

◆ mp_unpack_sequence()

void mp_unpack_sequence ( mp_obj_t  seq_in,
size_t  num,
mp_obj_t items 
)

Definition at line 827 of file runtime.c.

Variable Documentation

◆ mp_module___main__

const mp_obj_module_t mp_module___main__
Initial value:
= {
.base = { &mp_type_module },
.globals = (mp_obj_dict_t*)&MP_STATE_VM(dict_main),
}
#define MP_STATE_VM(x)
Definition: mpstate.h:241
const mp_obj_type_t mp_type_module
Definition: objmodule.c:94

Definition at line 53 of file runtime.c.