* SUMMARY The UChar and DeprecatedChar structs have implicit assumptions that they are two bytes on all platforms. It would be nice if there were compile-time assertions that prevented the project from compiling if these assumptions are ever violated. * NOTES A Google search yielded some solutions: Compile Time Assertions in C (CVu 11.3) http://www.jaggersoft.com/pubs/CVu11_3.html Compile-Time Assertions & Debugging http://www.ddj.com/development-tools/184402051 Compile-Time Assertions http://www.ddj.com/architect/184401873
If this is possible, it would be really helpful to check sizeof all JSObject subclasses at compile time. The collector assumes a maximum size, but it's not checked at compile time.
wtf/Assertions.h has COMPILE_ASSERT, so we just need to use it.
Created attachment 26413 [details] patch
Comment on attachment 26413 [details] patch r=me
http://trac.webkit.org/changeset/39585