Skip to content

Commit a0e33db

Browse files
authored
Merge pull request #9260 from dhalbert/pragma-once
Convert #include guards to #pragma once; add missing #pragma once
2 parents acebb1b + 950b5d0 commit a0e33db

File tree

1,277 files changed

+1994
-2418
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,277 files changed

+1994
-2418
lines changed

devices/ble_hci/common-hal/_bleio/Adapter.h

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,7 @@
66
//
77
// SPDX-License-Identifier: MIT
88

9-
#ifndef MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_ADAPTER_H
10-
#define MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_ADAPTER_H
9+
#pragma once
1110

1211
#include "py/obj.h"
1312
#include "py/objtuple.h"
@@ -75,5 +74,3 @@ uint16_t bleio_adapter_max_attribute_handle(bleio_adapter_obj_t *adapter);
7574
void bleio_adapter_background(bleio_adapter_obj_t *adapter);
7675
void bleio_adapter_gc_collect(bleio_adapter_obj_t *adapter);
7776
void bleio_adapter_reset(bleio_adapter_obj_t *adapter);
78-
79-
#endif // MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_ADAPTER_H

devices/ble_hci/common-hal/_bleio/Attribute.h

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,9 @@
44
//
55
// SPDX-License-Identifier: MIT
66

7-
#ifndef MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_ATTRIBUTE_H
8-
#define MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_ATTRIBUTE_H
7+
#pragma once
98

109
#include "shared-module/_bleio/Attribute.h"
1110
#include "shared-bindings/_bleio/UUID.h"
1211

1312
bleio_uuid_obj_t *bleio_attribute_get_uuid(mp_obj_t *attribute);
14-
15-
#endif // MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_ATTRIBUTE_H

devices/ble_hci/common-hal/_bleio/Characteristic.h

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,7 @@
55
//
66
// SPDX-License-Identifier: MIT
77

8-
#ifndef MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_CHARACTERISTIC_H
9-
#define MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_CHARACTERISTIC_H
8+
#pragma once
109

1110
#include "shared-bindings/_bleio/Attribute.h"
1211
#include "common-hal/_bleio/Descriptor.h"
@@ -39,5 +38,3 @@ bool bleio_characteristic_set_local_value(bleio_characteristic_obj_t *self, mp_b
3938

4039
void bleio_characteristic_set_observer(bleio_characteristic_obj_t *self, mp_obj_t observer);
4140
void bleio_characteristic_clear_observer(bleio_characteristic_obj_t *self);
42-
43-
#endif // MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_CHARACTERISTIC_H

devices/ble_hci/common-hal/_bleio/CharacteristicBuffer.h

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,7 @@
44
//
55
// SPDX-License-Identifier: MIT
66

7-
#ifndef MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_CHARACTERISTICBUFFER_H
8-
#define MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_CHARACTERISTICBUFFER_H
7+
#pragma once
98

109
#include "py/ringbuf.h"
1110
#include "shared-bindings/_bleio/Characteristic.h"
@@ -19,5 +18,3 @@ typedef struct {
1918
} bleio_characteristic_buffer_obj_t;
2019

2120
void bleio_characteristic_buffer_update(bleio_characteristic_buffer_obj_t *self, mp_buffer_info_t *bufinfo);
22-
23-
#endif // MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_CHARACTERISTICBUFFER_H

devices/ble_hci/common-hal/_bleio/Connection.h

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,7 @@
55
//
66
// SPDX-License-Identifier: MIT
77

8-
#ifndef MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_CONNECTION_H
9-
#define MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_CONNECTION_H
8+
#pragma once
109

1110
#include <stdbool.h>
1211

@@ -66,5 +65,3 @@ uint16_t bleio_connection_get_conn_handle(bleio_connection_obj_t *self);
6665
mp_obj_t bleio_connection_new_from_internal(bleio_connection_internal_t *connection);
6766
bleio_connection_internal_t *bleio_conn_handle_to_connection(uint16_t conn_handle);
6867
void bleio_connection_clear(bleio_connection_internal_t *self);
69-
70-
#endif // MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_CONNECTION_H

devices/ble_hci/common-hal/_bleio/Descriptor.h

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,7 @@
66
//
77
// SPDX-License-Identifier: MIT
88

9-
#ifndef MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_DESCRIPTOR_H
10-
#define MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_DESCRIPTOR_H
9+
#pragma once
1110

1211
#include "py/obj.h"
1312

@@ -29,5 +28,3 @@ typedef struct _bleio_descriptor_obj {
2928
bleio_attribute_security_mode_t write_perm;
3029
struct _bleio_descriptor_obj *next;
3130
} bleio_descriptor_obj_t;
32-
33-
#endif // MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_DESCRIPTOR_H

devices/ble_hci/common-hal/_bleio/PacketBuffer.h

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,7 @@
44
//
55
// SPDX-License-Identifier: MIT
66

7-
#ifndef MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_PACKETBUFFER_H
8-
#define MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_PACKETBUFFER_H
7+
#pragma once
98

109
#include "py/ringbuf.h"
1110
#include "shared-bindings/_bleio/Characteristic.h"
@@ -30,5 +29,3 @@ typedef struct {
3029
} bleio_packet_buffer_obj_t;
3130

3231
void bleio_packet_buffer_update(bleio_packet_buffer_obj_t *self, mp_buffer_info_t *bufinfo);
33-
34-
#endif // MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_PACKETBUFFER_H

devices/ble_hci/common-hal/_bleio/Service.h

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,7 @@
55
//
66
// SPDX-License-Identifier: MIT
77

8-
#ifndef MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_SERVICE_H
9-
#define MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_SERVICE_H
8+
#pragma once
109

1110
#include "py/objlist.h"
1211
#include "common-hal/_bleio/UUID.h"
@@ -30,5 +29,3 @@ typedef struct bleio_service_obj {
3029
} bleio_service_obj_t;
3130

3231
void bleio_service_from_connection(bleio_service_obj_t *self, mp_obj_t connection);
33-
34-
#endif // MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_SERVICE_H

devices/ble_hci/common-hal/_bleio/UUID.h

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,7 @@
66
//
77
// SPDX-License-Identifier: MIT
88

9-
#ifndef MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_UUID_H
10-
#define MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_UUID_H
9+
#pragma once
1110

1211
#include "py/obj.h"
1312

@@ -34,5 +33,3 @@ typedef struct {
3433
} bleio_uuid_obj_t;
3534

3635
uint16_t bleio_uuid_get_uuid16_or_unknown(bleio_uuid_obj_t *uuid);
37-
38-
#endif // MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_UUID_H

devices/ble_hci/common-hal/_bleio/__init__.h

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,7 @@
44
//
55
// SPDX-License-Identifier: MIT
66

7-
#ifndef MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_INIT_H
8-
#define MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_INIT_H
7+
#pragma once
98

109
#include <stdbool.h>
1110

@@ -37,5 +36,3 @@ extern bool vm_used_ble;
3736

3837
// UUID shared by all CCCD's.
3938
extern bleio_uuid_obj_t cccd_uuid;
40-
41-
#endif // MICROPY_INCLUDED_BLE_HCI_COMMON_HAL_INIT_H

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy