24. Inline Functions

Question.5

A developer marks a 20-line error handler as inline. It's called from 50 different locations in the firmware:

inline void handle_error(int code) {
   // 20 lines: log, save state, reset peripheral
   log_error(code);
   save_crash_dump();
   reset_peripheral();
   // ... more lines ...
}

If the compiler honors the inline request, what happens to Flash usage?

Need Help? Refer to the Quick Guide below

Select Answer