Revert pairs and ipairs to their lua implementation

They were changed because it was not possible to iterate over __index
metamethods. However, with this implementation, it is ONLY possible to
iterate over the table specified in __index.

Furthermore, the implementation of ipairs was iterating over some string
indices, as well.

Fixes #137
Merge pull request #138 from Xandaros/iss137

Revert pairs and ipairs to their lua implementation