Hugo Thunnissen
8a96383407
Implement resolving variable types through inline @var annotations
1 month ago
Hugo Thunnissen
99e628847c
Wrap buffer edit logic in `save-excursion'
1 month ago
Hugo Thunnissen
e0f494feb4
s/class/namespace/
1 month ago
Hugo Thunnissen
93f5cb1f45
Remove unused lexical variables and fix invalid inline-function
1 month ago
Hugo Thunnissen
8734c9418d
Test + improve `phpinspect-fix-imports' (and parse enums as classes)
...
- `phpinspect-fix-imports' now sorts the imports alphabetically
- `phpinspect-fix-imports' removes excess trailing newlines
- "enum" keywords are now regarded like "class" keywords. (enum cases not yet
supported)
- Namespaces were added to token index
1 month ago
Hugo Thunnissen
be2f8dada5
Add test for phpinspect-fix-imports
1 month ago
Hugo Thunnissen
5032ae74ff
Resolve types of expressions nested in list tokens
...
- Resolve "(new Foo())->bar"
- Resolve "if ($foo = new Bar()) { $foo->baz"
1 month ago
Hugo Thunnissen
14c63e4187
Improve method return-type test
1 month ago
Hugo Thunnissen
58ef5e3599
Refactor use of project root to project obj injection + test and fix some bugs
...
- Test/Fix indexation of method return types
- Get rid of some technical debt (use of project-root and global variables)
- Cleanup/refactor tests
1 month ago
Hugo Thunnissen
e04ab0c118
Resolve types of suggested variable completions
1 month ago
Hugo Thunnissen
ae681a0663
Fix bug that broke stub cache
...
Empty, non-indexed classes were created by
`phpinspect-project-enqueue-if-not-present', which caused them to override any
fully indexed stub classes that might be available.
1 month ago
Hugo Thunnissen
2052c289e1
Use `phpinspect--display-format-type-name' as standardized propertized string
...
- Move `propertize' calls into `phpinspect--display-format-type-name'
- Use for completion as well as eldoc hints
1 month ago
Hugo Thunnissen
4ec4c40c9d
Add eldoc for sigil variables and allow display of multiple eldoc results
...
By allowing multiple eldoc results, displaying variable information doesn't
interfere with function parameter hints.
1 month ago
Hugo Thunnissen
2e064d52e1
Implement containing type inference for collection-like class properties
1 month ago
Hugo Thunnissen
3a0ce3ac2d
Fix another infinite recursion bug
...
Bug occured in scenario's where array-members were self-referentially assigned
in a foreach loop.
like so:
foreach($things as $thing) {
$thing = $this->something;
}
1 month ago
Hugo Thunnissen
2d93ec7f79
Fix infinite recursion bug in `phpinspect--get-pattern-type-in-block'
1 month ago
Hugo Thunnissen
93b815d71a
Index used traits (juste use of type, no actual functionality outside of that)
1 month ago
Hugo Thunnissen
130e2c06c5
Index types used in arrays
1 month ago
Hugo Thunnissen
b6eadfb799
Make autoload indexation more robust and prevent double indexation
...
Prevent the project directory from being indexed multiple times (because of
directory-files-recursively also returning "." and "..".
1 month ago
Hugo Thunnissen
f1dc699560
Detect types used with "instanceoff"
1 month ago
Hugo Thunnissen
c20f010ee4
Introduce `phpinspect-buffer-fresh-p' and `phpinspect-buffer-reparse-if-not-fresh'
...
+ use in `phpinspect-fix-imports' instead of `phpinspect-buffer-reparse'
1 month ago
Hugo Thunnissen
31c6e06934
Reparse buffer when fixing import (+ add comment explaining why)
1 month ago
Hugo Thunnissen
d141f8a6db
Infer namespace token within import manipulation loop
1 month ago
Hugo Thunnissen
8296641ba9
Implement removal of unused imports in `phpinspect-fix-imports'
1 month ago
Hugo Thunnissen
6a175c9e44
Update a few doc strings in phpinspect-index.el
1 month ago
Hugo Thunnissen
f2f1ac9b84
Add property types and anonymous function argument types to used-types index
1 month ago
Hugo Thunnissen
d3f100388e
Resolve property types using other methods when resolving from constructor fails
...
Property types of classes in live buffers are now resolved from assignments in
other methods when resolving from the __construct method fails.
1 month ago
Hugo Thunnissen
3fff772d8a
Fix phpinspect-buffer-index-functions test
1 month ago
Hugo Thunnissen
2520c89680
Account for tokens after @method annotation when indexing
...
- Add :rest keyword to `phpinspect--match-sequence'
- Use :rest keyword in `phpinspect--index-method-annotations'
1 month ago
Hugo Thunnissen
5528aff2a2
Handle cases where the filepath of a type cannot be determined
1 month ago
Hugo Thunnissen
3887bc58d4
Implement indexation of readonly variables + allow invalid keywords
...
readonly variables no longer result in a failed indexation.
When we fail matching the scope keywords + variable patterns, only the variable
name is indexed instead of throwing an error.
1 month ago
Hugo Thunnissen
2fcb326747
Add log groups for completion and resolve
1 month ago
Hugo Thunnissen
e9ffa3a0ad
Fully reindex buffer after save
1 month ago
Hugo Thunnissen
9877166986
Fix reference to free variable
2 months ago
Hugo Thunnissen
9a317473b7
Synchronously index classes when fetching for eldoc hints
2 months ago
Hugo Thunnissen
f7f43332b2
Synchronously index classes when listing methods/properties for completion
2 months ago
Hugo Thunnissen
62bfc7830a
Fix namespace resolution bug in phpinspect-fix-imports
...
Incorrect use of phpinspect-namespace-name caused phpinspect-fix-imports to
incorrectly determine the current namespace. This resulted in imports being
suggested/added for types that already were available in the current
namespace. It did not make the PHP code invalid, but it did cause unnecessary
use statements for types in the same namespace.
This bug has now been fixed.
2 months ago
Hugo Thunnissen
3d68374fd0
Add some documentation for phpinspect-meta objects
2 months ago
Hugo Thunnissen
dfdef3e382
Implement support for PHP8.1 property typehints
2 months ago
Hugo Thunnissen
8569553981
Use inhibit-quit to prevent interruption of index updates
2 months ago
Hugo Thunnissen
2aac7a273e
Support @method annotations for static methods
2 months ago
Hugo Thunnissen
4d9907fedc
Strip partially typed attributes from resolvecontext when suggesting attributes
ci/woodpecker/push/woodpecker Pipeline failed
Details
6 months ago
Hugo Thunnissen
797efe9530
Only attempt to return completion kind when it can be found
...
When completions aren't found this is probably the result of a bug, but errors
in corfu's hooks are a pain for users so it is better to handle them gracefully
6 months ago
Hugo Thunnissen
18bc2e83ad
Convert names to alist for use as completing-read collection
...
ci/woodpecker/push/woodpecker Pipeline failed
Details
Fixes bug in `phpinspect-fix-imports'
6 months ago
Hugo Thunnissen
712268e4ec
Fix bug in autoloader that caused registration of only one FQN per type
ci/woodpecker/push/woodpecker Pipeline failed
Details
6 months ago
Hugo Thunnissen
42c7bd2715
Handle unsupported annotation styles gracefully
ci/woodpecker/push/woodpecker Pipeline failed
Details
6 months ago
Hugo Thunnissen
0509d8c669
Ignore nil-value completions
...
ci/woodpecker/push/woodpecker Pipeline failed
Details
There is probably a bug in an undedlying completion strategy that is causing
these nil-values. But this function should be able to deal with that regardless
as completion-strategies may not always be stable. Especially if user-defined
strategies ever become a thing.
6 months ago
Hugo Thunnissen
ea133c2044
Fix bug in `phpinspect-splayt-find-all-between' that impacted import indexation
ci/woodpecker/push/woodpecker Pipeline failed
Details
6 months ago
Hugo Thunnissen
e436b3fae0
Ignore non-existant directories in psr4 autoload config
ci/woodpecker/push/woodpecker Pipeline failed
Details
7 months ago
Hugo Thunnissen
7f2baf2c68
Make phpinspect--match-sequence return nil unless entire sequence matches
ci/woodpecker/push/woodpecker Pipeline failed
Details
1 year ago