ref abstract method

int ref(
  1. int idx
)

lua_unref equivalent. Stores the value at idx in the registry and returns an integer id to unref and get it. This is a strong reference, the object will not get garbage collected until it is unreffed.

Implementation

int ref(int idx);