Should the write functions use int64_t instead of long for row_count.
khc8749 opened this issue · 1 comments
khc8749 commented
Is there a good reason not to change these functions from
readstat_error_t readstat_begin_writing_dta(readstat_writer_t *writer, void *user_ctx, long row_count);
readstat_error_t readstat_begin_writing_por(readstat_writer_t *writer, void *user_ctx, long row_count);
readstat_error_t readstat_begin_writing_sas7bcat(readstat_writer_t *writer, void *user_ctx);
readstat_error_t readstat_begin_writing_sas7bdat(readstat_writer_t *writer, void *user_ctx, long row_count);
readstat_error_t readstat_begin_writing_sav(readstat_writer_t *writer, void *user_ctx, long row_count);
readstat_error_t readstat_begin_writing_xport(readstat_writer_t *writer, void *user_ctx, long row_count);
to
readstat_error_t readstat_begin_writing_dta(readstat_writer_t *writer, void *user_ctx, int64_t row_count);
readstat_error_t readstat_begin_writing_por(readstat_writer_t *writer, void *user_ctx, int64_t row_count);
readstat_error_t readstat_begin_writing_sas7bdat(readstat_writer_t *writer, void *user_ctx, int64_t row_count);
readstat_error_t readstat_begin_writing_sav(readstat_writer_t *writer, void *user_ctx, int64_t row_count);
readstat_error_t readstat_begin_writing_xport(readstat_writer_t *writer, void *user_ctx, int64_t row_count);
The read functions use int64_t for row_count
evanmiller commented
That would be a better design but would represent an API change as long
is 32-bit on Windows.