Bring heavy cream and whole milk to a simmer in a small saucepan over medium heat.
In a separate, medium-sized bowl, whisk together egg yolks, cornstarch (optional), sugar, and salt.
Slowly whisk the hot cream/milk into the egg mixture and then pour the mixture back into the saucepan, keeping over medium heat.
Keep stirring, constantly, until the mixture thickens enough to coat the back of the spoon, about 4 minutes. Make sure to be scraping the bottom of the saucepan while you stir, so the eggs don’t curdle.
Put bittersweet chocolate in a separate medium-sized bowl and pour custard mixture over it. Let sit for 1-2 minutes, before stirring to ensure that all the chocolate melts into a smooth mixture.