Fix E002 E003
This commit is contained in:
parent
87ff42ab0f
commit
804b04fa9f
@ -6,17 +6,17 @@ let s:CHINEXE_PUNCTUATION = "\u3002\uff1f\uff01\uff0c\u3001\uff1b\uff1a\u201c\u2
|
||||
" 英文标点
|
||||
let s:punctuation = ','
|
||||
" 中文标点符号
|
||||
let s:punctuation_cn = "[\u3002\uff1b\uff0c\uff1a\u201c\u201d\uff08\uff09\u3001\uff1f\u300a\u300b]"
|
||||
let s:punctuation_cn = '[\u3002\uff1b\uff0c\uff1a\u201c\u201d\uff08\uff09\u3001\uff1f\u300a\u300b]'
|
||||
" 中文汉字
|
||||
let s:chars_cn = "[\u4e00-\u9fa5]"
|
||||
let s:chars_cn = '[\u4e00-\u9fa5]'
|
||||
" 数字
|
||||
let s:numbers = '[0-9]'
|
||||
" 英文字母
|
||||
let s:chars = '[a-zA-Z]'
|
||||
let s:ERRORS = {
|
||||
\ 'E001' : ['中文字符后存在英文标点', s:chars_cn . s:punctuation],
|
||||
\ 'E002' : ['中英文之间没有空格', '(' . s:chars_cn . s:chars . ')\|(' . s:chars . s:chars_cn . ')'],
|
||||
\ 'E003' : ['中文与数字之间没有空格', '(' . s:chars_cn . s:numbers . ')\|(' . s:numbers . s:chars_cn . ')'],
|
||||
\ 'E002' : ['中英文之间没有空格', '\(' . s:chars_cn . s:chars . '\)\|\(' . s:chars . s:chars_cn . '\)'],
|
||||
\ 'E003' : ['中文与数字之间没有空格', '\(' . s:chars_cn . s:numbers . '\)\|\(' . s:numbers . s:chars_cn . '\)'],
|
||||
\ 'E004' : ['中文标点之后存在空格', s:punctuation_cn . '\s\+'],
|
||||
\ }
|
||||
" TODO
|
||||
|
Loading…
x
Reference in New Issue
Block a user