Kautenja / PotatoChips

Eurorack modules based on programmable sound chip emulation.
Other
45 stars 4 forks source link

Appropriate Error Handling #35

Closed Kautenja closed 3 years ago

Kautenja commented 4 years ago

In many cases, debug assertions can be replace with exceptions in runtime code with no cost (assuming they never throw). In particular, errors can be thrown when:

This isn't useful for VCV Rack, but is useful when using the dsp code as a library in other projects. It's also more readable and clear.

Kautenja commented 3 years ago

Updated for the 10 chip emulations that rely on BLIPBuffer.

all exceptions implement the what() protocol to provide information about the cause of failure.