The __writeonly type qualifier indicates
that a data object cannot be read from.
In the C and C++ type system it behaves as a cv-qualifier
like const or volatile. Its specific effect
is that an lvalue with __writeonly type cannot
be converted to an rvalue.
Assignment to a __writeonly bitfield is
not allowed if the assignment is implemented as read-modify-write.
This is implementation-dependent.
Example
void foo(__writeonly int *ptr)
{
*ptr = 0; // allowed
printf("ptr value = %d\n", *ptr); // error
}
This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies.
ARM websites use two types of cookie: (1) those that enable the site to function and perform as required; and (2) analytical cookies which anonymously track visitors only while using the site. If you are not happy with this use of these cookies please review our Privacy Policy to learn how they can be disabled. By disabling cookies some features of the site will not work.