quote keys in library objects when necessary; fixes #1908