Place sugar and cream in a heavy, medium-sized saucepan and bring mixture to a boil.
Reduce to a simmer and cook for 8 minutes.
Remove from heat and add chocolate and butter, cut into little pieces. Mix well.
When chocolate and butter are completely melted, add pinch of salt (optional) and vanilla extract.
Place in refrigerator until mixture has cooled.
If necessary, beat with a spoon or whisk until frosting is the right consistency for frosting the cake.