mirror of
https://github.com/nim-lang/Nim.git
synced 2026-01-04 12:07:51 +00:00
ccgtypes: improve internal documentation
This commit is contained in:
@@ -855,8 +855,10 @@ proc getTypeDesc(m: BModule, typ: PType): Rope =
|
||||
result = getTypeDescAux(m, typ, check)
|
||||
|
||||
type
|
||||
TClosureTypeKind = enum
|
||||
clHalf, clHalfWithEnv, clFull
|
||||
TClosureTypeKind = enum ## In C closures are mapped to 3 different things.
|
||||
clHalf, ## fn(args) type without the trailing 'void* env' parameter
|
||||
clHalfWithEnv, ## fn(args, void* env) type with trailing 'void* env' parameter
|
||||
clFull ## struct {fn(args, void* env), env}
|
||||
|
||||
proc getClosureType(m: BModule, t: PType, kind: TClosureTypeKind): Rope =
|
||||
assert t.kind == tyProc
|
||||
|
||||
Reference in New Issue
Block a user