[INTERPRETER]
* BUG: The PUSH CHAR byte code now works correctly with ASCII code greater than 127. git-svn-id: svn://localhost/gambas/trunk@6481 867c0c6c-44f3-4631-809d-bfa615b0a4ec
This commit is contained in:
parent
5b6e0d2b82
commit
a3c59253f6
6 changed files with 6 additions and 7 deletions
|
@ -977,7 +977,7 @@ static void add_string()
|
|||
i = xdigit_val(get_char_offset(2));
|
||||
if (i >= 0)
|
||||
{
|
||||
car = (car << 4) | i;
|
||||
car = (car << 4) | (uchar)i;
|
||||
*p = car;
|
||||
source_ptr += 2;
|
||||
continue;
|
||||
|
|
|
@ -717,7 +717,7 @@ _PUSH_INTEGER:
|
|||
|
||||
_PUSH_CHAR:
|
||||
|
||||
STRING_char_value(SP, (char)GET_UX());
|
||||
STRING_char_value(SP, GET_UX());
|
||||
SP++;
|
||||
goto _NEXT;
|
||||
|
||||
|
|
|
@ -1071,8 +1071,7 @@ __JAVASCRIPT:
|
|||
for (i = 0; i < lstr; i++)
|
||||
{
|
||||
c = str[i];
|
||||
//if (c >= ' ' && c <= 126 && c != '\\' && c != '"')
|
||||
if (c >= ' ' && c != '\\' && c != '\'')
|
||||
if (c >= ' ' && c <= 126 && c != '\\' && c != '\'')
|
||||
STRING_make_char(c);
|
||||
else
|
||||
{
|
||||
|
|
|
@ -999,7 +999,7 @@ static void add_string()
|
|||
i = xdigit_val(get_char_offset(2));
|
||||
if (i >= 0)
|
||||
{
|
||||
car = (car << 4) | i;
|
||||
car = (car << 4) | (uchar)i;
|
||||
*p = car;
|
||||
source_ptr += 2;
|
||||
continue;
|
||||
|
|
|
@ -134,7 +134,7 @@ void CODE_dup(void);
|
|||
|
||||
void CODE_return(int return_value);
|
||||
|
||||
void CODE_push_char(char car);
|
||||
void CODE_push_char(uchar car);
|
||||
void CODE_push_void(void);
|
||||
|
||||
void CODE_subr(short subr, short nparam, short optype, bool fixed);
|
||||
|
|
|
@ -1031,7 +1031,7 @@ void CODE_stop(void)
|
|||
#endif /* PROJECT_COMP */
|
||||
|
||||
|
||||
void CODE_push_char(char car)
|
||||
void CODE_push_char(uchar car)
|
||||
{
|
||||
LAST_CODE;
|
||||
|
||||
|
|
Loading…
Reference in a new issue