summary refs log blame commit diff stats
path: root/tests/accept/compile/tstrtabs.nim
blob: 251ec77eff67e5eea5fc0c1bcdc29e558e487f02 (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11
12

              
                                                           








                                                                     
import strtabs

var tab = newStringTable({"key1": "val1", "key2": "val2"}, 
                         modeStyleInsensitive)
for i in 0..80:
  tab["key_" & $i] = "value" & $i
  
for key, val in pairs(tab):
  writeln(stdout, key, ": ", val)
writeln(stdout, "length of table ", $tab.len)

writeln(stdout, `%`("$key1 = $key2; ${PATH}", tab, {useEnvironment}))