{"action":"closed","issue":{"url":"https://api.github.com/repos/serde-rs/serde/issues/415","repository_url":"https://api.github.com/repos/serde-rs/serde","labels_url":"https://api.github.com/repos/serde-rs/serde/issues/415/labels{/name}","comments_url":"https://api.github.com/repos/serde-rs/serde/issues/415/comments","events_url":"https://api.github.com/repos/serde-rs/serde/issues/415/events","html_url":"https://github.com/serde-rs/serde/issues/415","id":162867209,"number":415,"title":"Is it possible to handle tagged enums?","user":{"login":"hh9527","id":3439410,"avatar_url":"https://avatars.githubusercontent.com/u/3439410?v=3","gravatar_id":"","url":"https://api.github.com/users/hh9527","html_url":"https://github.com/hh9527","followers_url":"https://api.github.com/users/hh9527/followers","following_url":"https://api.github.com/users/hh9527/following{/other_user}","gists_url":"https://api.github.com/users/hh9527/gists{/gist_id}","starred_url":"https://api.github.com/users/hh9527/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hh9527/subscriptions","organizations_url":"https://api.github.com/users/hh9527/orgs","repos_url":"https://api.github.com/users/hh9527/repos","events_url":"https://api.github.com/users/hh9527/events{/privacy}","received_events_url":"https://api.github.com/users/hh9527/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/serde-rs/serde/labels/support","name":"support","color":"fef2c0"}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2016-06-29T08:22:22Z","updated_at":"2016-06-29T16:09:36Z","closed_at":"2016-06-29T16:09:36Z","body":"```rust\r\n#[derive(Serialize, Deserialize, Debug)]\r\nenum Motion {\r\n  Column(i32),\r\n  Line(i32),\r\n}\r\n\r\n#[derive(Serialize, Deserialize, Debug)]\r\nenum Command {\r\n  Move(Motion),\r\n  Delete(Motion),\r\n  Input(String),\r\n}\r\n\r\nfn main() {\r\n  let cmd = Command::Move(Motion::Column(1));\r\n  let cmd_str = serde_json::to_string(&cmd).unwrap();\r\n  println!(\"result: {}\", cmd_str);\r\n}\r\n```\r\n\r\nthis will get result like this:\r\n```json\r\n{\r\n  \"Move\": {\r\n    \"Column\": 1\r\n  }\r\n}\r\n```\r\n\r\nIs it possible to make it be:\r\n```json\r\n{\r\n  \"type\": \"Move\",\r\n  \"content\": {\r\n    \"type\": \"Column\",\r\n    \"content\": 1\r\n  }\r\n}\r\n```\r\n"}}
{"actor":{"display_login":"dtolnay"}}