Line a baking sheet with a lightly buttered sheet of aluminum foil (or to reduce the chance of getting greasy brittle use parchment without buttering)
Optional but highly recommended: heat oven to 200F and warm the baking sheet to get it ready for the last step.
In a heavy, medium-sized saucepan, combine the butter, sugar, and corn syrup and warm over medium-low heat
Stir occasionally and continue heating until the temperature reaches 290 degrees on a candy thermometer (approximately 20 to 30 minutes, will depend on the power of your burner)
NOTE: If you're not using a candy thermometer, you may need 1 teaspoon of baking soda. But first, test the mixture after it darkens and looks like lava by dropping in a teaspoonful in very cold water. It is finished when it separates into hard threads that soften when removed from water. If your threads remain brittle after removing from water, add 1 teaspoon of baking soda and stir a little before you add the cashews.
Remove pan from heat and stir in cashews or peanuts.
Pour the mixture onto the prepared baking sheet, and spread across the pan
Let the mixture cool for 10 minutes and then transfer to the refrigerator for 5 more minutes.
Break into individual serving size, and store in an airtight container