mirror of
https://github.com/luau-lang/luau.git
synced 2025-05-04 10:33:46 +01:00
Change parameter type
This commit is contained in:
parent
a6c9a06237
commit
d07a8e531d
1 changed files with 1 additions and 1 deletions
|
@ -12,7 +12,7 @@ When debugging, it is often useful to compare identity. Usually `print` will pri
|
||||||
|
|
||||||
## Design
|
## Design
|
||||||
|
|
||||||
`debug.id(value: any): number` always returns the identifier unique to that value, and is not possible to override.
|
`debug.id(value: string | userdata | table | thread | function): number` always returns the identifier unique to that value, and is not possible to override.
|
||||||
|
|
||||||
While tables and userdata have individualized metatables, also allowing functions and threads to be passed to `debug.id` would let their type-level `__tostring` be redefined. Strings are useful to accept because of long, similar strings.
|
While tables and userdata have individualized metatables, also allowing functions and threads to be passed to `debug.id` would let their type-level `__tostring` be redefined. Strings are useful to accept because of long, similar strings.
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue