Skip to content

Commit 6b9c272

Browse files
author
robertDurst
committed
lexar 2.0
1 parent b4aa783 commit 6b9c272

File tree

16 files changed

+554
-3
lines changed

16 files changed

+554
-3
lines changed

.vscode/c_cpp_properties.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"${workspaceFolder}/**"
77
],
88
"defines": [],
9-
"compilerPath": "/usr/bin/gcc",
9+
"compilerPath": "/usr/bin/clang++",
1010
"cStandard": "c11",
1111
"cppStandard": "c++17",
1212
"intelliSenseMode": "clang-x64"
83.4 MB
Binary file not shown.
8 Bytes
Binary file not shown.
59.4 MB
Binary file not shown.
8 Bytes
Binary file not shown.
39.5 MB
Binary file not shown.
8 Bytes
Binary file not shown.

.vscode/settings.json

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,10 @@
4848
"variant": "cpp",
4949
"forward_list": "cpp",
5050
"list": "cpp",
51-
"unordered_set": "cpp"
51+
"unordered_set": "cpp",
52+
"chrono": "cpp",
53+
"numeric": "cpp",
54+
"ratio": "cpp",
55+
"algorithm": "cpp"
5256
}
5357
}

CMakeLists.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,12 @@
11
cmake_minimum_required(VERSION 2.6)
22

3+
set(CMAKE_CXX_STANDARD 17)
4+
35
# Add sailfishc libs. TODO: write this more eloquently
46
ADD_LIBRARY(SailfishcLibs
57
./src/lexar/Lexar.cpp
8+
./src/lexar/Lexar2.cpp
9+
./src/lexar/Token2.cpp
610
./src/parser/Parser.cpp
711
./src/visitor/Visitor.cpp
812
./src/semantics/SymbolTable.cpp

examples/sailfishv2.fish

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
Uat Node {
2+
Node next
3+
int data
4+
}
5+
6+
# This is a comment
7+
Ufn Node {
8+
(fun next(void)(Node)
9+
(own.next = 10, return own.next))
10+
}
11+
12+
start (
13+
# This is also a comment
14+
dec int i = 10
15+
i += (10 - 11)
16+
)

0 commit comments

Comments
 (0)