[<<][c][>>][..]
Fri Aug 17 16:43:27 EDT 2012

C eval

I need a simple way to convert a C string to .bin for data structures.
Something like:

int eval(const char *c_init, void *buf, int bufsize);

Which could evaluate "int a[] = {1,2,3};" to binary:
01 00 00 00 02 00 00 00 03 00 00 00

The script part of it seems relatively easy.  Run make and dump the
.bin to stdout.  How to do the spawn?




[Reply][About]
[<<][c][>>][..]