title: C# Nesting asynchronous methods
body: <p>is it possible to do something like this or is it dangerous/bad practice?  If it's not good, what would be another way to go about it?</p>
  
  <pre><code>void methodA () 
  {
      while (something) {
          // do stuff
          methodB();
      }
  }
  
  async Task methodB() 
  {
       bool b = await methodC();
       // do something with b
  }
  
  async Task&lt;bool&gt; methodC() 
  {
      await Task.Delay(1000);
  }
  </code></pre>
  
  <p>What I'm trying to achieve is for <code>methodA</code> to be able to do stuff while <code>methodC</code> is waiting on IO.  So with this I'm hoping that <code>methodC</code> will return to <code>methodB</code> while busy and since <code>methodB</code> awaits the answer, it will return to <code>methodA</code>, where <code>methodA</code> can keep working on stuff and perhaps call <code>methodB</code> once again</p>