Error handling for embedded non-struct types

Fixes #17.