[cfe-dev] Changing the size of ConstantArrayType

Dimitrij Kotrev dimitrij.kotrev at googlemail.com
Tue Feb 1 00:37:51 PST 2011


> That's actually implementable in Clang, but the problem you're trying to solve can't be solved in the general case. I could have one .cpp file with
> a Derived3 that is 1000 bytes long and another .cpp file with a Derived4 that's 2000 bytes. So Other's buffer would end up being 1000 bytes in
> one file and 2000 bytes in the other, and you'll crash when trying to pass Other from one translation unit to another.

That's ok, because my programs consist of just one translation unit. I
already can calculate the max size of a class hierarchy.
Last thing that was missing is changing the size of an array. But
since this looks very difficult to do, i think i'm going to try


More information about the cfe-dev mailing list