mirror of
https://github.com/luau-lang/luau.git
synced 2025-05-04 10:33:46 +01:00
Update rfcs/generalized-iteration.md
Co-authored-by: vegorov-rbx <75688451+vegorov-rbx@users.noreply.github.com>
This commit is contained in:
parent
57b7d723bf
commit
e69aaa400f
1 changed files with 1 additions and 1 deletions
|
@ -50,7 +50,7 @@ To support self-iterating objects, we modify the iteration protocol as follows:
|
|||
|
||||
```lua
|
||||
if getmetatable(gen) and getmetatable(gen).__iter then
|
||||
gen, state, index = getmetatable(state).__iter(gen)
|
||||
gen, state, index = getmetatable(gen).__iter(gen)
|
||||
end
|
||||
```
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue