|
Hello -,
PHP Tools for Visual Studio extension is getting exciting new features, improvements, and fixes! Welcome to our newsletter, and thank you for using our tools.
The January update of PHP Tools for Visual Studio introduces tons of improvements and fixes. We have fine-tuned the IntelliSense and started recognizing more PHPDoc type annotations used by various frameworks such as Symfony, Laravel, PHPStan, PHPCS, WordPress, and others. Additionally, there are new custom formatting options, improved performance, and memory efficiency.
IntelliPHP in Visual Studio 2019
It's been in Visual Studio 2022 for a while and now - we're adding our local AI suggestions to Visual Studio 2019 as well!

Refactorings
We're constantly adding new quick refactorings and improving existing ones. This update improves the following:
- Refactoring of
private properties
- Adding refactoring of property names specified inside
property_exists() function.
- Fixes generating implementation for abstract methods and interfaces.
- Added new quick refactorings for simplifying
?: conditional expressions.

Completion for $GLOBALS and $_SERVER
A must have code completion for arrays has been added to PHP Tools. Array keys for variables, and super-global variables are listed in code completion:

Custom Formatting & Code Styles
The options pages with formatting code styles has been updated, and vast array of new custom formatting options has been added. Additionally, the editor suggests removing of unnecessary ?> closing tag:

Other Improvements
- Doc Block with multiline
array<> syntax supported.
- Doc Block with
@psalm-type definition using = character supported.
- Doc Block with
@var defining a type of whole expression (not just a variable) is handled.
- Type analysis improved in case there are a lot of array types with key names.
- Type analysis handles complex L-value of
instanceof operator.
- Type analysis improved in case there are a lot of array types with key names.
- Improves handling global variables in WordPress source code.
- Code completion for array keys, type inferring for array entries, and array keys for
$_SERVER and $GLOBALS.
- Improved
array_unshift() type analysis.
- Improved detection and completion for eloquent local scopes.
- WordPress's structured array/object doc comment syntax is recognized and respected by code analysis and code completion.
- Workarounds diagnostics in incorrectly generated type names in
_ide_helper.php.
- Diagnostic for
${} deprecated string interpolation and corresponding code action.
- Improves resolution of methods returning
static/$this (#1820).
- Various code analysis improvements.
- Memory usage optimizations, and general performance improvements.
Fixes
- Stability fixes for Stack Overflow Exception (happens in Symfony framework) #437/46
- Updated PHP parser to handle keywords in PHP8+ FQN namespace syntax.
- Fixes falsy diagnostics of unreachable code.
- Not reporting unknown property if it was checked with
property_exists().
- Fixed inlay hints in ambiguous function calls (a function defined in two places or opened in two files).
- Crash fixes.
|
|