Children born to mothers who take heartburn medication during pregnancy may have a greater risk of developing asthma, research suggests.