m
Move page script moved page API newproxy to WoW:API newproxy without leaving a redirect
(New page: {{wowapi}} __NOTOC__ <!-- Describe the purpose of the function, exhausting detail can be saved for a later section --> Creates a zero-size "userdata" object, optionally with a sharable me...) |
m (Move page script moved page API newproxy to WoW:API newproxy without leaving a redirect) |
||
| (One intermediate revision by one other user not shown) | |||
| Line 1: | Line 1: | ||
{{ | {{wowlua}} | ||
<!-- Describe the purpose of the function, exhausting detail can be saved for a later section --> | <!-- Describe the purpose of the function, exhausting detail can be saved for a later section --> | ||
Creates a zero-size "userdata" object, optionally with a sharable empty metatable. | Creates a zero-size "userdata" object, optionally with a sharable empty metatable. | ||
| Line 11: | Line 10: | ||
:(boolean or otherproxy) | :(boolean or otherproxy) | ||
:;boolean : Whether to create a metatable for the userdata. | :;boolean | ||
:;otherproxy : If an object previously created by newproxy is passed, the new userdata will share that proxy's metatable. | :: Whether to create a metatable for the userdata. | ||
:;otherproxy | |||
:: If an object previously created by newproxy is passed, the new userdata will share that proxy's metatable. | |||
| Line 18: | Line 19: | ||
<!-- List each return value, together with its type --> | <!-- List each return value, together with its type --> | ||
:;obj : Userdata (an opaque block of memory) | :;obj | ||
:: Userdata (an opaque block of memory) | |||
== Details == | == Details == | ||
The newproxy function is an undocumented part of the Lua 5 base library. | The newproxy function is an undocumented part of the Lua 5 base library. It is included here because it | ||
is used in the implementation of the Secure Headers added in WoW 3.0 (see FrameXML\SecureHandlers.lua), and | is used in the implementation of the Secure Headers added in WoW 3.0 (see FrameXML\SecureHandlers.lua), and | ||
addon authors looking over that code are likely to be curious about what it does. | addon authors looking over that code are likely to be curious about what it does. | ||
For more details, see http://lua-users.org/wiki/HiddenFeatures (including the links into the lua-users mailing | For more details, see http://lua-users.org/wiki/HiddenFeatures (including the links into the lua-users mailing | ||
list at the end of that section). | list at the end of that section). A concise summary is [http://lua-users.org/lists/lua-l/2003-01/msg00205.html here]. | ||