fixed schema type handling for maps and pairs, added tests, closes #954
Merge pull request #957 from scopatz/stmid

fixed schema type handling for maps and pairs, added tests, closes #954