prefix of "OP_TFORCALL" and "OP_TFORLOOP"

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

prefix of "OP_TFORCALL" and "OP_TFORLOOP"

Hugo
Hi, everyone

Opcode "OP_TFORCALL" and "OP_TFORLOOP" are for "generic for loop", I'm curious about what is the prefix "T" stands for ?  Does it mean "Type" ?


 

Reply | Threaded
Open this post in threaded view
|

Re: prefix of "OP_TFORCALL" and "OP_TFORLOOP"

Luiz Henrique de Figueiredo
> Opcode "OP_TFORCALL" and "OP_TFORLOOP" are for "generic for loop", I'm curious about what is the prefix "T" stands for ?

It means "table". It's from the time before the generic for, when
there was a table loop: for k,v in t do ... end.