--- Begin Message ---
Subject: |
[PATCH] Add < and > to the syntax table in c++-ts-mode |
Date: |
Tue, 13 Dec 2022 22:39:36 +0100 |
Tags: patch
Given the following C++ code (where "|" represents the point):
|Expected<int> getFoo();
If you press C-M-d when c++-ts-mode is enabled, point moves to:
Expected<int> getFoo(|);
In c++-mode, point moves (correctly) to:
Expected<|int> getFoo();
Also, show-paren-mode does not highlight any <> pairs in c++-ts-mode.
My proposed fix is to create a syntax table for c++-ts-mode and add "<"
and ">" to it as open/close delimiters.
The attached patch implements the proposed solution. Thanks.
0001-Add-and-to-the-syntax-table-in-c-ts-mode.patch
Description: Text Data
--- End Message ---
--- Begin Message ---
Subject: |
Re: bug#60049: [PATCH] Add < and > to the syntax table in c++-ts-mode |
Date: |
Tue, 13 Dec 2022 18:10:14 -0800 |
Daniel MartÃn <mardani29@yahoo.es> writes:
> Tags: patch
>
>
> Given the following C++ code (where "|" represents the point):
>
> |Expected<int> getFoo();
>
> If you press C-M-d when c++-ts-mode is enabled, point moves to:
>
> Expected<int> getFoo(|);
>
> In c++-mode, point moves (correctly) to:
>
> Expected<|int> getFoo();
>
> Also, show-paren-mode does not highlight any <> pairs in c++-ts-mode.
>
> My proposed fix is to create a syntax table for c++-ts-mode and add "<"
> and ">" to it as open/close delimiters.
>
> The attached patch implements the proposed solution. Thanks.
Applied, thanks!
Yuan
--- End Message ---