Sorry if this has already been reported, but there are so many AC issues that it's hard to know if this is a duplicate.
This is using the PHP mode
This works
This doesn't
It should be showing foreach
and endforeach
, but instead it's finding letters throughout the possible options.
I am still finding my way around ACE so I haven't looked at the regex involved, but maybe someone else has an idea if this has already been discussed.
Thanks!
Looks like this is being worked on in this PR: https://github.com/ajaxorg/ace/pull/2996
This issue should be fixed by #3730.
@nightwing - just testing this now with v1.4.0 and unfortunately it doesn't seem any better with my OP example:
It's still not matching foreach
correctly.
OT, but I also think it would be nice if the matching popup was wider so that you could read all of php function
Thanks again and please let me know if I can help test this further somehow.
@adrianbj do you disable the snippet completer?
looks like aside from the sorting issue, there is also an issue with foreach not being present in the list of functions.
I am setting:
enableBasicAutocompletion: true,
enableLiveAutocompletion: true,
but not specifically setting enableSnippets: true
I didn't think that setting was relevant in this case.
Maybe the only outstanding issue here is a missing foreach
?
Thanks for adding foreach
, but it's still missing endforeach
.
Actually I am just noticing that if
, else
, elseif
, endif
and I am sure many others are also missing. I am not sure what your end goal is in terms of supporting all functions and language constructs in all supported languages. Do you have certain people maintaining certain languages?
BTW - I am not too worried about this - just wanted to get your thoughts on the importance of completeness.
php completer was contributed by @adamjimenez, and i am not sure why are all the keywords missing, perhaps completer should use the list of keywords from the mode too.
I think with the next release we need to split completers and linters into separate packages to help community create better tooling for different languages, without having to go through one central place.
Just a quick note. There is a typo: arrsort
instead of arsort
. There are two things to notice in this screencast - one is the arrsort
typo, but the other is that even though arrsort
exists in the list, as you type more characters to get closer to arrsort
, it actually removes the match leaving two results, neither of which are really that relevant at this point.
fixed this in #3745