RUNS: LuaStack refactored, ReadDirChanges fix

LuaStack refactored into templates for most of the functions, with explicit
instantiations for the types that are supported. For unsupported types, an
exception is thrown, because it is an exceptional code case which should
not be allowed to continue, and should be fixed promptly.

The ReadDirectoryChanges class used a list to store the notifications, which
sometimes had an error in reading the front of the list (due to multithreading).
Changed it to a vector and use a circular buffer principle, so it should be fine now.

NOTE: i should probably replace the vector with a plain array...