feat(week-03): complete dev, quiz assignment#39
Open
kignoh wants to merge 3 commits intoBay-17th:mainfrom
Open
feat(week-03): complete dev, quiz assignment#39kignoh wants to merge 3 commits intoBay-17th:mainfrom
kignoh wants to merge 3 commits intoBay-17th:mainfrom
Conversation
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.
과제 제출 정보
주차: Week 03
과제 유형:
구현 내용
배운 점 (What I Learned)
이번 주에 배운 것 (2-3가지)
어려웠던 점과 해결 방법
어려웠던 점:
재진입 가드 방식 선택 (revert vs return)
해결 방법:
처음에는 if (_withdrawing) revert()를 사용했으나, 이 경우 공격자의 receive() 내부에서 revert가 발생하고, 그 revert가 원래 call()까지 전파되어 success = false → require(success, "Transfer failed") revert로 이어지는 문제가 있었습니다. if (_withdrawing) return으로 바꿔 receive()가 정상 반환하도록 처리하여 해결했습니다.
질문 사항
체크리스트
테스트
forge build성공forge test모든 테스트 통과제출 규칙
{username}/week-{XX}형식.env파일이 커밋에 포함되지 않음