title: read a character from a string via inline assembler in visual studio
body: <p>I'm having a problem with the visual studio inline assembler and it doesn't seem to be loading the right values. I declare a C-string like so:</p>
  
  <pre><code>const char* str = "1235";  
  </code></pre>
  
  <p>Then I access the string like so in asm:</p>
  
  <pre><code>movzx ebx, byte ptr str[esi]
  </code></pre>
  
  <p>the problem is that instead of loading 49 into ebx (ascii code for '1') it loads 0. I'm sure that esi is the right index because of extensive debugging. am I loading the string wrong?</p>