Skip to content

Commit c7b959a

Browse files
committed
Comments updated
1 parent b0b3a36 commit c7b959a

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

utbot-framework/src/main/kotlin/org/utbot/framework/codegen/model/constructor/tree/CgCallableAccessManager.kt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,10 @@ internal class CgCallableAccessManagerImpl(val context: CgContext) : CgCallableA
129129
)
130130
}
131131
// we can access the field only via reflection
132+
133+
// NOTE that current implementation works only if field access is located
134+
// in the right part of the assignment. However, obtaining this construction
135+
// as an "l-value" seems to be an error in assemble models or somewhere else.
132136
is ReflectionOnly -> fieldId.accessWithReflection(this)
133137
}
134138
}

utbot-framework/src/main/kotlin/org/utbot/framework/modifications/UtBotFieldsModificatorsSearcher.kt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,7 @@ class UtBotFieldsModificatorsSearcher {
4343
if (this.isPublic) return true
4444
if (this.isProtected) return classPackageName.startsWith(basePackageName)
4545
if (this.isPackagePrivate) return classPackageName == basePackageName
46-
//privates can be accessible here only from their parent methods,
47-
//so no additional filtering is required
46+
//for private fields no filtering based on package names is required
4847
return true
4948
}
5049
}

0 commit comments

Comments
 (0)