{"action":"closed","issue":{"url":"https://api.github.com/repos/nim-lang/Nim/issues/955","labels_url":"https://api.github.com/repos/nim-lang/Nim/issues/955/labels{/name}","comments_url":"https://api.github.com/repos/nim-lang/Nim/issues/955/comments","events_url":"https://api.github.com/repos/nim-lang/Nim/issues/955/events","html_url":"https://github.com/nim-lang/Nim/issues/955","id":28128204,"number":955,"title":"TTable doesn't store value when used as compiletime var","user":{"login":"zielmicha","id":364357,"avatar_url":"https://avatars.githubusercontent.com/u/364357?v=3","gravatar_id":"","url":"https://api.github.com/users/zielmicha","html_url":"https://github.com/zielmicha","followers_url":"https://api.github.com/users/zielmicha/followers","following_url":"https://api.github.com/users/zielmicha/following{/other_user}","gists_url":"https://api.github.com/users/zielmicha/gists{/gist_id}","starred_url":"https://api.github.com/users/zielmicha/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zielmicha/subscriptions","organizations_url":"https://api.github.com/users/zielmicha/orgs","repos_url":"https://api.github.com/users/zielmicha/repos","events_url":"https://api.github.com/users/zielmicha/events{/privacy}","received_events_url":"https://api.github.com/users/zielmicha/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/nim-lang/Nim/labels/Medium%20Priority","name":"Medium Priority","color":"f7c6c7"},{"url":"https://api.github.com/repos/nim-lang/Nim/labels/VM","name":"VM","color":"d4c5f9"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2014-02-23T21:43:50Z","updated_at":"2015-06-18T12:44:03Z","closed_at":"2015-06-18T12:44:03Z","body":"```\r\nimport tables, macros\r\nvar jmethodSpec* {.compiletime.} = initTable[string, string]()\r\n\r\nmacro foo(): stmt =\r\n  jmethodSpec[\"a\"] = \"b\"\r\n  echo jmethodSpec.repr\r\n  parseStmt(\"discard\")\r\n\r\nfoo\r\n```\r\nproduces:\r\n```\r\n([(seEmpty, nil, nil), (seEmpty, nil, nil), (seEmpty, nil, nil), \r\n  (seEmpty, nil, nil), (seEmpty, nil, nil), (seEmpty, nil, nil), \r\n  (seEmpty, nil, nil), (seEmpty, nil, nil), (seEmpty, nil, nil), \r\n...\r\n  (seEmpty, nil, nil), (seEmpty, nil, nil), (seEmpty, nil, nil), \r\n  (seEmpty, nil, nil), (seEmpty, nil, nil), (seEmpty, nil, nil), \r\n  (seEmpty, nil, nil)], true)\r\n```\r\nwhich represents empty hashtable, but it shouldn't be empty. However, `echo jmethodSpec.len` produces `1`."}}