Стандарт C++ 98, страница 5

PDF-файл Стандарт C++ 98, страница 5 Практикум (Прикладное программное обеспечение и системы программирования) (37588): Другое - 4 семестрСтандарт C++ 98: Практикум (Прикладное программное обеспечение и системы программирования) - PDF, страница 5 (37588) - СтудИзба2019-05-09СтудИзба

Описание файла

PDF-файл из архива "Стандарт C++ 98", который расположен в категории "". Всё это находится в предмете "практикум (прикладное программное обеспечение и системы программирования)" из 4 семестр, которые можно найти в файловом архиве МГУ им. Ломоносова. Не смотря на прямую связь этого архива с МГУ им. Ломоносова, его также можно найти и в других разделах. .

Просмотр PDF-файла онлайн

Текст 5 страницы из PDF

Any source filecharacter not in the basic source character set (2.2) is replaced by the universal-character-name that designates that character. (An implementation may use any internal encoding, so long as an actualextended character encountered in the source file, and the same extended character expressed in thesource file as a universal-character-name (i.e. using the \uXXXX notation), are handled equivalently.)2 Each instance of a new-line character and an immediately preceding backslash character is deleted,splicing physical source lines to form logical source lines. If, as a result, a character sequence thatmatches the syntax of a universal-character-name is produced, the behavior is undefined. If a sourcefile that is not empty does not end in a new-line character, or ends in a new-line character immediatelypreceded by a backslash character, the behavior is undefined.3 The source file is decomposed into preprocessing tokens (2.4) and sequences of white-space characters(including comments).

A source file shall not end in a partial preprocessing token or partial comment14). Each comment is replaced by one space character. New-line characters are retained. Whethereach nonempty sequence of white-space characters other than new-line is retained or replaced by onespace character is implementation-defined. The process of dividing a source file’s characters into preprocessing tokens is context-dependent. [Example: see the handling of < within a #include preprocessing directive.

]4 Preprocessing directives are executed and macro invocations are expanded. If a character sequence thatmatches the syntax of a universal-character-name is produced by token concatenation (16.3.3), thebehavior is undefined. A #include preprocessing directive causes the named header or source file tobe processed from phase 1 through phase 4, recursively.5 Each source character set member, escape sequence, or universal-character-name in character literalsand string literals is converted to a member of the execution character set (2.13.2, 2.13.4).6 Adjacent ordinary string literal tokens are concatenated. Adjacent wide string literal tokens are concatenated.7 White-space characters separating tokens are no longer significant. Each preprocessing token is__________________13) Implementations must behave as if these separate phases occur, although in practice different phases might be folded together.14) A partial preprocessing token would arise from a source file ending in the first portion of a multi-character token that requires a terminating sequence of characters, such as a header-name that is missing the closing " or >.

A partial comment would arise from asource file ending with an unclosed /* comment.9ISO/IEC 14882:1998(E)© ISO/IEC2.1 Phases of translation2 Lexical conventionsconverted into a token. (2.6). The resulting tokens are syntactically and semantically analyzed andtranslated. [Note: Source files, translation units and translated translation units need not necessarily bestored as files, nor need there be any one-to-one correspondence between these entities and any externalrepresentation. The description is conceptual only, and does not specify any particular implementation.]8 Translated translation units and instantiation units are combined as follows: [Note: some or all of thesemay be supplied from a library.

] Each translated translation unit is examined to produce a list ofrequired instantiations. [Note: this may include instantiations which have been explicitly requested(14.7.2). ] The definitions of the required templates are located. It is implementation-defined whetherthe source of the translation units containing these definitions is required to be available. [Note: animplementation could encode sufficient information into the translated translation unit so as to ensurethe source is not required here. ] All the required instantiations are performed to produce instantiationunits. [Note: these are similar to translated translation units, but contain no references to uninstantiatedtemplates and no template definitions.

] The program is ill-formed if any instantiation fails.9 All external object and function references are resolved. Library components are linked to satisfy external references to functions and objects not defined in the current translation. All such translator outputis collected into a program image which contains information needed for execution in its executionenvironment.2.2 Character sets1The basic source character set consists of 96 characters: the space character, the control characters representing horizontal tab, vertical tab, form feed, and new-line, plus the following 91 graphical characters:15)aA0_2[lex.charset]bB1{cC2}dD3[eE4]fF5#gG6(hH7)iI8<j k l m n o p q r s t u v w x y zJ K L M N O P Q R S T U V W X Y Z9> % : ; . ? * + - / ^ & | ~ ! = , \ " ’The universal-character-name construct provides a way to name other characters.hex-quad:hexadecimal-digit hexadecimal-digit hexadecimal-digit hexadecimal-digituniversal-character-name:\u hex-quad\U hex-quad hex-quadThe character designated by the universal-character-name \UNNNNNNNN is that character whose charactershort name in ISO/IEC 10646 is NNNNNNNN; the character designated by the universal-character-name\uNNNN is that character whose character short name in ISO/IEC 10646 is 0000NNNN.

If the hexadecimalvalue for a universal character name is less than 0x20 or in the range 0x7F-0x9F (inclusive), or if the universal character name designates a character in the basic source character set, then the program is illformed.3The basic execution character set and the basic execution wide-character set shall each contain all themembers of the basic source character set, plus control characters representing alert, backspace, and carriage return, plus a null character (respectively, null wide character), whose representation has all zero bits.For each basic execution character set, the values of the members shall be non-negative and distinct fromone another. The execution character set and the execution wide-character set are supersets of the basicexecution character set and the basic execution wide-character set, respectively.

The values of the membersof the execution character sets are implementation-defined, and any additional members are locale-specific.__________________15) The glyphs for the members of the basic source character set are intended to identify characters from the subset of ISO/IEC 10646which corresponds to the ASCII character set.

However, because the mapping from source file characters to the source character set(described in translation phase 1) is specified as implementation-defined, an implementation is required to document how the basicsource characters are represented in source files.10© ISO/IECISO/IEC 14882:1998(E)2 Lexical conventions2.3 Trigraph sequences2.3 Trigraph sequences1[lex.trigraph]Before any other processing takes place, each occurrence of one of the following sequences of three characters (“trigraph sequences”) is replaced by the single character indicated in Table 1.Table 1—trigraph sequences_______________________________________________________________________________________________________________________________________trigraph replacement  trigraph replacement  trigraph replacement __________________________________________________________________??=#[{___________________________________________________________________ ??( ??<___________________________________________________________________??/\ ??)] ??>} ??’^|~___________________________________________________________________ ??! ??2[Example:??=define arraycheck(a,b) a??(b??) ??!??! b??(a??)becomes#define arraycheck(a,b) a[b] || b[a]—end example]3No other trigraph sequence exists.

Each ? that does not begin one of the trigraphs listed above is notchanged.2.4 Preprocessing tokens[lex.pptoken]preprocessing-token:header-nameidentifierpp-numbercharacter-literalstring-literalpreprocessing-op-or-punceach non-white-space character that cannot be one of the above1Each preprocessing token that is converted to a token (2.6) shall have the lexical form of a keyword, anidentifier, a literal, an operator, or a punctuator.2A preprocessing token is the minimal lexical element of the language in translation phases 3 through 6.The categories of preprocessing token are: header names, identifiers, preprocessing numbers, characterliterals, string literals, preprocessing-op-or-punc, and single non-white-space characters that do not lexically match the other preprocessing token categories. If a ’ or a " character matches the last category, thebehavior is undefined.

Preprocessing tokens can be separated by white space; this consists of comments(2.7), or white-space characters (space, horizontal tab, new-line, vertical tab, and form-feed), or both. Asdescribed in clause 16, in certain circumstances during translation phase 4, white space (or the absencethereof) serves as more than preprocessing token separation. White space can appear within a preprocessing token only as part of a header name or between the quotation characters in a character literal or stringliteral.3If the input stream has been parsed into preprocessing tokens up to a given character, the next preprocessingtoken is the longest sequence of characters that could constitute a preprocessing token, even if that wouldcause further lexical analysis to fail.4[Example: The program fragment 1Ex is parsed as a preprocessing number token (one that is not a validfloating or integer literal token), even though a parse as the pair of preprocessing tokens 1 and Ex mightproduce a valid expression (for example, if Ex were a macro defined as +1).

Similarly, the program fragment 1E1 is parsed as a preprocessing number (one that is a valid floating literal token), whether or not E isa macro name. ]11ISO/IEC 14882:1998(E)© ISO/IEC2.4 Preprocessing tokens52 Lexical conventions[Example: The program fragment x+++++y is parsed as x ++ ++ + y, which, if x and y are of built-intypes, violates a constraint on increment operators, even though the parse x ++ + ++ y might yield acorrect expression. ]2.5 Alternative tokens[lex.digraph]16)1Alternative token representations are provided for some operators and punctuators.2In all respects of the language, each alternative token behaves the same, respectively, as its primary token,except for its spelling17).

Свежие статьи
Популярно сейчас
Как Вы думаете, сколько людей до Вас делали точно такое же задание? 99% студентов выполняют точно такие же задания, как и их предшественники год назад. Найдите нужный учебный материал на СтудИзбе!
Ответы на популярные вопросы
Да! Наши авторы собирают и выкладывают те работы, которые сдаются в Вашем учебном заведении ежегодно и уже проверены преподавателями.
Да! У нас любой человек может выложить любую учебную работу и зарабатывать на её продажах! Но каждый учебный материал публикуется только после тщательной проверки администрацией.
Вернём деньги! А если быть более точными, то автору даётся немного времени на исправление, а если не исправит или выйдет время, то вернём деньги в полном объёме!
Да! На равне с готовыми студенческими работами у нас продаются услуги. Цены на услуги видны сразу, то есть Вам нужно только указать параметры и сразу можно оплачивать.
Отзывы студентов
Ставлю 10/10
Все нравится, очень удобный сайт, помогает в учебе. Кроме этого, можно заработать самому, выставляя готовые учебные материалы на продажу здесь. Рейтинги и отзывы на преподавателей очень помогают сориентироваться в начале нового семестра. Спасибо за такую функцию. Ставлю максимальную оценку.
Лучшая платформа для успешной сдачи сессии
Познакомился со СтудИзбой благодаря своему другу, очень нравится интерфейс, количество доступных файлов, цена, в общем, все прекрасно. Даже сам продаю какие-то свои работы.
Студизба ван лав ❤
Очень офигенный сайт для студентов. Много полезных учебных материалов. Пользуюсь студизбой с октября 2021 года. Серьёзных нареканий нет. Хотелось бы, что бы ввели подписочную модель и сделали материалы дешевле 300 рублей в рамках подписки бесплатными.
Отличный сайт
Лично меня всё устраивает - и покупка, и продажа; и цены, и возможность предпросмотра куска файла, и обилие бесплатных файлов (в подборках по авторам, читай, ВУЗам и факультетам). Есть определённые баги, но всё решаемо, да и администраторы реагируют в течение суток.
Маленький отзыв о большом помощнике!
Студизба спасает в те моменты, когда сроки горят, а работ накопилось достаточно. Довольно удобный сайт с простой навигацией и огромным количеством материалов.
Студ. Изба как крупнейший сборник работ для студентов
Тут дофига бывает всего полезного. Печально, что бывают предметы по которым даже одного бесплатного решения нет, но это скорее вопрос к студентам. В остальном всё здорово.
Спасательный островок
Если уже не успеваешь разобраться или застрял на каком-то задание поможет тебе быстро и недорого решить твою проблему.
Всё и так отлично
Всё очень удобно. Особенно круто, что есть система бонусов и можно выводить остатки денег. Очень много качественных бесплатных файлов.
Отзыв о системе "Студизба"
Отличная платформа для распространения работ, востребованных студентами. Хорошо налаженная и качественная работа сайта, огромная база заданий и аудитория.
Отличный помощник
Отличный сайт с кучей полезных файлов, позволяющий найти много методичек / учебников / отзывов о вузах и преподователях.
Отлично помогает студентам в любой момент для решения трудных и незамедлительных задач
Хотелось бы больше конкретной информации о преподавателях. А так в принципе хороший сайт, всегда им пользуюсь и ни разу не было желания прекратить. Хороший сайт для помощи студентам, удобный и приятный интерфейс. Из недостатков можно выделить только отсутствия небольшого количества файлов.
Спасибо за шикарный сайт
Великолепный сайт на котором студент за не большие деньги может найти помощь с дз, проектами курсовыми, лабораторными, а также узнать отзывы на преподавателей и бесплатно скачать пособия.
Популярные преподаватели
Добавляйте материалы
и зарабатывайте!
Продажи идут автоматически
5259
Авторов
на СтудИзбе
421
Средний доход
с одного платного файла
Обучение Подробнее