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

Bug with template parameters expanded from a macro #5783

Closed
zajo opened this issue Jul 15, 2020 · 3 comments
Closed

Bug with template parameters expanded from a macro #5783

zajo opened this issue Jul 15, 2020 · 3 comments
Labels
bug fixed Check the Milestone for the release in which the fix is or will be available. Language Service Visual Studio Inherited from Visual Studio
Milestone

Comments

@zajo
Copy link

zajo commented Jul 15, 2020

Type: LanguageService

First thank you for the excellent work, to my pleasant surprise Intellisense on Windows works nearly perfectly. I'm reporting an issue which isn't super important, but it is the only part of my library it has problems with.

For portability between C++11 and 17 I use a macro for deducing nontype template arguments:

template <class E, BOOST_LEAF_MATCH_ARGS(match_enum_type<E>, V1, V)>
struct is_predicate<match<E, V1, V...>>: std::true_type
{
};

Intellisense ignores the macro, reporting errors in that prat of the program, even though pointing at the macro with the mouse proves it is not confused about where and how the macro is defined.

For reference: the macro is defined here and used in several places, e.g. here.

@sean-mcmanus sean-mcmanus self-assigned this Jul 15, 2020
@sean-mcmanus
Copy link
Collaborator

sean-mcmanus commented Jul 15, 2020

Thanks for reporting this. I've filed a bug at https://developercommunity.visualstudio.com/content/problem/1114791/cc-intellisense-gives-error-parameter-pack-was-ref.html .

I also got some IntelliSense process crashes when I used "cl.exe /P /std:c++latest /I ...\leaf-develop\include ...\leaf-develop\test\match_test.cpp" to create a stand alone TU, so I've reported that at https://developercommunity.visualstudio.com/content/problem/1114794/cc-intellisense-process-crashes.html . I'm not sure if those crashes are something you would hit normally, but it would potentially could happen after opening certain headers that the match_test.cpp includes.

UPDATE: Fix should be in 0.30.0-insiders (no ETA yet).

@sean-mcmanus sean-mcmanus removed their assignment Jul 15, 2020
@sean-mcmanus sean-mcmanus added bug Visual Studio Inherited from Visual Studio Language Service labels Jul 15, 2020
@sean-mcmanus sean-mcmanus added this to the Tracking milestone Jul 15, 2020
@sean-mcmanus sean-mcmanus self-assigned this Jul 20, 2020
@sean-mcmanus sean-mcmanus modified the milestones: Tracking, 0.30.0 Jul 20, 2020
@sean-mcmanus sean-mcmanus added the fixed Check the Milestone for the release in which the fix is or will be available. label Jul 20, 2020
@zajo
Copy link
Author

zajo commented Aug 5, 2020

I confirm this is fixed in v0.30.0-insiders. Thanks!

@sean-mcmanus sean-mcmanus removed their assignment Aug 5, 2020
@zajo
Copy link
Author

zajo commented Sep 15, 2020

Thanks!

@github-actions github-actions bot locked and limited conversation to collaborators Oct 9, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug fixed Check the Milestone for the release in which the fix is or will be available. Language Service Visual Studio Inherited from Visual Studio
Projects
None yet
Development

No branches or pull requests

2 participants