Add generic support to CF build; fixes #327

This PR ports generic support to CF using fixes created by Neil in his Crestron build. Any further problems with this feature should have new issues created so we can work them in priority order.
These methods are tested indirectly by the tests that have been enabled for the CF build, but the cyclomatic complexity of this method and the TypeArrayIterator is fairly high, so it would be nice if these had some more direct tests. The tests would also better document the intentions. They are internal and should stay that way, but we could mark this assembly internals visible to the test assembly since it is signed.