Browse Source

fix c++ comment continuation highlighting #2497

nreed 4 năm trước cách đây
mục cha
commit
7b96ed2fbd
1 tập tin đã thay đổi với 2 bổ sung0 xóa
  1. 2 0
      src/cpp/cpp.ts

+ 2 - 0
src/cpp/cpp.ts

@@ -347,10 +347,12 @@ export const language = <languages.IMonarchLanguage>{
 			[/[ \t\r\n]+/, ''],
 			[/\/\*\*(?!\/)/, 'comment.doc', '@doccomment'],
 			[/\/\*/, 'comment', '@comment'],
+			[/\/\/.*\\$/, 'comment', '@comment'],
 			[/\/\/.*$/, 'comment']
 		],
 
 		comment: [
+			[/.*[^\\]$/, 'comment', '@pop'],
 			[/[^\/*]+/, 'comment'],
 			[/\*\//, 'comment', '@pop'],
 			[/[\/*]/, 'comment']