Skip to content

:CopyCode<cr>出错 #3

@g1050

Description

@g1050

1.测试文件

//vim.h
#ifndef vim_H
#define vim_H

class Vim{
public:
    inline int func(int a);
private:
    int a;
};
#endif

2..执行<leader> y报错

    inline int func(int a);                                                                                                                  
处理 function <SNR>91_copy_code[3]..cppmode#gen_fun#copy_function[7]..<SNR>137_get_class_name[2]..<SNR>137_parse_class_name 时发生错误:      
第    1 行:                                                                                                                                  
E684: List 索引超出范围: 2                                                                                                                   
E15: 无效的表达式: matchlist(a:text, '\(\<class\>\|\<struct\>\)\s\+\(\w\+\)')[2]

3.执行<leader> p复制结果如下

0::int func(int a)
{

}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions