Skip to content

Commit

Permalink
Detail explanation comment
Browse files Browse the repository at this point in the history
Co-authored-by: Jonne Haß <[email protected]>
  • Loading branch information
j8r and jhass authored Jun 15, 2020
1 parent 304c0e7 commit ee16b5c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/static_array.cr
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ struct StaticArray(T, N)
def self.new(& : Int32 -> T)
array = uninitialized self
buf = array.to_unsafe
# Using a macro prevents slow compile times: https://github.com/crystal-lang/crystal/issues/2485
# Unroll the loop in Crystal land to avoid slow compile times in release mode. See https://github.com/crystal-lang/crystal/issues/2485#issuecomment-644416515
{% for i in 0...N %}
buf[{{i.id}}] = yield {{i.id}}
{% end %}
Expand Down

0 comments on commit ee16b5c

Please sign in to comment.