mirror of
https://github.com/nim-lang/Nim.git
synced 2025-12-30 18:02:05 +00:00
Update a use of initTable to avoid initial enlarge.
This commit is contained in:
@@ -302,7 +302,7 @@ template build_specification_lookup():
|
||||
## Returns the table used to keep pointers to all of the specifications.
|
||||
var result {.gensym.}: OrderedTable[string, ptr Tparameter_specification]
|
||||
result = initOrderedTable[string, ptr Tparameter_specification](
|
||||
nextPowerOfTwo(expected.len))
|
||||
tables.rightSize(expected.len))
|
||||
for i in 0..expected.len-1:
|
||||
for param_to_detect in expected[i].names:
|
||||
if result.hasKey(param_to_detect):
|
||||
|
||||
Reference in New Issue
Block a user