Example: The fresh _Success_ Annotation in conjunction with _Out_

Example: The fresh _Success_ Annotation in conjunction with _Out_

Example: The fresh _In_ Annotation

_In_ specifies “read-only”. A familiar mistake is to use _In_ to help you a factor that ought to feel the _Inout_ annotation rather.

When you use Artwork Facility Password Study with this example, it validates that callers violation a non-Null pointer so you can an enthusiastic initialized barrier to possess pInt . In cases like this, pInt tip can’t be NULL.

Example: The fresh _In_opt_ Annotation

_In_opt_ matches _In_ , aside from the fresh new enter in factor try supposed to be NULL and, hence, the function would be to choose it.

Example: The latest _Out_ Annotation

_Out_ supports a familiar condition in which a non-NULL pointer that what to a feature boundary try passed in the therefore the setting initializes the newest feature. The new person does not have any in order to initialize the boundary before label; new called means intends to initialize they earlier efficiency.

Artwork Business Password Research Device validates your person tickets an excellent non-NULL pointer so you’re able to a shield having pInt and this the latest boundary try initialized by form before it returns.

Example: The fresh new _Out_opt_ Annotation

_Out_opt_ matches _Out_ , besides the latest factor was supposed to be NULL and, hence, the big event is look for it.

Artwork Business Password Study validates this function checks having NULL ahead of pInt is actually dereferenced, while pInt is not NULL, that barrier is actually initialized by function before it productivity. ادامه مطلب