@@ -49,8 +49,9 @@ int f( bool b )
49
49
50
50
## Heuristics
51
51
52
- Variables are also considered initialized when they are passed by reference to
53
- another function. Thus, the example below would also consider ` i ` to be initialized.
52
+ Variables are also considered initialized when they're passed by reference to
53
+ another function. Thus, the following example would also consider ` i ` to be
54
+ initialized.
54
55
55
56
``` cpp
56
57
void init ( int& i );
@@ -69,15 +70,14 @@ int f( bool b )
69
70
}
70
71
```
71
72
72
- This is to support the pattern of passing a pointer to a variable into an
73
- initialization function.
73
+ This is to support the pattern of passing a pointer to a variable into
74
+ an initialization function.
74
75
75
- Note that many functions expect pointers to point to initialized data already,
76
- in which case this heuristic would lead to false negatives. [SAL annotations]
77
- such as `_In_` and `_Out_` can be used to more precisely describe a function's
78
- behavior. For example, in the following we call an external function that
79
- expects its argument to already be initialized and the warning is still
80
- generated.
76
+ Since many functions expect pointers to point to initialized data already, this
77
+ heuristic can lead to false negatives. [SAL annotations] such as `_In_` and
78
+ `_Out_` can be used to more precisely describe a function's behavior. For
79
+ example, in the following we call an external function that expects its argument
80
+ to already be initialized and the warning is still generated.
81
81
82
82
```cpp
83
83
void use( _In_ int& i );
0 commit comments