Don't pass type via ret_handles, it's already known
Fix NaClPromise wrapper
Experimenting with promises
.
works
Move promise code into its own file
Fix a couple of licenses