Hey @rgamble,
Currently I am trying to read an export of a government website, which contains fixed size fields such as DOB, mobile number, etc and where names and country specific ID numbers have a hard limit.
For reading contents of known size, it be would be great to get pointer and size of the csv fields of the given buffer when receiving callback instead of the internally allocated one.
Since void *, size_t combo is already provisioned in void cb1(void *s, size_t len, void *data), it would be possible to implement this without breaking the ABI and I hope it could be introduced as an option via int csv_set_opts(struct csv_parser *p, unsigned char options). CSV_NO_ALLOC perhaps?
This feature would be extremely useful when the file we are reading is large, but well within the limits of the total memory. Say 15-100 mb, which could be easily mmaped for a better performance.
Hey @rgamble,
Currently I am trying to read an export of a government website, which contains fixed size fields such as DOB, mobile number, etc and where names and country specific ID numbers have a hard limit.
For reading contents of known size, it be would be great to get pointer and size of the csv fields of the given buffer when receiving callback instead of the internally allocated one.
Since
void *, size_tcombo is already provisioned invoid cb1(void *s, size_t len, void *data), it would be possible to implement this without breaking the ABI and I hope it could be introduced as an option viaint csv_set_opts(struct csv_parser *p, unsigned char options). CSV_NO_ALLOC perhaps?This feature would be extremely useful when the file we are reading is large, but well within the limits of the total memory. Say 15-100 mb, which could be easily mmaped for a better performance.