Skip to content

Commit

Permalink
Fix hexChar for inputs 0 <= i < 10
Browse files Browse the repository at this point in the history
  • Loading branch information
Anonymous Maarten authored and Dimitri van Heesch committed Oct 20, 2015
1 parent ace0af4 commit 327422d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion vhdlparser/TokenMgrError.cc
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ namespace parser {
// i < 16 - guaranteed
char hexChar(int i) {
if (i < 10) {
return i - '0';
return i + '0';
}
return 'a' + (i - 10);
}
Expand Down

0 comments on commit 327422d

Please sign in to comment.