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

Shouldn't bulit-ins get completed? #67

Closed
cprn opened this issue Oct 4, 2016 · 4 comments
Closed

Shouldn't bulit-ins get completed? #67

cprn opened this issue Oct 4, 2016 · 4 comments
Labels

Comments

@cprn
Copy link

cprn commented Oct 4, 2016

Everything works okay in most cases, e.g.:

<?php
class Foo {}
$x = new F # Padawan suggests `Foo`

But shouldn't the built-in functions (like below) get completed as well?

<?php
func_g # Padawan doesn't return suggestions
func_get_args(); # same
imagecreatetruecolor(); # same
foreach(); # same

All I get is:

Padawan.php error: Could not define empty line context

Maybe there's something wrong with my installation process?

  1. Installed NVIM-0.1.6-dev and vundle,
  2. installed deoplete, deoplete-padawan and padawan,
  3. installed composer global require mkusher/padawan,
  4. installed PHP 5.6.11.1 via sudo apt-get install php,
  5. created file foo.php, opened it with nvim and started typing.

As far as I understand, the purpose of the set omnifunc provider is to provide language syntax completion? At least phpcomplete-extended was doing that... So what am I doing wrong?

[EDITED] If I install UltiSnips and a snippets pack I get templates suggestions, so it doesn't seem to be the problem with deoplete.

@mkusher
Copy link
Member

mkusher commented Oct 5, 2016

it looks more like problem with deoplete-padawan, it doesn't send prefix.
Cc @pbogut

@mkusher mkusher added the bug label Oct 5, 2016
@pbogut
Copy link
Member

pbogut commented Oct 5, 2016

@mkusher, your right, prefix is not sent by the deoplete-padawan. The column is always set at the beginning of the word. I wIll take a look at this later.

@cprn, which version of padawan you are using? As far as I can tell the error is displayed on stable 0.2.1 but this version doesn't support build in functions anyway.

If you want to use omnifunc with deoplete it will take async benefits away.

It will work as expected with padawan from the master branch when I fix the issue @mkusher has addressed.

@cprn
Copy link
Author

cprn commented Oct 5, 2016

which version of padawan you are using?

Whatever gets installed with vim-plug:

git log --pretty=oneline
d74aad4dcfe0ce9e5f89b79f23ad92fa6b86d0d5 Update README.md

It will work as expected with padawan from the master branch when I fix the issue @mkusher has addressed.

Sounds legit.

Do we close this issue and move to your github? (it says 0 open issues)

@mkusher
Copy link
Member

mkusher commented Oct 5, 2016

@cprn yeah, it's better to continue there https://github.com/pbogut/deoplete-padawan

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

No branches or pull requests

3 participants