Data commit

This commit is contained in:
Ingy döt Net 2023-07-01 11:58:00 -04:00
parent 7387c8f97b
commit cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions

View file

@ -0,0 +1,21 @@
using System.Diagnostics; // Debug and Trace are in this namespace.
static class Program
{
static void Main()
{
int a = 0;
Console.WriteLine("Before");
// Always hit.
Trace.Assert(a == 42, "Trace assertion failed");
Console.WriteLine("After Trace.Assert");
// Only hit in debug builds.
Debug.Assert(a == 42, "Debug assertion failed");
Console.WriteLine("After Debug.Assert");
}
}

View file

@ -0,0 +1,21 @@
Imports System.Diagnostics
' Note: VB Visual Studio projects have System.Diagnostics imported by default,
' along with several other namespaces.
Module Program
Sub Main()
Dim a As Integer = 0
Console.WriteLine("Before")
' Always hit.
Trace.Assert(a = 42, "Trace assertion failed: The Answer was incorrect")
Console.WriteLine("After Trace.Assert")
' Only hit in debug builds.
Debug.Assert(a = 42, "Debug assertion failed: The Answer was incorrect")
Console.WriteLine("After Debug.Assert")
End Sub
End Module

View file

@ -0,0 +1 @@
Trace.Listeners.Add(new ConsoleTraceListener())