comparison src/ex_docmd.c @ 21471:126dcb0411ed v8.2.1286

patch 8.2.1286: Vim9: No error when using a type to a window variable Commit: https://github.com/vim/vim/commit/43e969d3f98766824c18d20b84f2fab00feef683 Author: Bram Moolenaar <Bram@vim.org> Date: Thu Jul 23 21:14:43 2020 +0200 patch 8.2.1286: Vim9: No error when using a type to a window variable Problem: Vim9: No error when using a type to a window variable Solution: Recognize the syntax and give an error. (closes https://github.com/vim/vim/issues/6521)
author Bram Moolenaar <Bram@vim.org>
date Thu, 23 Jul 2020 21:15:05 +0200
parents 4dfd00f481fb
children eec2d2120cde
comparison
equal deleted inserted replaced
21470:f0304ef8ac7d 21471:126dcb0411ed
3322 { 3322 {
3323 eap->cmdidx = CMD_let; 3323 eap->cmdidx = CMD_let;
3324 return eap->cmd; 3324 return eap->cmd;
3325 } 3325 }
3326 } 3326 }
3327
3328 // Recognize using a type for a w:, b:, t: or g: variable:
3329 // "w:varname: number = 123".
3330 if (eap->cmd[1] == ':' && *p == ':')
3331 {
3332 eap->cmdidx = CMD_eval;
3333 return eap->cmd;
3334 }
3327 } 3335 }
3328 #endif 3336 #endif
3329 3337
3330 /* 3338 /*
3331 * Isolate the command and search for it in the command table. 3339 * Isolate the command and search for it in the command table.