-
Notifications
You must be signed in to change notification settings - Fork 114
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into compilergb
- Loading branch information
Showing
264 changed files
with
4,175 additions
and
1,606 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -18,16 +18,14 @@ jobs: | |
run: | | ||
cd main/ | ||
git submodule update --init --recursive | ||
- name: Pull engine updates | ||
uses: space-wizards/[email protected] | ||
- name: Update Engine Submodules | ||
run: | | ||
cd main/RobustToolbox/ | ||
git submodule update --init --recursive | ||
- name: Setup .NET Core | ||
uses: actions/setup-dotnet@v1 | ||
with: | ||
dotnet-version: 8.0.100 | ||
dotnet-version: 9.0.100 | ||
- name: Install compiler dependencies | ||
run: dotnet restore main/DMCompiler/DMCompiler.csproj | ||
- name: Install disassembler dependencies | ||
|
@@ -38,6 +36,10 @@ jobs: | |
run: dotnet build main/DMDisassembler/DMDisassembler.csproj --property WarningLevel=0 --configuration Release --no-restore /m | ||
- name: Compile TestGame | ||
run: main\bin\DMCompiler\DMCompiler.exe main\TestGame\environment.dme --suppress-unimplemented | ||
- name: Compile TestGame in directory | ||
run: | | ||
cd main\TestGame\ | ||
..\bin\DMCompiler\DMCompiler.exe environment.dme --suppress-unimplemented | ||
- name: Checkout /tg/station Master | ||
uses: actions/checkout@v2 | ||
with: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 10 additions & 0 deletions
10
Content.IntegrationTests/DMProject/Tests/atom_appearance.dm
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
/obj/thingtocopy | ||
name = "hello" | ||
desc = "this is a thing" | ||
|
||
/proc/test_appearance() | ||
var/obj/thingtocopy/T = new() | ||
var/obj/otherthing = new() | ||
otherthing.appearance = T.appearance | ||
ASSERT(otherthing.name == T.name) | ||
ASSERT(otherthing.desc == T.desc) |
16 changes: 16 additions & 0 deletions
16
Content.IntegrationTests/DMProject/Tests/filter_initial.dm
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
/obj/blurry | ||
filters = filter(type="blur", size=2) | ||
|
||
/obj/veryblurry | ||
filters = list(type="blur", size=4) | ||
|
||
/obj/notatallblurry | ||
filters = list() | ||
|
||
/proc/test_filter_init() | ||
var/obj/veryblurry/VB = new() | ||
ASSERT(length(VB.filters) == 1) | ||
var/obj/blurry/B = new() | ||
ASSERT(length(B.filters) == 1) | ||
var/obj/notatallblurry/NAB = new() | ||
ASSERT(length(NAB.filters) == 0) |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,6 +10,6 @@ | |
out += dir | ||
ASSERT(out == 14) | ||
|
||
/proc/RunTest() | ||
/proc/test_nonlocal_var() | ||
var/mob/m = new | ||
m.dodir() |
13 changes: 13 additions & 0 deletions
13
Content.IntegrationTests/DMProject/Tests/string_interpolation.dm
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
/obj/blombo | ||
name = "Blombo" | ||
gender = FEMALE | ||
|
||
/obj/blorpo | ||
name = "Blorpo" | ||
gender = MALE | ||
|
||
/proc/test_string_interpolation() | ||
var/obj/blombo/b = new | ||
var/obj/blorpo/b2 = new | ||
var/result_text = "[b]? Nobody likes \him. \He is awful! Unlike [b2]. \He is pretty cool!" | ||
ASSERT(result_text == "Blombo? Nobody likes her. She is awful! Unlike Blorpo. He is pretty cool!") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,12 @@ | ||
#include "code.dm" | ||
#include "Tests/atom_appearance.dm" | ||
#include "Tests/block.dm" | ||
#include "Tests/color_matrix.dm" | ||
#include "Tests/range.dm" | ||
#include "Tests/verb_duplicate.dm" | ||
#include "Tests/nonlocal_var.dm" | ||
#include "Tests/image.dm" | ||
#include "Tests/filter_initial.dm" | ||
#include "Tests/string_interpolation.dm" | ||
#include "map.dmm" | ||
#include "interface.dmf" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9 changes: 0 additions & 9 deletions
9
Content.Tests/DMProject/Broken Tests/Expression/Constants/numeral_inf.dm
This file was deleted.
Oops, something went wrong.
13 changes: 0 additions & 13 deletions
13
Content.Tests/DMProject/Broken Tests/Expression/proccall_keyword_param.dm
This file was deleted.
Oops, something went wrong.
6 changes: 0 additions & 6 deletions
6
Content.Tests/DMProject/Broken Tests/Procs/Arglist/initial.dm
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
var/const/ConstProc1_a = rgb(0,0,255) | ||
|
||
/proc/RunTest() | ||
var/const/ConstProc1_b = rgb(0,0,255) | ||
ASSERT(ConstProc1_a == "#0000ff") | ||
ASSERT(ConstProc1_b == "#0000ff") |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion
2
...en Tests/Tree/Const/Div_Zero/div_zero1.dm → ...kenTests/Tree/Const/Div_Zero/div_zero1.dm
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
// COMPILE ERROR | ||
// COMPILE ERROR OD0011 | ||
|
||
var/a = 1 / 0 | ||
|
||
|
2 changes: 1 addition & 1 deletion
2
...en Tests/Tree/Const/Div_Zero/div_zero3.dm → ...kenTests/Tree/Const/Div_Zero/div_zero3.dm
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
// COMPILE ERROR | ||
// COMPILE ERROR OD0011 | ||
|
||
var/static/a = 1 / 0 | ||
|
||
|
2 changes: 1 addition & 1 deletion
2
...en Tests/Tree/Const/Div_Zero/div_zero4.dm → ...kenTests/Tree/Const/Div_Zero/div_zero4.dm
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
// COMPILE ERROR | ||
// COMPILE ERROR OD0011 | ||
|
||
/proc/one() | ||
return 1 | ||
|
2 changes: 1 addition & 1 deletion
2
...en Tests/Tree/Const/Div_Zero/div_zero6.dm → ...kenTests/Tree/Const/Div_Zero/div_zero6.dm
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
// COMPILE ERROR | ||
// COMPILE ERROR OD0011 | ||
|
||
var/const/a = 0 | ||
var/b = 1 / a | ||
|
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,10 @@ | ||
|
||
|
||
/datum/test/var/bar = "foobar" | ||
/datum/test | ||
/proc/RunTest() | ||
var/datum/test/D = __IMPLIED_TYPE__ | ||
ASSERT(D.bar == "foobar") | ||
ASSERT(D == /datum/test) | ||
D = ArgumentTest(__IMPLIED_TYPE__) | ||
|
||
/proc/ArgumentTest(some_argument) | ||
ASSERT(some_argument == /datum/test) |
8 changes: 8 additions & 0 deletions
8
Content.Tests/DMProject/Tests/Expression/Constants/stringify_inf.dm
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
|
||
/proc/RunTest() | ||
var/a = 1#INF | ||
var/b = -1#INF | ||
var/c = -1#IND | ||
ASSERT("[a]" == "inf") | ||
ASSERT("[b]" == "-inf") | ||
ASSERT("[c]" == "nan") |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
|
||
//# issue 380 | ||
|
||
/proc/RunTest() | ||
var/a = @(ZZZ) | ||
asdfZZZ | ||
ASSERT(a == "asdf") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
|
||
//# issue 380 | ||
|
||
/proc/RunTest() | ||
var/a = @(ZZQ) | ||
asdfZZQ | ||
ASSERT(a == "asdf") |
11 changes: 11 additions & 0 deletions
11
Content.Tests/DMProject/Tests/Expression/proccall_keyword_param.dm
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
|
||
//# issue 655 | ||
//# issue 265 | ||
|
||
/datum/proc/nullproc(null, temp) | ||
ASSERT(isnull(null)) | ||
ASSERT(temp == 2) | ||
|
||
/proc/RunTest() | ||
var/datum/D = new | ||
D.nullproc(1,2) |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
/proc/RunTest() | ||
var/L1 = list(1, 2) | ||
L1 += L1 | ||
ASSERT(L1 ~= list(1, 2, 1, 2)) | ||
|
||
var/L2 = list(a=1, b=2) | ||
L2 += L2 | ||
ASSERT(L2 ~= list(a=1, b=2, "a", "b")) |
2 changes: 1 addition & 1 deletion
2
...MProject/Broken Tests/List/ListNullArg.dm → ...Tests/DMProject/Tests/List/ListNullArg.dm
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
// RUNTIME ERROR | ||
|
||
/proc/ListNullArg2(a[5][3]) | ||
ASSERT(a[1].len == 3) | ||
ASSERT(a[1].len == 3) // a should be null | ||
|
||
/proc/RunTest() | ||
ListNullArg2() |
2 changes: 1 addition & 1 deletion
2
...Project/Broken Tests/List/ListNullArg1.dm → ...ests/DMProject/Tests/List/ListNullArg1.dm
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
// RUNTIME ERROR | ||
|
||
/proc/ListNullArg1(a[5]) | ||
ASSERT(a.len == 5) | ||
ASSERT(a.len == 5) // a should be null | ||
|
||
/proc/RunTest() | ||
ListNullArg1() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.