Ehelper.Code (Ehelper v0.2.8)
View SourceCode helpers Interface to the Erlang code server process.
Summary
Functions
See :code.clash/0.
:interactive (default) or :embeded by erl -mode embedded
iex> Code.require_file("run/demo.exs")
Functions
See :code.all_loaded/0.
See :code.clash/0.
:interactive (default) or :embeded by erl -mode embedded
- https://www.erlang.org/doc/apps/kernel/code.html#get_mode/0
- In interactive mode, which is default, only the modules needed by the runtime system are loaded during system startup. Other code is dynamically loaded when first referenced. When a call to a function in a certain module is made, and that module is not loaded, the code server searches for and tries to load that module.
- In embedded mode, modules are not auto-loaded. Trying to use a module that has not been loaded results in an error. This mode is recommended when the boot script loads all modules, as it is typically done in OTP releases. (Code can still be loaded later by explicitly ordering the code server to do so).
iex> Code.require_file("run/demo.exs")