Skip to content

cmState: return by-reference from GetCommand() and GetCommandByExactName()

Oleksandr Koval requested to merge OleksandrKvl/cmake:optimize-commands into master

Returning std::function by-value from cmState::GetCommandByExactName() could be quite expensive, return by-reference to make it cheaper.

I delay MR that stores cmListFileFunction as a shared_ptr because there might be some merge conflicts, I think this one should be merged first, tell me if you want it in another way.

Edited by Oleksandr Koval

Merge request reports