Fix missing return types.

Fixes #1352