Mercurial > vim
comparison src/eval.c @ 8763:4b83af41f5db v7.4.1670
commit https://github.com/vim/vim/commit/a32095fc8fdf5fe3d487c86d9cc54adb1236731e
Author: Bram Moolenaar <Bram@vim.org>
Date: Mon Mar 28 19:27:13 2016 +0200
patch 7.4.1670
Problem: Completion doesn't work well for a variable containing "#".
Solution: Recognize the "#". (Watiko)
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Mon, 28 Mar 2016 19:30:06 +0200 |
parents | 65a5a18d3acf |
children | 65be74c1467b |
comparison
equal
deleted
inserted
replaced
8762:bc5139e55a67 | 8763:4b83af41f5db |
---|---|
3397 else if (c == '=') | 3397 else if (c == '=') |
3398 { | 3398 { |
3399 got_eq = TRUE; | 3399 got_eq = TRUE; |
3400 xp->xp_context = EXPAND_EXPRESSION; | 3400 xp->xp_context = EXPAND_EXPRESSION; |
3401 } | 3401 } |
3402 else if (c == '#' | |
3403 && xp->xp_context == EXPAND_EXPRESSION) | |
3404 { | |
3405 /* Autoload function/variable contains '#'. */ | |
3406 break; | |
3407 } | |
3402 else if ((c == '<' || c == '#') | 3408 else if ((c == '<' || c == '#') |
3403 && xp->xp_context == EXPAND_FUNCTIONS | 3409 && xp->xp_context == EXPAND_FUNCTIONS |
3404 && vim_strchr(xp->xp_pattern, '(') == NULL) | 3410 && vim_strchr(xp->xp_pattern, '(') == NULL) |
3405 { | 3411 { |
3406 /* Function name can start with "<SNR>" and contain '#'. */ | 3412 /* Function name can start with "<SNR>" and contain '#'. */ |