title: Difference between "yield" of Tornado and "yield from" of asyncio in mechanism?
body: <p>In Tornado, we usually write the following code to call a function asynchronously:</p>
  
  <pre><code>class MainHandler(tornado.web.RequestHandler):
  
      @tornado.gen.coroutine
      def post(self):
          ...
          yield self.handleRequest(foo)
          ...
  
      @tornado.gen.coroutine
      def handleRequest(self, foo):
          ...
  </code></pre>
  
  <p>But in asyncio (will be shipped with Python 3.4, can be installed from pip for Python 3.3), we use <code>yield from</code> to achieve the same thing:</p>
  
  <pre><code>@asyncio.coroutine
  def myPostHandler():
      ...
      yield from handleRequest(foo)
      ...
  
  
  @asyncio.coroutine
  def handleRequest(foo)
      ...
  </code></pre>
  
  <p>Seeing from the code, the difference is <code>yield</code> and <code>yield from</code>. However the former <code>handleRequest(foo)</code> returns a <code>tornado.concurrent.Future</code> object, the latter returns a <code>generator</code> object.</p>
  
  <p>My question is, what is the difference between the two things in mechanism? How is the control flow? And who calls the actual <code>handleRequest</code> and retrieves its returning value?</p>
  
  <p>Append: I have basic knowledge of Python generators and iterators. I wanted to understand what Tornado and asyncio achieved by using these, and what is the difference between those two mechanisms.</p>