Skip to content

Releases: MrUnbelievable92/C-Sharp-Dev-Tools

v1.0.10

14 Nov 17:13
b9e07c4
Compare
Choose a tag to compare

Fixes

  • fixed COMPARISON_CHECKS assertions' CompareTo calls to allow for T being of the type byte, as byte.CompareTo does not necessarily only return 0, 1 and -1

Improvements

  • reduced memory footprint in the Unity Editor slightly

v1.0.9

14 Oct 14:30
2d42bdb
Compare
Choose a tag to compare

Additions

  • added IEnumerable<T> ForEachDirectory<T>(string folder, Func<string, T> func) to DirectoryExtensions
  • added IEnumerable<T> ForEachFile<T>(string folder, Func<string, T> func) to DirectoryExtensions
  • added DebugBurstIntrinsicsWindow if used within a Unity project as an editor window (Window/C# Dev Tools/Debug Burst Intrinsics (Local Packages Only)), enabling source code modification of used Unity.Burst compiler intrinsics within the LocalPackages folder
  • added AreNotAliased and AreNotAliased<T, U> assertions to ensure that pointers i.e. arrays do not overlap
  • added UnreachableException and an accompanying assertion Assert.Unreachable(), mainly to replace the default: throw null/new Exception("unreachable code") pattern in switch statements with default: throw Assert.Unreachable()

Improvements

  • added a more recognizable error message prefix "Assertion failed:" to all assertions

Fixes

  • fixed incorrect call counts of assertions being displayed in the Unity editor control window (Window/C# Dev Tools/Manage Safety Checks...)

Fixed Oversights

  • included .meta files to allow for adding the repository to Unity projects via its GitHub URL

v1.0.8f

05 Sep 13:39
78bb90e
Compare
Choose a tag to compare

Reactivated assertions by default

v1.0.8

18 Aug 06:16
2a4d4bf
Compare
Choose a tag to compare

Additions

  • added IEnumerable<T> ForEachDirectory<T>(string folder, Func<string, T> func) to DirectoryExtensions
  • added IEnumerable<T> ForEachFile<T>(string folder, Func<string, T> func) to DirectoryExtensions

Fixed Oversights

  • .meta files are now included to allow for adding the repository to Unity projects via its github URL

v1.0.7

11 Jun 14:03
d5f138c
Compare
Choose a tag to compare

Additions

  • Added a generic extension method Log<T>(this T obj, string format = null, IFormatProvider formatProvider = null), which logs obj.ToString() using UnityEngine.Debug.Log() when using the Unity Editor, Console.WriteLine() otherwise
  • Added some IO/Directory related utility as methods in the static DirectoryExtensions class. NOTE: These are subject to change

Improvements

  • When using the Unity Editor, the Window\C# Dev Tools\Manage Safety Checks window now shows the number of method calls of Assertions that can be enabled/disabled. It is not necessarily 100% accurate.
  • Made I/O bound task during Unity editor startup asynchronous

v1.0.6

06 Oct 06:24
Compare
Choose a tag to compare

Additions

  • Added IsMemoryAligned<T>(T* address) to Assert
  • UNITY ONLY: Added a simple editor extension at "Window/C# Dev Tools/Manage Safety Checks..." which enables users to enable/disable safety checks one by one or alltogether

Changes

  • API BREAKING CHANGE: Renamed the Log class to Dump

Fixed Oversights

  • Added a check whether or not the supplied numEntries parameter is 0 to Assert.IsValidSubarray

Dev Tools v.1.0.5

24 Dec 04:08
Compare
Choose a tag to compare

Added sign checks:
Assert.IsNonNegative
Assert.IsNotPositive
Assert.IsNegative
Assert.IsPositive

which express the programmer's intention more clearly than "Assert.IsNotSmaller(value, 0)" or "Assert.IsGreater(value, -1)".

C Sharp Dev Tools v1.0.4

22 Dec 01:32
Compare
Choose a tag to compare
Cosmetics

replaced "" with string.Empty
replaced "integral value" with "numerical value"