zend-code icon indicating copy to clipboard operation
zend-code copied to clipboard

Results 31 zend-code issues
Sort by recently updated
recently updated
newest added

The `ParameterGenerator` always considers [`ReflectionParameter#isOptional()`](https://github.com/zendframework/zend-code/blob/3da502f243df7a189b9c1cfc70a96944ef111957/src/Generator/ParameterGenerator.php#L77) when checking for default parameter values. A variadic argument is, though, always optional and never has a default value.

bug
help wanted

Is it possible to generate property without default value? ``` php $x = new ClassGenerator; $x->setName('Classa'); $x->addProperty('test'); ``` Should output: ``` php class Classa { public $test; } ``` Maybe...

Requested here: https://github.com/zendframework/zend-code/issues/82#issuecomment-233306028 @Ocramius Used reflection since the method is protected.

bug
awaiting author updates

This is just an attempt to fix the type-hinting mess inside the library. This is a BC break, as inheritance may be broken if the child classes do not respect...

enhancement
WIP
BC Break

Provide a narrative description of what you are trying to accomplish: - [Y ] Is this related to quality assurance? Return type of `\Zend\Code\Generator\FileGenerator::getClass` only has `ClassGenerator` while it can...

Unless I'm missing something, there is no way to add a type-hinted parameter to a method that does not use the fully-qualified name (as it exists as a use statement)....

enhancement
question

Hi, I think that Classgenerator should support docblock for constants . Ex : ``` php

I scan with this class a directory for classes. But getClasses returns an empty array. When I test getFiles it works I get dozens files. I use php7.

bug
duplicate

I believe the issue is with `MethodScanner` and not `ParameterScanner`, as this is what is actually parsing the PHP tokens - it correctly ignores non-scalar type declarations such as `array`...

``` PHP Notice: Undefined offset: 585 in /var/www/.../current/vendor/zendframework/zend-code/src/Scanner/ClassScanner.php on line 939 Notice: Uninitialized string offset: 1 in /var/www/.../current/vendor/zendframework/zend-code/src/Scanner/ClassScanner.php on line 971 Notice: Uninitialized string offset: 1 in /var/www/.../current/vendor/zendframework/zend-code/src/Scanner/ClassScanner.php on line...