On Sunday, 6 September 2015 at 10:24:25 UTC, Marc Schütz wrote:
Untested:struct Vector(T) { T[42] data; auto opDispatch(string func, Args...)(Args args)if(is(typeof(mixin("data."~func)(Args.init))) && func != "length"){ return mixin("data."~func)(Args.init); } }
Unfortunately not working, afaics the built in static array does not have the property opIndex et al. so they cannot be forwarded, right?