branch: externals/csharp-mode commit 49d83924afa71fa3f7dc774f2856977d1ce43fc4 Author: Theodor Thornhill <theodor.thornh...@frende.no> Commit: Theodor Thornhill <theodor.thornh...@frende.no>
Add nullable operator to concatenated identifiers --- csharp-mode.el | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/csharp-mode.el b/csharp-mode.el index a680f69..8110e41 100644 --- a/csharp-mode.el +++ b/csharp-mode.el @@ -61,7 +61,8 @@ csharp "\\(\\?\\)") (c-lang-defconst c-identifier-ops - csharp '((left-assoc "."))) + csharp '((left-assoc "?") + (left-assoc "."))) (c-lang-defconst c-overloadable-operators csharp '("+" "-" "*" "/" "%" "&" "|" "^" "<<" ">>" "==" @@ -262,7 +263,8 @@ casts and declarations are fontified. Used on level 2 and higher." "\\)")) `((let (id-end) (goto-char (1+ (match-beginning 0))) - (while (and (eq (char-before) ?.) + (while (and (or (eq (char-before) ?.) + (eq (char-before) ?\?)) (progn (backward-char) (c-backward-syntactic-ws)