Fix crash when using tagof(tagname:)

This fixes #18.