|
From: Bertho S. <lc...@va...> - 2026-07-22 12:18:49
|
Hi all, There is a an option 'constructable' in halcompile that should make it possible to instantiate a component from an already loaded module. The halcmd instruction 'newinst' would then call down to the module via rtapi_app and call the constructor. However, the option 'constructable' is not documented in halcompile. The 'newinst' option to halcmd has been commented out with an #if 0 with the comment "newinst deferred to version 2.2". The 'newinst' code is present in rtapi_app. The problem is that the constructor signature is missing "const" in its arguments and the rtapi_app call down to HAL uses private internal functions. Both can be fixed easily and are already prepared to be fixed. There are no in-tree components or code using any of this. However, out-of-tree code could potentially, however unlikely, use it. Therefore, changing any of it is a risk, however small it may be. So, the question is: Does anybody use 'constructable' components and direct calls to rtapi_app with 'newinst' to instantiate components from the same module? -- Greetings Bertho (disclaimers are disclaimed) |