cores: arduino: Format with clang-format#166
cores: arduino: Format with clang-format#166DhruvaG2000 merged 1 commit intozephyrproject-rtos:nextfrom
Conversation
There was a problem hiding this comment.
Pull request overview
This PR primarily applies clang-format style changes across the Arduino Zephyr core to standardize indentation and brace placement, while also pulling in a couple of functional tweaks that go beyond formatting.
Changes:
- Reformat Arduino core sources/headers (Serial, Print, common utilities, entrypoint) for consistent style.
- Update the
hello_arduinosampleprintkformat specifiers to use%zuforsize_t. - Modify
delay()/delayMicroseconds()inzephyrCommon.cpp(addsalways_inlineattribute and changes microsecond delay behavior).
Reviewed changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| samples/hello_arduino/src/app.cpp | Updates printk size_t format specifiers (%zu). |
| cores/arduino/zephyrSerial.h | clang-format pass over Serial class declarations/macros. |
| cores/arduino/zephyrSerial.cpp | clang-format pass; macro formatting and serialEventRun braces. |
| cores/arduino/zephyrPrint.h | clang-format pass over inline Print methods and helpers. |
| cores/arduino/zephyrPrint.cpp | clang-format pass over Print support implementation. |
| cores/arduino/zephyrCommon.cpp | clang-format pass plus behavioral changes to delay functions. |
| cores/arduino/main.cpp | clang-format pass; adds braces around serialEventRun call. |
| cores/arduino/apiCommon.cpp | clang-format pass; whitespace/indent changes. |
| cores/arduino/Arduino.h | clang-format pass over devicetree-related macros/enums. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
DhruvaG2000
left a comment
There was a problem hiding this comment.
Can you please rebase on top of just next?
Just the commit "cores: arduino: Format with clang-format" is fine for this PR.
Also, any ideas on how we can add clang format checks as part of our PR CI's itself? Will help maintain formatting in future as well
dc7b335 to
4e63d9c
Compare
It's best not to enforce this. Rules change sometimes, and sometimes not following the rules is easier to read. |
Use a formatter to standardize indentation. Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
4e63d9c to
d48673d
Compare
Use a formatter to standardize indentation.
Committing to reduce the diff in preparation for the merge.
Please approve #163 and #165 first.