Skip to main content
Module

x/ddc_vim/deps.ts>op.define

Dark deno-powered completion framework for neovim/Vim8
Go to Latest
variable op.define
import { op } from "https://deno.land/x/ddc_vim@v2.3.0/deps.ts";
const { define } = op;

Pattern to be used to find a macro definition. It is a search pattern, just like for the "/" command. This option is used for the commands like "[i" and "[d" |include-search|. The 'isident' option is used to recognize the defined name after the match: {match with 'define'}{non-ID chars}{defined name}{non-ID char} See |option-backslash| about inserting backslashes to include a space or backslash. The default value is for C programs. For C++ this value would be useful, to include const type declarations: > ^(#\s\s[a-z]) < You can also use "\ze" just before the name and continue the pattern to check what is following. E.g. for Javascript, if a function is defined with "func_name = function(args)": > ^\s=\sfunction( < If the function is defined with "func_name : function() {...": > \s[:]\sfunction\s*( < When using the ":set" command, you need to double the backslashes! To avoid that use :let with a single quote string: > let &l:define = '\s=\s*function(' <