Neverendingo (Talk | contribs) m (Text replace - "<code php>" to "<syntaxhighlight lang="php">") |
|||
(43 intermediate revisions by 4 users not shown) | |||
Line 8: | Line 8: | ||
! Status !! Category !! Description !! Contact | ! Status !! Category !! Description !! Contact | ||
{{FeatureDone|Parser|Parser written using kdevelop-pg-qt|niko.sams@gmail.com|Niko Sams}} | {{FeatureDone|Parser|Parser written using kdevelop-pg-qt|niko.sams@gmail.com|Niko Sams}} | ||
+ | {{FeatureTodo|Parser|PHP 5.3 support (configurable)|-}} | ||
{{FeatureInProgress|DUChain|DUChain generation|niko.sams@gmail.com|Niko Sams}} | {{FeatureInProgress|DUChain|DUChain generation|niko.sams@gmail.com|Niko Sams}} | ||
− | {{ | + | {{FeatureDone|DUChain|class declaration after class instantiation should work as in Php|niko.sams@gmail.com|Niko Sams}} |
− | {{ | + | {{FeatureDone|DUChain|static variables|niko.sams@gmail.com|Niko Sams}} |
+ | {{FeatureDone|DUChain|final / abstract classes|mail@milianw.de|Milian Wolff}} | ||
+ | {{FeatureDone|DUChain|final / abstract methods|mail@milianw.de|Milian Wolff}} | ||
+ | {{FeatureDone|DUChain|adapt isDestructor/isConstructor to handle __destruct / __construct|mail@milianw.de|Milian Wolff}} | ||
+ | {{FeatureDone|DUChain|add type for PHP resources|mail@milianw.de|Milian Wolff}} | ||
+ | {{FeatureDone|DUChain|global variables: global keyword, $GLOBALS, $_GET|niko.sams@gmail.com|Niko Sams}} | ||
+ | {{FeatureDone|DUChain|second parse pass when project opened - to find all types correctly|niko.sams@gmail.com|Niko Sams}} | ||
+ | {{FeatureInProgress|DUChain|try to improve performance of declaration- and usebuilder, esp. for large files|mail@milianw.de|Milian Wolff}} | ||
+ | {{FeatureTodo|DUChain|user configurable project dependencies on other projects/paths|-}} | ||
+ | {{FeatureTodo|DUChain|http://www.icosaedro.it/phplint/phpdoc.html|-}} | ||
+ | {{FeatureDone|DUChain|properly support magic constants: http://de3.php.net/language.constants.predefined | ||
+ | if possible show their value while hovering|mail@milianw.de|Milian Wolff}} | ||
+ | {{FeatureDone|DUChain|add variable definitions for key/value in foreach statements|mail@milianw.de|Milian Wolff}} | ||
+ | |||
{{FeatureInProgress|Code Completion||niko.sams@gmail.com|Niko Sams}} | {{FeatureInProgress|Code Completion||niko.sams@gmail.com|Niko Sams}} | ||
+ | {{FeatureDone|Code Completion|overloadable functions in class context|mail@milianw.de|Milian Wolff}} | ||
+ | {{FeatureDone|Code Completion|standard PHP keywords for current context (foreach, while, function, etc.)|mail@milianw.de|Milian Wolff}} | ||
+ | {{FeatureTodo|Code Completion|doxygen/phpdoc comment completion / skeleton generation|-}} | ||
+ | {{FeatureTodo|Code Completion|completion for default entries of $_SERVER array|-}} | ||
+ | {{FeatureDone|Code Completion|completion after require/include, similar to what cpp does after #include|mail@milianw.de|Milian Wolff}} | ||
+ | {{FeatureDone|Code Completion|only show visible methods (protected/private/public)|mail@milianw.de|Milian Wolff}} | ||
+ | {{FeatureDone|Code Completion|only show interfaces after "implements"|mail@milianw.de|Milian Wolff}} | ||
+ | {{FeatureDone|Code Completion|only show classes/interfaces after "extends"|mail@milianw.de|Milian Wolff}} | ||
+ | {{FeatureDone|Code Completion|only show Exceptions in "catch()" and after "throw"|mail@milianw.de|Milian Wolff}} | ||
+ | {{FeatureDone|Code Completion|filter abstract methods/classes|mail@milianw.de|Milian Wolff}} | ||
+ | {{FeatureTodo|Code Completion|mind type hinting for function argument completion|-}} | ||
+ | {{FeatureDone|Code Completion|skeletons for while/do/for/foreach/switch/class/interface statements|mail@milianw.de|Milian Wolff}} | ||
+ | {{FeatureTodo|Code Completion|filter functions and variables that won't ever be able to return arrays in foreach completion (i.e. no array, no functions that return arrays or objects, no objects)|-}} | ||
+ | {{FeatureTodo|Code Completion|group completion stuff by type, i.e. functions, classes, instances, keywords, etc.|-}} | ||
+ | {{FeatureTodo|Code Completion|Create a global Context (imports all files of a project) that is imported in every context. That way findDeclarations(...) works across all files and we can drop that PersistentSymbolTable and CodeModel stuff|-}} | ||
+ | {{FeatureTodo|Code Completion|create a phpdoc comment for functions / classes, see {{bug|95904}}|-}} | ||
+ | {{FeatureTodo|Code Completion|use PDTT tests http://wiki.eclipse.org/PDTT_-_PHP_5.3_Code_Assist_Tests|-}} | ||
+ | {{FeatureTodo|Code Completion|don't do autocompletion in strings, except for callback types|-}} | ||
+ | |||
{{FeatureInProgress|Problem reporting||niko.sams@gmail.com|Niko Sams}} | {{FeatureInProgress|Problem reporting||niko.sams@gmail.com|Niko Sams}} | ||
− | {{FeatureTodo|CodeGeneration|new Class|-}} | + | {{FeatureDone|Problem reporting|don't create problems for not found declarations - instead do it as Cpp does - so it is even configurable|niko.sams@gmail.com|Niko Sams}} |
+ | {{FeatureTodo|Problem reporting|give reasonable error messages|-}} | ||
+ | {{FeatureTodo|Problem reporting|validate declaration visibility|-}} | ||
+ | {{FeatureTodo|Problem reporting|configurable: report unreachable code (i.e. after return)|-}} | ||
+ | {{FeatureTodo|Problem reporting|configurable: variable assignment instead of bool check|-}} | ||
+ | {{FeatureTodo|Problem reporting|don't build declarations/types/uses/contexts for erroneous declarations|-}} | ||
+ | {{FeatureDone|Problem reporting|validate redeclarations, esp. classes, functions, methods etc.|mail@milianw.de|Milian Wolff}} | ||
+ | {{FeatureTodo|Problem reporting|respect "semantic error highlighting" option|-}} | ||
+ | {{FeatureDone|Problem reporting|support different severities|mail@milianw.de|Milian Wolff}} | ||
+ | |||
+ | {{FeatureDone|Internal Php functions|extract functions from php manual|niko.sams@gmail.com|Niko Sams}} | ||
+ | {{FeatureDone|Internal Php functions|add superglobal variables ($_GET, ...)|niko.sams@gmail.com|Niko Sams}} | ||
+ | {{FeatureTodo|Internal Php functions|configurable: ignore deprecated autoglobals like $argv, $HTTP_*_VARS|-}} | ||
+ | {{FeatureDone|Internal Php functions|add @since for functions only avaliable in Php 5.3|mail@milianw.de|Milian Wolff}} | ||
+ | |||
+ | {{FeatureTodo|CodeGeneration|new Class with support for extends/implements|-}} | ||
+ | {{FeatureTodo|CodeGeneration|file template with proper phpdoc/doxygen comment|-}} | ||
+ | {{FeatureTodo|CodeGeneration|Assistant popup for creating missing include files|-}} | ||
+ | |||
+ | {{FeatureInProgress|Semantic Highlighting||-}} | ||
+ | {{FeatureDone|Semantic Highlighting|make colors of member variables | ||
+ | and esp. of "$this" consistent|mail@milianw.de|Milian Wolff}} | ||
+ | {{FeatureTodo|Semantic Highlighting|highlight defines differently|-}} | ||
+ | {{FeatureTodo|Semantic Highlighting|highlight local variables in global context like local variable in func context|-}} | ||
+ | |||
+ | {{FeatureInProgress|Debugger|Full-Featured Debugger (XDebug)|niko.sams@gmail.com|Niko Sams}} | ||
+ | |||
+ | {{FeatureTodo|Unit Tests|refactor tests to reduce repeated code|-}} | ||
+ | {{FeatureTodo|Unit Tests|introduce tests for problem reporting|-}} | ||
+ | |||
+ | {{FeatureInProgress|Documentation|integrate PHP.net documentation into KDevelop |mail@milianw.de|Milian Wolff}} | ||
+ | {{FeatureDone|Documentation|remote php.net integrated|mail@milianw.de|Milian Wolff}} | ||
+ | {{FeatureInProgress|Documentation|integrate local copy of PHP.net documentation|mail@milianw.de|Milian Wolff}} | ||
+ | |||
+ | {{FeatureDone|Indenter|write an indenter script based on the C-style indenter which does not work for PHP due to <?php...?> tags | ||
+ | Note: cstyle.js works fine for PHP|mail@milianw.de|Milian Wolff}} | ||
+ | |||
+ | {{FeatureTodo|Assistant|take a look on where to integrate the assistant architecture|-}} | ||
+ | |||
+ | {{FeatureTodo|Formatter|Add a formatter plugin for the [http://pear.php.net/package/PHP_Beautifier/ PHP beautifier]|-}} | ||
|} | |} | ||
+ | |||
+ | Fix PHP-related Quanta bugs ([https://bugs.kde.org/buglist.cgi?query_format=advanced&short_desc_type=allwordssubstr&short_desc=php&product=kate&product=kdevelop&product=kdevplatform&product=quanta&long_desc_type=substring&long_desc=&bug_file_loc_type=allwordssubstr&bug_file_loc=&keywords_type=allwords&keywords=&bug_status=UNCONFIRMED&bug_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED&emailassigned_to1=1&emailtype1=substring&email1=&emailassigned_to2=1&emailreporter2=1&emailcc2=1&emailtype2=substring&email2=&bugidtype=include&bug_id=&votes=&chfieldfrom=&chfieldto=Now&chfieldvalue=&cmdtype=doit&order=Reuse+same+sort+as+last+time&field0-0-0=noop&type0-0-0=noop&value0-0-0= list of bugs containing "PHP" keyword in products: kate, kdevelop, kdevplatform, quanta]) | ||
+ | |||
+ | == Kate PHP Highlighting == | ||
+ | |||
+ | There are some bugs in the general PHP highlighting for Kate and other KTextEditor components. Note: Make sure to fix it in all files which use PHP. | ||
+ | |||
+ | {| class="sortable" border="1" cellpadding="5" cellspacing="0" style="border: gray solid 1px; border-collapse: collapse; text-align: left; width: 100%;" | ||
+ | |- style="background: #ececec; white-space:nowrap;" | ||
+ | ! Status !! Category !! Description !! Contact | ||
+ | {{FeatureDone| keywords | fix <?PHP ,i.e. capital PHP |mail@milianw.de|Milian Wolff}} | ||
+ | {{FeatureDone| constants | add missing magic constants, see http://de3.php.net/language.constants.predefined |mail@milianw.de|Milian Wolff}} | ||
+ | |} | ||
+ | |||
+ | == Cleanup == | ||
+ | |||
+ | Various stuff we should investigate and probably cleanup one day. Listed here so I don't forget them: | ||
+ | |||
+ | * make sure all iterators are const where possible | ||
+ | * be krazy | ||
+ | |||
+ | == Known Limitations == | ||
+ | |||
+ | '''return-type in recursive functions''' | ||
+ | |||
+ | In the following snippet, the variable $foo will have the wrong type mixed, instead of stdClass: | ||
+ | |||
+ | <syntaxhighlight lang="php"> | ||
+ | function bar() { | ||
+ | $bar = bar(); | ||
+ | return new stdClass; | ||
+ | } | ||
+ | </syntaxhighlight> | ||
+ | |||
+ | You can workaround that, by adding a ''@param stdClass'' to the doccomment of the function. |
This is a todo list for Quanta4
Status | Category | Description | Contact |
---|---|---|---|
DONE | Parser | Parser written using kdevelop-pg-qt | Niko Sams <niko.sams@gmail.com> |
TO DO | Parser | PHP 5.3 support (configurable) | <-> |
IN PROGRESS | DUChain | DUChain generation | Niko Sams <niko.sams@gmail.com> |
DONE | DUChain | class declaration after class instantiation should work as in Php | Niko Sams <niko.sams@gmail.com> |
DONE | DUChain | static variables | Niko Sams <niko.sams@gmail.com> |
DONE | DUChain | final / abstract classes | Milian Wolff <mail@milianw.de> |
DONE | DUChain | final / abstract methods | Milian Wolff <mail@milianw.de> |
DONE | DUChain | adapt isDestructor/isConstructor to handle __destruct / __construct | Milian Wolff <mail@milianw.de> |
DONE | DUChain | add type for PHP resources | Milian Wolff <mail@milianw.de> |
DONE | DUChain | global variables: global keyword, $GLOBALS, $_GET | Niko Sams <niko.sams@gmail.com> |
DONE | DUChain | second parse pass when project opened - to find all types correctly | Niko Sams <niko.sams@gmail.com> |
IN PROGRESS | DUChain | try to improve performance of declaration- and usebuilder, esp. for large files | Milian Wolff <mail@milianw.de> |
TO DO | DUChain | user configurable project dependencies on other projects/paths | <-> |
TO DO | DUChain | http://www.icosaedro.it/phplint/phpdoc.html | <-> |
DONE | DUChain | properly support magic constants: http://de3.php.net/language.constants.predefined
if possible show their value while hovering |
Milian Wolff <mail@milianw.de> |
DONE | DUChain | add variable definitions for key/value in foreach statements | Milian Wolff <mail@milianw.de>
|
IN PROGRESS | Code Completion | Niko Sams <niko.sams@gmail.com> | |
DONE | Code Completion | overloadable functions in class context | Milian Wolff <mail@milianw.de> |
DONE | Code Completion | standard PHP keywords for current context (foreach, while, function, etc.) | Milian Wolff <mail@milianw.de> |
TO DO | Code Completion | doxygen/phpdoc comment completion / skeleton generation | <-> |
TO DO | Code Completion | completion for default entries of $_SERVER array | <-> |
DONE | Code Completion | completion after require/include, similar to what cpp does after #include | Milian Wolff <mail@milianw.de> |
DONE | Code Completion | only show visible methods (protected/private/public) | Milian Wolff <mail@milianw.de> |
DONE | Code Completion | only show interfaces after "implements" | Milian Wolff <mail@milianw.de> |
DONE | Code Completion | only show classes/interfaces after "extends" | Milian Wolff <mail@milianw.de> |
DONE | Code Completion | only show Exceptions in "catch()" and after "throw" | Milian Wolff <mail@milianw.de> |
DONE | Code Completion | filter abstract methods/classes | Milian Wolff <mail@milianw.de> |
TO DO | Code Completion | mind type hinting for function argument completion | <-> |
DONE | Code Completion | skeletons for while/do/for/foreach/switch/class/interface statements | Milian Wolff <mail@milianw.de> |
TO DO | Code Completion | filter functions and variables that won't ever be able to return arrays in foreach completion (i.e. no array, no functions that return arrays or objects, no objects) | <-> |
TO DO | Code Completion | group completion stuff by type, i.e. functions, classes, instances, keywords, etc. | <-> |
TO DO | Code Completion | Create a global Context (imports all files of a project) that is imported in every context. That way findDeclarations(...) works across all files and we can drop that PersistentSymbolTable and CodeModel stuff | <-> |
TO DO | Code Completion | create a phpdoc comment for functions / classes, see bug #95904 | <-> |
TO DO | Code Completion | use PDTT tests http://wiki.eclipse.org/PDTT_-_PHP_5.3_Code_Assist_Tests | <-> |
TO DO | Code Completion | don't do autocompletion in strings, except for callback types | <->
|
IN PROGRESS | Problem reporting | Niko Sams <niko.sams@gmail.com> | |
DONE | Problem reporting | don't create problems for not found declarations - instead do it as Cpp does - so it is even configurable | Niko Sams <niko.sams@gmail.com> |
TO DO | Problem reporting | give reasonable error messages | <-> |
TO DO | Problem reporting | validate declaration visibility | <-> |
TO DO | Problem reporting | configurable: report unreachable code (i.e. after return) | <-> |
TO DO | Problem reporting | configurable: variable assignment instead of bool check | <-> |
TO DO | Problem reporting | don't build declarations/types/uses/contexts for erroneous declarations | <-> |
DONE | Problem reporting | validate redeclarations, esp. classes, functions, methods etc. | Milian Wolff <mail@milianw.de> |
TO DO | Problem reporting | respect "semantic error highlighting" option | <-> |
DONE | Problem reporting | support different severities | Milian Wolff <mail@milianw.de>
|
DONE | Internal Php functions | extract functions from php manual | Niko Sams <niko.sams@gmail.com> |
DONE | Internal Php functions | add superglobal variables ($_GET, ...) | Niko Sams <niko.sams@gmail.com> |
TO DO | Internal Php functions | configurable: ignore deprecated autoglobals like $argv, $HTTP_*_VARS | <-> |
DONE | Internal Php functions | add @since for functions only avaliable in Php 5.3 | Milian Wolff <mail@milianw.de>
|
TO DO | CodeGeneration | new Class with support for extends/implements | <-> |
TO DO | CodeGeneration | file template with proper phpdoc/doxygen comment | <-> |
TO DO | CodeGeneration | Assistant popup for creating missing include files | <->
|
IN PROGRESS | Semantic Highlighting | <-> | |
DONE | Semantic Highlighting | make colors of member variables
and esp. of "$this" consistent |
Milian Wolff <mail@milianw.de> |
TO DO | Semantic Highlighting | highlight defines differently | <-> |
TO DO | Semantic Highlighting | highlight local variables in global context like local variable in func context | <->
|
IN PROGRESS | Debugger | Full-Featured Debugger (XDebug) | Niko Sams <niko.sams@gmail.com>
|
TO DO | Unit Tests | refactor tests to reduce repeated code | <-> |
TO DO | Unit Tests | introduce tests for problem reporting | <->
|
IN PROGRESS | Documentation | integrate PHP.net documentation into KDevelop | Milian Wolff <mail@milianw.de> |
DONE | Documentation | remote php.net integrated | Milian Wolff <mail@milianw.de> |
IN PROGRESS | Documentation | integrate local copy of PHP.net documentation | Milian Wolff <mail@milianw.de>
|
DONE | Indenter | write an indenter script based on the C-style indenter which does not work for PHP due to <?php...?> tags
Note: cstyle.js works fine for PHP |
Milian Wolff <mail@milianw.de>
|
TO DO | Assistant | take a look on where to integrate the assistant architecture | <->
|
TO DO | Formatter | Add a formatter plugin for the PHP beautifier | <-> |
Fix PHP-related Quanta bugs (list of bugs containing "PHP" keyword in products: kate, kdevelop, kdevplatform, quanta)
There are some bugs in the general PHP highlighting for Kate and other KTextEditor components. Note: Make sure to fix it in all files which use PHP.
Status | Category | Description | Contact |
---|---|---|---|
DONE | keywords | fix <?PHP ,i.e. capital PHP | Milian Wolff <mail@milianw.de> |
DONE | constants | add missing magic constants, see http://de3.php.net/language.constants.predefined | Milian Wolff <mail@milianw.de> |
Various stuff we should investigate and probably cleanup one day. Listed here so I don't forget them:
return-type in recursive functions
In the following snippet, the variable $foo will have the wrong type mixed, instead of stdClass:
function bar() {
$bar = bar();
return new stdClass;
}
You can workaround that, by adding a @param stdClass to the doccomment of the function.