{"action":"created","comment":{"url":"https://api.github.com/repos/neovim/neovim/pulls/comments/28188512","id":28188512,"diff_hunk":"@@ -1834,15 +1839,26 @@ getexmodeline (\n         } else {\n           p[line_ga.ga_len] = NUL;\n           indent = get_indent_str(p, 8, FALSE);\n+          if (indent == 0) {\n+            continue;\n+          }\n           --indent;\n           indent -= indent % get_sw_value(curbuf);\n         }\n-        while (get_indent_str(p, 8, FALSE) > indent) {\n-          char_u *s = skipwhite(p);\n \n-          memmove(s - 1, s, line_ga.ga_len - (s - p) + 1);\n-          --line_ga.ga_len;\n+        // Delete trailing leading whitespaces until enough indentation\n+        // is removed.","path":"src/nvim/ex_getln.c","position":53,"original_position":53,"commit_id":"f349151e5f1a74303ca2913a0befdc0eb9b505b8","original_commit_id":"f349151e5f1a74303ca2913a0befdc0eb9b505b8","user":{"login":"splinterofchaos","id":38515,"avatar_url":"https://avatars.githubusercontent.com/u/38515?v=3","gravatar_id":"","url":"https://api.github.com/users/splinterofchaos","html_url":"https://github.com/splinterofchaos","followers_url":"https://api.github.com/users/splinterofchaos/followers","following_url":"https://api.github.com/users/splinterofchaos/following{/other_user}","gists_url":"https://api.github.com/users/splinterofchaos/gists{/gist_id}","starred_url":"https://api.github.com/users/splinterofchaos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/splinterofchaos/subscriptions","organizations_url":"https://api.github.com/users/splinterofchaos/orgs","repos_url":"https://api.github.com/users/splinterofchaos/repos","events_url":"https://api.github.com/users/splinterofchaos/events{/privacy}","received_events_url":"https://api.github.com/users/splinterofchaos/received_events","type":"User","site_admin":false},"body":"\"trailing **and** leading whitespace\"? Enough indentation removed for what?","created_at":"2015-04-10T23:45:17Z","updated_at":"2015-04-10T23:45:17Z","html_url":"https://github.com/neovim/neovim/pull/2319#discussion_r28188512","pull_request_url":"https://api.github.com/repos/neovim/neovim/pulls/2319","_links":{"self":{"href":"https://api.github.com/repos/neovim/neovim/pulls/comments/28188512"},"html":{"href":"https://github.com/neovim/neovim/pull/2319#discussion_r28188512"},"pull_request":{"href":"https://api.github.com/repos/neovim/neovim/pulls/2319"}}},"pull_request":{"url":"https://api.github.com/repos/neovim/neovim/pulls/2319","id":32355936,"html_url":"https://github.com/neovim/neovim/pull/2319","diff_url":"https://github.com/neovim/neovim/pull/2319.diff","patch_url":"https://github.com/neovim/neovim/pull/2319.patch","issue_url":"https://api.github.com/repos/neovim/neovim/issues/2319","number":2319,"state":"open","locked":false,"title":"[RFC] ex_getln: Fixes for some problems with getexmodeline()","user":{"login":"oni-link","id":2077655,"avatar_url":"https://avatars.githubusercontent.com/u/2077655?v=3","gravatar_id":"","url":"https://api.github.com/users/oni-link","html_url":"https://github.com/oni-link","followers_url":"https://api.github.com/users/oni-link/followers","following_url":"https://api.github.com/users/oni-link/following{/other_user}","gists_url":"https://api.github.com/users/oni-link/gists{/gist_id}","starred_url":"https://api.github.com/users/oni-link/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/oni-link/subscriptions","organizations_url":"https://api.github.com/users/oni-link/orgs","repos_url":"https://api.github.com/users/oni-link/repos","events_url":"https://api.github.com/users/oni-link/events{/privacy}","received_events_url":"https://api.github.com/users/oni-link/received_events","type":"User","site_admin":false},"body":"ex_getln: Fixes for some problems with getexmodeline()\r\n\r\nProblems with line-input editing commands in Ex mode\r\n('nvim -e' or 'Q' in normal mode):\r\n\r\nCTRL_U: Only after the next keystroke the complete\r\n        line change is shown if the indentation was\r\n        not 0.\r\n\r\n        :     asdfCTRL_U\r\n\r\nCTRL_T: Memory reallocation with ga_grows() before a\r\n        memmove(), but pointers into the memory are\r\n        not updated.\r\n\r\n        :set sw=40\r\n        :CTRL_T\r\n        ...\r\n\r\n        Should complain about error a memory error.\r\n\r\nCTRL_D: Trying to reduce an indentation of 0.\r\n\r\n        :set sw=1\r\n        :CTRL_D\r\n\r\n        Segfault","created_at":"2015-03-31T19:18:34Z","updated_at":"2015-04-10T23:45:17Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f1254910e62133c6dce2e059cd6b4d01013028a0","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/neovim/neovim/pulls/2319/commits","review_comments_url":"https://api.github.com/repos/neovim/neovim/pulls/2319/comments","review_comment_url":"https://api.github.com/repos/neovim/neovim/pulls/comments{/number}","comments_url":"https://api.github.com/repos/neovim/neovim/issues/2319/comments","statuses_url":"https://api.github.com/repos/neovim/neovim/statuses/f349151e5f1a74303ca2913a0befdc0eb9b505b8","head":{"label":"oni-link:fixes.for.getexmodeline","ref":"fixes.for.getexmodeline","sha":"f349151e5f1a74303ca2913a0befdc0eb9b505b8","user":{"login":"oni-link","id":2077655,"avatar_url":"https://avatars.githubusercontent.com/u/2077655?v=3","gravatar_id":"","url":"https://api.github.com/users/oni-link","html_url":"https://github.com/oni-link","followers_url":"https://api.github.com/users/oni-link/followers","following_url":"https://api.github.com/users/oni-link/following{/other_user}","gists_url":"https://api.github.com/users/oni-link/gists{/gist_id}","starred_url":"https://api.github.com/users/oni-link/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/oni-link/subscriptions","organizations_url":"https://api.github.com/users/oni-link/orgs","repos_url":"https://api.github.com/users/oni-link/repos","events_url":"https://api.github.com/users/oni-link/events{/privacy}","received_events_url":"https://api.github.com/users/oni-link/received_events","type":"User","site_admin":false},"repo":{"id":17510953,"name":"neovim","full_name":"oni-link/neovim","owner":{"login":"oni-link","id":2077655,"avatar_url":"https://avatars.githubusercontent.com/u/2077655?v=3","gravatar_id":"","url":"https://api.github.com/users/oni-link","html_url":"https://github.com/oni-link","followers_url":"https://api.github.com/users/oni-link/followers","following_url":"https://api.github.com/users/oni-link/following{/other_user}","gists_url":"https://api.github.com/users/oni-link/gists{/gist_id}","starred_url":"https://api.github.com/users/oni-link/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/oni-link/subscriptions","organizations_url":"https://api.github.com/users/oni-link/orgs","repos_url":"https://api.github.com/users/oni-link/repos","events_url":"https://api.github.com/users/oni-link/events{/privacy}","received_events_url":"https://api.github.com/users/oni-link/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/oni-link/neovim","description":"vim's rebirth for the 21st century","fork":true,"url":"https://api.github.com/repos/oni-link/neovim","forks_url":"https://api.github.com/repos/oni-link/neovim/forks","keys_url":"https://api.github.com/repos/oni-link/neovim/keys{/key_id}","collaborators_url":"https://api.github.com/repos/oni-link/neovim/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/oni-link/neovim/teams","hooks_url":"https://api.github.com/repos/oni-link/neovim/hooks","issue_events_url":"https://api.github.com/repos/oni-link/neovim/issues/events{/number}","events_url":"https://api.github.com/repos/oni-link/neovim/events","assignees_url":"https://api.github.com/repos/oni-link/neovim/assignees{/user}","branches_url":"https://api.github.com/repos/oni-link/neovim/branches{/branch}","tags_url":"https://api.github.com/repos/oni-link/neovim/tags","blobs_url":"https://api.github.com/repos/oni-link/neovim/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/oni-link/neovim/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/oni-link/neovim/git/refs{/sha}","trees_url":"https://api.github.com/repos/oni-link/neovim/git/trees{/sha}","statuses_url":"https://api.github.com/repos/oni-link/neovim/statuses/{sha}","languages_url":"https://api.github.com/repos/oni-link/neovim/languages","stargazers_url":"https://api.github.com/repos/oni-link/neovim/stargazers","contributors_url":"https://api.github.com/repos/oni-link/neovim/contributors","subscribers_url":"https://api.github.com/repos/oni-link/neovim/subscribers","subscription_url":"https://api.github.com/repos/oni-link/neovim/subscription","commits_url":"https://api.github.com/repos/oni-link/neovim/commits{/sha}","git_commits_url":"https://api.github.com/repos/oni-link/neovim/git/commits{/sha}","comments_url":"https://api.github.com/repos/oni-link/neovim/comments{/number}","issue_comment_url":"https://api.github.com/repos/oni-link/neovim/issues/comments{/number}","contents_url":"https://api.github.com/repos/oni-link/neovim/contents/{+path}","compare_url":"https://api.github.com/repos/oni-link/neovim/compare/{base}...{head}","merges_url":"https://api.github.com/repos/oni-link/neovim/merges","archive_url":"https://api.github.com/repos/oni-link/neovim/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/oni-link/neovim/downloads","issues_url":"https://api.github.com/repos/oni-link/neovim/issues{/number}","pulls_url":"https://api.github.com/repos/oni-link/neovim/pulls{/number}","milestones_url":"https://api.github.com/repos/oni-link/neovim/milestones{/number}","notifications_url":"https://api.github.com/repos/oni-link/neovim/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/oni-link/neovim/labels{/name}","releases_url":"https://api.github.com/repos/oni-link/neovim/releases{/id}","created_at":"2014-03-07T10:40:03Z","updated_at":"2015-03-23T08:54:34Z","pushed_at":"2015-04-09T20:47:52Z","git_url":"git://github.com/oni-link/neovim.git","ssh_url":"git@github.com:oni-link/neovim.git","clone_url":"https://github.com/oni-link/neovim.git","svn_url":"https://github.com/oni-link/neovim","homepage":"http://neovim.org/","size":29087,"stargazers_count":1,"watchers_count":1,"language":"VimL","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":1,"default_branch":"master"}},"base":{"label":"neovim:master","ref":"master","sha":"cb7bb70c4902a38165e3d1cb3158704dbac228c4","user":{"login":"neovim","id":6471485,"avatar_url":"https://avatars.githubusercontent.com/u/6471485?v=3","gravatar_id":"","url":"https://api.github.com/users/neovim","html_url":"https://github.com/neovim","followers_url":"https://api.github.com/users/neovim/followers","following_url":"https://api.github.com/users/neovim/following{/other_user}","gists_url":"https://api.github.com/users/neovim/gists{/gist_id}","starred_url":"https://api.github.com/users/neovim/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/neovim/subscriptions","organizations_url":"https://api.github.com/users/neovim/orgs","repos_url":"https://api.github.com/users/neovim/repos","events_url":"https://api.github.com/users/neovim/events{/privacy}","received_events_url":"https://api.github.com/users/neovim/received_events","type":"Organization","site_admin":false},"repo":{"id":16408992,"name":"neovim","full_name":"neovim/neovim","owner":{"login":"neovim","id":6471485,"avatar_url":"https://avatars.githubusercontent.com/u/6471485?v=3","gravatar_id":"","url":"https://api.github.com/users/neovim","html_url":"https://github.com/neovim","followers_url":"https://api.github.com/users/neovim/followers","following_url":"https://api.github.com/users/neovim/following{/other_user}","gists_url":"https://api.github.com/users/neovim/gists{/gist_id}","starred_url":"https://api.github.com/users/neovim/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/neovim/subscriptions","organizations_url":"https://api.github.com/users/neovim/orgs","repos_url":"https://api.github.com/users/neovim/repos","events_url":"https://api.github.com/users/neovim/events{/privacy}","received_events_url":"https://api.github.com/users/neovim/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/neovim/neovim","description":"vim out of the box","fork":false,"url":"https://api.github.com/repos/neovim/neovim","forks_url":"https://api.github.com/repos/neovim/neovim/forks","keys_url":"https://api.github.com/repos/neovim/neovim/keys{/key_id}","collaborators_url":"https://api.github.com/repos/neovim/neovim/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/neovim/neovim/teams","hooks_url":"https://api.github.com/repos/neovim/neovim/hooks","issue_events_url":"https://api.github.com/repos/neovim/neovim/issues/events{/number}","events_url":"https://api.github.com/repos/neovim/neovim/events","assignees_url":"https://api.github.com/repos/neovim/neovim/assignees{/user}","branches_url":"https://api.github.com/repos/neovim/neovim/branches{/branch}","tags_url":"https://api.github.com/repos/neovim/neovim/tags","blobs_url":"https://api.github.com/repos/neovim/neovim/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/neovim/neovim/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/neovim/neovim/git/refs{/sha}","trees_url":"https://api.github.com/repos/neovim/neovim/git/trees{/sha}","statuses_url":"https://api.github.com/repos/neovim/neovim/statuses/{sha}","languages_url":"https://api.github.com/repos/neovim/neovim/languages","stargazers_url":"https://api.github.com/repos/neovim/neovim/stargazers","contributors_url":"https://api.github.com/repos/neovim/neovim/contributors","subscribers_url":"https://api.github.com/repos/neovim/neovim/subscribers","subscription_url":"https://api.github.com/repos/neovim/neovim/subscription","commits_url":"https://api.github.com/repos/neovim/neovim/commits{/sha}","git_commits_url":"https://api.github.com/repos/neovim/neovim/git/commits{/sha}","comments_url":"https://api.github.com/repos/neovim/neovim/comments{/number}","issue_comment_url":"https://api.github.com/repos/neovim/neovim/issues/comments{/number}","contents_url":"https://api.github.com/repos/neovim/neovim/contents/{+path}","compare_url":"https://api.github.com/repos/neovim/neovim/compare/{base}...{head}","merges_url":"https://api.github.com/repos/neovim/neovim/merges","archive_url":"https://api.github.com/repos/neovim/neovim/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/neovim/neovim/downloads","issues_url":"https://api.github.com/repos/neovim/neovim/issues{/number}","pulls_url":"https://api.github.com/repos/neovim/neovim/pulls{/number}","milestones_url":"https://api.github.com/repos/neovim/neovim/milestones{/number}","notifications_url":"https://api.github.com/repos/neovim/neovim/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/neovim/neovim/labels{/name}","releases_url":"https://api.github.com/repos/neovim/neovim/releases{/id}","created_at":"2014-01-31T13:39:22Z","updated_at":"2015-04-10T23:04:02Z","pushed_at":"2015-04-10T23:40:23Z","git_url":"git://github.com/neovim/neovim.git","ssh_url":"git@github.com:neovim/neovim.git","clone_url":"https://github.com/neovim/neovim.git","svn_url":"https://github.com/neovim/neovim","homepage":"http://neovim.org","size":60015,"stargazers_count":12839,"watchers_count":12839,"language":"VimL","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":866,"mirror_url":null,"open_issues_count":439,"forks":866,"open_issues":439,"watchers":12839,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/neovim/neovim/pulls/2319"},"html":{"href":"https://github.com/neovim/neovim/pull/2319"},"issue":{"href":"https://api.github.com/repos/neovim/neovim/issues/2319"},"comments":{"href":"https://api.github.com/repos/neovim/neovim/issues/2319/comments"},"review_comments":{"href":"https://api.github.com/repos/neovim/neovim/pulls/2319/comments"},"review_comment":{"href":"https://api.github.com/repos/neovim/neovim/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/neovim/neovim/pulls/2319/commits"},"statuses":{"href":"https://api.github.com/repos/neovim/neovim/statuses/f349151e5f1a74303ca2913a0befdc0eb9b505b8"}}}}