From: Phil Jackson Date: 2006-06-06T00:30:21+09:00 Subject: Inheritance from c Hi All, I'm messing about with inheritance from my C application but can't get it to work properly. Here is a quick overview of what I want to achieve: class Hello should parent Helloworld. Both use Data_Wrap_Struct to wrap up and struct whos memory is allocated with ALLOC. Silly example: struct Hello_struct { VALUE name; } struct Helloworld_struct { VALUE count; } The trouble is when I try to call a function from a Helloworld instance that reads/writes to a copy of the Hello_struct I get a segfault. This implies to me that memory is not being allocated for Hello_struct. Do I have to tell Heloworld that space for Hello needs to be allocated? If so how? Confused, Phil