[svn r104] TONS OF FIXES.

Split up declaration, constant initializer gen and definition for globals, structs, classes and functions.
Improved ClassInfo support (not complete), not in vtable yet.
Fixed a bunch of forward reference problems.
Much more. Major commit! :)
This commit is contained in:
Tomas Lindquist Olsen
2007-11-16 08:21:47 +01:00
parent 7d6bbcd87d
commit d1cfe9524c
35 changed files with 1824 additions and 1452 deletions

View File

@@ -88,40 +88,6 @@ void _d_array_init(void* a, size_t na, void* v, size_t nv)
}
}
// array comparison routines
bool _d_static_array_eq(void* lhs, void* rhs, size_t bytesize)
{
if (lhs is rhs)
return true;
return memcmp(lhs,rhs,bytesize) == 0;
}
bool _d_static_array_neq(void* lhs, void* rhs, size_t bytesize)
{
if (lhs is rhs)
return false;
return memcmp(lhs,rhs,bytesize) != 0;
}
bool _d_dyn_array_eq(void[] lhs, void[] rhs)
{
if (lhs.length != rhs.length)
return false;
else if (lhs is rhs)
return true;
return memcmp(lhs.ptr,rhs.ptr,lhs.length) == 0;
}
bool _d_dyn_array_neq(void[] lhs, void[] rhs)
{
if (lhs.length != rhs.length)
return true;
else if (lhs is rhs)
return false;
return memcmp(lhs.ptr,rhs.ptr,lhs.length) != 0;
}
// for array cast
size_t _d_array_cast_len(size_t len, size_t elemsz, size_t newelemsz)
{