diff --git a/ExampleCodes/FigFig/main.fig b/ExampleCodes/FigFig/main.fig new file mode 100644 index 0000000..e42d173 --- /dev/null +++ b/ExampleCodes/FigFig/main.fig @@ -0,0 +1,4 @@ +import std.io; + +import token {Token, TokenType}; +import tokenizer {Tokenizer}; diff --git a/ExampleCodes/FigFig/token.fig b/ExampleCodes/FigFig/token.fig new file mode 100644 index 0000000..a1d81b6 --- /dev/null +++ b/ExampleCodes/FigFig/token.fig @@ -0,0 +1,31 @@ +/* +Example code: FigFig + +Token.fig +Copyright (C) 2020-2026 PuqiAR + +*/ +struct _TokenTypes +{ + public EOF = -1; + public Identifier = 0; + + public StringLiteral = 1; + public NumberLiteral = 2; + public True = 3; + public False = 4; + public Null = 5; + + public Plus = 6; + public Minus = 7; + public Asterisk = 8; + public Slash = 9; +} + +public const TokenType := new _TokenTypes{}; + +public struct Token +{ + public literal: String = ""; + public type: Int = TokenType.EOF; +} \ No newline at end of file diff --git a/ExampleCodes/FigFig/tokenizer.fig b/ExampleCodes/FigFig/tokenizer.fig new file mode 100644 index 0000000..8d4ecb5 --- /dev/null +++ b/ExampleCodes/FigFig/tokenizer.fig @@ -0,0 +1,20 @@ +/* +Example code: FigFig + +Tokenizer.fig +Copyright (C) 2020-2026 PuqiAR + +*/ + +import token {Token, TokenType}; + +public struct Tokenizer +{ + src: String = ""; + + public func TokenizeAll() -> List + { + var output := []; + return output; + } +} \ No newline at end of file diff --git a/src/Core/core.hpp b/src/Core/core.hpp index a49dec2..2e07843 100644 --- a/src/Core/core.hpp +++ b/src/Core/core.hpp @@ -4,7 +4,7 @@ #include #include -#define __FCORE_VERSION "0.4.2-alpha" +#define __FCORE_VERSION "0.4.3-alpha" #if defined(_WIN32) #define __FCORE_PLATFORM "Windows"