| description | Learn more about: retval | |
|---|---|---|
| title | retval (C++ COM Attribute) | |
| ms.date | 10/02/2018 | |
| f1_keywords |
|
|
| helpviewer_keywords |
|
|
| ms.assetid | bfa16f08-157d-4eea-afde-1232c54b8501 |
Designates the parameter that receives the return value of the member.
[retval]The retval C++ attribute has the same functionality as the retval MIDL attribute.
retval must appear on the last argument in a function's declaration.
See the example for bindable for a sample use of retval.
| Attribute context | Value |
|---|---|
| Applies to | Interface parameter, interface method |
| Repeatable | No |
| Required attributes | out |
| Invalid attributes | in |
For more information about the attribute contexts, see Attribute Contexts.