improve error messages for directives - add directive and attribute
names to messages