Skip to content

Commit 6445028

Browse files
committed
ctor => construct
1 parent 7c3f0e6 commit 6445028

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

tools/nimdigger.nim

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -130,13 +130,13 @@ proc runCmdOutput(cmd: string, dir = ""): string =
130130
result = outp
131131
stripLineEnd(result)
132132

133-
macro ctor(obj: untyped, a: varargs[untyped]): untyped =
133+
macro construct(obj: untyped, a: varargs[untyped]): untyped =
134134
## Generates an object constructor call from a list of fields.
135135
# xxx expose in std/sugar, factor with https://github.com/nim-lang/fusion/pull/32
136136
runnableExamples:
137137
type Foo = object
138138
a, b: int
139-
doAssert Foo.ctor(a,b) == Foo(a: a, b: b)
139+
doAssert Foo.construct(a,b) == Foo(a: a, b: b)
140140
result = nnkObjConstr.newTree(obj)
141141
for ai in a: result.add nnkExprColonExpr.newTree(ai, ai)
142142

@@ -317,7 +317,7 @@ proc main(rev = "", nimDir = "", compileNim = false, fetch = false, oldnew = "",
317317
bisectCmd = args.quoteShellCommand
318318
else:
319319
doAssert args.len == 0
320-
main2(DiggerOpt.ctor(rev, nimDir, compileNim, fetch, bisectCmd, oldnew, bisectBugfix))
320+
main2(DiggerOpt.construct(rev, nimDir, compileNim, fetch, bisectCmd, oldnew, bisectBugfix))
321321

322322
when isMainModule:
323323
import pkg/cligen

0 commit comments

Comments
 (0)