libprimis icon indicating copy to clipboard operation
libprimis copied to clipboard

Reduce deep nesting in `command.cpp`

Open no-lex opened this issue 4 years ago • 0 comments

Parts of command.cpp are nested 11-deep, making the code almost impossible to parse. This should be flattened to about half as deep if possible. command.cpp handles Cubescript functionality and is therefore quite important to the integrity of the scripting and UI side of the engine.

The worst offenders are compilelookup() (9-deep) and compilestatements() (11-deep), but this deep nesting occurs elsewhere as well.

no-lex avatar Apr 28 '20 05:04 no-lex