caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* Should one use caml_ prefix in C code ?
@ 2005-03-28  4:43 Sébastien Hinderer
  2005-03-28  5:07 ` [Caml-list] " Robert Roessler
  0 siblings, 1 reply; 2+ messages in thread
From: Sébastien Hinderer @ 2005-03-28  4:43 UTC (permalink / raw)
  To: caml-list

Dear all,

Among Caml header files is one called compatibility.h.
This file defines macros allowing one to use, say, copy_string rather
than caml_copy_string when writing stub functions.
But what is the recommended style for writing stubs ?
Should the caml_ prefix be used, or not ?
The documentation does not seem to mention anything about that.

Thanks,
Sébastien.


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [Caml-list] Should one use caml_ prefix in C code ?
  2005-03-28  4:43 Should one use caml_ prefix in C code ? Sébastien Hinderer
@ 2005-03-28  5:07 ` Robert Roessler
  0 siblings, 0 replies; 2+ messages in thread
From: Robert Roessler @ 2005-03-28  5:07 UTC (permalink / raw)
  To: Sébastien Hinderer; +Cc: Caml-list

Sébastien Hinderer wrote:

> Among Caml header files is one called compatibility.h.
> This file defines macros allowing one to use, say, copy_string rather
> than caml_copy_string when writing stub functions.
> But what is the recommended style for writing stubs ?
> Should the caml_ prefix be used, or not ?
> The documentation does not seem to mention anything about that.

The "caml_" prefix was added in 3.08.0 to avoid name conflicts when 
linking with other libraries.  I believe the relevant entries in 
compatibility.h are there so the Caml developers were not forced to 
edit all of the sources... but you should use the new "official" 
naming in code you write that needs to reference the affected C 
globals. :)

Robert Roessler
roessler@rftp.com
http://www.rftp.com


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2005-03-28  5:07 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-03-28  4:43 Should one use caml_ prefix in C code ? Sébastien Hinderer
2005-03-28  5:07 ` [Caml-list] " Robert Roessler

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).