PaulStoffregen / USBHost_t36

USB Host Library for Teensy 3.6 and 4.0
166 stars 85 forks source link

Mark functions as properly pure virtual #125

Closed pr8x closed 11 months ago

pr8x commented 11 months ago

Not defining or marking a virtual function pure virtual (=0) is actually UB in C++:

C++03 Standard: 10.3 Virtual functions [class.virtual]

A virtual function declared in a class shall be defined, or declared pure (10.4) in that class, or both; but no diagnostic is required (3.2).

This was actually causing obscure linker issues in debug mode (see here)