View previous topic :: View next topic |
Author |
Message |
baxissimo
Joined: 23 Oct 2006 Posts: 241 Location: Tokyo, Japan
|
Posted: Tue Feb 17, 2009 12:58 am Post subject: Const problem with DerelictFT |
|
|
In fttypes.d there's this struct:
Code: | struct FT_Open_Args
{
FT_UInt flags;
const FT_Byte* memory_base;
FT_Long memory_size;
FT_String* pathname;
FT_Stream stream;
FT_Module driver;
FT_Int num_params;
FT_Parameter* params;
}
|
That const generates an error now with DMD 1.040 when you try to set the memory_base member. (Could have been added anywhere between 1.038 and 1.040).
Anyway, what is the intent? If it is that the bytes be const but not the pointer, as in C, such a thing does not work in D. And according to Walter you should just remove it for D1.
For D2 if it's trying to do const-bytes unconst pointer, then it should be
Code: | const(FT_Byte)* memory_base;
|
|
|
Back to top |
|
|
aldacron
Joined: 05 May 2004 Posts: 1322 Location: Seoul, South Korea
|
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|