[IR] Fixed bug with thread unsafety
There is no need in a singleton here
This commit is contained in:
@@ -466,7 +466,7 @@ val IrFunction.allParametersCount: Int
|
||||
// This is essentially the same as FakeOverrideBuilder,
|
||||
// but it bypasses SymbolTable.
|
||||
// TODO: merge it with FakeOverrideBuilder.
|
||||
private object FakeOverrideBuilderForLowerings : FakeOverrideBuilderStrategy() {
|
||||
private class FakeOverrideBuilderForLowerings : FakeOverrideBuilderStrategy() {
|
||||
|
||||
override fun linkFunctionFakeOverride(declaration: IrFakeOverrideFunction) {
|
||||
declaration.acquireSymbol(IrSimpleFunctionSymbolImpl(WrappedSimpleFunctionDescriptor()))
|
||||
@@ -491,7 +491,7 @@ private object FakeOverrideBuilderForLowerings : FakeOverrideBuilderStrategy() {
|
||||
}
|
||||
|
||||
fun IrClass.addFakeOverrides(irBuiltIns: IrBuiltIns, implementedMembers: List<IrOverridableMember> = emptyList()) {
|
||||
IrOverridingUtil(irBuiltIns, FakeOverrideBuilderForLowerings)
|
||||
IrOverridingUtil(irBuiltIns, FakeOverrideBuilderForLowerings())
|
||||
.buildFakeOverridesForClassUsingOverriddenSymbols(this, implementedMembers)
|
||||
.forEach { addChild(it) }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user