Skip to content
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

Function f() in listing_2.6 needs extra parentheses #16

Open
demucin opened this issue Oct 8, 2021 · 0 comments
Open

Function f() in listing_2.6 needs extra parentheses #16

demucin opened this issue Oct 8, 2021 · 0 comments

Comments

@demucin
Copy link

demucin commented Oct 8, 2021

Hello,
İt does not work.
I think function declaration and object creation are mixed in function "f()" this line needs extra parentheses:

scoped_thread t(std::thread(func(some_local_state)));
should be
scoped_thread t((std::thread(func(some_local_state))));
or
scoped_thread t{std::thread(func(some_local_state))};

@demucin demucin changed the title Function f in listing_2.6 needs extra parentheses Function f() in listing_2.6 needs extra parentheses Oct 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant