In a medium heat-proof bowl, whisk the egg yolks until smooth (you'll be using them soon).
In a medium saucepan, whisk together the sugar, cornstarch and salt. Whisk in the milk.
Place the saucepan over medium heat and cook, whisking constantly, until the milk comes to a simmer, about 5-8 minutes—don’t be tempted to walk away during this time (whisking constantly will prevent the bottom from browning and will create a smooth texture). Remove the pan from the heat.
Using a ladle, slowly pour about 1 cup of the hot milk mixture into the bowl with the egg yolks while whisking (this is called tempering the eggs and will prevent them from curdling in the hot liquid). Pour the egg mixture back into the saucepan in a slow, steady stream while whisking.
Put the saucepan over medium-low heat and cook, whisking, until the pudding starts to bubble and thicken, about 1-2 minutes (it will continue to thicken as it chills). Remove the pan from the heat and stir in the butter pieces and vanilla paste (for a lightly almond-scented pudding, add ¼ teaspoon of almond extract as well).
Pour the pudding into a storage container or bowl (if some of the egg has curdled, or if the bottom has browned, pour the pudding through a mesh strainer). Cover the pudding with plastic wrap, placing it directly on the surface of the pudding (this will prevent a skin from forming).
Refrigerate the pudding for at least 2 hours, or for up to 5 days (it will thicken as it cools). Whisk or stir the pudding before serving.