What does the __index variable in Lua do? | Sololearn: Learn to code for FREE!
Nouvelle formation ! Tous les codeurs devraient apprendre l'IA générative !
Essayez une leçon gratuite
0

What does the __index variable in Lua do?

When I'm defining a metatable for oop I want to use that, but I don't get what it does, can anyone explain it to me?

3rd Sep 2017, 5:57 PM
Elias
Elias - avatar
1 Réponse
+ 4
https://www.lua.org/pil/13.4.1.html Since there are no Lua courses on SoloLearn, I would recommend you to use stack overflow instead for better answers
3rd Sep 2017, 6:28 PM
Dapper Mink
Dapper Mink - avatar