1. I was looking at an addon and got a little confused by how LibStub was used - the addon was using a library called ScrollingTable (or externally, lib-st), and I saw in that library the call to LibStub:NewLibrary(), etc, but the main addon seems to be making a call that looks like:

    local ScrollingTable = LibStub("ScrollingTable")

    What does using the library name like a function call do? I've looked at the book and the WoWwiki page and can't seem to find a mention of that syntax. I'm sure it's hiding right in front of me 8^).

    It's a bit of magic, but LibStub("Foo") is the same as LibStub:GetLibrary("Foo"). This is accomplished via the __call metamethod in the LibStub table. You can read more about that metamethod in the book (the index should show the pages for it).

    That was fast 8^). Thanks, figured it was probably in there somewhere.