Du kannst nicht mehr als 25 Themen auswählen Themen müssen entweder mit einem Buchstaben oder einer Ziffer beginnen. Sie können Bindestriche („-“) enthalten und bis zu 35 Zeichen lang sein.
 
Ludovic 'Archivist' Lagouardette 947092c339 Merge branch 'master' of https://git.nekoit.xyz/Archivist/sugar vor 1 Jahr
.idea Work on interpreter vor 1 Jahr
include Merge branch 'master' of https://git.nekoit.xyz/Archivist/sugar vor 1 Jahr
prototypes/molasses First unit test added vor 1 Jahr
src Merge branch 'master' of https://git.nekoit.xyz/Archivist/sugar vor 1 Jahr
tests Merge branch 'master' of https://git.nekoit.xyz/Archivist/sugar vor 1 Jahr
.clang-format Compiles and build completely vor 1 Jahr
.clang-tidy Added several features vor 1 Jahr
.gitignore Added tests for error messages on all build system known failure vor 1 Jahr
CMakeLists.txt Merge branch 'master' of https://git.nekoit.xyz/Archivist/sugar vor 1 Jahr
README.md Made help into a proper readme too vor 1 Jahr

README.md

Sugar

Commands

lex : string ➔ lexed_output

takes a filename to a file that must be compiled

merge : lexed_output lexed_output ➔ lexed_output

merges two lexed modules together

parse : lexed_output ➔ parsed_output

prepares code for generation

generate : parsed_output string ➔ string

takes a root filename, it will be appended with ".s" and that will be the generated assembly file, the filename will not be consumed

assemble : string ➔ _

takes a root filename, it will be appended with ".s" and that file will be compiled, the compiled output will be the given filename

help : _ ➔ _

prints this help

Examples

  • compile the file "example.mol" into the "potato.s" assembly file

$ sugar example.mol lex parse potato generate

  • compile the file "example.mol" into the "potato" executable

$ sugar example.mol lex parse potato generate assemble

  • compile the file "example.mol" and "2.mol" into the "potato" executable

$ sugar example.mol lex 2.mol lex merge parse potato generate assemble