{"action":"created","comment":{"url":"https://api.github.com/repos/jonathandturner/rls/pulls/comments/85215524","pull_request_review_id":5939522,"id":85215524,"diff_hunk":"@@ -87,72 +90,56 @@ impl Location {\n             uri: Url::from_file_path(&file_name).unwrap().into_string(),\n             range: Range {\n                 start: Position {\n-                    line: line,\n-                    character: col,\n+                    line: from_usize(line),\n+                    character: from_usize(col),\n                 },\n                 end: Position {\n-                    line: line,\n-                    character: col,\n+                    line: from_usize(line),\n+                    character: from_usize(col),\n                 },\n             },\n         }\n     }\n }\n \n-/// The initialize request is sent as the first request from the client to the server.\n-#[allow(non_snake_case)]\n-#[derive(Debug, Deserialize)]\n-pub struct InitializeParams {\n-    pub processId: usize,\n-    pub rootPath: PathBuf\n-}\n-\n-#[derive(Debug, Deserialize)]\n-pub struct Document {\n-    pub uri: String\n+pub fn sk_from_def_kind(k: raw::DefKind) -> SymbolKind {\n+    match k {\n+        raw::DefKind::Enum => SymbolKind::Enum,\n+        raw::DefKind::Tuple => SymbolKind::Array,\n+        raw::DefKind::Struct => SymbolKind::Class,\n+        raw::DefKind::Trait => SymbolKind::Interface,\n+        raw::DefKind::Function => SymbolKind::Function,\n+        raw::DefKind::Method => SymbolKind::Function,\n+        raw::DefKind::Macro => SymbolKind::Function,\n+        raw::DefKind::Mod => SymbolKind::Module,\n+        raw::DefKind::Type => SymbolKind::Interface,\n+        raw::DefKind::Local => SymbolKind::Variable,\n+        raw::DefKind::Static => SymbolKind::Variable,\n+        raw::DefKind::Const => SymbolKind::Variable,\n+        raw::DefKind::Field => SymbolKind::Variable,\n+        raw::DefKind::Import => SymbolKind::Module,\n+    }\n }\n \n-impl_file_name!(Document);\n-\n-#[allow(non_snake_case)]\n-#[derive(Debug, Deserialize)]\n-pub struct TextDocumentIdentifier {\n-    pub uri: String\n+pub fn new_completion_item(label: String, detail: String) -> CompletionItem {\n+\tCompletionItem {\n+        label : label,\n+        kind: None,\n+        detail: Some(detail),\n+        documentation: None,\n+        sort_text: None,\n+        filter_text: None,\n+        insert_text: None,\n+        text_edit: None,\n+        additional_text_edits: None,\n+        command: None,\n+        data: None,\n+\t}\n }\n \n-impl_file_name!(TextDocumentIdentifier);\n-\n-#[allow(non_snake_case)]\n-#[derive(Debug, Deserialize)]\n-pub struct VersionedTextDocumentIdentifier {\n-    pub version: u64,\n-    pub uri: String\n-}\n+pub type HoverParams = TextDocumentPositionParams;","path":"src/lsp_data.rs","position":194,"original_position":194,"commit_id":"d87d7dbb23a80fa569b522fec6a99eb2f699fabd","original_commit_id":"d87d7dbb23a80fa569b522fec6a99eb2f699fabd","user":{"login":"nrc","id":762626,"avatar_url":"https://avatars.githubusercontent.com/u/762626?v=3","gravatar_id":"","url":"https://api.github.com/users/nrc","html_url":"https://github.com/nrc","followers_url":"https://api.github.com/users/nrc/followers","following_url":"https://api.github.com/users/nrc/following{/other_user}","gists_url":"https://api.github.com/users/nrc/gists{/gist_id}","starred_url":"https://api.github.com/users/nrc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nrc/subscriptions","organizations_url":"https://api.github.com/users/nrc/orgs","repos_url":"https://api.github.com/users/nrc/repos","events_url":"https://api.github.com/users/nrc/events{/privacy}","received_events_url":"https://api.github.com/users/nrc/received_events","type":"User","site_admin":false},"body":"Can probably do without this","created_at":"2016-10-26T20:41:37Z","updated_at":"2016-10-26T20:41:37Z","html_url":"https://github.com/jonathandturner/rls/pull/79#discussion_r85215524","pull_request_url":"https://api.github.com/repos/jonathandturner/rls/pulls/79","_links":{"self":{"href":"https://api.github.com/repos/jonathandturner/rls/pulls/comments/85215524"},"html":{"href":"https://github.com/jonathandturner/rls/pull/79#discussion_r85215524"},"pull_request":{"href":"https://api.github.com/repos/jonathandturner/rls/pulls/79"}}},"pull_request":{"url":"https://api.github.com/repos/jonathandturner/rls/pulls/79","id":91072371,"html_url":"https://github.com/jonathandturner/rls/pull/79","diff_url":"https://github.com/jonathandturner/rls/pull/79.diff","patch_url":"https://github.com/jonathandturner/rls/pull/79.patch","issue_url":"https://api.github.com/repos/jonathandturner/rls/issues/79","number":79,"state":"open","locked":false,"title":"Use languageserver-types crate","user":{"login":"bruno-medeiros","id":4324232,"avatar_url":"https://avatars.githubusercontent.com/u/4324232?v=3","gravatar_id":"","url":"https://api.github.com/users/bruno-medeiros","html_url":"https://github.com/bruno-medeiros","followers_url":"https://api.github.com/users/bruno-medeiros/followers","following_url":"https://api.github.com/users/bruno-medeiros/following{/other_user}","gists_url":"https://api.github.com/users/bruno-medeiros/gists{/gist_id}","starred_url":"https://api.github.com/users/bruno-medeiros/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bruno-medeiros/subscriptions","organizations_url":"https://api.github.com/users/bruno-medeiros/orgs","repos_url":"https://api.github.com/users/bruno-medeiros/repos","events_url":"https://api.github.com/users/bruno-medeiros/events{/privacy}","received_events_url":"https://api.github.com/users/bruno-medeiros/received_events","type":"User","site_admin":false},"body":"See #52 \r\n\r\nOf note, need to review `lsp_data::to_usize` and `ActionHandler::on_change` when range is None","created_at":"2016-10-26T19:33:49Z","updated_at":"2016-10-26T20:46:12Z","closed_at":null,"merged_at":null,"merge_commit_sha":"91ba35f4e60073e4521a79f9b0f2e88e6a081475","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/jonathandturner/rls/pulls/79/commits","review_comments_url":"https://api.github.com/repos/jonathandturner/rls/pulls/79/comments","review_comment_url":"https://api.github.com/repos/jonathandturner/rls/pulls/comments{/number}","comments_url":"https://api.github.com/repos/jonathandturner/rls/issues/79/comments","statuses_url":"https://api.github.com/repos/jonathandturner/rls/statuses/d87d7dbb23a80fa569b522fec6a99eb2f699fabd","head":{"label":"bruno-medeiros:master","ref":"master","sha":"d87d7dbb23a80fa569b522fec6a99eb2f699fabd","user":{"login":"bruno-medeiros","id":4324232,"avatar_url":"https://avatars.githubusercontent.com/u/4324232?v=3","gravatar_id":"","url":"https://api.github.com/users/bruno-medeiros","html_url":"https://github.com/bruno-medeiros","followers_url":"https://api.github.com/users/bruno-medeiros/followers","following_url":"https://api.github.com/users/bruno-medeiros/following{/other_user}","gists_url":"https://api.github.com/users/bruno-medeiros/gists{/gist_id}","starred_url":"https://api.github.com/users/bruno-medeiros/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bruno-medeiros/subscriptions","organizations_url":"https://api.github.com/users/bruno-medeiros/orgs","repos_url":"https://api.github.com/users/bruno-medeiros/repos","events_url":"https://api.github.com/users/bruno-medeiros/events{/privacy}","received_events_url":"https://api.github.com/users/bruno-medeiros/received_events","type":"User","site_admin":false},"repo":{"id":72034657,"name":"rls","full_name":"bruno-medeiros/rls","owner":{"login":"bruno-medeiros","id":4324232,"avatar_url":"https://avatars.githubusercontent.com/u/4324232?v=3","gravatar_id":"","url":"https://api.github.com/users/bruno-medeiros","html_url":"https://github.com/bruno-medeiros","followers_url":"https://api.github.com/users/bruno-medeiros/followers","following_url":"https://api.github.com/users/bruno-medeiros/following{/other_user}","gists_url":"https://api.github.com/users/bruno-medeiros/gists{/gist_id}","starred_url":"https://api.github.com/users/bruno-medeiros/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bruno-medeiros/subscriptions","organizations_url":"https://api.github.com/users/bruno-medeiros/orgs","repos_url":"https://api.github.com/users/bruno-medeiros/repos","events_url":"https://api.github.com/users/bruno-medeiros/events{/privacy}","received_events_url":"https://api.github.com/users/bruno-medeiros/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/bruno-medeiros/rls","description":"Repository for the Rust Language Service (aka RLS)","fork":true,"url":"https://api.github.com/repos/bruno-medeiros/rls","forks_url":"https://api.github.com/repos/bruno-medeiros/rls/forks","keys_url":"https://api.github.com/repos/bruno-medeiros/rls/keys{/key_id}","collaborators_url":"https://api.github.com/repos/bruno-medeiros/rls/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/bruno-medeiros/rls/teams","hooks_url":"https://api.github.com/repos/bruno-medeiros/rls/hooks","issue_events_url":"https://api.github.com/repos/bruno-medeiros/rls/issues/events{/number}","events_url":"https://api.github.com/repos/bruno-medeiros/rls/events","assignees_url":"https://api.github.com/repos/bruno-medeiros/rls/assignees{/user}","branches_url":"https://api.github.com/repos/bruno-medeiros/rls/branches{/branch}","tags_url":"https://api.github.com/repos/bruno-medeiros/rls/tags","blobs_url":"https://api.github.com/repos/bruno-medeiros/rls/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/bruno-medeiros/rls/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/bruno-medeiros/rls/git/refs{/sha}","trees_url":"https://api.github.com/repos/bruno-medeiros/rls/git/trees{/sha}","statuses_url":"https://api.github.com/repos/bruno-medeiros/rls/statuses/{sha}","languages_url":"https://api.github.com/repos/bruno-medeiros/rls/languages","stargazers_url":"https://api.github.com/repos/bruno-medeiros/rls/stargazers","contributors_url":"https://api.github.com/repos/bruno-medeiros/rls/contributors","subscribers_url":"https://api.github.com/repos/bruno-medeiros/rls/subscribers","subscription_url":"https://api.github.com/repos/bruno-medeiros/rls/subscription","commits_url":"https://api.github.com/repos/bruno-medeiros/rls/commits{/sha}","git_commits_url":"https://api.github.com/repos/bruno-medeiros/rls/git/commits{/sha}","comments_url":"https://api.github.com/repos/bruno-medeiros/rls/comments{/number}","issue_comment_url":"https://api.github.com/repos/bruno-medeiros/rls/issues/comments{/number}","contents_url":"https://api.github.com/repos/bruno-medeiros/rls/contents/{+path}","compare_url":"https://api.github.com/repos/bruno-medeiros/rls/compare/{base}...{head}","merges_url":"https://api.github.com/repos/bruno-medeiros/rls/merges","archive_url":"https://api.github.com/repos/bruno-medeiros/rls/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/bruno-medeiros/rls/downloads","issues_url":"https://api.github.com/repos/bruno-medeiros/rls/issues{/number}","pulls_url":"https://api.github.com/repos/bruno-medeiros/rls/pulls{/number}","milestones_url":"https://api.github.com/repos/bruno-medeiros/rls/milestones{/number}","notifications_url":"https://api.github.com/repos/bruno-medeiros/rls/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/bruno-medeiros/rls/labels{/name}","releases_url":"https://api.github.com/repos/bruno-medeiros/rls/releases{/id}","deployments_url":"https://api.github.com/repos/bruno-medeiros/rls/deployments","created_at":"2016-10-26T18:55:12Z","updated_at":"2016-10-26T18:55:14Z","pushed_at":"2016-10-26T19:30:51Z","git_url":"git://github.com/bruno-medeiros/rls.git","ssh_url":"git@github.com:bruno-medeiros/rls.git","clone_url":"https://github.com/bruno-medeiros/rls.git","svn_url":"https://github.com/bruno-medeiros/rls","homepage":"","size":223,"stargazers_count":0,"watchers_count":0,"language":"Rust","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":"jonathandturner:master","ref":"master","sha":"82187a34af9a8bd1a95f91bcb9815190becaa902","user":{"login":"jonathandturner","id":547158,"avatar_url":"https://avatars.githubusercontent.com/u/547158?v=3","gravatar_id":"","url":"https://api.github.com/users/jonathandturner","html_url":"https://github.com/jonathandturner","followers_url":"https://api.github.com/users/jonathandturner/followers","following_url":"https://api.github.com/users/jonathandturner/following{/other_user}","gists_url":"https://api.github.com/users/jonathandturner/gists{/gist_id}","starred_url":"https://api.github.com/users/jonathandturner/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jonathandturner/subscriptions","organizations_url":"https://api.github.com/users/jonathandturner/orgs","repos_url":"https://api.github.com/users/jonathandturner/repos","events_url":"https://api.github.com/users/jonathandturner/events{/privacy}","received_events_url":"https://api.github.com/users/jonathandturner/received_events","type":"User","site_admin":false},"repo":{"id":66979953,"name":"rls","full_name":"jonathandturner/rls","owner":{"login":"jonathandturner","id":547158,"avatar_url":"https://avatars.githubusercontent.com/u/547158?v=3","gravatar_id":"","url":"https://api.github.com/users/jonathandturner","html_url":"https://github.com/jonathandturner","followers_url":"https://api.github.com/users/jonathandturner/followers","following_url":"https://api.github.com/users/jonathandturner/following{/other_user}","gists_url":"https://api.github.com/users/jonathandturner/gists{/gist_id}","starred_url":"https://api.github.com/users/jonathandturner/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jonathandturner/subscriptions","organizations_url":"https://api.github.com/users/jonathandturner/orgs","repos_url":"https://api.github.com/users/jonathandturner/repos","events_url":"https://api.github.com/users/jonathandturner/events{/privacy}","received_events_url":"https://api.github.com/users/jonathandturner/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jonathandturner/rls","description":"Repository for the Rust Language Service (aka RLS)","fork":false,"url":"https://api.github.com/repos/jonathandturner/rls","forks_url":"https://api.github.com/repos/jonathandturner/rls/forks","keys_url":"https://api.github.com/repos/jonathandturner/rls/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jonathandturner/rls/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jonathandturner/rls/teams","hooks_url":"https://api.github.com/repos/jonathandturner/rls/hooks","issue_events_url":"https://api.github.com/repos/jonathandturner/rls/issues/events{/number}","events_url":"https://api.github.com/repos/jonathandturner/rls/events","assignees_url":"https://api.github.com/repos/jonathandturner/rls/assignees{/user}","branches_url":"https://api.github.com/repos/jonathandturner/rls/branches{/branch}","tags_url":"https://api.github.com/repos/jonathandturner/rls/tags","blobs_url":"https://api.github.com/repos/jonathandturner/rls/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jonathandturner/rls/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jonathandturner/rls/git/refs{/sha}","trees_url":"https://api.github.com/repos/jonathandturner/rls/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jonathandturner/rls/statuses/{sha}","languages_url":"https://api.github.com/repos/jonathandturner/rls/languages","stargazers_url":"https://api.github.com/repos/jonathandturner/rls/stargazers","contributors_url":"https://api.github.com/repos/jonathandturner/rls/contributors","subscribers_url":"https://api.github.com/repos/jonathandturner/rls/subscribers","subscription_url":"https://api.github.com/repos/jonathandturner/rls/subscription","commits_url":"https://api.github.com/repos/jonathandturner/rls/commits{/sha}","git_commits_url":"https://api.github.com/repos/jonathandturner/rls/git/commits{/sha}","comments_url":"https://api.github.com/repos/jonathandturner/rls/comments{/number}","issue_comment_url":"https://api.github.com/repos/jonathandturner/rls/issues/comments{/number}","contents_url":"https://api.github.com/repos/jonathandturner/rls/contents/{+path}","compare_url":"https://api.github.com/repos/jonathandturner/rls/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jonathandturner/rls/merges","archive_url":"https://api.github.com/repos/jonathandturner/rls/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jonathandturner/rls/downloads","issues_url":"https://api.github.com/repos/jonathandturner/rls/issues{/number}","pulls_url":"https://api.github.com/repos/jonathandturner/rls/pulls{/number}","milestones_url":"https://api.github.com/repos/jonathandturner/rls/milestones{/number}","notifications_url":"https://api.github.com/repos/jonathandturner/rls/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jonathandturner/rls/labels{/name}","releases_url":"https://api.github.com/repos/jonathandturner/rls/releases{/id}","deployments_url":"https://api.github.com/repos/jonathandturner/rls/deployments","created_at":"2016-08-30T21:42:03Z","updated_at":"2016-10-26T17:28:02Z","pushed_at":"2016-10-26T19:33:49Z","git_url":"git://github.com/jonathandturner/rls.git","ssh_url":"git@github.com:jonathandturner/rls.git","clone_url":"https://github.com/jonathandturner/rls.git","svn_url":"https://github.com/jonathandturner/rls","homepage":"","size":235,"stargazers_count":276,"watchers_count":276,"language":"Rust","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":15,"mirror_url":null,"open_issues_count":44,"forks":15,"open_issues":44,"watchers":276,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/jonathandturner/rls/pulls/79"},"html":{"href":"https://github.com/jonathandturner/rls/pull/79"},"issue":{"href":"https://api.github.com/repos/jonathandturner/rls/issues/79"},"comments":{"href":"https://api.github.com/repos/jonathandturner/rls/issues/79/comments"},"review_comments":{"href":"https://api.github.com/repos/jonathandturner/rls/pulls/79/comments"},"review_comment":{"href":"https://api.github.com/repos/jonathandturner/rls/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/jonathandturner/rls/pulls/79/commits"},"statuses":{"href":"https://api.github.com/repos/jonathandturner/rls/statuses/d87d7dbb23a80fa569b522fec6a99eb2f699fabd"}}}}
{"actor":{"display_login":"nrc"}}