Preheat oven to 350° F.Coat an 8-inch-square baking pan with butter. Add a spoonful of flour, tilt to coat, and tap out any excess; set aside.In a double boiler or a large heatproof bowl placed over a pan of simmering water, combine the chocolate and butter. Heat, stirring occasionally, until the chocolate melts. Remove from heat; let cool. Meanwhile, combine the flour, baking powder, and salt in a medium bowl; set aside.Whisk the eggs and vanilla extract in a large bowl until foamy. Add the sugar and whisk until light and frothy, about 1 minute. Slowly stir in the cooled chocolate mixture. Add the flour mixture in 2 batches, whisking until incorporated after each addition. Scrape the batter into the prepared pan. Bake until a skewer or toothpick inserted 1 inch from the edge of the pan comes out clean, 20 to 25 minutes (a bit of moist batter should cling to the skewer). Transfer the pan to a rack to cool for 10 minutes before slicing.