title: How to preserve trailing whitespace in bash function arguments?
body: <p>Consider the following bash script:</p>
  
  <pre class="lang-bash prettyprint-override"><code>#!/bin/bash
  
  function foo {
    echo -n $1
    echo $2
  }
  
  foo 'Testing... ' 'OK' # =&gt; Testing...OK
  # Whitespace --^                      ^
  # Missing whitespace -----------------^
  </code></pre>
  
  <p>What happened to the trailing whitespace in the first argument?  How can preserve it?</p>