-
Notifications
You must be signed in to change notification settings - Fork 8
Replace goto statements #319
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
base: main
Are you sure you want to change the base?
Conversation
|
Moving @chipbarnaby's comment here. |
|
@chipbarnaby Would it be ok if I replace it for a function? Perhaps an inline function? |
tanaya-mankad
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What was the reason for changing just exit68 to a function, and not other gotos?
|
Because |
|
The error occurs because as far as the compiler is concerned, |
|
Is limiting the scope the best out of all of those options? |
|
Not inline! That would just duplicate the code at each call.
You could use a lambda or non-inline function.
(Or leave the goto. I really don't see what is wrong with it. We need a
policy discussion -- absolutely always outlawing some approach does not
make sense in my opinion.)
…On Wed, Jun 15, 2022 at 5:23 PM Cesar Galan ***@***.***> wrote:
@chipbarnaby <https://github.com/chipbarnaby> Would it be ok if I replace
it for a function? Perhaps an inline function?
—
Reply to this email directly, view it on GitHub
<#319 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/ACWGW7BKYKJCFQP4464BB6DVPJCU7ANCNFSM5Y4VJO7A>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
Description
Replaces a goto statement for an inline function to exit
sunLitFractfunction.Author Progress Checklist:
Reviewer Checklist: