What does sugar do in baked goods?
Shirley Corriher from Cooking Light explains:
Sugar prevents the flour proteins from joining and making gluten; gluten development would make a cake or cookie tough. In this way sugar acts as a tenderizer and can replace some of the fat in the recipe. When sugar is present in amounts above 2 tablespoons per cup of flour, the two proteins in flour that normally join with each other and water to form gluten join with the sugar instead.
Sugar also caramelizes in baking, which enriches flavors. Substituting as little as a tablespoon of corn syrup for sugar can make cookies much browner, because corn syrup browns at a lower temperature than sugar. Some sugars, like honey and brown sugar, absorb moisture from the atmosphere, which means that things baked with them will stay soft and moist longer.