python alternatives to C structs??
KoolD
sourya.s7 at gmail.com
Sat Apr 18 15:25:29 EDT 2009
Hey all,
I need to convert a C code to python please help me figure out how to
do
it.
Suppose the C program's like:
------------------------------------
typedef struct _str
{
int a;
char *b;
int c;
}str;
int main()
{
str mbr;
fd=open("/dev/sda",O_RDONLY);
read(fd,&mbr,sizeof(str));
}
------------------------------------
Is there a way to code it in python.
Thanks
Sourya
More information about the Python-list
mailing list