Upgrade to .NET 8 and code cleanup

This commit is contained in:
Stone_Red
2024-08-07 19:48:03 +02:00
parent 84afe70c96
commit 7078ed5637
33 changed files with 960 additions and 1008 deletions
@@ -2,35 +2,34 @@
using YesNt.Interpreter.Enums;
namespace YesNt.Interpreter.Attributes
namespace YesNt.Interpreter.Attributes;
[AttributeUsage(AttributeTargets.Method, AllowMultiple = false)]
internal class StatementAttribute : Attribute
{
[AttributeUsage(AttributeTargets.Method, AllowMultiple = false)]
internal class StatementAttribute : Attribute
public string Name { get; }
public SearchMode SearchMode { get; }
public SpaceAround SpaceAround { get; }
public ConsoleColor Color { get; set; }
public Priority Priority { get; set; } = Priority.Normal;
public bool ExecuteInSearchMode { get; set; }
public bool KeepStatementInArgs { get; set; }
public bool IgnoreSyntaxHighlighting { get; }
public string Separator { get; set; }
internal StatementAttribute(string name, SearchMode searchMode, SpaceAround spaceAround, ConsoleColor color)
{
public string Name { get; }
public SearchMode SearchMode { get; }
public SpaceAround SpaceAround { get; }
public ConsoleColor Color { get; set; }
public Priority Priority { get; set; } = Priority.Normal;
public bool ExecuteInSearchMode { get; set; }
public bool KeepStatementInArgs { get; set; }
public bool IgnoreSyntaxHighlighting { get; }
public string Seperator { get; set; }
Name = name;
SearchMode = searchMode;
SpaceAround = spaceAround;
Color = color;
}
internal StatementAttribute(string name, SearchMode searchMode, SpaceAround spaceAround, ConsoleColor color)
{
Name = name;
SearchMode = searchMode;
SpaceAround = spaceAround;
Color = color;
}
internal StatementAttribute(string name, SearchMode searchMode, SpaceAround spaceAround)
{
Name = name;
SearchMode = searchMode;
SpaceAround = spaceAround;
IgnoreSyntaxHighlighting = true;
}
internal StatementAttribute(string name, SearchMode searchMode, SpaceAround spaceAround)
{
Name = name;
SearchMode = searchMode;
SpaceAround = spaceAround;
IgnoreSyntaxHighlighting = true;
}
}