diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..ddf5681 --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2024 Kyler Olsen + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/docs/ytd 12-bit computer.md b/README.md similarity index 94% rename from docs/ytd 12-bit computer.md rename to README.md index 8944dd6..8b3eae4 100644 --- a/docs/ytd 12-bit computer.md +++ b/README.md @@ -71,7 +71,7 @@ About - Typing Discipline: ~~Typeless~~ Static, Weak - Platform: ytd 12-bit computer, ytd 12-bit emulator (from *pytd12dk*, multi-platform) -- License: *Tentatively MIT* +- License: MIT - Filename extension: `.ytd12c` - Compiler Implementations: `pytd12dk` (Python), `ytd12nc` (*bootstrapped compiler*) @@ -432,23 +432,7 @@ compiler, assembler with linker, and emulator. ## ytd12nc `ytd12nc` (ytd 12-bit native compiler) is a compiler and assembler with linker -set written in the native high-level programming language and assembly language +written in the native high-level programming language and assembly language to compile software for the ytd 12-bit computer natively. Currently development of `ytd12nc` has not yet started. - -### Bootstrapping - -In order to compile the the compiler, we need a compiler to compile it. This -process is called *bootstrapping* as it is like pulling ourselves up by our -bootstraps. This requires writing a compiler in assembly language or another -high-level programming language. In our case we are lucky to have the compiler -that is apart of `pytd12dk`. - -| Compiler | *Compiler* Compiler | *Compiler Compiler* Compiler | -| --- | --- | --- | -| `pytd12dk` | `CPython` | `gcc`, `clang`, or other C compiler | -| `ytd12nc` (a) | `pytd12dk` | `CPython` | -| `ytd12nc` (b) | `ytd12nc` (a) | `pytd12dk` | -| `ytd12nc` (c) | `ytd12nc` (b) | `ytd12nc` (a) | -| `ytd12nc` (d) | `ytd12nc` (c) | `ytd12nc` (b) | diff --git a/pytd12dk/compiler/main.py b/pytd12dk/compiler/main.py index fbc0540..ae2bc95 100644 --- a/pytd12dk/compiler/main.py +++ b/pytd12dk/compiler/main.py @@ -5,8 +5,8 @@ from typing import Sequence import argparse from .compiler_types import CompilerError -from .lexer import lexer, LexerError -from .syntactical_analyzer import syntactical_analyzer, SyntaxError +from .lexer import lexer +from .syntactical_analyzer import syntactical_analyzer def _compile(args: argparse.Namespace): diff --git a/pytd12dk/compiler/compiler.py b/pytd12dk/compiler/semantical_analyzer.py similarity index 51% rename from pytd12dk/compiler/compiler.py rename to pytd12dk/compiler/semantical_analyzer.py index 1b1db77..48586b0 100644 --- a/pytd12dk/compiler/compiler.py +++ b/pytd12dk/compiler/semantical_analyzer.py @@ -1,4 +1,2 @@ # Kyler Olsen -# Feb 2024 - - +# Mar 2024