Skip to content

Commit

Permalink
[misc] Update style to clang-format 19, black 25 and isort 6
Browse files Browse the repository at this point in the history
  • Loading branch information
kuba2k2 committed Jan 30, 2025
1 parent d17ea4d commit 6083cca
Show file tree
Hide file tree
Showing 8 changed files with 13 additions and 12 deletions.
2 changes: 1 addition & 1 deletion builder/family/realtek-ambz2.py
Original file line number Diff line number Diff line change
Expand Up @@ -410,7 +410,7 @@
image_ota_clear = env.subst("${BUILD_DIR}/raw_ota_clear.bin")
if not isfile(image_ota_clear):
with open(image_ota_clear, "wb") as f:
f.write(b"\xFF" * 4096)
f.write(b"\xff" * 4096)

# Build all libraries
queue.BuildLibraries()
Expand Down
4 changes: 2 additions & 2 deletions cores/common/arduino/libraries/ext/WebServer/uri/UriBraces.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
class UriBraces : public Uri {

public:
explicit UriBraces(const char *uri) : Uri(uri){};
explicit UriBraces(const String &uri) : Uri(uri){};
explicit UriBraces(const char *uri) : Uri(uri) {};
explicit UriBraces(const String &uri) : Uri(uri) {};

Uri *clone() const override final {
return new UriBraces(_uri);
Expand Down
4 changes: 2 additions & 2 deletions cores/common/arduino/libraries/ext/WebServer/uri/UriGlob.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
class UriGlob : public Uri {

public:
explicit UriGlob(const char *uri) : Uri(uri){};
explicit UriGlob(const String &uri) : Uri(uri){};
explicit UriGlob(const char *uri) : Uri(uri) {};
explicit UriGlob(const String &uri) : Uri(uri) {};

Uri *clone() const override final {
return new UriGlob(_uri);
Expand Down
4 changes: 2 additions & 2 deletions cores/common/arduino/libraries/ext/WebServer/uri/UriRegex.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
class UriRegex : public Uri {

public:
explicit UriRegex(const char *uri) : Uri(uri){};
explicit UriRegex(const String &uri) : Uri(uri){};
explicit UriRegex(const char *uri) : Uri(uri) {};
explicit UriRegex(const String &uri) : Uri(uri) {};

Uri *clone() const override final {
return new UriRegex(_uri);
Expand Down
2 changes: 1 addition & 1 deletion cores/common/arduino/src/wiring/wiring_compat.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ extern "C" {
#define voidFuncPtrArg voidFuncPtrParam

// Additional Arduino compatibility macros
#define round(x) ((x) >= 0 ? (long)((x) + 0.5) : (long)((x)-0.5))
#define round(x) ((x) >= 0 ? (long)((x) + 0.5) : (long)((x) - 0.5))
#define digitalPinToInterrupt(pin) (pin)

// FreeRTOS utilities
Expand Down
4 changes: 3 additions & 1 deletion cores/common/base/config/fal_cfg.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,9 @@ extern const struct fal_flash_dev flash0;
#define FAL_FLASH_DEV_NAME "flash0"

#define FAL_FLASH_DEV_TABLE \
{ &flash0, }
{ \
&flash0, \
}

#define FAL_DEV_NAME_MAX 16 // no need for 24 chars (default)

Expand Down
2 changes: 1 addition & 1 deletion examples/PinScan/src/pinscan.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ void setup() {
server.begin();
server.setNoDelay(true);
#else
stream = &Serial;
stream = &Serial;
#if LT_UART_DEFAULT_SERIAL == 0
output = 0;
pinSkip[0] = PIN_SERIAL0_TX;
Expand Down
3 changes: 1 addition & 2 deletions tools/libretiny/board.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
# Copyright (c) Kuba Szczodrzyński 2022-07-29.

from typing import Union

from genericpath import isfile
from typing import Union

from .dict import merge_dicts
from .fileio import readjson
Expand Down

0 comments on commit 6083cca

Please sign in to comment.