Makes .as more flexible
Merge pull request #51 from johnynek/feature/as-fix

Makes .as more flexible