Translation of C struct to D

Michael Kremser mkspamx-usenet at yahoo.de
Thu Nov 17 06:30:18 PST 2011


Am 2011-11-16 23:23, schrieb Trass3r:
>> If I try to cast with register_chrdev(0, (char*)DEVICE_NAME, &fops);
>> the following error appears:
>>
>> C style cast illegal, use cast(char*)DEVICE_NAME
>
> Or use DEVICE_NAME.ptr

Compilation now succeeded, but when I try to load with insmod, the 
following errors appear:

Nov 17 15:03:49 eeepc1104 kernel: [43799.326876] hello: Unknown symbol 
_D3std6string12__ModuleInfoZ (err 0)
Nov 17 15:03:49 eeepc1104 kernel: [43799.327297] hello: Unknown symbol 
register_chrdev (err 0)
Nov 17 15:03:49 eeepc1104 kernel: [43799.327702] hello: Unknown symbol 
_D15TypeInfo_Struct6__vtblZ (err 0)
Nov 17 15:03:49 eeepc1104 kernel: [43799.328252] hello: Unknown symbol

Best regards

Michael


More information about the Digitalmars-d mailing list