Skip to content

Commit

Permalink
fixes nim-lang#14470 [backport:1.2] (nim-lang#19115)
Browse files Browse the repository at this point in the history
  • Loading branch information
Araq authored and PMunch committed Mar 28, 2022
1 parent 561464e commit 653cdfe
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion compiler/ccgtypes.nim
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,8 @@ proc isInvalidReturnType(conf: ConfigRef; rettype: PType): bool =
# such a poor programming language.
# We exclude records with refs too. This enhances efficiency and
# is necessary for proper code generation of assignments.
if rettype == nil: result = true
if rettype == nil or getSize(conf, rettype) > conf.target.floatSize*3:
result = true
else:
case mapType(conf, rettype, skResult)
of ctArray:
Expand Down

0 comments on commit 653cdfe

Please sign in to comment.