I've had this happen a few times. If I'm adding objects to the current layer using select/cancel and then undo then the "undo" will delete those items. This happened to me when I was trying to add a built house to the current layer. I was trying to delete a power line and accidentally deleted the house behind it. When I used "undo" the house didn't come back but the last item I selected for the layer was deleted instead. If I pressed undo again then more of the previously selected items were deleted.