Merged
Conversation
DanielYY95
reviewed
Jan 24, 2025
5장_제네릭/아이템_27/비검사_경고를_제거하라.md
Outdated
Contributor
There was a problem hiding this comment.
@SuppressWarnings를 사용할 때, 경고를 무시해도 되는 이유를 주석으로 남겨야 한다고 했는데, 구체적인 예시가 있을까요?
yerim123456
reviewed
Jan 25, 2025
5장_제네릭/아이템_27/비검사_경고를_제거하라.md
Outdated
Contributor
There was a problem hiding this comment.
해당 타입이 안전하다는 확신을 얻기 위해 어떤 검증들을 해보는 게 좋은지 궁금합니다!
yunjeooong
reviewed
Jan 25, 2025
5장_제네릭/아이템_27/비검사_경고를_제거하라.md
Outdated
Contributor
There was a problem hiding this comment.
저는 개인적으로 경고를 무시해서 "안전한" 경우는 거의 없다고 생각합니다. 그래서 @SuppressWarnings 를 지양하는 편인데요!
혹시 경고를 무시하는게 좀 더 나은 경우가 있나요??
LeeHusung
reviewed
Jan 25, 2025
5장_제네릭/아이템_27/비검사_경고를_제거하라.md
Outdated
Contributor
There was a problem hiding this comment.
만약 List<Object>를 그대로 사용하고 싶고,
list.add(1);
int intValue = (int) list.get(1);이런 코드를 추가하고 싶다면
@SuppressWarnings("unchecked") 를 메서드 레벨로 빼야 할까요? 아니면 int intValue = (int) list.get(1); 이 위에 달아야할까요? 의견이 궁금합니다 :)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.