-
Notifications
You must be signed in to change notification settings - Fork 38
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cmakepp custom return() command gives warnings in some cases #127
Comments
Hi Manu, You are right: the UX should be the prime focus for cmakepp and I too have had the issue with the warning that no PARENT_SCOPE exists when on the root level of scopes. There is no reliable way for detecting wether or not a PARENT_SCOPE exists and no way to suppress this warning to my knowledge (the latter would be the solution I would prefer most if it were possible) There should not be too many places that |
Well, let's follow C++ conventions and call this "Undefined Behavior" ;) I don't expect a |
seems consistent (kinda) |
that's |
no, I do mean raw I also noticed that some things might become faster because I do not have to |
Ah, I see.
really? My idea was to submit a PR this weekend with the changes :)
Haha, we can start sketching an optimizing backend for your cmake transpiler :P |
Ahh well if your already doing it then i'd be happy to accept the PR :D if I do it I do not know how long it will take :/ |
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 nakedreturn()
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 asPARENT_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.
The text was updated successfully, but these errors were encountered: