www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - About headers and lib files...

reply clep <clep_member pathlink.com> writes:
Hello,

I was attracted by D's promise to avoid that .h #include files in C (and their
separation form libs and so on). I think (ok, it's my opinion) that tpu's in
Pascal are a better choice (i.e. only one file). However, this approach lacks
self-documentation.
So, nothing seems to be right... Why then not allow D compiler to import and
link some hybrid files, by example a standard archive format (.zip or .rar)
where the two files ("header(s)" and "obj/lib") to be bundled. This way, there
is no need to have two files (at least to distribute) and still, one could
easily open that archive and watch the headers for some kind of function
prototype.
More, the compiler could automatically generate this kind of bundled libs...
Ok, just an opinion. Please provide comments.

clep
Jun 22 2004
parent =?ISO-8859-1?Q?Sigbj=F8rn_Lund_Olsen?= <sigbjorn lundolsen.net> writes:
clep wrote:
 Hello,
 
 I was attracted by D's promise to avoid that .h #include files in C (and their
 separation form libs and so on). I think (ok, it's my opinion) that tpu's in
 Pascal are a better choice (i.e. only one file). However, this approach lacks
 self-documentation.
 So, nothing seems to be right... Why then not allow D compiler to import and
 link some hybrid files, by example a standard archive format (.zip or .rar)
Both .rar and .zip formats are proprietary formats, not open, stable standards by anybody's yardstick - even though most .zip handling utilities conform to infoZip/pkzip/winzip. If you want a stable, open, free, widely understood/supported, patent-unencumbered archiving format for any purpose at all you want to use .gz or .bz2. Those are my 2 dollars worth of thought.
 where the two files ("header(s)" and "obj/lib") to be bundled. This way, there
 is no need to have two files (at least to distribute) and still, one could
 easily open that archive and watch the headers for some kind of function
 prototype.
 More, the compiler could automatically generate this kind of bundled libs...
 Ok, just an opinion. Please provide comments.
I like the idea a lot, as it is, even though I don't think it deserves priority compared to a lot of other showencumbering issues D has atm. It would be easy to hook up the compiler with zlib/libbzip2, too. Cheers, Sigbjørn Lund Olsen
Jun 22 2004