@StudentScripter When you set an item in the model, the model becomes the owner of the item and thus controls its lifetime. If calling removeRows would leave the item(s) it contains intact, you would just have a memory leak by now.
Then please mark the model as solved using the "Topic Tools" button or the dotted menu beside the answer you deem correct so that other forum users may know a solution has been found :-)
Interesting, a clean build later it works fine. That's unexpected.
Still silly of me not to try that first - my bad. Sorry guys! Thanks for your help though, much appreciated!