<div class="gmail_quote">2011/9/22 Zariko Taba <span dir="ltr"><<a href="mailto:zariko.taba@gmail.com">zariko.taba@gmail.com</a>></span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div id=":9n">[translation:ERROR] ValueError: character code not in range(256)<br><br>With this snippet of code :<br><br>self.constants_dict[key] = 256 - len(constants)<br>
<br>If len(constants) is 257,<br>then self.constants_dict[key] is -1<br>and chr(-1) raise the ValueError.<br><br>I attached a (really) stupid example to reproduce.<br>When I browse pypy sources in rpython, I can't believe there is less than 256 constants of type 'ref'.<br>
<br>What do you think ? Did I miss something ?<br></div></blockquote></div><br>There are many string constants in your function.<div>Did you try something like</div><div> raise Exception("Opcode not implemented : %d" % opcode)<br clear="all">
<div><br></div>-- <br>Amaury Forgeot d'Arc<br>
</div>