I think it does have a bit to do with it, but there are a lot of dependencies I think. For example a four year age gap means A LOT more in your teenage years where it means little in your adult years.
Personally I feel like you're pushing it at ten years. There are lots of things to consider when choosing someone to spend the rest of your life with. If you are thirty and marry someone who is fifty- your spouse may not live to see your first born get married- let alone see their grandchildren.
I've also read from personal stories of young girls falling in love with older men(can happen vice versa) becoming socially isolated. The older person doesn't want to be friends with a bunch of kids who like to party-hardy because he has moved past that, so she tries to befriend his friends but they're all so much older that she doesn't fit in. Thus he is the only person she can really talk to so she gets lonely.
So yes it has something to do with falling in love. It doesn't stop it from happening, just makes room for problems a couple who are about the same age probably wouldn't face.