cher-nov / Gena

Generic pseudo-templated containers for C. Written entirely in C89 with design inspired by the C++ STL. /// DOCS ARE SLIGHTLY OUTDATED, PROJECT IS STABLE AND STILL BEING DEVELOPED
https://habr.com/ru/post/324210/
Do What The F*ck You Want To Public License
89 stars 6 forks source link

Add support for static array types #9

Closed cher-nov closed 7 years ago

cher-nov commented 7 years ago

They're cannot be naively assigned through = operator, so we need to add something like GENA_COMPARE_NAIVE / GENA_COMPARE_MEMCMP / GENA_COMPARE_STRCMP, but for assignment, say GENA_ASSIGN_NAIVE / GENA_ASSIGN_MEMCPY / GENA_ASSIGN_STRCPY.

We also may want to add G***_INSTANTIATE_EX and so on, which will support additional argument for assignment type. That's useful because array types are such a rare and specific case, and all other types can (and should) use naive assignment.

cher-nov commented 7 years ago

Successfully implemented for genmap.

cher-nov commented 7 years ago

Successfully implemented for genvector.