I am reading a book for English languages learners, Oliver Twist, and there are two parts that surprise me. Both have the same form. I have copied the text word for word:
But the magistrate sentenced him to three months in prison, with hard labour, and the boy would have been taken away to prison had it not been for the owner of the bookshop, who rushed into the office and at this point advanced towards the bench.
The second one:
The fellow touched his hat with a smile, expecting something for his trouble; but the old gentleman looked at him with and expression of dislike, and would have run away himself had not a police officer at that moment made his way through the crowd and seized Oliver by the collar.
I understand what it means but I'm surprised because there is no "if" before "had".
For example, why isn't it written "and would have run away himself if there had not a police officer" or something like this in the second part?
Please, could you explain this to me? I can't find a rule about that.
Thank you so much.