title: How to create a macro for creating a symbol in Julia
body: <p>I am trying to create a <a href="http://julia.readthedocs.org/en/latest/manual/metaprogramming/#non-standard-string-literals" rel="nofollow">string literal macro</a> in Julia to create a <code>symbol</code>, so that <code>s"x"</code> is the same as <code>:x</code>. It does not work:</p>
  
  <pre><code>julia&gt; macro s_str(p)
             symbol(p)
         end
  
  julia&gt; s'x'
  ERROR: s not defined
  
  julia&gt; s"x"
  ERROR: x not defined
  </code></pre>