E.g. ctrl.handleLine("extension info.kwarc.mmt.api.presentation.MMTSyntaxPresenter") fails since MMTSyntaxPresenter has a non-empty constructor:
class MMTSyntaxPresenter(objectPresenter: ObjectPresenter = new NotationBasedPresenter)
Note that while new MMTSyntaxPresenter() compiles fine, the default argument value gets lost via reflection, so the reflection only sees a constructor taking an ObjectPresenter. (Actually not totally lost, you can retrieve it with enough hackery).
We should remove the argument and override Extension#start. I'll probably do while refactoring the presenter anyway. (CC @bankinus, @rappatoni)
Does anyone use MMTStructurePresenter or FlatMMTStructurePresenter or AbstractMMTStructurePresenter apart MMTSyntaxPresenter itself? Sounds like they are dead code.
E.g.
ctrl.handleLine("extension info.kwarc.mmt.api.presentation.MMTSyntaxPresenter")
fails sinceMMTSyntaxPresenter
has a non-empty constructor:Note that while
new MMTSyntaxPresenter()
compiles fine, the default argument value gets lost via reflection, so the reflection only sees a constructor taking anObjectPresenter
. (Actually not totally lost, you can retrieve it with enough hackery).We should remove the argument and override
Extension#start
. I'll probably do while refactoring the presenter anyway. (CC @bankinus, @rappatoni)Does anyone use
MMTStructurePresenter
orFlatMMTStructurePresenter
orAbstractMMTStructurePresenter
apartMMTSyntaxPresenter
itself? Sounds like they are dead code.