diff --git a/lib/system.nim b/lib/system.nim index 9b00ff145208..60892dd94afc 100644 --- a/lib/system.nim +++ b/lib/system.nim @@ -2667,8 +2667,11 @@ when not defined(nimscript) and hasAlloc: {.warning: "GC_disableMarkAndSweep is a no-op in JavaScript".} "" -template accumulateResult*(iter: untyped) = - ## helps to convert an iterator to a proc. +template accumulateResult*(iter: untyped) {.deprecated: "use `sequtils.toSeq` instead (more hygienic, sometimes more efficient)".} = + ## helps to convert an iterator to a proc. + ## See also `sequtils.toSeq` which is more hygienic and efficient. + ## + ## **Deprecated since v0.19.0:** use toSeq instead result = @[] for x in iter: add(result, x)