Add empty cwl command

This commit is contained in:
Stone_Red
2022-11-17 14:07:29 +01:00
parent ef1f731adc
commit 2e023f1a4e
2 changed files with 256 additions and 252 deletions
@@ -9,10 +9,10 @@ using YesNt.Interpreter.Attributes;
using YesNt.Interpreter.Enums;
using YesNt.Interpreter.Utilities;
namespace YesNt.Interpreter.Runtime
namespace YesNt.Interpreter.Runtime;
public class YesNtInterpreter
{
public class YesNtInterpreter
{
private readonly RuntimeInformation runtimeInfo = new RuntimeInformation();
private Dictionary<StatementAttribute, Action<string>> statements = new();
private List<KeyValuePair<StaticStatementAttribute, Action>> staticStatements = new();
@@ -283,5 +283,4 @@ namespace YesNt.Interpreter.Runtime
return true;
}
}
}
@@ -6,10 +6,16 @@ using YesNt.Interpreter.Enums;
using YesNt.Interpreter.Runtime;
using YesNt.Interpreter.Utilities;
namespace YesNt.Interpreter.Statements
namespace YesNt.Interpreter.Statements;
internal class ConsoleStatements : StatementRuntimeInformation
{
internal class ConsoleStatements : StatementRuntimeInformation
[Statement("cwl", SearchMode.Exact, SpaceAround.None, ConsoleColor.DarkGreen, Priority = Priority.VeryLow)]
public void WriteLineEmpty(string _)
{
RuntimeInfo.WriteLine(string.Empty);
}
[Statement("cwl", SearchMode.StartOfLine, SpaceAround.End, ConsoleColor.DarkGreen, Priority = Priority.VeryLow)]
public void WriteLine(string args)
{
@@ -57,5 +63,4 @@ namespace YesNt.Interpreter.Statements
{
Console.Clear();
}
}
}