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

Right angled brackets seems to break highlighting #58

Open
tankorsmash opened this issue Oct 21, 2017 · 1 comment
Open

Right angled brackets seems to break highlighting #58

tankorsmash opened this issue Oct 21, 2017 · 1 comment

Comments

@tankorsmash
Copy link

tankorsmash commented Oct 21, 2017

Seems like using brackets on a line like that breaks the highlighting for text.

{
    std::stringstream ss;
    ss << "IS NOT HIGHLIGHTED" << MyTemplate<int>{1,2,3} << "THIS IS HIGHLIGHTED";

    //or with broken code
    int var = 1;
    ss << "IS NOT HIGHLIGHTED" << var-> << "THIS IS HIGHLIGHTED"

};

The cpp settings here are:

let g:cpp_class_scope_highlight = 1
let g:cpp_member_variable_highlight = 1
let g:cpp_class_decl_highlight = 1
let g:cpp_experimental_template_highlight = 1
@tankorsmash
Copy link
Author

tankorsmash commented Oct 21, 2017

Seems like it's related to #30 as disabling experimental seems to fix this, except with simple mode on, this happens instead:

ss << "GREEN TEXT" << std::chrono::duration_cast<std::chrono::seconds>(time_left) << " PROPER YELLOW";

The cpp settings here are similar, but simple is on instead

let g:cpp_class_scope_highlight = 1
let g:cpp_member_variable_highlight = 1
let g:cpp_class_decl_highlight = 1
let g:cpp_experimental_simple_template_highlight = 1

Without either experimental flags, this is the output, which looks more or less correct:

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