Combine sugar and water in a medium saucepan. Heat over low heat, stirring, until sugar has dissolved and the syrup is clear. Increase heat to medium-high and allow syrup to come to a boil.
Place yolks in the bowl of a stand-mixer fitted with the whisk (or, if using a handheld mixer, in a medium mixing bowl) and beat until thick and foamy.
Cook syrup until it registers 235°F, then immediately remove from heat. With the mixer running, slowly drizzle hot syrup into the bowl with the yolks: don't pour the syrup onto the whisk, or the syrup may splatter against the sides of the bowl; instead, aim for a spot close to the whisk.
Once all the syrup has been added, keep mixing until the bottom of the bowl feels cool to the touch and the yolk mixture has cooled to room temperature.
Add butter one cube at a time, beating well after each addition. Beat in vanilla and salt. Continue mixing until the buttercream looks smooth and creamy, about 5 minutes. (If the buttercream separates, keep mixing: it will come together eventually.)