Page 1 of 535Free preview · 1–5

About this document

N2310 is a C language standard draft with change markings, dated November 6, 2018. It specifies the representation, syntax, constraints, and semantics of C programs, translation and execution environments, and standard library facilities, with the aim of promoting portability, reliability, maintainability, and efficient execution. The draft marks changes relative to ISO/IEC 9899:2018 and incorporates listed defect reports and proposals. It is intended for knowledgeable C programmers and implementors, not as a tutorial. The supplied excerpt includes the abstract, contents, foreword, introduction, and technical text through part of the floating constants section.

Free preview text

The first 5 pages, shown as text so search engines and readers can find this document.

Page 1

N2310 ::: diff :::::: marks — November 6, 2018 ISO/IEC 9899:2017:: 2x (E) INTERNATIONAL STANDARD ©ISO/IEC ISO/IEC 9899:yyyy Programming languages — C Abstract (This cover sheet to be replaced by ISO.) This document specifies the form and establishes the interpretation of programs expressed in the programming language C. Its purpose is to promote portability, reliability, maintainability, and efficient execution of C language programs on a variety of computing systems. Clauses are included that detail the C language itself and the contents of the C language execution library. Annexes summarize aspects of both of them, and enumerate factors that influence the portability of C programs. Although this document is intended to guide knowledgeable C language programmers as well as implementors of C language translation systems, the document itself is not designed to serve as a tutorial. Recipients of this draft are invited to submit, with their comments, notification of any relevant patent rights of which they are aware and to provide supporting documentation. Changes from the previous draft (ISO/IEC 9899:2018) are indicated by striking out text that has been deleted and:::::::::: underlining text that has been added. Pages that contain changes are marked with C2x CHANGES and are listed in the index under that key. The following documents have been applied to this draft: DR 476 volatile semantics for lvalues DR 488 c16rtomb() on wide characters encoded as multiple char16_t DR 494 Part 1: Alignment specifier expression evaluation DR 497 "white-space character" defined in two places DR 499 Anonymous structure in union behavior DR 500 Ambiguous specification for FLT_EVAL_METHOD N2186 Alternative to N2166 N2260 Clarifying the restrict Keyword v2 N2265 Harmonizing static_assert with C++ N2271 CR for pow divide-by-zero case Abstract i

Page 2

ISO/IEC 9899:2017 :: 2x (E) ::: diff :::::: marks — November 6, 2018 N2310 (no diff marks, here) ii Abstract

Page 3

N2310 ::: diff :::::: marks — November 6, 2018 ISO/IEC 9899:2017:: 2x (E) (no diff marks, here) Contents iii

Page 4

ISO/IEC 9899:2017 :: 2x (E) ::: diff :::::: marks — November 6, 2018 N2310 Contents Foreword xii Introduction xiii 1 Scope 1 2 Normative references 2 3 Terms, definitions, and symbols 3 4 Conformance 8 5 Environment 9 5.1 Conceptual models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9 5.1.1 Translation environment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9 5.1.2 Execution environments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10 5.2 Environmental considerations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 5.2.1 Character sets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 5.2.2 Character display semantics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 5.2.3 Signals and interrupts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 5.2.4 Environmental limits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 6 Language 28 6.1 Notation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 6.2 Concepts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 6.2.1 Scopes of identifiers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 6.2.2 Linkages of identifiers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29 6.2.3 Name spaces of identifiers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29 6.2.4 Storage durations of objects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30 6.2.5 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31 6.2.6 Representations of types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33 6.2.7 Compatible type and composite type . . . . . . . . . . . . . . . . . . . . . . . 35 6.2.8 Alignment of objects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36 6.3 Conversions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37 6.3.1 Arithmetic operands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37 6.3.2 Other operands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40 6.4 Lexical elements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 6.4.1 Keywords . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42 6.4.2 Identifiers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 iv Contents

Page 5

N2310 ::: diff :::::: marks — November 6, 2018 ISO/IEC 9899:2017:: 2x (E) 6.4.3 Universal character names . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44 6.4.4 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45 6.4.5 String literals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50 6.4.6 Punctuators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52 6.4.7 Header names . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53 6.4.8 Preprocessing numbers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53 6.4.9 Comments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54 6.5 Expressions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55 6.5.1 Primary expressions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56 6.5.2 Postfix operators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57 6.5.3 Unary operators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63 6.5.4 Cast operators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65 6.5.5 Multiplicative operators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66 6.5.6 Additive operators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66 6.5.7 Bitwise shift operators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68 6.5.8 Relational operators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68 6.5.9 Equality operators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69 6.5.10 Bitwise AND operator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 70 6.5.11 Bitwise exclusive OR operator . . . . . . . . . . . . . . . . . . . . . . . . . . . 70 6.5.12 Bitwise inclusive OR operator . . . . . . . . . . . . . . . . . . . . . . . . . . . 70 6.5.13 Logical AND operator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71 6.5.14 Logical OR operator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71 6.5.15 Conditional operator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71 6.5.16 Assignment operators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72 6.5.17 Comma operator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75 6.6 Constant expressions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 76 6.7 Declarations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 78 6.7.1 Storage-class specifiers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 79 6.7.2 Type specifiers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 79 6.7.3 Type qualifiers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 87 6.7.4 Function specifiers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 91 6.7.5 Alignment specifier . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 92 6.7.6 Declarators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 93 6.7.7 Type names . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99 6.7.8 Type definitions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99 6.7.9 Initialization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101 6.7.10 Static assertions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 106 6.8 Statements and blocks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 107 6.8.1 Labeled statements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 107 6.8.2 Compound statement . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 108 Contents v

Tags

Doxxly editorial guide

Programming languages - C: summary, contents and background

This guide helps you understand the scope of Programming languages - C before or alongside reading the original document. It is based on the catalogue record, credited creator, source, classification and topics shown on this page. It does not replace the original work and does not invent claims about passages that Doxxly cannot verify.

Summary and overview

Programming languages - C is a 535-page documentcredited to Ivo W. Quinlan. N2310 is a C language standard draft with change markings, dated November 6, 2018. It specifies the representation, syntax, constraints, and semantics of C programs, translation and execution environments, and standard library facilities, with the aim of promoting portability, reliability, maintainability, and efficient execution. The draft marks changes relative to ISO/IEC 9899:2018 and incorporates listed defect reports and proposals. It is intended for knowledgeable C programmers and implementors, not as a tutorial. The supplied excerpt includes the abstract, contents, foreword, introduction, and technical text through part of the floating constants section. It appears in the Technology & Security collection, which groups it with other material that readers may use for comparison and further study.

The item can be approached in several ways. A reader looking for a quick orientation can begin with the free five-page preview, inspect the page structure and use the metadata to judge relevance. Someone undertaking deeper research can work through the complete file, search its indexed text, record useful page references and compare its treatment of C programming language, ISO/IEC 9899, N2310, C2x, Standards draft, Language specification, Standard library, Portability with the related resources linked below.

Rather than reducing the work to a single claim, this page treats it as a source that should be read in context. The title, creator, publication source, licence and format all help explain what kind of evidence it may offer. Readers should distinguish the original author's statements from Doxxly's catalogue description, and should cite the original edition when using the material in academic, professional or published work.

Key topics and reader takeaways

The catalogue connects this document with C programming language, ISO/IEC 9899, N2310, C2x, Standards draft, Language specification, Standard library, Portability. These terms offer practical entry points rather than a substitute for close reading. Start by identifying the definitions, examples, arguments, tables or visual explanations attached to each topic. Then note where the creator draws connections, makes distinctions or moves from background material to a conclusion, recommendation, calculation or narrative development.

A useful reading method is to separate description from interpretation. First record what the item actually presents: names, headings, figures, formulas, quotations or stated propositions. Next consider why those details matter within the whole work. Finally compare them with another source from the same subject area. This process helps turn a long digital file into evidence that can be evaluated rather than merely skimmed.

Table of contents and reading guide

The following is an editorial content guide based on the verified catalogue topics. It is not represented as the original author's formal table of contents. Use it to organise notes while moving through the 535 pages in the player.

  1. Part 1

    C programming language

    Use this section of the reading guide to identify how C programming language appears in Programming languages - C, note important terms, and connect the subject to the wider purpose of the work.

  2. Part 2

    ISO/IEC 9899

    Use this section of the reading guide to identify how ISO/IEC 9899 appears in Programming languages - C, note important terms, and connect the subject to the wider purpose of the work.

  3. Part 3

    N2310

    Use this section of the reading guide to identify how N2310 appears in Programming languages - C, note important terms, and connect the subject to the wider purpose of the work.

  4. Part 4

    C2x

    Use this section of the reading guide to identify how C2x appears in Programming languages - C, note important terms, and connect the subject to the wider purpose of the work.

  5. Part 5

    Standards draft

    Use this section of the reading guide to identify how Standards draft appears in Programming languages - C, note important terms, and connect the subject to the wider purpose of the work.

  6. Part 6

    Language specification

    Use this section of the reading guide to identify how Language specification appears in Programming languages - C, note important terms, and connect the subject to the wider purpose of the work.

  7. Part 7

    Standard library

    Use this section of the reading guide to identify how Standard library appears in Programming languages - C, note important terms, and connect the subject to the wider purpose of the work.

  8. Part 8

    Portability

    Use this section of the reading guide to identify how Portability appears in Programming languages - C, note important terms, and connect the subject to the wider purpose of the work.

When a heading in the original differs from this guide, follow the original heading in your citation. Page numbers can also vary between editions. Doxxly's direct page field is useful for navigation, but formal references should include the title, creator, source and edition details available in the file itself.

About Ivo W. Quinlan

Doxxly credits Ivo W. Quinlan as the author or creator of Programming languages - C. This page does not add an unverified biography, job title or institutional affiliation. The attribution is preserved so readers can distinguish the creator from the hosting library and follow the original record when an external author link is available.

Author context matters because a work reflects a particular purpose, audience and point of view. Before relying on the material, consider what the creator set out to explain, when the source was produced and whether later research or revised guidance should also be consulted. For literature and philosophy, compare translations and editions; for technical material, check whether a newer version has superseded the one shown here.

About the source organisation

The recorded source for this item is open-std.org. Doxxly provides access and discovery tools but does not claim to be the original publisher unless explicitly stated. Source links, creator attribution and the recorded Publicly available file collected for editorial review licence are displayed to help readers assess provenance and permitted use.

Provenance is especially important for reports, standards, presentations and working spreadsheets. Check the original source for amendments, supporting files and current policy. A trustworthy research workflow keeps the source URL with any notes or downloaded copy, verifies important figures against the original, and avoids treating an archived document as automatically current.

Visit open-std.org

How to read and use this document

Begin with the title and opening pages, then use the guide above to decide whether to read sequentially or move to a particular topic. The Doxxly player provides previous and next navigation, a direct page field, zoom steps, fit-to-width and fit-to-page modes, rotation and fullscreen. These controls are useful when a page contains small type, a wide table, an image, a scanned layout or a dense sequence of notes.

The first five pages are open to every visitor. A plan unlocks the complete item and full-document search. Search is best used for distinctive names, technical terms or short phrases; broad words can produce too many possible contexts. When you find a useful passage, read the surrounding pages so that a sentence, chart or formula is not separated from its explanation.

If downloading is enabled, members can obtain the original PDF file. Keep the original format when formulas, slide sequencing, pagination or layout carries meaning. Respect the Publicly available file collected for editorial review terms displayed on this page, and use the rights-report link if you believe the attribution or availability needs review.

Research questions to consider

As you read Programming languages - C, ask which audience the creator addresses, what problem or idea organises the work, what evidence is presented, and which assumptions remain unstated. Note whether important terms are defined consistently and whether examples represent a broader pattern or a narrow case. For quantitative material, record units, time periods, formulas and data sources. For interpretive material, separate the creator's language from your own summary.

A second set of questions concerns relevance today. Which parts remain durable, which depend on their historical or institutional setting, and what would need confirmation from a newer source? Following the tags and the Technology & Security collection can reveal useful comparisons. Agreement between sources can strengthen confidence, while disagreement can point to changing definitions, methods, evidence or priorities.

Finally, decide what you need from the item: background knowledge, a quotation, a worked example, a model, a visual explanation or a starting bibliography. That purpose should guide the depth of reading and the notes you keep. Doxxly helps locate and navigate the source; careful interpretation remains the reader's responsibility.

Explore more Technology & Security resources

Frequently asked questions about Programming languages - C

Practical answers about reading, downloading and understanding this document on Doxxly.

More in Technology & Security