Skip to content

Commit 414538b

Browse files
authored
fix: autocomplete for sub-options (#1556)
1 parent 580fb1d commit 414538b

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

server/src/sas/CodeZoneManager.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1161,7 +1161,7 @@ export class CodeZoneManager {
11611161
} else if (zone.type === CodeZoneManager.ZONE_TYPE.OPT_VALUE) {
11621162
type = CodeZoneManager.ZONE_TYPE.PROC_STMT_OPT_VALUE;
11631163
} else if (zone.type === CodeZoneManager.ZONE_TYPE.SUB_OPT_NAME) {
1164-
const stmtWithDatasetOption = LexerEx.prototype.stmtWithDatasetOption_;
1164+
const stmtWithDatasetOption = LexerEx.stmtWithDatasetOption_;
11651165
if (stmtWithDatasetOption[this._procName + "/" + stmt.text]) {
11661166
type = CodeZoneManager.ZONE_TYPE.DATA_SET_OPT_NAME;
11671167
} else if (

server/src/sas/LexerEx.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1834,7 +1834,7 @@ export class LexerEx {
18341834
}
18351835
return token;
18361836
}
1837-
stmtWithDatasetOption_ = arrayToMap([
1837+
static readonly stmtWithDatasetOption_ = arrayToMap([
18381838
//special
18391839
"DATA/SET",
18401840
"DATA/MERGE",
@@ -1897,7 +1897,7 @@ export class LexerEx {
18971897
subOptName,
18981898
pos,
18991899
).isKeyword ||
1900-
(this.stmtWithDatasetOption_[
1900+
(LexerEx.stmtWithDatasetOption_[
19011901
this.curr.procName + "/" + this.curr.name
19021902
]
19031903
? this.syntaxDb.isDatasetKeyword(subOptName)
@@ -1950,7 +1950,7 @@ export class LexerEx {
19501950
subOptName,
19511951
);
19521952
if (!isKeyword) {
1953-
if (this.stmtWithDatasetOption_["DATA/" + this.curr.name]) {
1953+
if (LexerEx.stmtWithDatasetOption_["DATA/" + this.curr.name]) {
19541954
isKeyword = this.syntaxDb.isDatasetKeyword(subOptName);
19551955
}
19561956
}

0 commit comments

Comments
 (0)