summary refs log tree commit diff stats
path: root/compiler/semobjconstr.nim
diff options
context:
space:
mode:
authorringabout <43030857+ringabout@users.noreply.github.com>2023-04-13 18:11:06 +0800
committerGitHub <noreply@github.com>2023-04-13 12:11:06 +0200
commit16f42084d32144d5afb2a5cc3a5a833e5295a8bc (patch)
treecee13e611922cc1f232423718ec1af314b79e698 /compiler/semobjconstr.nim
parent3f51b6f73ddc476c645f1e3e0205d2f203eaf8e2 (diff)
downloadNim-16f42084d32144d5afb2a5cc3a5a833e5295a8bc.tar.gz
fixes #20900; Calling template through from generic function across module fails to build (#21649)
* fixes #20900; Calling template through from generic function across module fails to build

* sanother way
Diffstat (limited to 'compiler/semobjconstr.nim')
-rw-r--r--compiler/semobjconstr.nim1
1 files changed, 1 insertions, 0 deletions
diff --git a/compiler/semobjconstr.nim b/compiler/semobjconstr.nim
index 2d95da50d..28471f016 100644
--- a/compiler/semobjconstr.nim
+++ b/compiler/semobjconstr.nim
@@ -86,6 +86,7 @@ proc semConstrField(c: PContext, flags: TExprFlags,
     var initValue = semExprFlagDispatched(c, assignment[1], flags, field.typ)
     if initValue != nil:
       initValue = fitNodeConsiderViewType(c, field.typ, initValue, assignment.info)
+    initValue.flags.incl nfSkipFieldChecking
     assignment[0] = newSymNode(field)
     assignment[1] = initValue
     assignment.flags.incl nfSem