Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: too many arguments for function strcharpart #171

Closed
delatorrejuanchi opened this issue Jul 12, 2023 · 3 comments
Closed

Bug: too many arguments for function strcharpart #171

delatorrejuanchi opened this issue Jul 12, 2023 · 3 comments

Comments

@delatorrejuanchi
Copy link

It seems 66f055a may have introduced a bug.

Description

Trying to initiate a search fails with the following error:

E5108: Error executing lua: Vim:E118: Too many arguments for function: strcharpart
stack traceback:
        [C]: in function 'strcharpart'
        .../.local/share/nvim/lazy/leap.nvim/lua/leap/highlight.lua:66: in function 'highlight-cursor'
        .../.local/share/nvim/lazy/leap.nvim/lua/leap/main.lua:730: in function 'get_first_pattern_input'
        .../.local/share/nvim/lazy/leap.nvim/lua/leap/main.lua:987: in function 'leap'
        .../.local/share/nvim/lazy/leap.nvim/plugin/init.lua:25: in function <.../.local/share/nvim/lazy/leap.nvim/plugin/init.lua:24>

Config

Using a base NvChad setup with the following configuration

local plugins = {
  ...

  {
    "ggandor/leap.nvim",
    lazy = false,
    config = function()
      require("leap").add_default_mappings()
    end,
  },
}
@kinyoubi1009
Copy link

Experiencing the same issue with LazyVim.

vim.fn.strcharpart

only takes 3 arguments but in highlight.lua and search.lua, 4 arguments are used:

strcharpart(line_str, start, 1, 1)

@jam1015
Copy link

jam1015 commented Jul 13, 2023

confirmed. temproarily fixed by rolling back to the previous commits for leap and flit.

	{
		"ggandor/flit.nvim",
		commit = "5c9a78b97f7f4301473ea5e37501b5b1d4da167b",
	},
	{
		"ggandor/leap.nvim",
		commit ="8facf2eb6a378fd7691dce8c8a7b2726823e2408",
	},

@ggandor
Copy link
Owner

ggandor commented Jul 13, 2023

Oops, this is a recent addition: neovim/neovim@3724e65.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants