-
Notifications
You must be signed in to change notification settings - Fork 37
cmakepp custom return() command gives warnings in some cases #127
Description
Hi Tobias,
I'm having some issues related to the way you handled #3: Your return() command overrides the default CMake one so if you do a naked return() invocation in a module for example (As many CMake built-in modules do) you end up with warnings about the module not having a parent scope.
I would consider using a CACHE variable for __ans instead. I know this is not as performant as PARENT_SCOPE, but most scripts using cmakepp have already a noticeable slowdown by the temporary file creation for dynamic function invocation and the like. I don't specially care about performance when using cmakepp, I care about expressiveness and the huge amount of extra tools I have. So picking UX in favor of performance would be fine for me. What do you think?
Thanks.