Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

442 reflection named type #445

Merged
merged 26 commits into from
Aug 9, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
00d1189
build: upgrade dom requirement and loosen version range
g105b Jul 24, 2022
3fcbcb9
Merge branch 'master' of github.com:/PhpGt/DomTemplate
g105b Aug 14, 2022
2a79afb
Merge branch 'master' of github.com:/PhpGt/DomTemplate
g105b Aug 18, 2022
5d58fc4
docs: update examples
g105b Aug 18, 2022
e3957a8
Merge branch 'master' of github.com:/PhpGt/DomTemplate
g105b Aug 26, 2022
73d0b85
Merge branch 'master' of github.com:/PhpGt/DomTemplate
g105b Sep 21, 2022
3cbb825
Merge branch 'master' of github.com:/PhpGt/DomTemplate
g105b Oct 5, 2022
fadbba7
Merge branch 'master' of github.com:/PhpGt/DomTemplate
g105b Oct 8, 2022
5403158
Merge branch 'master' of github.com:/PhpGt/DomTemplate
g105b Oct 31, 2022
224999b
Merge branch 'master' of github.com:/PhpGt/DomTemplate
g105b Jan 10, 2023
3def753
Merge branch 'master' of github.com:/PhpGt/DomTemplate
g105b Jan 17, 2023
3dbda21
feature: trim whitespace when there are only template children
g105b Jan 17, 2023
a28c12c
Merge branch 'master' of github.com:/PhpGt/DomTemplate
g105b Jan 17, 2023
da35c48
Merge branch 'master' of github.com:/PhpGt/DomTemplate
g105b Jan 23, 2023
b2f8fa5
Merge branch 'master' of github.com:/PhpGt/DomTemplate
g105b Jan 26, 2023
2f51576
Merge branch 'master' of github.com:/PhpGt/DomTemplate
g105b Jan 30, 2023
9655705
Merge branch 'master' of github.com:/PhpGt/DomTemplate
g105b Jan 31, 2023
7745df0
maintenance: phpstorm analysis improvements
g105b Jan 31, 2023
5ab8d14
Merge branch 'master' of github.com:/PhpGt/DomTemplate
g105b Feb 15, 2023
14029b2
Merge branch 'master' of github.com:/PhpGt/DomTemplate
g105b Feb 15, 2023
fa5c45b
Merge branch 'master' of github.com:/PhpGt/DomTemplate
g105b Mar 2, 2023
45007a4
Merge branch 'master' of github.com:/PhpGt/DomTemplate
g105b Jul 19, 2023
b47f5b2
tweak: remove data-element attribute
g105b Jul 19, 2023
5f0bbdf
Merge branch 'master' of github.com:/PhpGt/DomTemplate
g105b Jul 20, 2023
28f4cee
Merge branch 'master' of github.com:/PhpGt/DomTemplate
g105b Jul 28, 2023
672f621
fix: type check for ReflectionNamedType
g105b Aug 9, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions src/BindableCache.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,9 @@ public function isBindable(object $object):bool {

/** @var ?ReflectionNamedType $refReturn */
$refReturn = $refMethod->getReturnType();
if(!$refReturn instanceof ReflectionNamedType) {
continue;
}
$refReturnName = $refReturn?->getName();

foreach($refAttributes as $refAttr) {
Expand Down
2 changes: 1 addition & 1 deletion src/TableBinder.php
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ public function detectTableDataStructureType(array $array):TableDataStructureTyp
*/
foreach($rowData as $cellIndex => $cellData) {
if($rowIndex > 0) {
if(isset($array[0]) && is_array($array[0]) && array_is_list($array[0]) && !array_is_list($rowData)) {
if(isset($array[0]) && array_is_list($array[0]) && !array_is_list($rowData)) {
if(!is_iterable($cellData)) {
throw new IncorrectTableDataFormat("Row $rowIndex has a string key ($cellIndex) but the value is not iterable.");
}
Expand Down