diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml new file mode 100644 index 0000000..1c1db13 --- /dev/null +++ b/.github/FUNDING.yml @@ -0,0 +1,5 @@ +# These are supported funding model platforms + +patreon: krgamestudios +ko_fi: krgamestudios +custom: ["https://www.paypal.com/donate/?hosted_button_id=73Q82T2ZHV8AA"] diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md new file mode 100644 index 0000000..99ae358 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -0,0 +1,24 @@ +--- +name: Bug Report +about: Create a bug report to help us improve +labels: bug +--- + +## Describe The Bug + +A clear and concise description of the bug. + +## How To Reproduce + +How did you encounter the bug? Please provide step-by-step details if needed. + +## Version + +What version of Toy is displaying this bug? + +What platform are you operating on? + +### Additional Context + +If there's anything else you'd like to add, please add it here. + diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md new file mode 100644 index 0000000..112a2ad --- /dev/null +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -0,0 +1,18 @@ +--- +name: Feature Request +about: Suggest an idea +labels: enhancement +--- + +### Describe The Feature + +A clear and concise description of what you’d like to be able to do with Toy. + +### Describe The Alternatives + +A clear and concise description of any alternative solutions or workarounds you've considered. + +### Additional Context + +If there's anything else you'd like to add, please add it here. + diff --git a/.github/ISSUE_TEMPLATE/question.md b/.github/ISSUE_TEMPLATE/question.md new file mode 100644 index 0000000..6e41d24 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/question.md @@ -0,0 +1,10 @@ +--- +name: Question +about: Ask a Question +labels: question +--- + +### How can I help? + +I'm always here to help with any inquiries you have regarding Toy and its related projects. + diff --git a/.github/workflows/tests-full.yml b/.github/workflows/tests-full.yml new file mode 100644 index 0000000..1022839 --- /dev/null +++ b/.github/workflows/tests-full.yml @@ -0,0 +1,2 @@ +name: Comprehensive Tests + diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..c6127b3 --- /dev/null +++ b/.gitignore @@ -0,0 +1,52 @@ +# Prerequisites +*.d + +# Object files +*.o +*.ko +*.obj +*.elf + +# Linker output +*.ilk +*.map +*.exp + +# Precompiled Headers +*.gch +*.pch + +# Libraries +*.lib +*.a +*.la +*.lo + +# Shared objects (inc. Windows DLLs) +*.dll +*.so +*.so.* +*.dylib + +# Executables +*.exe +*.out +*.app +*.i*86 +*.x86_64 +*.hex + +# Debug files +*.dSYM/ +*.su +*.idb +*.pdb + +# Kernel Module Compile Results +*.mod* +*.cmd +.tmp_versions/ +modules.order +Module.symvers +Mkfile.old +dkms.conf diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..32bbcbc --- /dev/null +++ b/LICENSE @@ -0,0 +1,17 @@ +Copyright (c) 2020-2024 Kayne Ruse, KR Game Studios + +This software is provided 'as-is', without any express or implied +warranty. In no event will the authors be held liable for any damages +arising from the use of this software. + +Permission is granted to anyone to use this software for any purpose, +including commercial applications, and to alter it and redistribute it +freely, subject to the following restrictions: + +1. The origin of this software must not be misrepresented; you must not + claim that you wrote the original software. If you use this software + in a product, an acknowledgment in the product documentation would be + appreciated but is not required. +2. Altered source versions must be plainly marked as such, and must not be + misrepresented as being the original software. +3. This notice may not be removed or altered from any source distribution. \ No newline at end of file diff --git a/README.md b/README.md new file mode 100644 index 0000000..ed7d899 --- /dev/null +++ b/README.md @@ -0,0 +1,49 @@ +

+ +

+ +# Toy + +The Toy programming language is an imperative, bytecode-interpreted, embedded scripting language. Rather than functioning independently, it serves as part of another program—the ‘host.’ This design allows for straightforward customization by both the host’s developer and end users, achieved by exposing program logic through text files. + +This repository holds the reference implementation for Toy, written in C. + +# Nifty Features + +* Simple C-like syntax +* Intermediate bytecode interpretation +* Strong, but optional type system +* First-class and higher-order functions +* Extensible via external libraries +* Re-direct output, error and assertion failure messages +* Open source under the zlib license + +## Building + +*Omitted for review.* + +## Tools + +*Omitted for review.* + +## Syntax + +*Omitted for review.* + +# License + +This source code is covered by the zlib license (see [LICENSE](LICENSE)). + +# Contributions + +@hiperiondev - Disassembler, porting support and feedback +@add00 - Library support +@gruelingpine185 - Unofficial MacOS support +@solar-mist - Minor bugfixes +Unnamed Individuals - Feedback + +# Patrons via Patreon + +* Seth A. Robinson + +Special thanks to Robert Nystrom of http://craftinginterpreters.com/ for their fantastic book that set me on this path. \ No newline at end of file diff --git a/makefile b/makefile new file mode 100644 index 0000000..0439916 --- /dev/null +++ b/makefile @@ -0,0 +1,4 @@ +export CFLAGS+=-std=c17 -pedantic -Werror + +all: + diff --git a/toylogo.png b/toylogo.png new file mode 100644 index 0000000..4a39362 Binary files /dev/null and b/toylogo.png differ