Skip to content
This repository has been archived by the owner on Jul 6, 2024. It is now read-only.

bug: #182

Closed
3 tasks done
ivyl opened this issue Feb 7, 2024 · 0 comments
Closed
3 tasks done

bug: #182

ivyl opened this issue Feb 7, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@ivyl
Copy link

ivyl commented Feb 7, 2024

Did you check docs and existing issues?

  • I have read all the neodev.nvim docs
  • I have searched the existing issues of neodev.nvim
  • I have searched the existing issues of plugins related to this issue

Neovim version (nvim -v)

0.9.5

Operating system/version

Linux

Describe the bug

function vim.fn.bufname(buf) end
--- @param buf? buffer

buffer is an alias to integer but that function takes string (e.g. "%", "$")

Steps To Reproduce

  1. type vim.fn.bufnr("%") in your init.lua
  2. get:
param-type-mismatch: Cannot assign `string` to parameter `integer?`.
- `string` cannot match `integer?`
- Type `string` cannot match `nil`
- Type `string` cannot match `integer`

Expected Behavior

no lsp errors

Repro

No response

@ivyl ivyl added the bug Something isn't working label Feb 7, 2024
@folke folke closed this as completed Jul 6, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants