Question

Can anyone please tell me after compiling and loading a file do we still have to define the function(already in the file compiled and loaded) in repl to use it? or is there still process left so that the repl detects the function is already defined?

What is the significance of loading a file in lisp?

Thanks.

Was it helpful?

Solution

If the file contents have been read in, then, assuming there have been no errors thrown, all the forms of the contents have been executed. If one of those is a DEFUN form, then the function will have been defined.

To be precise, examine the LOAD definition in the HyperSpec.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top