Ask and you shall NOT receive

As

So when I was young my mum always told me that if I asked for anything I wouldn’t get it. Say if we were driving home from a holiday and we were passing McDonald’s, if I asked to get McDonald’s my mum would tell me no. If I didn’t ask however she might have gotten it for me. Is this a good thing to raise kids who aren’t entitled and spoilt or could it be a dangerous lesson in some way? Would you or do you tell your kid/s this and why or why not. Also I was told that at night the tv didn’t work so when I had a nightmare or something my mum didn’t have to stay up and watch tv with me. I think that was fine and wouldn’t be harmful at all but I’m not so sure about the whole asking and receiving thing.

Edit: I wasn’t starved or not allowed to eat, it was about treats and such. Say if I wanted ice cream at the mall, asked because I was hungry and got turned down, then we ate food at home. We could afford ice cream however it was supposed to be a lesson. I don’t totally agree with it but I don’t think it counts as abuse. I should have cleared it up before.