mt-lang 0.2.0 → 0.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/docs/index.html +4 -3
- data/lib/milk_tea/base.rb +1 -1
- data/std/asset_pack.mt +267 -0
- data/std/async/libuv_runtime.mt +539 -0
- data/std/async/mailbox.mt +191 -0
- data/std/async/runtime.mt +87 -0
- data/std/async.mt +87 -0
- data/std/base64.mt +185 -0
- data/std/behavior_tree.mt +396 -0
- data/std/binary.mt +314 -0
- data/std/binary_heap.mt +157 -0
- data/std/bitset.mt +239 -0
- data/std/box2d.mt +535 -0
- data/std/bytes.mt +46 -0
- data/std/c/box2d.mt +1254 -0
- data/std/c/cgltf.mt +647 -0
- data/std/c/cjson.mt +106 -0
- data/std/c/crypto.mt +11 -0
- data/std/c/crypto_support.h +51 -0
- data/std/c/ctype.mt +19 -0
- data/std/c/ctype_bindgen.h +29 -0
- data/std/c/curl.mt +1223 -0
- data/std/c/enet.mt +473 -0
- data/std/c/errno.mt +41 -0
- data/std/c/errno_bindgen.h +53 -0
- data/std/c/flecs.mt +2945 -0
- data/std/c/fs.linux.mt +43 -0
- data/std/c/fs.windows.mt +43 -0
- data/std/c/fs_support.h +954 -0
- data/std/c/gl.mt +2065 -0
- data/std/c/gl_registry_helpers.h +10748 -0
- data/std/c/glfw.mt +499 -0
- data/std/c/libc.mt +167 -0
- data/std/c/libuv.mt +1491 -0
- data/std/c/math.mt +22 -0
- data/std/c/math_bindgen.h +31 -0
- data/std/c/miniaudio.mt +3420 -0
- data/std/c/pcre2.mt +735 -0
- data/std/c/process.mt +58 -0
- data/std/c/process_support.h +1147 -0
- data/std/c/raygui.mt +1602 -0
- data/std/c/raylib.mt +1245 -0
- data/std/c/raymath.mt +163 -0
- data/std/c/rlgl.mt +434 -0
- data/std/c/rpng.mt +60 -0
- data/std/c/rres.mt +187 -0
- data/std/c/sdl3.mt +4132 -0
- data/std/c/sqlite3.mt +951 -0
- data/std/c/stb_image.mt +52 -0
- data/std/c/stb_image_resize2.mt +128 -0
- data/std/c/stb_image_write.mt +19 -0
- data/std/c/stb_rect_pack.mt +38 -0
- data/std/c/stb_truetype.mt +175 -0
- data/std/c/stb_vorbis.mt +31 -0
- data/std/c/stdio.mt +90 -0
- data/std/c/steamworks.h +5769 -0
- data/std/c/steamworks.mt +4771 -0
- data/std/c/string.mt +16 -0
- data/std/c/string_bindgen.h +36 -0
- data/std/c/sync.mt +33 -0
- data/std/c/sync_support.h +219 -0
- data/std/c/terminal.mt +24 -0
- data/std/c/terminal_support.h +408 -0
- data/std/c/time.mt +26 -0
- data/std/c/tls.mt +24 -0
- data/std/c/tls_support.h +626 -0
- data/std/c/tracy.mt +53 -0
- data/std/c/zlib.mt +20 -0
- data/std/c/zlib_support.h +239 -0
- data/std/c/zstd.mt +231 -0
- data/std/cell.mt +60 -0
- data/std/cgltf.mt +115 -0
- data/std/cjson.mt +90 -0
- data/std/cli.mt +768 -0
- data/std/cookie.mt +198 -0
- data/std/counter.mt +160 -0
- data/std/crypto.mt +74 -0
- data/std/cstring.mt +13 -0
- data/std/ctype.mt +52 -0
- data/std/curl/runtime.mt +261 -0
- data/std/curl.mt +38 -0
- data/std/deque.mt +348 -0
- data/std/encoding.mt +93 -0
- data/std/enet.mt +133 -0
- data/std/env.mt +41 -0
- data/std/errno.mt +47 -0
- data/std/flecs.mt +978 -0
- data/std/fmt.mt +271 -0
- data/std/fs.linux.mt +696 -0
- data/std/fs.windows.mt +711 -0
- data/std/fsm.mt +267 -0
- data/std/gl.mt +2062 -0
- data/std/glfw.mt +471 -0
- data/std/goap.mt +342 -0
- data/std/graph.mt +521 -0
- data/std/gzip.mt +77 -0
- data/std/hash.mt +429 -0
- data/std/http/server.mt +810 -0
- data/std/http.mt +1227 -0
- data/std/intern.mt +53 -0
- data/std/jobs.mt +288 -0
- data/std/json.mt +627 -0
- data/std/libc.mt +34 -0
- data/std/libuv.mt +554 -0
- data/std/linear_algebra.mt +243 -0
- data/std/linked_map.mt +372 -0
- data/std/linked_map_view.mt +49 -0
- data/std/linked_set.mt +117 -0
- data/std/log.mt +69 -0
- data/std/map.mt +418 -0
- data/std/math.mt +24 -0
- data/std/mem/arena.mt +137 -0
- data/std/mem/endian.mt +51 -0
- data/std/mem/heap.mt +298 -0
- data/std/mem/pool.mt +164 -0
- data/std/mem/stack.mt +47 -0
- data/std/mem/tracking.mt +119 -0
- data/std/miniaudio.mt +1299 -0
- data/std/multiset.mt +191 -0
- data/std/net/channel.mt +727 -0
- data/std/net/clock.mt +237 -0
- data/std/net/discovery.mt +277 -0
- data/std/net/lobby.mt +813 -0
- data/std/net/manager.mt +539 -0
- data/std/net/mux.mt +839 -0
- data/std/net/nat.mt +122 -0
- data/std/net/packet.mt +219 -0
- data/std/net/punch.mt +162 -0
- data/std/net/rpc.mt +119 -0
- data/std/net/session.mt +1157 -0
- data/std/net/stun.mt +252 -0
- data/std/net/sync.mt +183 -0
- data/std/net/turn.mt +459 -0
- data/std/net.mt +2944 -0
- data/std/oauth2.mt +408 -0
- data/std/option.mt +51 -0
- data/std/ordered_map.mt +497 -0
- data/std/ordered_set.mt +348 -0
- data/std/path.mt +368 -0
- data/std/pcre2/runtime.mt +35 -0
- data/std/pcre2.mt +78 -0
- data/std/priority_queue.mt +55 -0
- data/std/process.mt +837 -0
- data/std/queue.mt +55 -0
- data/std/random.mt +146 -0
- data/std/raygui.mt +99 -0
- data/std/raylib/debug_console.mt +71 -0
- data/std/raylib/easing.mt +388 -0
- data/std/raylib/packed_assets.mt +255 -0
- data/std/raylib/runtime.mt +30 -0
- data/std/raylib/tracy_gpu.mt +37 -0
- data/std/raylib.mt +1510 -0
- data/std/raymath.mt +153 -0
- data/std/result.mt +89 -0
- data/std/rlgl.mt +268 -0
- data/std/rpng.mt +46 -0
- data/std/rres.mt +36 -0
- data/std/sdl3/runtime.mt +54 -0
- data/std/sdl3.mt +1731 -0
- data/std/serialize.mt +68 -0
- data/std/set.mt +124 -0
- data/std/spatial.mt +176 -0
- data/std/sqlite3.mt +151 -0
- data/std/stack.mt +55 -0
- data/std/stb_image.mt +47 -0
- data/std/stb_image_resize2.mt +41 -0
- data/std/stb_image_write.mt +17 -0
- data/std/stb_rect_pack.mt +15 -0
- data/std/stb_truetype.mt +77 -0
- data/std/stb_vorbis.mt +16 -0
- data/std/stdio.mt +88 -0
- data/std/steamworks.mt +1542 -0
- data/std/str.mt +293 -0
- data/std/string.mt +234 -0
- data/std/sync.mt +194 -0
- data/std/tar.mt +704 -0
- data/std/terminal.mt +1002 -0
- data/std/testing.mt +266 -0
- data/std/thread.mt +120 -0
- data/std/time.mt +105 -0
- data/std/tls.mt +616 -0
- data/std/toml.mt +1310 -0
- data/std/tracy.mt +42 -0
- data/std/uri.mt +118 -0
- data/std/url.mt +372 -0
- data/std/vec.mt +433 -0
- data/std/zstd.mt +94 -0
- metadata +187 -2
data/std/cjson.mt
ADDED
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
# generated by mtc imported-bindings from std.c.cjson using bindings/imported/cjson.binding.json
|
|
2
|
+
|
|
3
|
+
import std.c.cjson as c
|
|
4
|
+
|
|
5
|
+
public type JSON = c.cJSON
|
|
6
|
+
public type Hooks = c.cJSON_Hooks
|
|
7
|
+
public type Bool = c.cJSON_bool
|
|
8
|
+
|
|
9
|
+
public const VERSION_MAJOR: int = c.CJSON_VERSION_MAJOR
|
|
10
|
+
public const VERSION_MINOR: int = c.CJSON_VERSION_MINOR
|
|
11
|
+
public const VERSION_PATCH: int = c.CJSON_VERSION_PATCH
|
|
12
|
+
public const NESTING_LIMIT: int = c.CJSON_NESTING_LIMIT
|
|
13
|
+
public const CIRCULAR_LIMIT: int = c.CJSON_CIRCULAR_LIMIT
|
|
14
|
+
|
|
15
|
+
public foreign function version() -> cstr = c.cJSON_Version
|
|
16
|
+
public foreign function init_hooks(hooks: ptr[Hooks]) -> void = c.cJSON_InitHooks
|
|
17
|
+
public foreign function parse(value: str as cstr) -> ptr[JSON]? = c.cJSON_Parse
|
|
18
|
+
public foreign function parse_with_length(value: str as cstr, buffer_length: ptr_uint) -> ptr[JSON]? = c.cJSON_ParseWithLength
|
|
19
|
+
public foreign function parse_with_opts(value: str as cstr, return_parse_end: ptr[cstr], require_null_terminated: int) -> ptr[JSON]? = c.cJSON_ParseWithOpts
|
|
20
|
+
public foreign function parse_with_length_opts(value: str as cstr, buffer_length: ptr_uint, return_parse_end: ptr[cstr], require_null_terminated: int) -> ptr[JSON]? = c.cJSON_ParseWithLengthOpts
|
|
21
|
+
public foreign function print(item: const_ptr[JSON]) -> ptr[char]? = c.cJSON_Print
|
|
22
|
+
public foreign function print_unformatted(item: const_ptr[JSON]) -> ptr[char]? = c.cJSON_PrintUnformatted
|
|
23
|
+
public foreign function print_buffered(item: const_ptr[JSON], prebuffer: int, fmt: int) -> ptr[char]? = c.cJSON_PrintBuffered
|
|
24
|
+
public foreign function print_preallocated(item: ptr[JSON], buffer: ptr[char], length: int, format: int) -> Bool = c.cJSON_PrintPreallocated
|
|
25
|
+
public foreign function delete(item: ptr[JSON]) -> void = c.cJSON_Delete
|
|
26
|
+
public foreign function get_array_size(array: const_ptr[JSON]) -> int = c.cJSON_GetArraySize
|
|
27
|
+
public foreign function get_array_item(array: const_ptr[JSON], index: int) -> ptr[JSON]? = c.cJSON_GetArrayItem
|
|
28
|
+
public foreign function get_object_item(object: const_ptr[JSON], string: str as cstr) -> ptr[JSON]? = c.cJSON_GetObjectItem
|
|
29
|
+
public foreign function get_object_item_case_sensitive(object: const_ptr[JSON], string: str as cstr) -> ptr[JSON]? = c.cJSON_GetObjectItemCaseSensitive
|
|
30
|
+
public foreign function has_object_item(object: const_ptr[JSON], string: str as cstr) -> Bool = c.cJSON_HasObjectItem
|
|
31
|
+
public foreign function get_error_ptr() -> cstr? = c.cJSON_GetErrorPtr
|
|
32
|
+
public foreign function get_string_value(item: const_ptr[JSON]) -> cstr? = c.cJSON_GetStringValue
|
|
33
|
+
public foreign function get_number_value(item: const_ptr[JSON]) -> double = c.cJSON_GetNumberValue
|
|
34
|
+
public foreign function is_invalid(item: const_ptr[JSON]) -> Bool = c.cJSON_IsInvalid
|
|
35
|
+
public foreign function is_false(item: const_ptr[JSON]) -> Bool = c.cJSON_IsFalse
|
|
36
|
+
public foreign function is_true(item: const_ptr[JSON]) -> Bool = c.cJSON_IsTrue
|
|
37
|
+
public foreign function is_bool(item: const_ptr[JSON]) -> Bool = c.cJSON_IsBool
|
|
38
|
+
public foreign function is_null(item: const_ptr[JSON]) -> Bool = c.cJSON_IsNull
|
|
39
|
+
public foreign function is_number(item: const_ptr[JSON]) -> Bool = c.cJSON_IsNumber
|
|
40
|
+
public foreign function is_string(item: const_ptr[JSON]) -> Bool = c.cJSON_IsString
|
|
41
|
+
public foreign function is_array(item: const_ptr[JSON]) -> Bool = c.cJSON_IsArray
|
|
42
|
+
public foreign function is_object(item: const_ptr[JSON]) -> Bool = c.cJSON_IsObject
|
|
43
|
+
public foreign function is_raw(item: const_ptr[JSON]) -> Bool = c.cJSON_IsRaw
|
|
44
|
+
public foreign function create_null() -> ptr[JSON]? = c.cJSON_CreateNull
|
|
45
|
+
public foreign function create_true() -> ptr[JSON]? = c.cJSON_CreateTrue
|
|
46
|
+
public foreign function create_false() -> ptr[JSON]? = c.cJSON_CreateFalse
|
|
47
|
+
public foreign function create_bool(boolean: int) -> ptr[JSON]? = c.cJSON_CreateBool
|
|
48
|
+
public foreign function create_number(num: double) -> ptr[JSON]? = c.cJSON_CreateNumber
|
|
49
|
+
public foreign function create_string(string: str as cstr) -> ptr[JSON]? = c.cJSON_CreateString
|
|
50
|
+
public foreign function create_raw(raw: str as cstr) -> ptr[JSON]? = c.cJSON_CreateRaw
|
|
51
|
+
public foreign function create_array() -> ptr[JSON]? = c.cJSON_CreateArray
|
|
52
|
+
public foreign function create_object() -> ptr[JSON]? = c.cJSON_CreateObject
|
|
53
|
+
public foreign function create_string_reference(string: str as cstr) -> ptr[JSON]? = c.cJSON_CreateStringReference
|
|
54
|
+
public foreign function create_object_reference(child: const_ptr[JSON]) -> ptr[JSON]? = c.cJSON_CreateObjectReference
|
|
55
|
+
public foreign function create_array_reference(child: const_ptr[JSON]) -> ptr[JSON]? = c.cJSON_CreateArrayReference
|
|
56
|
+
public foreign function create_int_array(numbers: const_ptr[int], count: int) -> ptr[JSON] = c.cJSON_CreateIntArray
|
|
57
|
+
public foreign function create_float_array(numbers: const_ptr[float], count: int) -> ptr[JSON] = c.cJSON_CreateFloatArray
|
|
58
|
+
public foreign function create_double_array(numbers: const_ptr[double], count: int) -> ptr[JSON] = c.cJSON_CreateDoubleArray
|
|
59
|
+
public foreign function create_string_array(strings: const_ptr[cstr], count: int) -> ptr[JSON] = c.cJSON_CreateStringArray
|
|
60
|
+
public foreign function add_item_to_array(array: ptr[JSON], item: ptr[JSON]) -> Bool = c.cJSON_AddItemToArray
|
|
61
|
+
public foreign function add_item_to_object(object: ptr[JSON], string: str as cstr, item: ptr[JSON]) -> Bool = c.cJSON_AddItemToObject
|
|
62
|
+
public foreign function add_item_to_object_cs(object: ptr[JSON], string: str as cstr, item: ptr[JSON]) -> Bool = c.cJSON_AddItemToObjectCS
|
|
63
|
+
public foreign function add_item_reference_to_array(array: ptr[JSON], item: ptr[JSON]) -> Bool = c.cJSON_AddItemReferenceToArray
|
|
64
|
+
public foreign function add_item_reference_to_object(object: ptr[JSON], string: str as cstr, item: ptr[JSON]) -> Bool = c.cJSON_AddItemReferenceToObject
|
|
65
|
+
public foreign function detach_item_via_pointer(parent: ptr[JSON], item: ptr[JSON]) -> ptr[JSON]? = c.cJSON_DetachItemViaPointer
|
|
66
|
+
public foreign function detach_item_from_array(array: ptr[JSON], which: int) -> ptr[JSON]? = c.cJSON_DetachItemFromArray
|
|
67
|
+
public foreign function delete_item_from_array(array: ptr[JSON], which: int) -> void = c.cJSON_DeleteItemFromArray
|
|
68
|
+
public foreign function detach_item_from_object(object: ptr[JSON], string: str as cstr) -> ptr[JSON]? = c.cJSON_DetachItemFromObject
|
|
69
|
+
public foreign function detach_item_from_object_case_sensitive(object: ptr[JSON], string: str as cstr) -> ptr[JSON]? = c.cJSON_DetachItemFromObjectCaseSensitive
|
|
70
|
+
public foreign function delete_item_from_object(object: ptr[JSON], string: str as cstr) -> void = c.cJSON_DeleteItemFromObject
|
|
71
|
+
public foreign function delete_item_from_object_case_sensitive(object: ptr[JSON], string: str as cstr) -> void = c.cJSON_DeleteItemFromObjectCaseSensitive
|
|
72
|
+
public foreign function insert_item_in_array(array: ptr[JSON], which: int, newitem: ptr[JSON]) -> Bool = c.cJSON_InsertItemInArray
|
|
73
|
+
public foreign function replace_item_via_pointer(parent: ptr[JSON], item: ptr[JSON], replacement: ptr[JSON]) -> Bool = c.cJSON_ReplaceItemViaPointer
|
|
74
|
+
public foreign function replace_item_in_array(array: ptr[JSON], which: int, newitem: ptr[JSON]) -> Bool = c.cJSON_ReplaceItemInArray
|
|
75
|
+
public foreign function replace_item_in_object(object: ptr[JSON], string: str as cstr, newitem: ptr[JSON]) -> Bool = c.cJSON_ReplaceItemInObject
|
|
76
|
+
public foreign function replace_item_in_object_case_sensitive(object: ptr[JSON], string: str as cstr, newitem: ptr[JSON]) -> Bool = c.cJSON_ReplaceItemInObjectCaseSensitive
|
|
77
|
+
public foreign function duplicate(item: const_ptr[JSON], recurse: int) -> ptr[JSON] = c.cJSON_Duplicate
|
|
78
|
+
public foreign function compare(a: const_ptr[JSON], b: const_ptr[JSON], case_sensitive: int) -> Bool = c.cJSON_Compare
|
|
79
|
+
public foreign function minify(json: ptr[char]) -> void = c.cJSON_Minify
|
|
80
|
+
public foreign function add_null_to_object(object: ptr[JSON], name: str as cstr) -> ptr[JSON]? = c.cJSON_AddNullToObject
|
|
81
|
+
public foreign function add_true_to_object(object: ptr[JSON], name: str as cstr) -> ptr[JSON]? = c.cJSON_AddTrueToObject
|
|
82
|
+
public foreign function add_false_to_object(object: ptr[JSON], name: str as cstr) -> ptr[JSON]? = c.cJSON_AddFalseToObject
|
|
83
|
+
public foreign function add_bool_to_object(object: ptr[JSON], name: str as cstr, boolean: int) -> ptr[JSON]? = c.cJSON_AddBoolToObject
|
|
84
|
+
public foreign function add_number_to_object(object: ptr[JSON], name: str as cstr, number: double) -> ptr[JSON]? = c.cJSON_AddNumberToObject
|
|
85
|
+
public foreign function add_string_to_object(object: ptr[JSON], name: str as cstr, string: str as cstr) -> ptr[JSON]? = c.cJSON_AddStringToObject
|
|
86
|
+
public foreign function add_raw_to_object(object: ptr[JSON], name: str as cstr, raw: str as cstr) -> ptr[JSON]? = c.cJSON_AddRawToObject
|
|
87
|
+
public foreign function add_object_to_object(object: ptr[JSON], name: str as cstr) -> ptr[JSON]? = c.cJSON_AddObjectToObject
|
|
88
|
+
public foreign function add_array_to_object(object: ptr[JSON], name: str as cstr) -> ptr[JSON]? = c.cJSON_AddArrayToObject
|
|
89
|
+
public foreign function set_number_helper(object: ptr[JSON], number: double) -> double = c.cJSON_SetNumberHelper
|
|
90
|
+
public foreign function set_valuestring(object: ptr[JSON], valuestring: str as cstr) -> ptr[char] = c.cJSON_SetValuestring
|