CppEditor: Fix crash in InsertQtPropertyMembers for invalid code

Change-Id: I8a3a3240033d23aa9e3df5276c4e6302d97f71b9
Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>