In a heavy saucepan whisk together sugar, cornstarch, and a pinch salt. Chop chocolate and add to sugar mixture. In a bowl whisk together milk and egg yolk and gradually whisk into chocolate mixture. Bring mixture just to a boil over moderate heat, whisking constantly, and boil 1 minute, whisking. Remove pan from heat and whisk in butter and vanilla. Divide pudding between 4 (8-ounce) ramekins. Chill puddings in freezer, surfaces covered with plastic wrap, until cooled, about 30 minutes.