File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change 1
- name = example_module
1
+ name = example
2
2
description = This is an example native module that can be used as a base for developing native modules.
3
3
version = 1.0.0-beta
4
4
Original file line number Diff line number Diff line change @@ -34,13 +34,13 @@ $internalVariable = 42
34
34
fn.moduleExportNormalVariable(pointerFromLib, $[internalVariable])
35
35
36
36
# Accessing exported module variables within the module (The module name must be used)
37
- fn.println(Int value from lib is [[example_module ]]::$intFromLib and the int value from native is [[example_module ]]::$intVar)
37
+ fn.println(Int value from lib is [[example ]]::$intFromLib and the int value from native is [[example ]]::$intVar)
38
38
39
39
# Modifying values of exported module variables (The exported variable may not be final)
40
- [[example_module ]]::$intFromLib += 1000
40
+ [[example ]]::$intFromLib += 1000
41
41
42
- [[example_module ]]::$secondIntFromLib = 30
42
+ [[example ]]::$secondIntFromLib = 30
43
43
44
- #[[example_module ]]::$newInt = 2 # If uncommented: error: Module variables may only be created with the module export variable functions
44
+ #[[example ]]::$newInt = 2 # If uncommented: error: Module variables may only be created with the module export variable functions
45
45
46
46
return parser.op(42 ** 2 ^ 15)
You can’t perform that action at this time.
0 commit comments