Rewrite some portions of the bridge

* support void function calls
* better error handling
* less code (hopefully more clear as well)