You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@netbeans.apache.org by "KacerCZ (via GitHub)" <gi...@apache.org> on 2023/02/19 14:23:26 UTC
[GitHub] [netbeans] KacerCZ opened a new pull request, #5534: Fixed detection of duplicate types
KacerCZ opened a new pull request, #5534:
URL: https://github.com/apache/netbeans/pull/5534
Goes through all types and does not return on first error.
Partial fix for #5072
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
[GitHub] [netbeans] KacerCZ commented on a diff in pull request #5534: Fixed detection of duplicate types
Posted by "KacerCZ (via GitHub)" <gi...@apache.org>.
KacerCZ commented on code in PR #5534:
URL: https://github.com/apache/netbeans/pull/5534#discussion_r1112261143
##########
php/php.editor/src/org/netbeans/modules/php/editor/verification/UnusableTypesHintError.java:
##########
@@ -430,18 +430,15 @@ private void checkDuplicateType(List<Expression> types) {
}
if (checkedTypes.contains(name)) {
createDuplicateTypeError(type, typeName);
- return;
} else if (checkedTypes.contains(Type.BOOL)) {
// bool|false bool|true
if (Type.FALSE.equals(name) || Type.TRUE.equals(name)) {
createDuplicateTypeError(type, typeName);
- return;
Review Comment:
I've added more test cases covering also combinations of boolean type error with duplicate class error.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
[GitHub] [netbeans] KacerCZ commented on pull request #5534: Fixed detection of duplicate types
Posted by "KacerCZ (via GitHub)" <gi...@apache.org>.
KacerCZ commented on PR #5534:
URL: https://github.com/apache/netbeans/pull/5534#issuecomment-1438716417
Thanks for the review.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
[GitHub] [netbeans] KacerCZ commented on a diff in pull request #5534: Fixed detection of duplicate types
Posted by "KacerCZ (via GitHub)" <gi...@apache.org>.
KacerCZ commented on code in PR #5534:
URL: https://github.com/apache/netbeans/pull/5534#discussion_r1112262521
##########
php/php.editor/src/org/netbeans/modules/php/editor/verification/UnusableTypesHintError.java:
##########
@@ -430,18 +430,15 @@ private void checkDuplicateType(List<Expression> types) {
}
if (checkedTypes.contains(name)) {
createDuplicateTypeError(type, typeName);
- return;
Review Comment:
Right, original code with early exit finishes faster.
If there is no error then all types will be checked anyway.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
[GitHub] [netbeans] junichi11 merged pull request #5534: Fixed detection of duplicate types
Posted by "junichi11 (via GitHub)" <gi...@apache.org>.
junichi11 merged PR #5534:
URL: https://github.com/apache/netbeans/pull/5534
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
[GitHub] [netbeans] junichi11 commented on a diff in pull request #5534: Fixed detection of duplicate types
Posted by "junichi11 (via GitHub)" <gi...@apache.org>.
junichi11 commented on code in PR #5534:
URL: https://github.com/apache/netbeans/pull/5534#discussion_r1111429941
##########
php/php.editor/src/org/netbeans/modules/php/editor/verification/UnusableTypesHintError.java:
##########
@@ -430,18 +430,15 @@ private void checkDuplicateType(List<Expression> types) {
}
if (checkedTypes.contains(name)) {
createDuplicateTypeError(type, typeName);
- return;
Review Comment:
I've added it for a little performance (because the next error is shown if the error is fixed) but I don't think this fix has a big problem. So, it's OK.
##########
php/php.editor/src/org/netbeans/modules/php/editor/verification/UnusableTypesHintError.java:
##########
@@ -430,18 +430,15 @@ private void checkDuplicateType(List<Expression> types) {
}
if (checkedTypes.contains(name)) {
createDuplicateTypeError(type, typeName);
- return;
} else if (checkedTypes.contains(Type.BOOL)) {
// bool|false bool|true
if (Type.FALSE.equals(name) || Type.TRUE.equals(name)) {
createDuplicateTypeError(type, typeName);
- return;
Review Comment:
Unit tests?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists