Fix include
This commit is contained in:
@@ -20,16 +20,19 @@ pub use my_module::MyType;
|
||||
|
||||
### Include Directives
|
||||
|
||||
Mist supports C-style include directives for importing external files and crates:
|
||||
Mist supports C-style include directives for
|
||||
|
||||
```mist
|
||||
// Global include (C-style)
|
||||
#include <stdio.h>
|
||||
// Global include (std::Display)
|
||||
// Includes all of the items *inside* the path
|
||||
#include <std/fmt>
|
||||
|
||||
// Use include (import from crate)
|
||||
pub use my_crate::my_module;
|
||||
// Use include (std::Display)
|
||||
// Includes *the path* itelf to the root.
|
||||
#use std::fmt::Display;
|
||||
|
||||
// Local include (import from relative path)
|
||||
// Local include
|
||||
// Textual include, transpiles to rust include! macro via .rs extension
|
||||
#include "my_local_module.mist"
|
||||
```
|
||||
|
||||
|
||||
Reference in New Issue
Block a user