Skip to content

Instantly share code, notes, and snippets.

@rojepp
Created October 4, 2012 06:40

Revisions

  1. rojepp created this gist Oct 4, 2012.
    22 changes: 22 additions & 0 deletions gistfile1.cs
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,22 @@
    using System;

    namespace ConsoleApplication2
    {
    class Program
    {
    static DateTime compbugresult;
    static void Main(string[] args)
    {
    compbugresult = compbug.result;
    }
    }
    static class compbug
    {
    static DateTime randB = System.DateTime.Now;
    public static DateTime result;
    static compbug()
    {
    result = System.Threading.Tasks.Task.Run(() => randB).Result;
    }
    }
    }