showbc: Add quotes around (some) string args, to show empty string properly.

This commit is contained in:
Paul Sokolovsky 2014-04-12 16:18:40 +03:00
parent d6c5d398fe
commit faf84491ce

View File

@ -98,7 +98,7 @@ void mp_byte_code_print(const byte *ip, int len) {
case MP_BC_LOAD_CONST_ID: case MP_BC_LOAD_CONST_ID:
DECODE_QSTR; DECODE_QSTR;
printf("LOAD_CONST_ID %s", qstr_str(qstr)); printf("LOAD_CONST_ID '%s'", qstr_str(qstr));
break; break;
case MP_BC_LOAD_CONST_BYTES: case MP_BC_LOAD_CONST_BYTES:
@ -108,7 +108,7 @@ void mp_byte_code_print(const byte *ip, int len) {
case MP_BC_LOAD_CONST_STRING: case MP_BC_LOAD_CONST_STRING:
DECODE_QSTR; DECODE_QSTR;
printf("LOAD_CONST_STRING %s", qstr_str(qstr)); printf("LOAD_CONST_STRING '%s'", qstr_str(qstr));
break; break;
case MP_BC_LOAD_NULL: case MP_BC_LOAD_NULL:
@ -452,12 +452,12 @@ void mp_byte_code_print(const byte *ip, int len) {
case MP_BC_IMPORT_NAME: case MP_BC_IMPORT_NAME:
DECODE_QSTR; DECODE_QSTR;
printf("IMPORT_NAME %s", qstr_str(qstr)); printf("IMPORT_NAME '%s'", qstr_str(qstr));
break; break;
case MP_BC_IMPORT_FROM: case MP_BC_IMPORT_FROM:
DECODE_QSTR; DECODE_QSTR;
printf("IMPORT_FROM %s", qstr_str(qstr)); printf("IMPORT_FROM '%s'", qstr_str(qstr));
break; break;
case MP_BC_IMPORT_STAR: case MP_BC_IMPORT_STAR: