programming-swift
Provides the complete content of 'The Swift Programming Language (6.3)' book by Apple. Use this skill when you need to verify Swift syntax, look up language features, understand concurrency, resolve compiler errors, or consult the formal language reference.
What this skill does
# The Swift Programming Language The entire content of The Swift Programming Language (6.3) book by Apple. This is a comprehensive language reference and guide to the Swift programming language. ## Documentation Structure ### Getting Started (GuidedTour) - **About Swift** ([GuidedTour/AboutSwift.md](GuidedTour/AboutSwift.md)): Understand the high-level goals of the language. - **Version Compatibility** ([GuidedTour/Compatibility.md](GuidedTour/Compatibility.md)): Learn what functionality is available in older language modes. - **A Swift Tour** ([GuidedTour/GuidedTour.md](GuidedTour/GuidedTour.md)): Explore the features and syntax of Swift. ### Language Guide - **The Basics** ([LanguageGuide/TheBasics.md](LanguageGuide/TheBasics.md)): Work with common kinds of data and write basic syntax. - **Basic Operators** ([LanguageGuide/BasicOperators.md](LanguageGuide/BasicOperators.md)): Perform operations like assignment, arithmetic, and comparison. - **Strings and Characters** ([LanguageGuide/StringsAndCharacters.md](LanguageGuide/StringsAndCharacters.md)): Store and manipulate text. - **Collection Types** ([LanguageGuide/CollectionTypes.md](LanguageGuide/CollectionTypes.md)): Organize data using arrays, sets, and dictionaries. - **Control Flow** ([LanguageGuide/ControlFlow.md](LanguageGuide/ControlFlow.md)): Structure code with branches, loops, and early exits. - **Functions** ([LanguageGuide/Functions.md](LanguageGuide/Functions.md)): Define and call functions, label their arguments, and use their return values. - **Closures** ([LanguageGuide/Closures.md](LanguageGuide/Closures.md)): Group code that executes together, without creating a named function. - **Enumerations** ([LanguageGuide/Enumerations.md](LanguageGuide/Enumerations.md)): Model custom types that define a list of possible values. - **Structures and Classes** ([LanguageGuide/ClassesAndStructures.md](LanguageGuide/ClassesAndStructures.md)): Model custom types that encapsulate data. - **Properties** ([LanguageGuide/Properties.md](LanguageGuide/Properties.md)): Access stored and computed values that are part of an instance or type. - **Methods** ([LanguageGuide/Methods.md](LanguageGuide/Methods.md)): Define and call functions that are part of an instance or type. - **Subscripts** ([LanguageGuide/Subscripts.md](LanguageGuide/Subscripts.md)): Access the elements of a collection. - **Inheritance** ([LanguageGuide/Inheritance.md](LanguageGuide/Inheritance.md)): Subclass to add or override functionality. - **Initialization** ([LanguageGuide/Initialization.md](LanguageGuide/Initialization.md)): Set the initial values for a type's stored properties and perform one-time setup. - **Deinitialization** ([LanguageGuide/Deinitialization.md](LanguageGuide/Deinitialization.md)): Release resources that require custom cleanup. - **Optional Chaining** ([LanguageGuide/OptionalChaining.md](LanguageGuide/OptionalChaining.md)): Access members of an optional value without unwrapping. - **Error Handling** ([LanguageGuide/ErrorHandling.md](LanguageGuide/ErrorHandling.md)): Respond to and recover from errors. - **Concurrency** ([LanguageGuide/Concurrency.md](LanguageGuide/Concurrency.md)): Perform asynchronous operations. - **Macros** ([LanguageGuide/Macros.md](LanguageGuide/Macros.md)): Use macros to generate code at compile time. - **Type Casting** ([LanguageGuide/TypeCasting.md](LanguageGuide/TypeCasting.md)): Determine a value's runtime type and give it more specific type information. - **Nested Types** ([LanguageGuide/NestedTypes.md](LanguageGuide/NestedTypes.md)): Define types inside the scope of another type. - **Extensions** ([LanguageGuide/Extensions.md](LanguageGuide/Extensions.md)): Add functionality to an existing type. - **Protocols** ([LanguageGuide/Protocols.md](LanguageGuide/Protocols.md)): Define requirements that conforming types must implement. - **Generics** ([LanguageGuide/Generics.md](LanguageGuide/Generics.md)): Write code that works for multiple types and specify requirements for those types. - **Opaque and Boxed Protocol Types** ([LanguageGuide/OpaqueTypes.md](LanguageGuide/OpaqueTypes.md)): Hide implementation details about a value's type. - **Automatic Reference Counting** ([LanguageGuide/AutomaticReferenceCounting.md](LanguageGuide/AutomaticReferenceCounting.md)): Model the lifetime of objects and their relationships. - **Memory Safety** ([LanguageGuide/MemorySafety.md](LanguageGuide/MemorySafety.md)): Structure your code to avoid conflicts when accessing memory. - **Access Control** ([LanguageGuide/AccessControl.md](LanguageGuide/AccessControl.md)): Manage the visibility of code by declaration, file, and module. - **Advanced Operators** ([LanguageGuide/AdvancedOperators.md](LanguageGuide/AdvancedOperators.md)): Define custom operators, perform bitwise operations, and use builder syntax. ### Reference Manual - **About the Language Reference** ([ReferenceManual/AboutTheLanguageReference.md](ReferenceManual/AboutTheLanguageReference.md)): Read the notation that the formal grammar uses. - **Lexical Structure** ([ReferenceManual/LexicalStructure.md](ReferenceManual/LexicalStructure.md)): Use the lowest-level components of the syntax. - **Types** ([ReferenceManual/Types.md](ReferenceManual/Types.md)): Use built-in named and compound types. - **Expressions** ([ReferenceManual/Expressions.md](ReferenceManual/Expressions.md)): Access, modify, and assign values. - **Statements** ([ReferenceManual/Statements.md](ReferenceManual/Statements.md)): Group expressions and control the flow of execution. - **Declarations** ([ReferenceManual/Declarations.md](ReferenceManual/Declarations.md)): Introduce types, operators, variables, and other names and constructs. - **Attributes** ([ReferenceManual/Attributes.md](ReferenceManual/Attributes.md)): Add information to declarations and types. - **Patterns** ([ReferenceManual/Patterns.md](ReferenceManual/Patterns.md)): Match and destructure values. - **Generic Parameters and Arguments** ([ReferenceManual/GenericParametersAndArguments.md](ReferenceManual/GenericParametersAndArguments.md)): Generalize declarations to abstract away concrete types. ## Usage Notes - Organized progressively: GuidedTour → LanguageGuide → ReferenceManual ## License & Attribution This skill contains content from [The Swift Programming Language](https://github.com/swiftlang/swift-book.git), distributed under the **Apache 2.0 License**. Copyright © Apple Inc. and the Swift project authors. This package is a derivative work that aggregates the original markdown content into a structure optimized for LLM context.
Related in Writing & Docs
jax-development
IncludedUse this skill when the user is writing, debugging, profiling, refactoring, reviewing, benchmarking, parallelising, exporting, or explaining JAX code, or when they mention JAX, jax.numpy, jit, grad, value_and_grad, vmap, scan, lax, random keys, pytrees, jax.Array, sharding, Mesh, PartitionSpec, NamedSharding, pmap, shard_map, Pallas, XLA, StableHLO, checkify, profiler, or the JAX repo. It helps turn NumPy or PyTorch-style code into pure functional JAX, fix tracer/control-flow/shape/PRNG bugs, remove recompiles and host-device syncs, choose transforms and sharding strategies, inspect jaxpr/lowering/IR, and benchmark compiled code correctly.
nature-article-writer
IncludedDrafts, rewrites, diagnostically critiques, and style-calibrates primary research manuscripts for Nature and Nature Portfolio journals. Use when the user wants a Nature-style title, summary paragraph or abstract, introduction, results, discussion, methods, figure legends, presubmission enquiry, cover letter, reviewer response, or when a scientific draft sounds generic, jargon-heavy, structurally weak, or AI-ish and needs precise, broad-reader-friendly prose without inventing data, analyses, or references. Best for primary research articles and letters rather than reviews or press releases unless explicitly adapting one.
deckrd
IncludedDocument-driven framework that derives requirements, specifications, implementation plans, and executable tasks from goals through structured AI dialogue. Use when user says "write requirements", "create spec", "plan implementation", "derive tasks", "structure this feature", "break down into tasks", or "document this module". Also use for reverse engineering existing code into docs (/deckrd rev). Do NOT use for direct code writing — use /deckrd-coder after tasks are generated. Do NOT use when the user only wants to run or fix existing code without planning.
clinical-decision-support
IncludedGenerate professional clinical decision support (CDS) documents for pharmaceutical and clinical research settings, including patient cohort analyses (biomarker-stratified with outcomes) and treatment recommendation reports (evidence-based guidelines with decision algorithms). Supports GRADE evidence grading, statistical analysis (hazard ratios, survival curves, waterfall plots), biomarker integration, and regulatory compliance. Outputs publication-ready LaTeX/PDF format optimized for drug development, clinical research, and evidence synthesis.
handling-sf-data
IncludedSalesforce data operations with 130-point scoring. Use this skill to create, update, delete, bulk import/export, generate test data, and clean up org records using sf CLI and anonymous Apex. TRIGGER when: user creates test data, performs bulk import/export, uses sf data CLI commands, needs data factory patterns for Apex tests, or needs to seed/clean records in a Salesforce org. DO NOT TRIGGER when: SOQL query writing only (use querying-soql), Apex test execution (use running-apex-tests), or metadata deployment (use deploying-metadata).
accelint-ac-to-playwright
IncludedConvert and validate acceptance criteria for Playwright test automation. Use when user asks to (1) review/evaluate/check if AC are ready for automation, (2) assess if AC can be converted as-is, (3) validate AC quality for Playwright, (4) turn AC into tests, (5) generate tests from acceptance criteria, (6) convert .md bullets or .feature Gherkin files to Playwright specs, (7) create test automation from requirements. Handles both bullet-style markdown and Gherkin syntax with JSON test plan generation and validation.