title: How do I increment/decrement a character in Ruby for all possible values?
body: <p>I have a string that is one character long and can be any possible character value:</p>
  
  <pre><code>irb(main):001:0&gt; "\x0"
  =&gt; "\u0000"
  </code></pre>
  
  <p>I thought this might work:</p>
  
  <pre><code>irb(main):002:0&gt; "\x0" += 1
  SyntaxError: (irb):2: syntax error, unexpected tOP_ASGN, expecting $end
  "\x0" += 1
          ^            from /opt/rh/ruby193/root/usr/bin/irb:12:in `&lt;main&gt;'
  </code></pre>
  
  <p>But, as you can see, it didn't. How can I increment/decrement my character?</p>
  
  <hr>
  
  <p>Edit:</p>
  
  <p>Ruby doesn't seem to be set up to do this. Maybe I'm approaching this the wrong way. I want to manipulate raw data in terms of 8-bit chunks. How can I best accomplish that sort of operation?</p>