summaryrefslogtreecommitdiffstats
path: root/itypes.c
Commit message (Collapse)AuthorAgeFilesLines
* ffi: bugfix: broken i64 conversion.Kaz Kylheku2017-05-121-1/+1
| | | | | * itypes.c (c_i64): Fix c_num being called on the function pointer num rather than the correct operand n.
* itypes: fix wrong error messages.Kaz Kylheku2017-05-041-5/+5
| | | | | * itypes.c (c_u8, c_u16, c_u32, c_u64, c_uint): Fix messages referring to signed version of type.
* Rename c_uint_ptr_num; introduce cunum typedef.Kaz Kylheku2017-04-211-3/+3
| | | | | | | | | | | | | | | Unsigned version of cnum becomes less verbose. * arith.c (c_uint_ptr_num): Renamed to c_unum. * arith.h (c_uint_ptr_num): Declaration removed. (c_unum): Declared. * itypes.c (c_u32, c_u64, c_uint): Follow rename. * lib.h (ucnum): New typedef. * rand.c (make_random_state): Follow rename.
* Continuing implementation of buffers.Kaz Kylheku2017-04-211-0/+232
* Makefile (OBJS): New objects itypes.o and buf.o. * buf.c, buf.h: New files. * itypes.c, itypes.h: New files. * lib.c (obj_print_impl): Handle BUF via buf_print and buf_pprint. (init): Call itypes_init and buf_init. * parser.h (end_of_buflit): Declared. * parser.l (BUFLIT): New exclusive state. (grammar): New rules for recognizing start of buffer literal and its interior. (end_of_buflit): New function. * parser.y (HASH_B_QUOTE): New token. (buflit, buflit_items, buflit_item): New nonterminals and corresponding grammar rules. (i_expr, n_expr): These symbols now generate a buflit; a buffer literal is a kind of expression. (yybadtoken): Handle HASH_B_QUOTE case.