You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 8c360d5
Browse filesBrowse the repository at this point in the historyBrowse files
Copy file name to clipboardExpand all lines: docs/preprocessor/alloc-text.md
+12-10Lines changed: 12 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -23,20 +23,22 @@ textsection
23
23
", function1, ... )
24
24
```
25
25
26
-
## Remarks
27
-
The **alloc_text** pragma does not handle C++ member functions or overloaded functions. It is applicable only to functions declared with C linkage — that is, functions declared with the **extern "C"** linkage specification. If you attempt to use this pragma on a function with C++ linkage, a compiler error is generated.
26
+
## Remarks
27
+
28
+
The **alloc_text** pragma does not handle C++ member functions or overloaded functions. It is applicable only to functions declared with C linkage — that is, functions declared with the **extern "C"** linkage specification. If you attempt to use this pragma on a function with C++ linkage, a compiler error is generated.
28
29
29
-
Since function addressing using `__based` is not supported, specifying section locations requires the use of the **alloc_text** pragma. The name specified by *textsection* should be enclosed in double quotation marks.
30
+
Since function addressing using `__based` is not supported, specifying section locations requires the use of the **alloc_text** pragma. The name specified by *textsection* should be enclosed in double quotation marks.
30
31
31
-
The **alloc_text** pragma must appear after the declarations of any of the specified functions and before the definitions of these functions.
32
+
The **alloc_text** pragma must appear after the declarations of any of the specified functions and before the definitions of these functions.
32
33
33
-
Functions referenced in an **alloc_text** pragma should be defined in the same module as the pragma. If this is not done and an undefined function is later compiled into a different text section, the error may or may not be caught. Although the program will usually run correctly, the function will not be allocated in the intended sections.
34
+
Functions referenced in an **alloc_text** pragma should be defined in the same module as the pragma. If this is not done and an undefined function is later compiled into a different text section, the error may or may not be caught. Although the program will usually run correctly, the function will not be allocated in the intended sections.
34
35
35
-
Other limitations on **alloc_text** are as follows:
36
+
Other limitations on **alloc_text** are as follows:
36
37
37
-
-It cannot be used inside a function.
38
+
- It cannot be used inside a function.
38
39
39
-
-It must be used after the function has been declared, but before the function has been defined.
40
+
- It must be used after the function has been declared, but before the function has been defined.
40
41
41
-
## See Also
42
-
[Pragma Directives and the __Pragma Keyword](../preprocessor/pragma-directives-and-the-pragma-keyword.md)
42
+
## See Also
43
+
44
+
[Pragma Directives and the __Pragma Keyword](../preprocessor/pragma-directives-and-the-pragma-keyword.md)
Copy file name to clipboardExpand all lines: docs/preprocessor/auto-inline.md
+5-3Lines changed: 5 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -22,7 +22,9 @@ Excludes any functions defined within the range where **off** is specified from
22
22
```
23
23
24
24
## Remarks
25
-
To use the **auto_inline** pragma, place it before and immediately after (not in) a function definition. The pragma takes effect at the first function definition after the pragma is seen.
25
+
26
+
To use the **auto_inline** pragma, place it before and immediately after (not in) a function definition. The pragma takes effect at the first function definition after the pragma is seen.
26
27
27
-
## See Also
28
-
[Pragma Directives and the __Pragma Keyword](../preprocessor/pragma-directives-and-the-pragma-keyword.md)
28
+
## See Also
29
+
30
+
[Pragma Directives and the __Pragma Keyword](../preprocessor/pragma-directives-and-the-pragma-keyword.md)
Copy file name to clipboardExpand all lines: docs/preprocessor/auto-search.md
+5-4Lines changed: 5 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -15,7 +15,7 @@ ms.workload: ["cplusplus"]
15
15
# auto_search
16
16
**C++ Specific**
17
17
18
-
Specifies that, when a type library is referenced with `#import` and itself references another type library, the compiler can do an implicit `#import` for the other type library.
18
+
Specifies that, when a type library is referenced with `#import` and itself references another type library, the compiler can do an implicit `#import` for the other type library.
Copy file name to clipboardExpand all lines: docs/preprocessor/bss-seg.md
+19-17Lines changed: 19 additions & 17 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -22,26 +22,27 @@ Specifies the segment where uninitialized variables are stored in the .obj file.
22
22
```
23
23
24
24
## Remarks
25
-
Obj files can be viewed with the [dumpbin](../build/reference/dumpbin-command-line.md) application. The default segment in the .obj file for uninitialized data is .bss. In some cases use of **bss_seg** can speed load times by grouping uninitialized data into one section.
25
+
26
+
Obj files can be viewed with the [dumpbin](../build/reference/dumpbin-command-line.md) application. The default segment in the .obj file for uninitialized data is .bss. In some cases use of **bss_seg** can speed load times by grouping uninitialized data into one section.
26
27
27
-
**bss_seg** with no parameters resets the segment to .bss.
28
+
**bss_seg** with no parameters resets the segment to .bss.
28
29
29
-
*push* (optional)
30
-
Puts a record on the internal compiler stack. A *push* can have an *identifier* and *segment-name*.
30
+
*push* (optional)
31
+
Puts a record on the internal compiler stack. A *push* can have an *identifier* and *segment-name*.
31
32
32
-
*pop* (optional)
33
-
Removes a record from the top of the internal compiler stack.
33
+
*pop* (optional)
34
+
Removes a record from the top of the internal compiler stack.
34
35
35
-
*identifier* (optional)
36
-
When used with *push*, assigns a name to the record on the internal compiler stack. When used with *pop*, pops records off the internal stack until *identifier* is removed; if *identifier* is not found on the internal stack, nothing is popped.
36
+
*identifier* (optional)
37
+
When used with *push*, assigns a name to the record on the internal compiler stack. When used with *pop*, pops records off the internal stack until *identifier* is removed; if *identifier* is not found on the internal stack, nothing is popped.
37
38
38
-
*identifier* enables multiple records to be popped with a single *pop* command.
39
+
*identifier* enables multiple records to be popped with a single *pop* command.
39
40
40
-
*"segment-name"*(optional)
41
-
The name of a segment. When used with *pop*, the stack is popped and *segment-name* becomes the active segment name.
41
+
*"segment-name"*(optional)
42
+
The name of a segment. When used with *pop*, the stack is popped and *segment-name* becomes the active segment name.
42
43
43
-
*"segment-class"* (optional)
44
-
Included for compatibility with C++ prior to version 2.0. It is ignored.
44
+
*"segment-class"* (optional)
45
+
Included for compatibility with C++ prior to version 2.0. It is ignored.
45
46
46
47
## Example
47
48
@@ -61,11 +62,12 @@ int main() {
61
62
}
62
63
```
63
64
64
-
You can also specify sections for initialized data ([data_seg](../preprocessor/data-seg.md)), functions ([code_seg](../preprocessor/code-seg.md)), and const variables ([const_seg](../preprocessor/const-seg.md)).
65
+
You can also specify sections for initialized data ([data_seg](../preprocessor/data-seg.md)), functions ([code_seg](../preprocessor/code-seg.md)), and const variables ([const_seg](../preprocessor/const-seg.md)).
65
66
66
-
Data allocated using the **bss_seg** pragma does not retain any information about its location.
67
+
Data allocated using the **bss_seg** pragma does not retain any information about its location.
67
68
68
-
See [/SECTION](../build/reference/section-specify-section-attributes.md) for a list of names you should not use when creating a section.
69
+
See [/SECTION](../build/reference/section-specify-section-attributes.md) for a list of names you should not use when creating a section.
69
70
70
71
## See Also
71
-
[Pragma Directives and the __Pragma Keyword](../preprocessor/pragma-directives-and-the-pragma-keyword.md)
72
+
73
+
[Pragma Directives and the __Pragma Keyword](../preprocessor/pragma-directives-and-the-pragma-keyword.md)
Copy file name to clipboardExpand all lines: docs/preprocessor/c-cpp-preprocessor-reference.md
+18-16Lines changed: 18 additions & 16 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -15,27 +15,29 @@ ms.workload: ["cplusplus"]
15
15
The *C/C++ Preprocessor Reference* explains the preprocessor as it is implemented in Microsoft C/C++. The preprocessor performs preliminary operations on C and C++ files before they are passed to the compiler. You can use the preprocessor to conditionally compile code, insert files, specify compile-time error messages, and apply machine-specific rules to sections of code.
Discusses pragmas, which offer a way for each compiler to offer machine- and operating system-specific features while retaining overall compatibility with the C and C++ languages.
Discusses pragmas, which offer a way for each compiler to offer machine- and operating system-specific features while retaining overall compatibility with the C and C++ languages.
29
30
30
31
## Related Sections
31
-
[C++ Language Reference](../cpp/cpp-language-reference.md)
32
-
Provides reference material for the Microsoft implementation of the C++ language.
32
+
33
+
[C++ Language Reference](../cpp/cpp-language-reference.md)
34
+
Provides reference material for the Microsoft implementation of the C++ language.
33
35
34
-
[C Language Reference](../c-language/c-language-reference.md)
35
-
Provides reference material for the Microsoft implementation of the C language.
36
+
[C Language Reference](../c-language/c-language-reference.md)
37
+
Provides reference material for the Microsoft implementation of the C language.
36
38
37
-
[Building a C/C++ Program](../build/reference/c-cpp-building-reference.md)
38
-
Provides links to topics discussing compiler and linker options.
39
+
[Building a C/C++ Program](../build/reference/c-cpp-building-reference.md)
40
+
Provides links to topics discussing compiler and linker options.
39
41
40
-
[Creating and Managing Visual C++ Projects](../ide/creating-and-managing-visual-cpp-projects.md)
41
-
Describes the user interface in Visual Studio that enables you to specify the directories that the project system will search to locate files for your C++ project.
42
+
[Creating and Managing Visual C++ Projects](../ide/creating-and-managing-visual-cpp-projects.md)
43
+
Describes the user interface in Visual Studio that enables you to specify the directories that the project system will search to locate files for your C++ project.
Copy file name to clipboardExpand all lines: docs/preprocessor/charizing-operator-hash-at.md
+7-6Lines changed: 7 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -15,27 +15,28 @@ ms.workload: ["cplusplus"]
15
15
# Charizing Operator (#@)
16
16
**Microsoft Specific**
17
17
18
-
The charizing operator can be used only with arguments of macros. If `#@` precedes a formal parameter in the definition of the macro, the actual argument is enclosed in single quotation marks and treated as a character when the macro is expanded. For example:
18
+
The charizing operator can be used only with arguments of macros. If `#@` precedes a formal parameter in the definition of the macro, the actual argument is enclosed in single quotation marks and treated as a character when the macro is expanded. For example:
19
19
20
20
```
21
21
#define makechar(x) #@x
22
22
```
23
23
24
-
causes the statement
24
+
causes the statement
25
25
26
26
```
27
27
a = makechar(b);
28
28
```
29
29
30
-
to be expanded to
30
+
to be expanded to
31
31
32
32
```
33
33
a = 'b';
34
34
```
35
35
36
-
The single-quotation character cannot be used with the charizing operator.
36
+
The single-quotation character cannot be used with the charizing operator.
Copy file name to clipboardExpand all lines: docs/preprocessor/check-stack.md
+6-4Lines changed: 6 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -22,10 +22,11 @@ Instructs the compiler to turn off stack probes if `off` (or `-`) is specified,
22
22
#pragma check_stack{+ | -}
23
23
```
24
24
25
-
## Remarks
26
-
If no argument is given, stack probes are treated according to the default. This pragma takes effect at the first function defined after the pragma is seen. Stack probes are neither a part of macros nor of functions that are generated inline.
25
+
## Remarks
26
+
27
+
If no argument is given, stack probes are treated according to the default. This pragma takes effect at the first function defined after the pragma is seen. Stack probes are neither a part of macros nor of functions that are generated inline.
27
28
28
-
If you don't give an argument for the **check_stack** pragma, stack checking reverts to the behavior specified on the command line. For more information, see [Compiler Reference](../build/reference/compiler-options.md). The interaction of the `#pragma check_stack` and the [/Gs](../build/reference/gs-control-stack-checking-calls.md) option is summarized in the following table.
29
+
If you don't give an argument for the **check_stack** pragma, stack checking reverts to the behavior specified on the command line. For more information, see [Compiler Reference](../build/reference/compiler-options.md). The interaction of the `#pragma check_stack` and the [/Gs](../build/reference/gs-control-stack-checking-calls.md) option is summarized in the following table.
29
30
30
31
### Using the check_stack Pragma
31
32
@@ -37,4 +38,5 @@ Instructs the compiler to turn off stack probes if `off` (or `-`) is specified,
37
38
|`#pragma check_stack(off)`<br /><br /> or `#pragma check_stack -`|Yes or No|Turns off stack checking for functions that follow|
38
39
39
40
## See Also
40
-
[Pragma Directives and the __Pragma Keyword](../preprocessor/pragma-directives-and-the-pragma-keyword.md)
41
+
42
+
[Pragma Directives and the __Pragma Keyword](../preprocessor/pragma-directives-and-the-pragma-keyword.md)
0 commit comments