View Single Post
07-10-14, 04:54 PM   #14
Phanx
Cat.
 
Phanx's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2006
Posts: 5,617
getglobal(x) doesn't just essentially return _G[x] -- it literally does that:

Code:
function getglobal(varr)
  return _G[varr];
end
It's defined in FrameXML/UIParent.lua. There is absolutely no reason to ever use getglobal in actively maintained or newly written code. The only excuse for it to be used anywhere would be in ancient code that still works but is not being maintained by anyone.
__________________
Retired author of too many addons.
Message me if you're interested in taking over one of my addons.
Don’t message me about addon bugs or programming questions.
  Reply With Quote