[vim/vim] Add v:exiting variable to get the Vim exit code (#7395)

17 views
Skip to first unread message

Yegappan Lakshmanan

unread,
Nov 29, 2020, 1:36:58 PM11/29/20
to vim/vim, Subscribed

Port the support for v:exiting variable from Neovim:

neovim/neovim#5651
neovim/neovim@d2e8c76


You can view, comment on, or merge this pull request online at:

  https://github.com/vim/vim/pull/7395

Commit Summary

  • Add v:exiting variable to get the Vim exit code

File Changes

Patch Links:


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.

codecov[bot]

unread,
Nov 29, 2020, 2:33:16 PM11/29/20
to vim/vim, Subscribed

Codecov Report

No coverage uploaded for pull request base (master@23515b4). Click here to learn what that means.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff            @@

##             master    #7395   +/-   ##

=========================================

  Coverage          ?   88.88%           

=========================================

  Files             ?      148           

  Lines             ?   163113           

  Branches          ?        0           

=========================================

  Hits              ?   144984           

  Misses            ?    18129           

  Partials          ?        0           
Impacted Files Coverage Δ
src/evalvars.c 95.80% <100.00%> (ø)
src/main.c 87.32% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 23515b4...e986ff0. Read the comment docs.

Bram Moolenaar

unread,
Nov 29, 2020, 2:57:08 PM11/29/20
to vim/vim, Subscribed

Shouldn't the entry in vimvars[] use VAR_SPECIAL? the value is v:null until it's set to a number.

Yegappan Lakshmanan

unread,
Nov 29, 2020, 4:34:59 PM11/29/20
to vim/vim, Push

@yegappan pushed 1 commit.

  • 95d3412 Convert type of v:exiting variable to VAR_SPECIAL


You are receiving this because you are subscribed to this thread.

View it on GitHub or unsubscribe.

Yegappan Lakshmanan

unread,
Nov 29, 2020, 4:36:12 PM11/29/20
to vim_dev, reply+ACY5DGBBILALGSZ3Y6...@reply.github.com, vim/vim, Subscribed
On Sun, Nov 29, 2020 at 11:57 AM Bram Moolenaar <vim-dev...@256bit.org> wrote:

Shouldn't the entry in vimvars[] use VAR_SPECIAL? the value is v:null until it's set to a number.



I have updated the PR to use VAR_SPECIAL type for v:exiting.

Does anyone think we should rename this variable to v:exitval? This will not be
compatible with Neovim though.

Regards,
Yegappan
 

vim-dev ML

unread,
Nov 29, 2020, 4:36:30 PM11/29/20
to vim/vim, vim-dev ML, Your activity

Yegappan Lakshmanan

unread,
Nov 29, 2020, 9:36:16 PM11/29/20
to vim/vim, vim-dev ML, Push

@yegappan pushed 1 commit.


You are receiving this because you are subscribed to this thread.

Christian Brabandt

unread,
Nov 30, 2020, 3:44:55 AM11/30/20
to vim_dev

On So, 29 Nov 2020, Yegappan Lakshmanan wrote:

> Does anyone think we should rename this variable to v:exitval? This
> will not be compatible with Neovim though.

While I think v:exitval describes it better, I don't think we should
change this and be incompatible with Neovim.

Best,
Christian
--
Lieber arm dran als Arm ab.

James McCoy

unread,
Nov 30, 2020, 7:53:45 AM11/30/20
to vim/vim, vim-dev ML, Comment

Does anyone think we should rename this variable to v:exitval?

The initial naming was suggested to mirror v:dying. There were some better names, including exitval, suggested while working on the changes, but unfortunately v:exiting is what was eventually committed.

This will not be compatible with Neovim though.

It'd be nice to avoid gratuitous incompatibilities between the two.


You are receiving this because you commented.

Bram Moolenaar

unread,
Nov 30, 2020, 11:42:55 AM11/30/20
to vim/vim, vim-dev ML, Comment

Closed #7395 via f0068c5.


You are receiving this because you commented.

Reply all
Reply to author
Forward
0 new messages