Compare commits

...

2 Commits

Author SHA1 Message Date
Kayne Ruse 27d2a21710 Updated vscode settings 2026-05-28 23:03:40 +10:00
Kayne Ruse abba7e0534 Updated cheatsheet.md 2026-05-27 12:35:43 +10:00
3 changed files with 21 additions and 6 deletions
+1 -1
View File
@@ -1,5 +1,5 @@
{ {
"recommendations": [ "recommendations": [
"gruntfuggly.todo-tree" "FanaticPythoner.better-todo-tree"
] ]
} }
+4 -4
View File
@@ -1,16 +1,16 @@
{ {
"todo-tree.filtering.includeGlobs": [ "better-todo-tree.filtering.includeGlobs": [
"**/repl/**", "**/repl/**",
"**/scripts/**", "**/scripts/**",
"**/source/**", "**/source/**",
"**/tests/**", "**/tests/**",
"**/tools/**", "**/tools/**",
], ],
"todo-tree.filtering.excludeGlobs": [ "better-todo-tree.filtering.excludeGlobs": [
"**/obj/**", "**/obj/**",
"**/out/**", "**/out/**",
], ],
"todo-tree.general.tags": [ "better-todo-tree.general.tags": [
"URGENT", "URGENT",
"BUG", "BUG",
"TODO", "TODO",
@@ -19,7 +19,7 @@
"WONTFIX", "WONTFIX",
"NOTE" "NOTE"
], ],
"todo-tree.highlights.customHighlight": { "better-todo-tree.highlights.customHighlight": {
"URGENT": { "URGENT": {
"icon": "alert", "icon": "alert",
"type": "text", "type": "text",
+16 -1
View File
@@ -141,4 +141,19 @@ TOY_API void Toy_inheritVM(Toy_VM* parentVM, Toy_VM* subVM);
TOY_API unsigned int Toy_runVM(Toy_VM* vm); TOY_API unsigned int Toy_runVM(Toy_VM* vm);
TOY_API void Toy_freeVM(Toy_VM* vm); TOY_API void Toy_freeVM(Toy_VM* vm);
TOY_API Toy_Value Toy_getReturnValueFromVM(Toy_VM* parentVM, Toy_VM* subVM); TOY_API Toy_Value Toy_getReturnValueFromVM(Toy_VM* parentVM, Toy_VM* subVM);
``` ```
## Standard Library
The tools in `repl/` includes a standard library, which can be added to the root VM by calling `initStandardLibrary` just before `Toy_runVM`. It provides the following general purpose functions:
* `min(x, y)`
* `max(x, y)`
* `floor(x)`
* `ceil(x)`
* `sqrt(x)`
* `range(x)`
It also offers an example of how to write an API.
*Note: Range returns a closure intended for use in the `for` keyword, but the that keyword isn't done yet.*