From 0a1bc0e9cd30ef1a3654e7637795ed22010e7977 Mon Sep 17 00:00:00 2001 From: Charles Blake Date: Fri, 13 Feb 2015 08:33:15 -0500 Subject: [PATCH] Update a use of initTable to avoid initial enlarge. --- tests/manyloc/argument_parser/argument_parser.nim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/manyloc/argument_parser/argument_parser.nim b/tests/manyloc/argument_parser/argument_parser.nim index af671cd852..a507a08e40 100644 --- a/tests/manyloc/argument_parser/argument_parser.nim +++ b/tests/manyloc/argument_parser/argument_parser.nim @@ -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):