I wonder why `addGetter` extension was left on the...
# compiler
n
Managed to add it using
Copy code
inline fun IrProperty.addSetter(builder: IrFunctionBuilder.() -> Unit = {}): IrSimpleFunction =
        IrFunctionBuilder().run {
            factory.buildFun {
                this.name = Name.special("<set-${this@addSetter.name}>")
                builder()
            }.also {
                setter ->
                this@addSetter.setter = setter
                setter.correspondingPropertySymbol = this@addSetter.symbol
                setter.parent = this@addSetter.parent
            }
        }
Then call it on a property like
Copy code
val setter = property.addSetter() {
            visibility = DescriptorVisibilities.PUBLIC
            modality = Modality.FINAL
            returnType = pluginContext.irBuiltIns.unitType
            origin = IrDeclarationOrigin.DEFAULT_PROPERTY_ACCESSOR
        }
still wondering though why it was removed?