Obviously the nutrient quality of your food matters so a calorie is scientifically not just a calorie. But for practical purposes it is. What the average fatso does is look at a bunch of soda or cookies with “natural sugar” and decides “oh look no high fructose corn syrup. I can eat the whole box.” I see alot of people delude themselves into thinking they can get away with eating a ton of fruit or drinking gallons of orange juice. Bottom line is moderating your sugar/carb intake while creating an overall calorie deficit is the key to losing weight. Just avoiding the real crap like refined flour and HFCS will make you feel better but won’t necessarily make you lean.
But in the study, the rats ingested exactly the same thing in the exact same amounts, and the ones who had HFCS got fatter. It wasn't nutrient quality in the food, the only difference was switching sugar with HFCS.