-
Notifications
You must be signed in to change notification settings - Fork 29
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
Fully qualified namespace not found #17
Comments
Hi @tonglil, Could you provide an example (tag file + the file where the class is declared) ? |
Yes, when it happens again I will provide the directory structure, the file, and the tag file. I might have to redact some things though but we shall see. If I do, I will say what. |
+1 been getting the same problem for quite a while. I will see if I can recreate the problem. |
I'm getting this issue in a new Laravel project. I've recorded a screencap to show what exactly is happening in my case. For demonstration purposes, I removed the tags file and regenerated it manually. To demonstrate that the plugin works on certain files, I added the namespace of the class directly in the file. Then I attempted to add the same namespace to a file within Here's the generated tags: https://gist.github.com/dstrunk/f56eb483a829fc95d1e2a90eb43465ec I'm using Universal ctags (ctags.io), version d9d7aa7 |
Same error message. I am running NVIM v0.4.3 on Ubuntu 18.04 and create my tags file using Universal Ctags which I have built rather than snap installed.
if search('^\s*\%(/\*.*\*/\s*\)\?\%(\%(abstract\|final\)\_s\+\)*\%(class\|interface\|trait\)\_s\+' . a:name . '\>') > 0
if search('^\%(<?\%(php\s\+\)\?\)\?\s*namespace\s\+', 'be') > 0
let start = col('.')
call search('\([[:blank:]]*[[:alnum:]\\_]\)*', 'ce')
let end = col('.')
let ns = strpart(getline(line('.')), start, end-start)
return ['class', ns . "\\" . a:name]
else
return ['class', a:name]
endif
elseif search('^\s*function\_s\+' . a:name . '\>') > 0
if search('^\%(<?\%(php\s\+\)\?\)\?\s*namespace\s\+', 'be') > 0
let start = col('.')
call search('\([[:blank:]]*[[:alnum:]\\_]\)*', 'ce')
let end = col('.')
let ns = strpart(getline(line('.')), start, end-start)
return ['function', ns . "\\" . a:name]
else
return a:name
endif
else
throw a:name . ": not found!"
endif do
|
Hi, The plugin works like this:
The error Could you provide a php file and a tag file where this can be reproduced ? |
Can't seem to insert some use statements for classes.
I have verified that they are indeed in the tags file.
The text was updated successfully, but these errors were encountered: