Skip to content

Commit

Permalink
tests: fixed initialization (related #536)
Browse files Browse the repository at this point in the history
  • Loading branch information
iromeo committed Oct 15, 2024
1 parent ddc1f8d commit 8154e0b
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -79,9 +79,11 @@ open class SmkRuleOrCheckpointArgsSectionImpl(node: ASTNode) : SmkArgsSectionImp
return refFun(stringLiteral, offsetRelativeToSection)
}

override val isWildcardsExpandingSection = SnakemakeAPIProjectService.getInstance(this.project).isWildcardsExpandingSection(
sectionKeyword, getParentRuleOrCheckPoint().sectionKeyword
)
override val isWildcardsExpandingSection by lazy {
SnakemakeAPIProjectService.getInstance(this.project).isWildcardsExpandingSection(
sectionKeyword, getParentRuleOrCheckPoint().sectionKeyword
)
}

override val isWildcardsDefiningSection = sectionKeyword in WILDCARDS_DEFINING_SECTIONS_KEYWORDS

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,11 @@ class SmkUseArgsSectionImpl(node: ASTNode) : SmkArgsSectionImpl(node), SmkRuleOr
override fun getType(context: TypeEvalContext, key: TypeEvalContext.Key): PyType =
SmkRuleLikeSectionArgsType(this)

override val isWildcardsExpandingSection = SnakemakeAPIProjectService.getInstance(this.project).isWildcardsExpandingSection(
sectionKeyword, SnakemakeNames.USE_KEYWORD
)
override val isWildcardsExpandingSection by lazy {
SnakemakeAPIProjectService.getInstance(this.project).isWildcardsExpandingSection(
sectionKeyword, SnakemakeNames.USE_KEYWORD
)
}

override val isWildcardsDefiningSection = sectionKeyword in WILDCARDS_DEFINING_SECTIONS_KEYWORDS
}

0 comments on commit 8154e0b

Please sign in to comment.