Some more example code and documentation on how to use includes.
This commit is contained in:
parent
5b7b063086
commit
045d1c2809
3 changed files with 4 additions and 2 deletions
|
|
@ -11,6 +11,8 @@
|
|||
|
||||
// Demonstrates system library includes after installation to /usr/lib/fun
|
||||
|
||||
// includes can also be done with a leading # like in C, but some programmers maybe like more clean code without a
|
||||
// leading #.
|
||||
include <hello.fun>
|
||||
include <utils/math.fun>
|
||||
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@
|
|||
*/
|
||||
|
||||
// To test this you need to go to ./examples/ and test includes running ../build/fun include_local.fun
|
||||
// Local includes are always relative from the $PWD.
|
||||
// Local includes are always relative from the $PWD using "" and system includes are located at /usr/lib/fun using <>.
|
||||
|
||||
// Demonstrates local include:
|
||||
// This resolves relative to the current working directory where 'fun' is executed.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue