On Fri, Jun 26, 2015 at 7:33 PM, Michael Marcin
On 6/26/2015 3:42 AM, Emil Dotchevski wrote:
1) Character constants containing more than one character are implementation-defined (not portable).
2) The swizzling dispatch must be done at compile-time. You couldn't do this with an int argument to operator[].
3) operator[] must be a member function, and QVM operations work on user-defined types. You can, of course, define operator[] in your own types in terms of operator% from QVM.
So we're stuck with:
v%X *= 42; v%YXZ *= 42;
I'm not a TMP wizard and I haven't looked at your implementation but what about something like.
(v,yz)
This seems better than %, thanks. I need to think carefully if the , overload could somehow interfere with things like passing vectors to other functions. -- Emil Dotchevski Reverge Studios, Inc. http://www.revergestudios.com/reblog/index.php?n=ReCode