{"action":"created","comment":{"url":"https://api.github.com/repos/c5t/Current/pulls/comments/45022318","id":45022318,"diff_hunk":"@@ -69,20 +72,74 @@ CURRENT_STRUCT(ComplexSerializable) {\n   CURRENT_RETURNS(size_t) length_of_v() const { return v.size(); }\n };\n \n+CURRENT_STRUCT(WithFloatingPoint) {\n+  CURRENT_FIELD(f, float);\n+  CURRENT_FIELD(d, double);\n+};\n+\n CURRENT_STRUCT(WithVectorOfPairs) { CURRENT_FIELD(v, (std::vector<std::pair<int32_t, std::string>>)); };\n \n CURRENT_STRUCT(WithTrivialMap) { CURRENT_FIELD(m, (std::map<std::string, std::string>)); };\n \n CURRENT_STRUCT(WithNontrivialMap) { CURRENT_FIELD(q, (std::map<Serializable, std::string>)); };\n \n-enum class MyMagicGUID : uint64_t {};\n-CURRENT_STRUCT(WithEnumClass) {\n-  CURRENT_FIELD(id1, MyMagicGUID);\n-  CURRENT_FIELD(id2, MyMagicGUID, static_cast<MyMagicGUID>(1));\n-};\n-\n }  // namespace serialization_test\n \n+TEST(Serialization, Binary) {\n+  using namespace serialization_test;\n+  const std::string tmp_file = bricks::FileSystem::GenTmpFileName();\n+  const auto tmp_file_remover = bricks::FileSystem::ScopedRmFile(tmp_file);\n+  {\n+    std::ofstream ofs(tmp_file);\n+\n+    Serializable simple_object;\n+    simple_object.i = 42;\n+    simple_object.s = \"foo\";\n+    simple_object.b = true;\n+    simple_object.e = Enum::SET;\n+    SaveIntoBinary(ofs, simple_object);","path":"TypeSystem/Serialization/test.cc","position":50,"original_position":50,"commit_id":"72b3fac1c39b70cf456620d7aff48c3316021025","original_commit_id":"72b3fac1c39b70cf456620d7aff48c3316021025","user":{"login":"dkorolev","id":2159447,"avatar_url":"https://avatars.githubusercontent.com/u/2159447?v=3","gravatar_id":"","url":"https://api.github.com/users/dkorolev","html_url":"https://github.com/dkorolev","followers_url":"https://api.github.com/users/dkorolev/followers","following_url":"https://api.github.com/users/dkorolev/following{/other_user}","gists_url":"https://api.github.com/users/dkorolev/gists{/gist_id}","starred_url":"https://api.github.com/users/dkorolev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dkorolev/subscriptions","organizations_url":"https://api.github.com/users/dkorolev/orgs","repos_url":"https://api.github.com/users/dkorolev/repos","events_url":"https://api.github.com/users/dkorolev/events{/privacy}","received_events_url":"https://api.github.com/users/dkorolev/received_events","type":"User","site_admin":false},"body":"Although the file one is probably more end-to-end. Disregard. :-)","created_at":"2015-11-17T04:53:01Z","updated_at":"2015-11-17T04:53:01Z","html_url":"https://github.com/c5t/Current/pull/267#discussion_r45022318","pull_request_url":"https://api.github.com/repos/c5t/Current/pulls/267","_links":{"self":{"href":"https://api.github.com/repos/c5t/Current/pulls/comments/45022318"},"html":{"href":"https://github.com/c5t/Current/pull/267#discussion_r45022318"},"pull_request":{"href":"https://api.github.com/repos/c5t/Current/pulls/267"}}},"pull_request":{"url":"https://api.github.com/repos/c5t/Current/pulls/267","id":50853114,"html_url":"https://github.com/c5t/Current/pull/267","diff_url":"https://github.com/c5t/Current/pull/267.diff","patch_url":"https://github.com/c5t/Current/pull/267.patch","issue_url":"https://api.github.com/repos/c5t/Current/issues/267","number":267,"state":"open","locked":false,"title":"Binary (de)serialization.","user":{"login":"mzhurovich","id":11226961,"avatar_url":"https://avatars.githubusercontent.com/u/11226961?v=3","gravatar_id":"","url":"https://api.github.com/users/mzhurovich","html_url":"https://github.com/mzhurovich","followers_url":"https://api.github.com/users/mzhurovich/followers","following_url":"https://api.github.com/users/mzhurovich/following{/other_user}","gists_url":"https://api.github.com/users/mzhurovich/gists{/gist_id}","starred_url":"https://api.github.com/users/mzhurovich/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mzhurovich/subscriptions","organizations_url":"https://api.github.com/users/mzhurovich/orgs","repos_url":"https://api.github.com/users/mzhurovich/repos","events_url":"https://api.github.com/users/mzhurovich/events{/privacy}","received_events_url":"https://api.github.com/users/mzhurovich/received_events","type":"User","site_admin":false},"body":"@dkorolev I didn't make changes to floating point values (de)serialization that we discussed over the phone.","created_at":"2015-11-16T19:21:54Z","updated_at":"2015-11-17T04:53:01Z","closed_at":null,"merged_at":null,"merge_commit_sha":"652067b04a93448c57b501f6782b36a2647b83aa","assignee":{"login":"dkorolev","id":2159447,"avatar_url":"https://avatars.githubusercontent.com/u/2159447?v=3","gravatar_id":"","url":"https://api.github.com/users/dkorolev","html_url":"https://github.com/dkorolev","followers_url":"https://api.github.com/users/dkorolev/followers","following_url":"https://api.github.com/users/dkorolev/following{/other_user}","gists_url":"https://api.github.com/users/dkorolev/gists{/gist_id}","starred_url":"https://api.github.com/users/dkorolev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dkorolev/subscriptions","organizations_url":"https://api.github.com/users/dkorolev/orgs","repos_url":"https://api.github.com/users/dkorolev/repos","events_url":"https://api.github.com/users/dkorolev/events{/privacy}","received_events_url":"https://api.github.com/users/dkorolev/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/c5t/Current/pulls/267/commits","review_comments_url":"https://api.github.com/repos/c5t/Current/pulls/267/comments","review_comment_url":"https://api.github.com/repos/c5t/Current/pulls/comments{/number}","comments_url":"https://api.github.com/repos/c5t/Current/issues/267/comments","statuses_url":"https://api.github.com/repos/c5t/Current/statuses/72b3fac1c39b70cf456620d7aff48c3316021025","head":{"label":"mzhurovich:reflect_and_serialize","ref":"reflect_and_serialize","sha":"72b3fac1c39b70cf456620d7aff48c3316021025","user":{"login":"mzhurovich","id":11226961,"avatar_url":"https://avatars.githubusercontent.com/u/11226961?v=3","gravatar_id":"","url":"https://api.github.com/users/mzhurovich","html_url":"https://github.com/mzhurovich","followers_url":"https://api.github.com/users/mzhurovich/followers","following_url":"https://api.github.com/users/mzhurovich/following{/other_user}","gists_url":"https://api.github.com/users/mzhurovich/gists{/gist_id}","starred_url":"https://api.github.com/users/mzhurovich/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mzhurovich/subscriptions","organizations_url":"https://api.github.com/users/mzhurovich/orgs","repos_url":"https://api.github.com/users/mzhurovich/repos","events_url":"https://api.github.com/users/mzhurovich/events{/privacy}","received_events_url":"https://api.github.com/users/mzhurovich/received_events","type":"User","site_admin":false},"repo":{"id":31462826,"name":"Current","full_name":"mzhurovich/Current","owner":{"login":"mzhurovich","id":11226961,"avatar_url":"https://avatars.githubusercontent.com/u/11226961?v=3","gravatar_id":"","url":"https://api.github.com/users/mzhurovich","html_url":"https://github.com/mzhurovich","followers_url":"https://api.github.com/users/mzhurovich/followers","following_url":"https://api.github.com/users/mzhurovich/following{/other_user}","gists_url":"https://api.github.com/users/mzhurovich/gists{/gist_id}","starred_url":"https://api.github.com/users/mzhurovich/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mzhurovich/subscriptions","organizations_url":"https://api.github.com/users/mzhurovich/orgs","repos_url":"https://api.github.com/users/mzhurovich/repos","events_url":"https://api.github.com/users/mzhurovich/events{/privacy}","received_events_url":"https://api.github.com/users/mzhurovich/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mzhurovich/Current","description":"Our own core pieces to reuse.","fork":true,"url":"https://api.github.com/repos/mzhurovich/Current","forks_url":"https://api.github.com/repos/mzhurovich/Current/forks","keys_url":"https://api.github.com/repos/mzhurovich/Current/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mzhurovich/Current/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mzhurovich/Current/teams","hooks_url":"https://api.github.com/repos/mzhurovich/Current/hooks","issue_events_url":"https://api.github.com/repos/mzhurovich/Current/issues/events{/number}","events_url":"https://api.github.com/repos/mzhurovich/Current/events","assignees_url":"https://api.github.com/repos/mzhurovich/Current/assignees{/user}","branches_url":"https://api.github.com/repos/mzhurovich/Current/branches{/branch}","tags_url":"https://api.github.com/repos/mzhurovich/Current/tags","blobs_url":"https://api.github.com/repos/mzhurovich/Current/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mzhurovich/Current/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mzhurovich/Current/git/refs{/sha}","trees_url":"https://api.github.com/repos/mzhurovich/Current/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mzhurovich/Current/statuses/{sha}","languages_url":"https://api.github.com/repos/mzhurovich/Current/languages","stargazers_url":"https://api.github.com/repos/mzhurovich/Current/stargazers","contributors_url":"https://api.github.com/repos/mzhurovich/Current/contributors","subscribers_url":"https://api.github.com/repos/mzhurovich/Current/subscribers","subscription_url":"https://api.github.com/repos/mzhurovich/Current/subscription","commits_url":"https://api.github.com/repos/mzhurovich/Current/commits{/sha}","git_commits_url":"https://api.github.com/repos/mzhurovich/Current/git/commits{/sha}","comments_url":"https://api.github.com/repos/mzhurovich/Current/comments{/number}","issue_comment_url":"https://api.github.com/repos/mzhurovich/Current/issues/comments{/number}","contents_url":"https://api.github.com/repos/mzhurovich/Current/contents/{+path}","compare_url":"https://api.github.com/repos/mzhurovich/Current/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mzhurovich/Current/merges","archive_url":"https://api.github.com/repos/mzhurovich/Current/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mzhurovich/Current/downloads","issues_url":"https://api.github.com/repos/mzhurovich/Current/issues{/number}","pulls_url":"https://api.github.com/repos/mzhurovich/Current/pulls{/number}","milestones_url":"https://api.github.com/repos/mzhurovich/Current/milestones{/number}","notifications_url":"https://api.github.com/repos/mzhurovich/Current/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mzhurovich/Current/labels{/name}","releases_url":"https://api.github.com/repos/mzhurovich/Current/releases{/id}","created_at":"2015-02-28T13:03:55Z","updated_at":"2015-05-24T23:39:55Z","pushed_at":"2015-11-16T19:19:17Z","git_url":"git://github.com/mzhurovich/Current.git","ssh_url":"git@github.com:mzhurovich/Current.git","clone_url":"https://github.com/mzhurovich/Current.git","svn_url":"https://github.com/mzhurovich/Current","homepage":null,"size":9027,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"c5t:master","ref":"master","sha":"aafcae1f7603c8ac493243561d745fd6a76d6cd1","user":{"login":"c5t","id":12224789,"avatar_url":"https://avatars.githubusercontent.com/u/12224789?v=3","gravatar_id":"","url":"https://api.github.com/users/c5t","html_url":"https://github.com/c5t","followers_url":"https://api.github.com/users/c5t/followers","following_url":"https://api.github.com/users/c5t/following{/other_user}","gists_url":"https://api.github.com/users/c5t/gists{/gist_id}","starred_url":"https://api.github.com/users/c5t/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/c5t/subscriptions","organizations_url":"https://api.github.com/users/c5t/orgs","repos_url":"https://api.github.com/users/c5t/repos","events_url":"https://api.github.com/users/c5t/events{/privacy}","received_events_url":"https://api.github.com/users/c5t/received_events","type":"Organization","site_admin":false},"repo":{"id":27625425,"name":"Current","full_name":"c5t/Current","owner":{"login":"c5t","id":12224789,"avatar_url":"https://avatars.githubusercontent.com/u/12224789?v=3","gravatar_id":"","url":"https://api.github.com/users/c5t","html_url":"https://github.com/c5t","followers_url":"https://api.github.com/users/c5t/followers","following_url":"https://api.github.com/users/c5t/following{/other_user}","gists_url":"https://api.github.com/users/c5t/gists{/gist_id}","starred_url":"https://api.github.com/users/c5t/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/c5t/subscriptions","organizations_url":"https://api.github.com/users/c5t/orgs","repos_url":"https://api.github.com/users/c5t/repos","events_url":"https://api.github.com/users/c5t/events{/privacy}","received_events_url":"https://api.github.com/users/c5t/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/c5t/Current","description":"Data Infrastructure in the Box:","fork":false,"url":"https://api.github.com/repos/c5t/Current","forks_url":"https://api.github.com/repos/c5t/Current/forks","keys_url":"https://api.github.com/repos/c5t/Current/keys{/key_id}","collaborators_url":"https://api.github.com/repos/c5t/Current/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/c5t/Current/teams","hooks_url":"https://api.github.com/repos/c5t/Current/hooks","issue_events_url":"https://api.github.com/repos/c5t/Current/issues/events{/number}","events_url":"https://api.github.com/repos/c5t/Current/events","assignees_url":"https://api.github.com/repos/c5t/Current/assignees{/user}","branches_url":"https://api.github.com/repos/c5t/Current/branches{/branch}","tags_url":"https://api.github.com/repos/c5t/Current/tags","blobs_url":"https://api.github.com/repos/c5t/Current/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/c5t/Current/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/c5t/Current/git/refs{/sha}","trees_url":"https://api.github.com/repos/c5t/Current/git/trees{/sha}","statuses_url":"https://api.github.com/repos/c5t/Current/statuses/{sha}","languages_url":"https://api.github.com/repos/c5t/Current/languages","stargazers_url":"https://api.github.com/repos/c5t/Current/stargazers","contributors_url":"https://api.github.com/repos/c5t/Current/contributors","subscribers_url":"https://api.github.com/repos/c5t/Current/subscribers","subscription_url":"https://api.github.com/repos/c5t/Current/subscription","commits_url":"https://api.github.com/repos/c5t/Current/commits{/sha}","git_commits_url":"https://api.github.com/repos/c5t/Current/git/commits{/sha}","comments_url":"https://api.github.com/repos/c5t/Current/comments{/number}","issue_comment_url":"https://api.github.com/repos/c5t/Current/issues/comments{/number}","contents_url":"https://api.github.com/repos/c5t/Current/contents/{+path}","compare_url":"https://api.github.com/repos/c5t/Current/compare/{base}...{head}","merges_url":"https://api.github.com/repos/c5t/Current/merges","archive_url":"https://api.github.com/repos/c5t/Current/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/c5t/Current/downloads","issues_url":"https://api.github.com/repos/c5t/Current/issues{/number}","pulls_url":"https://api.github.com/repos/c5t/Current/pulls{/number}","milestones_url":"https://api.github.com/repos/c5t/Current/milestones{/number}","notifications_url":"https://api.github.com/repos/c5t/Current/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/c5t/Current/labels{/name}","releases_url":"https://api.github.com/repos/c5t/Current/releases{/id}","created_at":"2014-12-06T06:52:23Z","updated_at":"2015-11-08T23:52:54Z","pushed_at":"2015-11-16T19:21:55Z","git_url":"git://github.com/c5t/Current.git","ssh_url":"git@github.com:c5t/Current.git","clone_url":"https://github.com/c5t/Current.git","svn_url":"https://github.com/c5t/Current","homepage":"https://j.mp/currentintelligence","size":10216,"stargazers_count":21,"watchers_count":21,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":9,"mirror_url":null,"open_issues_count":36,"forks":9,"open_issues":36,"watchers":21,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/c5t/Current/pulls/267"},"html":{"href":"https://github.com/c5t/Current/pull/267"},"issue":{"href":"https://api.github.com/repos/c5t/Current/issues/267"},"comments":{"href":"https://api.github.com/repos/c5t/Current/issues/267/comments"},"review_comments":{"href":"https://api.github.com/repos/c5t/Current/pulls/267/comments"},"review_comment":{"href":"https://api.github.com/repos/c5t/Current/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/c5t/Current/pulls/267/commits"},"statuses":{"href":"https://api.github.com/repos/c5t/Current/statuses/72b3fac1c39b70cf456620d7aff48c3316021025"}}}}