- 导出标记
导出标记
如果声明的符号标有 asterisk 它从当前模块导出:
- proc exportedEcho*(s: string) = echo s
- proc `*`*(a: string; b: int): string =
- result = newStringOfCap(a.len * b)
- for i in 1..b: result.add a
- var exportedVar*: int
- const exportedConst* = 78
- type
- ExportedType* = object
- exportedField*: int