title: Reversing str.format() - getting arguments by placeholder
body: <p>What is the most elegant way to reverse the process of Python's str.format on replacing arguments by position?</p>
  
  <p>For example for the following</p>
  
  <pre><code>textpattern = 'Please move {0} to {1}'
  mystring = 'Please move a to b'
  </code></pre>
  
  <p>a <code>deformat</code> function :</p>
  
  <pre><code>mystring.deformat(textpattern)
  </code></pre>
  
  <p>will return the list <code>['a', 'b']</code>. The variable <code>textpattern</code> is being entered by the user and then dynamically fetched from the DB.</p>
  
  <p>The closest thing I found is <a href="https://stackoverflow.com/questions/2175080/sscanf-in-python">a question about scnaf in Python</a> but that's slightly different.</p>