Skip to content

Commit

Permalink
Update clang format, fix two warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
PeterTh committed Dec 13, 2023
1 parent d5a73c3 commit 57211f7
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 3 deletions.
4 changes: 3 additions & 1 deletion .clang-format
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Clang-format coding style definitions for simSYCL
#
# Due to some inconsistencies between releases we currently
# use clang-format 14 as the authoritative version.
# use clang-format 16 as the authoritative version.

BasedOnStyle: llvm

Expand All @@ -20,6 +20,7 @@ BreakBeforeBinaryOperators: All
BreakBeforeBraces: Attach
ColumnLimit: 120
Cpp11BracedListStyle: true
FixNamespaceComments: true
IndentCaseLabels: true
IndentWidth: 4
KeepEmptyLinesAtTheStartOfBlocks: false
Expand All @@ -28,6 +29,7 @@ NamespaceIndentation: None
PointerAlignment: Right
QualifierAlignment: Left
SpaceAfterCStyleCast: false
SpaceAfterTemplateKeyword : false
SpaceBeforeParens: Never
SpaceInEmptyParentheses: false
SpacesBeforeTrailingComments: 1
Expand Down
4 changes: 3 additions & 1 deletion include/simsycl/sycl/device.hh
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,9 @@ class device : public detail::reference_type<device, detail::device_state> {
device() : device(default_selector_v) {}

template <typename DeviceSelector>
explicit device(const DeviceSelector &device_selector) : reference_type(std::in_place) {}
explicit device(const DeviceSelector &device_selector) : reference_type(std::in_place) {
(void)(device_selector);
}

bool is_cpu() const;

Expand Down
4 changes: 3 additions & 1 deletion include/simsycl/sycl/platform.hh
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ class platform : public detail::reference_type<platform, detail::platform_state>
platform() : platform(default_selector_v) {}

template <typename DeviceSelector>
explicit platform(const DeviceSelector &device_selector) : reference_type(std::in_place) {}
explicit platform(const DeviceSelector &device_selector) : reference_type(std::in_place) {
(void)(device_selector);
}

backend get_backend() const noexcept;

Expand Down

0 comments on commit 57211f7

Please sign in to comment.