vapours: fix MASKL, MASK2L to match Armv8 ARM (inclusive bit range)

This commit is contained in:
TuxSH 2020-03-01 15:16:12 +00:00
parent dc1404061c
commit 4f33afe0ee

View file

@ -69,12 +69,12 @@ typedef u32 Result; ///< Function error code result type.
/// Creates a bitmask for bit range extraction.
#ifndef MASK2
#define MASK2(a,b) (MASK(a) & ~MASK(b))
#define MASK2(a,b) (MASK((a) + 1) & ~MASK(b))
#endif
/// Creates a bitmask for bit range extraction (long).
#ifndef MASK2L
#define MASK2L(a,b) (MASKL(a) & ~MASKL(b))
#define MASK2L(a,b) (MASKL((a) + 1) & ~MASKL(b))
#endif
/// Marks a function as not returning, for the purposes of compiler optimization.