Skip to content

Commit

Permalink
Fix comment continuation. (#7238)
Browse files Browse the repository at this point in the history
* Fix comment continuation.
  • Loading branch information
sean-mcmanus authored Mar 31, 2021
1 parent 0d2e793 commit db7c9c7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Extension/src/LanguageServer/languageConfig.ts
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ function getMLSplitAfterPattern(): string {

function getMLPreviousLinePattern(insert: string): string | undefined {
if (insert.startsWith("/*")) {
return `\\A(?=^(\\s*(\\/\\*\\*|\\*)).*)(?=(?!(\\s*\\*\\/)))`;
return `(?=^(\\s*(\\/\\*\\*|\\*)).*)(?=(?!(\\s*\\*\\/)))`;
}
return undefined;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ suite("multiline comment setting tests", function(): void {
},
{ // e.g. * ...|
beforeText: /^(\t|[ ])*\ \*(\ ([^\*]|\*(?!\/))*)?$/,
previousLineText: /\A(?=^(\s*(\/\*\*|\*)).*)(?=(?!(\s*\*\/)))/,
previousLineText: /(?=^(\s*(\/\*\*|\*)).*)(?=(?!(\s*\*\/)))/,
action: { indentAction: vscode.IndentAction.None, appendText: '* ' }
},
{ // e.g. */|
Expand Down

0 comments on commit db7c9c7

Please sign in to comment.