This also works: 
    
    
    import std/sugar
    
    template collected(make, iteration): untyped =
      block:
        collect(make): iteration
    
    echo collected(newSeq, (for i in 1..11: i))
    
    
    Run

Reply via email to