title: Task.ContinueWith fires before task is finished
body: <p>I'm trying to start a task after I register a continuation for it. But continuation fires immediately after <code>await Task.Delay()</code> is called.</p>
  
  <pre><code>using System;
  using System.Linq;
  using System.Threading.Tasks;
  
  namespace ConsoleApplication30
  {
      class Program
      {
          static void Main(string[] args)
          {
              var task = new Task(async delegate {
                  Console.WriteLine("Before delay");
                  await Task.Delay(1000);
                  Console.WriteLine("After delay");
              });
  
              task.ContinueWith(t =&gt; {
                  Console.WriteLine("ContinueWith");
              });
  
              task.Start();
  
              Console.ReadLine();
          }
      }
  }
  </code></pre>
  
  <p>Output:</p>
  
  <pre><code>Before delay
  ContinueWith
  After delay
  </code></pre>
  
  <p>What is wrong here?</p>