Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion Content.IntegrationTests/GameTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
namespace Content.IntegrationTests;
[TestFixture]
public sealed class GameTests : ContentIntegrationTest {

/// <summary>
/// Tests to make sure the IntegrationTest project does not runtime.
/// </summary>
Expand Down
1 change: 1 addition & 0 deletions DMCompiler/Compiler/CompilerError.cs
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ public enum WarningCode {
DanglingOverride = 405,
StaticOverride = 406,
FinalOverride = 407,

// ReSharper disable once InconsistentNaming
IAmATeaPot = 418, // TODO: Implement the HTCPC protocol for OD
HardConstContext = 500,
Expand Down
3 changes: 2 additions & 1 deletion DMCompiler/Compiler/DM/AST/DMAST.Expression.cs
Original file line number Diff line number Diff line change
Expand Up @@ -201,6 +201,7 @@ public abstract class Operation {
/// The location of the operation.
/// </summary>
public required Location Location;

/// <summary>
/// Whether we should short circuit if the expression we are accessing is null.
/// </summary>
Expand All @@ -212,6 +213,7 @@ public abstract class NamedOperation : Operation {
/// Name of the identifier.
/// </summary>
public required string Identifier;

/// <summary>
/// Whether we should check if the variable exists or not.
/// </summary>
Expand Down Expand Up @@ -247,7 +249,6 @@ public sealed class DMASTCallableProcIdentifier(Location location, string identi
}

public sealed class DMASTCallableSuper(Location location) : DMASTExpression(location), IDMASTCallable;

public sealed class DMASTCallableSelf(Location location) : DMASTExpression(location), IDMASTCallable;

public sealed class DMASTScopeIdentifier(
Expand Down
6 changes: 4 additions & 2 deletions DMCompiler/Compiler/DM/DMParser.cs
Original file line number Diff line number Diff line change
Expand Up @@ -195,6 +195,7 @@ public DMASTFile File() {
if (statements.Count == 0) return null;
}
} while (Delimiter());

Whitespace();

return statements;
Expand Down Expand Up @@ -673,6 +674,7 @@ public DMASTFile File() {
procStatements.Add(statement);
}
} while (Delimiter() || statement is DMASTProcStatementLabel);

Whitespace();

return (procStatements.Count > 0 ? procStatements : null, setStatements.Count > 0 ? setStatements : null);
Expand Down Expand Up @@ -1518,6 +1520,7 @@ private DMASTProcStatementSwitch.SwitchCase[] SwitchInner() {

Delimiter();
} while (Check(TokenType.DM_Comma));

Whitespace();
ConsumeRightParenthesis();
Whitespace();
Expand Down Expand Up @@ -1837,7 +1840,6 @@ private void ExpressionTo(out DMASTExpression endRange, out DMASTExpression? ste
DMASTExpression? value = ExpressionAssign();

while (value != null && Check(TokenType.DM_In)) {

Whitespace();
DMASTExpression? list = ExpressionAssign();
RequireExpression(ref list, "Expected a container to search in");
Expand Down Expand Up @@ -2349,6 +2351,7 @@ private bool Newline() {

while (Check(TokenType.Newline)) {
}

return hasNewline;
}

Expand Down Expand Up @@ -2800,7 +2803,6 @@ private void BracketWhitespace() {
Compiler.Emit(WarningCode.BadToken, CurrentLoc,
$"Only one type path can be used, ignoring {pathType}");
}

} while (Check(TokenType.DM_Bar));

if (parenthetical) {
Expand Down
2 changes: 2 additions & 0 deletions DMCompiler/Compiler/DMPreprocessor/DMPreprocessor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -673,6 +673,7 @@ private void HandlePragmaDirective() {
compiler.Emit(WarningCode.BadDirective, warningTypeToken.Location, "Runtime pragmas do not support directive: info");
return;
}

compiler.SetPragma(warningCode, ErrorLevel.Notice);
break;
case "warning":
Expand All @@ -681,6 +682,7 @@ private void HandlePragmaDirective() {
compiler.Emit(WarningCode.BadDirective, warningTypeToken.Location, "Runtime pragmas do not support directive: warn");
return;
}

compiler.SetPragma(warningCode, ErrorLevel.Warning);
break;
case "error":
Expand Down
2 changes: 1 addition & 1 deletion DMCompiler/Compiler/DMPreprocessor/DMPreprocessorLexer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -554,10 +554,10 @@ private bool TryMacroKeyword(string text, [NotNullWhen(true)] out Token? token)
token = null; // maybe should use ref instead of out?
return false;
}

return true;
}


///<summary>
/// Lex a string <br/>
///</summary>
Expand Down
1 change: 0 additions & 1 deletion OpenDreamClient/Interface/Controls/ControlGrid.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ public ControlGrid(ControlDescriptor controlDescriptor, ControlWindow window) :

protected override Control CreateUIElement() {
_grid = new GridContainer() {

};

return _grid;
Expand Down
2 changes: 1 addition & 1 deletion OpenDreamClient/Interface/DMF/IDMFProperty.cs
Original file line number Diff line number Diff line change
Expand Up @@ -522,8 +522,8 @@ public bool Equals(string comparison) {
}

#region Serializers
/// TLDR everything is a string passed to the constructor

/// TLDR everything is a string passed to the constructor
[TypeSerializer]
public sealed class DMFPropertyStringSerializer : ITypeSerializer<DMFPropertyString, ValueDataNode>, ITypeCopyCreator<DMFPropertyString> {
public DMFPropertyString Read(ISerializationManager serializationManager, ValueDataNode node,
Expand Down
Loading
Loading