interop.c

Include dependency graph for interop.c:

digraph {
    graph [bgcolor="#00000000"]
    node [shape=rectangle style=filled fillcolor="#FFFFFF" font=Helvetica padding=2]
    edge [color="#1414CE"]
    "6" [label="atom.h" tooltip="atom.h"]
    "27" [label="bitstring.h" tooltip="bitstring.h"]
    "3" [label="context.h" tooltip="context.h"]
    "28" [label="defaultatoms.h" tooltip="defaultatoms.h"]
    "8" [label="erl_nif.h" tooltip="erl_nif.h"]
    "4" [label="globalcontext.h" tooltip="globalcontext.h"]
    "1" [label="/home/winford/github/UncleGrumpy/AtomVM/src/libAtomVM/interop.c" tooltip="/home/winford/github/UncleGrumpy/AtomVM/src/libAtomVM/interop.c" fillcolor="#BFBFBF"]
    "2" [label="interop.h" tooltip="interop.h"]
    "12" [label="list.h" tooltip="list.h"]
    "26" [label="mailbox.h" tooltip="mailbox.h"]
    "20" [label="memory.h" tooltip="memory.h"]
    "23" [label="refc_binary.h" tooltip="refc_binary.h"]
    "24" [label="resources.h" tooltip="resources.h"]
    "13" [label="smp.h" tooltip="smp.h"]
    "16" [label="synclist.h" tooltip="synclist.h"]
    "29" [label="tempstack.h" tooltip="tempstack.h"]
    "18" [label="term.h" tooltip="term.h"]
    "9" [label="term_typedef.h" tooltip="term_typedef.h"]
    "25" [label="timer_list.h" tooltip="timer_list.h"]
    "21" [label="utils.h" tooltip="utils.h"]
    "30" [label="valueshashtable.h" tooltip="valueshashtable.h"]
    "11" [label="inttypes.h" tooltip="inttypes.h"]
    "10" [label="limits.h" tooltip="limits.h"]
    "15" [label="stdatomic.h" tooltip="stdatomic.h"]
    "14" [label="stdbool.h" tooltip="stdbool.h"]
    "22" [label="stddef.h" tooltip="stddef.h"]
    "5" [label="stdint.h" tooltip="stdint.h"]
    "17" [label="stdio.h" tooltip="stdio.h"]
    "7" [label="stdlib.h" tooltip="stdlib.h"]
    "19" [label="string.h" tooltip="string.h"]
    "6" -> "5" [dir=forward tooltip="include"]
    "6" -> "7" [dir=forward tooltip="include"]
    "27" -> "18" [dir=forward tooltip="include"]
    "27" -> "14" [dir=forward tooltip="include"]
    "27" -> "5" [dir=forward tooltip="include"]
    "3" -> "4" [dir=forward tooltip="include"]
    "3" -> "12" [dir=forward tooltip="include"]
    "3" -> "26" [dir=forward tooltip="include"]
    "3" -> "13" [dir=forward tooltip="include"]
    "3" -> "18" [dir=forward tooltip="include"]
    "3" -> "25" [dir=forward tooltip="include"]
    "28" -> "4" [dir=forward tooltip="include"]
    "8" -> "9" [dir=forward tooltip="include"]
    "4" -> "5" [dir=forward tooltip="include"]
    "4" -> "6" [dir=forward tooltip="include"]
    "4" -> "8" [dir=forward tooltip="include"]
    "4" -> "12" [dir=forward tooltip="include"]
    "4" -> "13" [dir=forward tooltip="include"]
    "4" -> "16" [dir=forward tooltip="include"]
    "4" -> "18" [dir=forward tooltip="include"]
    "4" -> "25" [dir=forward tooltip="include"]
    "1" -> "2" [dir=forward tooltip="include"]
    "1" -> "27" [dir=forward tooltip="include"]
    "1" -> "28" [dir=forward tooltip="include"]
    "1" -> "29" [dir=forward tooltip="include"]
    "1" -> "18" [dir=forward tooltip="include"]
    "1" -> "9" [dir=forward tooltip="include"]
    "1" -> "30" [dir=forward tooltip="include"]
    "1" -> "5" [dir=forward tooltip="include"]
    "2" -> "3" [dir=forward tooltip="include"]
    "2" -> "18" [dir=forward tooltip="include"]
    "26" -> "14" [dir=forward tooltip="include"]
    "26" -> "12" [dir=forward tooltip="include"]
    "26" -> "13" [dir=forward tooltip="include"]
    "26" -> "9" [dir=forward tooltip="include"]
    "26" -> "21" [dir=forward tooltip="include"]
    "20" -> "8" [dir=forward tooltip="include"]
    "20" -> "9" [dir=forward tooltip="include"]
    "20" -> "21" [dir=forward tooltip="include"]
    "20" -> "5" [dir=forward tooltip="include"]
    "20" -> "7" [dir=forward tooltip="include"]
    "23" -> "14" [dir=forward tooltip="include"]
    "23" -> "7" [dir=forward tooltip="include"]
    "23" -> "12" [dir=forward tooltip="include"]
    "23" -> "24" [dir=forward tooltip="include"]
    "23" -> "13" [dir=forward tooltip="include"]
    "24" -> "7" [dir=forward tooltip="include"]
    "24" -> "8" [dir=forward tooltip="include"]
    "24" -> "12" [dir=forward tooltip="include"]
    "13" -> "14" [dir=forward tooltip="include"]
    "13" -> "15" [dir=forward tooltip="include"]
    "16" -> "12" [dir=forward tooltip="include"]
    "16" -> "17" [dir=forward tooltip="include"]
    "16" -> "13" [dir=forward tooltip="include"]
    "29" -> "9" [dir=forward tooltip="include"]
    "29" -> "21" [dir=forward tooltip="include"]
    "18" -> "14" [dir=forward tooltip="include"]
    "18" -> "5" [dir=forward tooltip="include"]
    "18" -> "17" [dir=forward tooltip="include"]
    "18" -> "7" [dir=forward tooltip="include"]
    "18" -> "19" [dir=forward tooltip="include"]
    "18" -> "20" [dir=forward tooltip="include"]
    "18" -> "23" [dir=forward tooltip="include"]
    "18" -> "21" [dir=forward tooltip="include"]
    "18" -> "9" [dir=forward tooltip="include"]
    "9" -> "10" [dir=forward tooltip="include"]
    "9" -> "11" [dir=forward tooltip="include"]
    "9" -> "5" [dir=forward tooltip="include"]
    "25" -> "14" [dir=forward tooltip="include"]
    "25" -> "5" [dir=forward tooltip="include"]
    "25" -> "12" [dir=forward tooltip="include"]
    "21" -> "22" [dir=forward tooltip="include"]
}

Functions

char *interop_term_to_string(term t, int *ok)
char *interop_binary_to_string(term binary)
char *interop_iolist_to_string(term list, int *ok)
char *interop_list_to_string(term list, int *ok)
char *interop_atom_to_string(Context *ctx, term atom)
term interop_proplist_get_value(term list, term key)
term interop_proplist_get_value_default(term list, term key, term default_value)
inline InteropFunctionResult interop_chardata_fold(term t, interop_chardata_fold_fun fold_fun, interop_chardata_rest_fun rest_fun, void *accum)
static inline InteropFunctionResult size_fold_fun(term t, void *accum)
InteropFunctionResult interop_iolist_size(term t, size_t *size)
static inline InteropFunctionResult write_string_fold_fun(term t, void *accum)
InteropFunctionResult interop_write_iolist(term t, char *p)
static enum UnicodeConversionResult interop_binary_conversion(term t, uint8_t *output, size_t *output_len, size_t *rest_crsr, enum CharDataEncoding in_encoding, enum CharDataEncoding out_encoding)
static InteropFunctionResult chardata_to_bytes_size_fold_fun(term t, void *accum)
static void chardata_to_bytes_size_rest_fun(term t, void *accum)
enum UnicodeConversionResult interop_chardata_to_bytes_size(term t, size_t *size, size_t *rest_size, enum CharDataEncoding in_encoding, enum CharDataEncoding out_encoding)
static InteropFunctionResult chardata_to_bytes_fold_fun(term t, void *accum)
static void chardata_to_bytes_rest_fun(term t, void *accum)
enum UnicodeConversionResult interop_chardata_to_bytes(term t, uint8_t *output, term *rest, enum CharDataEncoding in_encoding, enum CharDataEncoding out_encoding, Heap *heap)
term interop_map_get_value(GlobalContext *glb, term map, term key)
term interop_map_get_value_default(GlobalContext *glb, term map, term key, term default_value)
int interop_atom_term_select_int(const AtomStringIntPair *table, term atom, GlobalContext *global)
term interop_kv_get_value_default(term kv, AtomString key, term default_value, GlobalContext *glb)
struct CharDataToBytesSizeAcc

Public Members

enum CharDataEncoding in_encoding
enum CharDataEncoding out_encoding
size_t size
size_t rest_size
bool badarg
bool incomplete_transform
struct CharDataToBytesAcc

Collaboration diagram for CharDataToBytesAcc:

digraph {
    graph [bgcolor="#00000000"]
    node [shape=rectangle style=filled fillcolor="#FFFFFF" font=Helvetica padding=2]
    edge [color="#1414CE"]
    "1" [label="CharDataToBytesAcc" tooltip="CharDataToBytesAcc" fillcolor="#BFBFBF"]
    "2" [label="Heap" tooltip="Heap"]
    "3" [label="HeapFragment" tooltip="HeapFragment"]
    "1" -> "2" [dir=forward tooltip="usage"]
    "2" -> "3" [dir=forward tooltip="usage"]
    "3" -> "3" [dir=forward tooltip="usage"]
}

Public Members

enum CharDataEncoding in_encoding
enum CharDataEncoding out_encoding
uint8_t *output
term *rest
Heap *heap
bool badarg
bool incomplete_transform