Feat/swift errorHandling - #321
Merged
Merged
Conversation
nank1ro
force-pushed
the
feat/swift-errorHandling
branch
from
September 17, 2026 05:42
05d99dd to
637b044
Compare
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.
Summary
Adds a new Swift argument, errorHandling, with 16 exercises (order 29) across all 12 locales (en, it, de, es, fr, hi, it, ja, ko, pl, pt, ru, zh).
Exercise mix: 7 type-1 (Run Code), 4 type-2 (Fill Empty Spaces), 3 type-3 (Choose Answer), 2 type-4 (Sort Items).
Concepts, in order:
Errortype and handling a thrown error withdo/catch(1, type 2)throwsand throwing a custom error (2, type 1)do/catchcontrol flow (4, type 3)do/catch(6, type 4)guard ... else { throw }(7, type 1)try?and optional results (8, type 2)try?with??for a default value (9, type 1)try!is appropriate (10, type 3)deferfor cleanup on both normal return and throw (11, type 1)rethrows) with throwing closures (13, type 1)do/catch(15, type 4)Checks run
_theory.md, and all 12swift/data.jsonfiles declareerrorHandlingcurriculum.jsonand all_theory.mdfiles regeneratedKnown issues
None.