AFFINITY_MASK - NtDoc

Native API online documentation, based on the System Informer (formerly Process Hacker) phnt headers
#ifndef _PHNT_NTDEF_H
#ifndef _NTDEF_
#if defined(__INTELLISENSE__) || defined(DOXYGEN)
#ifndef AFFINITY_MASK

/**
 * The AFFINITY_MASK macro creates a single-bit affinity mask from an index.
 *
 * \param n Zero-based bit index.
 * \return A `KAFFINITY` mask with only bit @p n set.
 * \remarks Shifting by a value >= bit-width of `KAFFINITY` is undefined behavior.
 */
#define AFFINITY_MASK(n) ((KAFFINITY)1 << (n))

#endif
#endif
#endif
#endif

View code on GitHub
#ifndef _PHNT_NTDEF_H
#ifndef _NTDEF_
#if defined(__INTELLISENSE__) || defined(DOXYGEN)
// ...
#else
#ifndef AFFINITY_MASK

#define AFFINITY_MASK(n) ((KAFFINITY)1 << (n))

#endif
#endif
#endif
#endif

View code on GitHub

NtDoc

No description available.