This is harmful to children. The reason is that a child needs to understand that there are good limits to place on oneself for healthy reasons. For example, how is the child in the ice cream example able to learn about eating healthy portions, if you teach him that he can have whatever he wants, whenever he wants?
A better way is to say, no, and then teach with love. Say, "I wish we could all eat 5 scoops. Ice cream is yummy. But no, we have to try and stay healthy, and so we just eat 2 scoops." If the child resists, it is a good time to teach him about how healthy limits help us to stay happy and free of illness.
Saying "no" when appropriate and with love and teaching will help your child grow up to be a happy and healthy, high functioning adult in today's society.