mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-03-27 21:44:14 +03:00
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
This commit is contained in:
parent
1b567c5f66
commit
44d70b8b25
|
@ -9,6 +9,7 @@ The contents of this file are hereby released in the public domain (CC0)
|
|||
Full text of the CC0 license:
|
||||
https://creativecommons.org/publicdomain/zero/1.0/
|
||||
"""
|
||||
|
||||
from __future__ import annotations
|
||||
|
||||
import struct
|
||||
|
|
|
@ -31,12 +31,12 @@ typedef struct {
|
|||
|
||||
#define BIT_MASK(bit_count) ((1 << (bit_count)) - 1)
|
||||
#define SET_BITS(target, bit_offset, bit_count, value) \
|
||||
target |= (((value)&BIT_MASK(bit_count)) << (bit_offset))
|
||||
target |= (((value) & BIT_MASK(bit_count)) << (bit_offset))
|
||||
#define GET_BITS(source, bit_offset, bit_count) \
|
||||
((source) & (BIT_MASK(bit_count) << (bit_offset))) >> (bit_offset)
|
||||
#define SWAP(TYPE, A, B) \
|
||||
do { \
|
||||
TYPE TMP = A; \
|
||||
(A) = B; \
|
||||
(B) = TMP; \
|
||||
(A) = B; \
|
||||
(B) = TMP; \
|
||||
} while (0)
|
||||
|
|
|
@ -15,8 +15,6 @@
|
|||
|
||||
#include "Bcn.h"
|
||||
|
||||
|
||||
|
||||
#define LOAD16(p) (p)[0] | ((p)[1] << 8)
|
||||
|
||||
#define LOAD32(p) (p)[0] | ((p)[1] << 8) | ((p)[2] << 16) | ((p)[3] << 24)
|
||||
|
|
Loading…
Reference in New Issue
Block a user