Checks for type 'int' added to binary header

The structure 'AbsLineInfo' is hard-dumped into binary chunks, and
it comprises two 'int' fields.
This commit is contained in:
Roberto Ierusalimschy
2025-03-10 15:21:32 -03:00
parent cb88c1cd5d
commit b5b1995f29
4 changed files with 67 additions and 36 deletions

View File

@@ -17,8 +17,9 @@
/* data to catch conversion errors */
#define LUAC_DATA "\x19\x93\r\n\x1a\n"
#define LUAC_INT 0x5678
#define LUAC_NUM cast_num(370.5)
#define LUAC_INT -0x5678
#define LUAC_INST 0x12345678
#define LUAC_NUM cast_num(-370.5)
/*
** Encode major-minor version in one byte, one nibble for each