/*D
   MPI_Win_get_attr - Get attribute cached on an MPI window object

Synopsis:
.vb
int MPI_Win_get_attr(MPI_Win win, int win_keyval, void *attribute_val,
                     int *flag)
.ve

Input Parameters:
+ win - window to which the attribute is attached (handle)
- win_keyval - key value (integer)

Output Parameters:
+ attribute_val - attribute value, unless flag = false (None)
- flag - false if no attribute is associated with the key (logical)

Notes:
The following attributes are predefined for all MPI Window objects\:

+ MPI_WIN_BASE - window base address.
. MPI_WIN_SIZE - window size, in bytes.
- MPI_WIN_DISP_UNIT - displacement unit associated with the window.

Attributes must be extracted from the same language as they were inserted
in with 'MPI_ATTR_PUT'.  The notes for C and Fortran below explain why.

.N ThreadSafe

Notes for C:
    Even though the 'attribute_val' argument is declared as 'void *', it is
    really the address of a void pointer (i.e., a 'void **').  Using
    a 'void *', however, is more in keeping with C idiom and allows the
    pointer to be passed without additional casts.

.N Fortran
    The 'attribute_val' in Fortran is a pointer to a Fortran integer, not
    a pointer to a 'void *'.

.N Errors
.N MPI_SUCCESS
.N MPI_ERR_ARG
.N MPI_ERR_KEYVAL
.N MPI_ERR_WIN
.N MPI_ERR_OTHER

D*/

