Refactor and also write in idiomatic lua

1. lua provides a meta-method __tostring for conversion to strings from other types
2. Put the expected value first, and the actual value second in assert statements
3. Replace if/then/else with regex that uses a quantifier ?, to ignore 1
4. Use string.gsub instead of string:gsub, to allow both strings and numbers in constructor
Refactor and also write in idiomatic lua

1. lua provides a meta-method __tostring for conversion to strings from other types
2. Put the expected value first, and the actual value second in assert statements
3. Replace if/then/else with regex that uses a quantifier ?, to ignore 1
4. Use string.gsub instead of string:gsub, to allow both strings and numbers in constructor
Merge branch 'master' of github.com:aarti/xlua
Merge pull request #48 from aarti/master

Refactor and also write in idiomatic lua