colon to invoke methods

This commit is contained in:
Junseo Yoo 2024-07-01 11:48:31 -07:00
parent 0cc4a86dca
commit 96611f14cb

View file

@ -25,11 +25,11 @@ end
For instance, the `rawget` type function can be written as:
```luau
type function rawget(tbl, prop)
if (~tbl.istable()) then
if (~tbl:istable()) then
error("First parameter of rawget is not a table!") -- fails to reduce
end
return tbl.getprops()[prop.getvalue()]
return tbl:getprops()[prop:getvalue()]
end
type Person = {