Schematic for common buck/boost converter designs
The basic circuit comes from National (now TI) datasheet.
The application examples show Buck Boost.
The CC part relies on LM358 dual OP AMP and LM78L05 voltage regulator.
Normally the voltage control loop is in charge. When load current exceeds a value preset by an adjustable divider from LM78L05 5V, the current limiting loop takes over (the voltage sags as required to contain the current. It is achieved by pulling the FB pin above its nominal 1.24V (making LM2577 see excessive voltage i.e. lower the duty cycle)