{"action":"created","issue":{"url":"https://api.github.com/repos/cockroachdb/cockroach/issues/3554","labels_url":"https://api.github.com/repos/cockroachdb/cockroach/issues/3554/labels{/name}","comments_url":"https://api.github.com/repos/cockroachdb/cockroach/issues/3554/comments","events_url":"https://api.github.com/repos/cockroachdb/cockroach/issues/3554/events","html_url":"https://github.com/cockroachdb/cockroach/issues/3554","id":124295718,"number":3554,"title":"Bug in func MergeInto of TimestampCache","user":{"login":"changrui82","id":15647248,"avatar_url":"https://avatars.githubusercontent.com/u/15647248?v=3","gravatar_id":"","url":"https://api.github.com/users/changrui82","html_url":"https://github.com/changrui82","followers_url":"https://api.github.com/users/changrui82/followers","following_url":"https://api.github.com/users/changrui82/following{/other_user}","gists_url":"https://api.github.com/users/changrui82/gists{/gist_id}","starred_url":"https://api.github.com/users/changrui82/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/changrui82/subscriptions","organizations_url":"https://api.github.com/users/changrui82/orgs","repos_url":"https://api.github.com/users/changrui82/repos","events_url":"https://api.github.com/users/changrui82/events{/privacy}","received_events_url":"https://api.github.com/users/changrui82/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/cockroachdb/cockroach/labels/easy","name":"easy","color":"009800"},{"url":"https://api.github.com/repos/cockroachdb/cockroach/labels/helpwanted","name":"helpwanted","color":"bfdadc"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-12-30T02:39:46Z","updated_at":"2016-01-13T10:15:11Z","closed_at":null,"body":"```\r\nfunc (tc *TimestampCache) MergeInto(dest *TimestampCache, clear bool) {\r\n\tif clear {\r\n\t\tdest.cache.Clear()\r\n\t\tdest.lowWater = tc.lowWater\r\n\t\tdest.latest = tc.latest\r\n\t} else {\r\n\t\tif dest.lowWater.Less(tc.lowWater) {\r\n\t\t\tdest.lowWater = tc.lowWater\r\n\t\t}\r\n\t\tif dest.latest.Less(tc.latest) {\r\n\t\t\ttc.latest = dest.latest\r\n\t\t}\r\n\t}\r\n\ttc.cache.Do(func(k, v interface{}) {\r\n\t\tdest.cache.Add(k, v)\r\n\t})\r\n}\r\n```\r\nI thinks `tc.latest = dest.latest` should be `dest.latest = tc.latest`, right?"},"comment":{"url":"https://api.github.com/repos/cockroachdb/cockroach/issues/comments/171241952","html_url":"https://github.com/cockroachdb/cockroach/issues/3554#issuecomment-171241952","issue_url":"https://api.github.com/repos/cockroachdb/cockroach/issues/3554","id":171241952,"user":{"login":"tschottdorf","id":5076964,"avatar_url":"https://avatars.githubusercontent.com/u/5076964?v=3","gravatar_id":"","url":"https://api.github.com/users/tschottdorf","html_url":"https://github.com/tschottdorf","followers_url":"https://api.github.com/users/tschottdorf/followers","following_url":"https://api.github.com/users/tschottdorf/following{/other_user}","gists_url":"https://api.github.com/users/tschottdorf/gists{/gist_id}","starred_url":"https://api.github.com/users/tschottdorf/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tschottdorf/subscriptions","organizations_url":"https://api.github.com/users/tschottdorf/orgs","repos_url":"https://api.github.com/users/tschottdorf/repos","events_url":"https://api.github.com/users/tschottdorf/events{/privacy}","received_events_url":"https://api.github.com/users/tschottdorf/received_events","type":"User","site_admin":false},"created_at":"2016-01-13T10:15:11Z","updated_at":"2016-01-13T10:15:11Z","body":"Hey @AbhishekSaha, I've commented on your PR #3797."}}