Re: Compilation without implementation source



Gene wrote:
For an educational exercise using GNAT and gnatmake, I need to hide
implementations of some modules from students in the simplest possible
way.

Is there a way to give them .ali, .ads, and .o files while withholding
the corresponding .adb, somehow telling gnatmake (and gnatbind) to
ignore the absence?

IIRC, if the .ali files are read-only, GNAT will not require the source of the bodies. This may not work for generics or other cases where the compilation has a dependency on the body, such as cross-unit inlining.

--
Jeff Carter
"Whatever it is, I'm against it."
Horse Feathers
46
.