Hello Developers

I'm a bit puzzled there're 2 units in fpc-xml: xmlcfg and xmlconfg

Both of them declare TXMLConfig class. The interfaces of both classes
seems to be quite identical.

If one of them is up-kept for backward compatibility, shouldn't it be like:

[code]
unit
  xmlcfg;

uses
  xmlconfig;

type
  TXMLConfig = class(xmlconfig.TXMLConfig);
[/code]
or vice versa?!

LCL also provides its own TXMLConfig at Laz_XMLCfg (with the same interface).

I'm pretty sure that compiler is not smart enough to smart-link away
(similar) classes :)
So I guess, there's alway a risk of duplicating code (3 times, by
using 3 different TXMLConfigs).

So, what unit should an IDE extension and/or LCL components use?

xmlconf: is used by LazReport
xmlcfg: is used by Grids, XMLPropStorage and the packager
(RegisterFCL.pas, but not sure why)
Laz_XMLCfg: is used by LazarusIDE, CodeTools, packager (!!) and fpdoceditor

thanks,
dmitry

--
_______________________________________________
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply via email to