Use expression body syntax

This commit is contained in:
teinarss
2021-02-25 20:52:13 +01:00
committed by Paul Chote
parent 555c43843b
commit 4a1e4f3e16
403 changed files with 1342 additions and 2031 deletions

View File

@@ -24,7 +24,7 @@ namespace OpenRA
public struct WDist : IComparable, IComparable<WDist>, IEquatable<WDist>, IScriptBindable, ILuaAdditionBinding, ILuaSubtractionBinding, ILuaEqualityBinding, ILuaTableBinding
{
public readonly int Length;
public long LengthSquared { get { return (long)Length * Length; } }
public long LengthSquared => (long)Length * Length;
public WDist(int r) { Length = r; }
public static readonly WDist Zero = new WDist(0);
@@ -148,10 +148,7 @@ namespace OpenRA
}
}
set
{
throw new LuaException("WDist is read-only. Use WDist.New to create a new value");
}
set => throw new LuaException("WDist is read-only. Use WDist.New to create a new value");
}
#endregion
}