![]() |
【转帖】define od-use-stub-fns question
define "od_use_stub_fns" question
define "od_use_stub_fns" question hi, why is the macro definition od_use_stub_fns placed at most of the oddbcurve methods? currently i cannot use these methods through the oddbcurve interface class, but only through the inheritants thanks in advance for any help. regards chudomir oddbcurve methods which are not implemented in all oddbcurve inheritants are commented out. sergey slezkin thank you for your reply, sergey. but why don't you just return enotimplemented or similar , so we can use the oddbcurve class as an interface and determine at runtime whether a class supports such operations like getpointatparam, etc, or not. so the client code will remain unchanged when there are new implementations in the inherited classes. however, you probably have certain reasons to do it... regards chudomir i do not have strong opinion on this. untill all methods are implemented we'll get compains like -my code compiles but i get unresolved externals at linking. -my code compiles and links but i get enotimplemented exception. sergey slezkin so i suppose i can define od_use_stub_fns before include the dwgdirect headers and i've got the methods? thanks. chudomir if you recompile dd - yes. defining the symbol changes size of virtual functions table... sergey slezkin well, i'm not a fan of recompiling third party libraries (though i have the sources as part from the founding membership). moreover, not only the virtual table, but also the implementation of these functions in the cpp file will be problematic without recompilation (some playing with inlining them should be a questionable success). sorry for losing your time with this, sergey, and thanks once again. regards chudomir |
所有的时间均为北京时间。 现在的时间是 05:07 AM. |