Add support for dict style roledefs

Fixes #1097