mirror of
https://github.com/luau-lang/luau.git
synced 2024-11-15 22:35:43 +08:00
Update index.md
This commit is contained in:
parent
a78be01124
commit
a0cd6aa160
@ -5,7 +5,7 @@ Luau is a fast, small, safe, gradually typed embeddable scripting language deriv
|
|||||||
```lua
|
```lua
|
||||||
type Point = { x: number, y: number }
|
type Point = { x: number, y: number }
|
||||||
|
|
||||||
local p = { x = 1, y = 2 }
|
local p: Point = { x = 1, y = 2 }
|
||||||
|
|
||||||
print(p.x, p.y)
|
print(p.x, p.y)
|
||||||
-- print(p.z) results in a type error
|
-- print(p.z) results in a type error
|
||||||
|
Loading…
Reference in New Issue
Block a user