3 ms·
> Is it so difficult to create an object by just setting some attribs and tagging the table with a name? Is it so difficult to create a struct by just memcpy-i
by Joker_vD 3y ago
> Is it so difficult to create an object by just setting some attribs and tagging the table with a name?
Is it so difficult to create a struct by just memcpy-ing some data into a malloc-ed buffer and not even putting a tag anywhere? No, it is not. Neither is reading the fields back by using the pre-computed offsets. But people for some reason dislike writing such easy code by hand.
- caligian 3y agoUsing a table is still simpler because people literally use dicts everywhere without actually thinking of them as containers but only as 'lookup containers'