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
@@ -11,50 +12,41 @@ Causes a call to the `_penter` function at the start of every method or function
11
12
12
13
## Syntax
13
14
14
-
```
15
-
/Gh
16
-
```
15
+
> **`/Gh`**
17
16
18
17
## Remarks
19
18
20
-
The `_penter` function is not part of any library and it is up to you to provide a definition for `_penter`.
19
+
The `_penter` function isn't part of any library. It's up to you to provide a definition for `_penter`.
21
20
22
-
Unless you plan to explicitly call `_penter`, you do not need to provide a prototype. The function must appear as if it had the following prototype, and it must push the content of all registers on entry and pop the unchanged content on exit:
21
+
Unless you plan to explicitly call `_penter`, you don't need to provide a prototype. The function must push the content of all registers on entry and pop the unchanged content on exit. It must appear as if it had the following prototype:
23
22
24
23
```cpp
25
24
void__declspec(naked) __cdecl _penter( void );
26
25
```
27
26
28
-
This declaration is not available for 64-bit projects.
27
+
This declaration isn't available for 64-bit projects.
29
28
30
29
### To set this compiler option in the Visual Studio development environment
31
30
32
31
1. Open the project's **Property Pages** dialog box. For details, see [Set C++ compiler and build properties in Visual Studio](../working-with-project-properties.md).
33
32
34
-
1. Click the **C/C++** folder.
35
-
36
-
1. Click the **Command Line** property page.
33
+
1. Open the **Configuration Properties** > **C/C++** > **Command Line** property page.
37
34
38
-
1. Type the compiler option in the **Additional Options** box.
35
+
1. Enter the compiler option in the **Additional Options** box.
39
36
40
37
### To set this compiler option programmatically
41
38
42
39
- See <xref:Microsoft.VisualStudio.VCProjectEngine.VCCLCompilerTool.AdditionalOptions%2A>.
43
40
44
41
## Example
45
42
46
-
The following code, when compiled with **/Gh**, shows how `_penter` is called twice; once when entering function `main` and once when entering function `x`.
43
+
The following code, when compiled with **/Gh**, shows how `_penter` is called twice; once when entering function `main` and once when entering function `x`. The example consists of two source files, which you compile separately.
@@ -11,31 +12,29 @@ Calls the `_pexit` function at the end of every method or function.
11
12
12
13
## Syntax
13
14
14
-
```
15
-
/GH
16
-
```
15
+
> **`/GH`**
17
16
18
17
## Remarks
19
18
20
-
The `_pexit` function is not part of any library and it is up to you to provide a definition for `_pexit`.
19
+
The `_pexit` function isn't part of any library. It's up to you to provide a definition for `_pexit`.
21
20
22
-
Unless you plan to explicitly call `_pexit`, you do not need to provide a prototype. The function must appear as if it had the following prototype, and it must push the content of all registers on entry and pop the unchanged content on exit:
21
+
Unless you plan to explicitly call `_pexit`, you don't need to provide a prototype. The function must push the content of all registers on entry and pop the unchanged content on exit. It must appear as if it had the following prototype:
23
22
24
23
```cpp
25
24
void__declspec(naked) __cdecl _pexit( void );
26
25
```
27
26
28
-
`_pexit` is similar to `_penter`; see [/Gh (Enable _penter Hook Function)](gh-enable-penter-hook-function.md) for an example of how to write a `_pexit` function.
27
+
This declaration isn't available for 64-bit projects.
28
+
29
+
`_pexit` is similar to `_penter`; see [`/Gh` (Enable _penter Hook Function)](gh-enable-penter-hook-function.md) for an example of how to write a `_penter` function.
29
30
30
31
### To set this compiler option in the Visual Studio development environment
31
32
32
33
1. Open the project's **Property Pages** dialog box. For details, see [Set C++ compiler and build properties in Visual Studio](../working-with-project-properties.md).
33
34
34
-
1. Click the **C/C++** folder.
35
-
36
-
1. Click the **Command Line** property page.
35
+
1. Open the **Configuration Properties** > **C/C++** > **Command Line** property page.
37
36
38
-
1. Type the compiler option in the **Additional Options** box.
37
+
1. Enter the compiler option in the **Additional Options** box.
0 commit comments