Skip to content

Commit

Permalink
Add an option to configure AA type inference for single file
Browse files Browse the repository at this point in the history
  • Loading branch information
CaelmBleidd committed Dec 26, 2024
1 parent fd7df17 commit b6d907c
Showing 1 changed file with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -94,11 +94,14 @@ fun generateSdkIR(sdkPath: Path): Path = generateEtsIR(
useArkAnalyzerTypeInference = 0,
)

fun loadEtsFileAutoConvert(projectPath: Path): EtsFile {
fun loadEtsFileAutoConvert(
projectPath: Path,
useArkAnalyzerTypeInference: Int? = 1,
): EtsFile {
val irFilePath = generateEtsIR(
projectPath,
isProject = false,
useArkAnalyzerTypeInference = 1,
useArkAnalyzerTypeInference = useArkAnalyzerTypeInference,
)
irFilePath.inputStream().use { stream ->
val etsFileDto = EtsFileDto.loadFromJson(stream)
Expand Down

0 comments on commit b6d907c

Please sign in to comment.