Thursday, 31 July 2014

Operators

Before handling virtual functions, I fixed up operators. You can now export operators, you can access operator members and use them as expressions, you can access operators statically, etc. You can also have dynamic operators when before they were banned.

I need to switch to Ubuntu to try and figure out why 209 tests suddenly failed on TeamCity, though.

So up next I promise: virtual functions. I already added support for final classes.

I also removed "auto" as a feature. Previously when doing type-inferred arguments, you could use "auto" as the decayed argument, so you could do e.g. "f(arg := auto.lvalue)" that would only accept lvalues. I removed this feature because it's redundant in the face of concepts and complicated the implementation for little benefit.

I'm also hunting to reduce ABI dependence. The MinGW x64 ABI is quite similar to Itanium but the EH is different. This obviously isn't a big deal for me, pretty much all the work is done on the LLVM side and not the Wide side. But in general, I have a bunch of stuff which is full of Itanium-specific details, like layout, vtables, RTTI and such.

Also turns out that I totally mis-implemented Itanium ABI for function calling, so parameters you pass by value to C++ functions will be incorrectly not destroyed, and there are other destructor bugs w.r.t. this misinterpretation that I wish to fix. It also makes my life easier w.r.t. elision in many ways. I'm a big fan of this and this fix because it only removed complexity from the compiler.

No comments:

Post a Comment