only if it's too high power at a certain rpm

it could cope with an infinitely high power if it was at infinitely high rpm and hence torque is practically zero*
*although the shaft would break with extremely high rpm, but from a different failure mechanism, and the engine or gearbox would probably fail first