In an answer to another question, someone jokingly mentioned using <: :>
instead of []
for array subscripting. I had never heard of this, and apparently neither has Google, so I did a bit of testing and found that all the way back in C compilers, <:
is interchangable with [
and :>
is interchangable with ]
, IE:
int* ptr;
ptr<:0:>;
ptr<:0];
ptr[0:>;
All compile and mean the same thing. What was the purpose of this operator?