Attitudes toward masturbation reflect attitudes toward sex generally. But because masturbation to discharge has no other purpose than pleasure (and perhaps self-awareness), the personal and social reaction to it reveals pleasure-anxiety more plainly than even the reaction to coitus. It is possible to engage in sex in order to perform for the aggrandizement of the ego, or to submit to sex to prove loyalty or earn love. These distorted motives, as well as the motive of reproduction, are not available for masturbation.
Masturbation is a natural act for all children and adults. Because masturbation will naturally occur much earlier than sexual activity with others, it represents a 'first opportunity' for a negative environmental response. If one does not know and understand how one can experience pleasure with one's body, it is not possible to find others a source of pleasure of any sort. Love is based on pleasure shared. Masturbation may be a more limited experience than sex with another person, lacking superimposition, but it is an essential part of sexual development and maintenance.
A distinction might well be made between masturbation with the intent of genital discharge and 'mere' genital touching, especially with children. In sexual behavior, genital manipulation helps focus sexual energy into the genitals. However, because the genitals are more strongly connected to the parasympathetic part of the autonomic nervous system, touching the genital may serve sometimes as a calming mechanism more than a focusing mechanism, and this is even more likely with pre-pubescent and especially very young children.