Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

clang-format Result headers #292

Merged
merged 1 commit into from
Sep 27, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion include/result/result_fnd.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
DEFINE_HORIZON_RESULT_MODULE(Result::FND, FND);

namespace Result::FND {
DEFINE_HORIZON_RESULT(InvalidEnumValue, 1005, InvalidArgument, Permanent);
DEFINE_HORIZON_RESULT(InvalidEnumValue, 1005, InvalidArgument, Permanent);
};
2 changes: 1 addition & 1 deletion include/result/result_gsp.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
DEFINE_HORIZON_RESULT_MODULE(Result::GSP, GSP);

namespace Result::GSP {
DEFINE_HORIZON_RESULT(SuccessRegisterIRQ, 519, Success, Success);
DEFINE_HORIZON_RESULT(SuccessRegisterIRQ, 519, Success, Success);
};
17 changes: 8 additions & 9 deletions include/result/result_kernel.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,11 @@
DEFINE_HORIZON_RESULT_MODULE(Result::Kernel, Kernel);

namespace Result::Kernel {
// Returned when a thread releases a mutex it does not own
DEFINE_HORIZON_RESULT(InvalidMutexRelease, 31, InvalidArgument, Permanent);
DEFINE_HORIZON_RESULT(NotFound, 1018, NotFound, Permanent);
DEFINE_HORIZON_RESULT(InvalidEnumValue, 1005, InvalidArgument, Permanent);
DEFINE_HORIZON_RESULT(InvalidHandle, 1015, InvalidArgument, Permanent);


static_assert(InvalidHandle == 0xD8E007F7, "conversion broken");
};
// Returned when a thread releases a mutex it does not own
DEFINE_HORIZON_RESULT(InvalidMutexRelease, 31, InvalidArgument, Permanent);
DEFINE_HORIZON_RESULT(NotFound, 1018, NotFound, Permanent);
DEFINE_HORIZON_RESULT(InvalidEnumValue, 1005, InvalidArgument, Permanent);
DEFINE_HORIZON_RESULT(InvalidHandle, 1015, InvalidArgument, Permanent);

static_assert(InvalidHandle == 0xD8E007F7, "conversion broken");
}; // namespace Result::Kernel
16 changes: 8 additions & 8 deletions include/result/result_os.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@
DEFINE_HORIZON_RESULT_MODULE(Result::OS, OS);

namespace Result::OS {
DEFINE_HORIZON_RESULT(PortNameTooLong, 30, InvalidArgument, Usage);
DEFINE_HORIZON_RESULT(InvalidHandle, 1015, WrongArgument, Permanent);
DEFINE_HORIZON_RESULT(InvalidCombination, 1006, InvalidArgument, Usage);
DEFINE_HORIZON_RESULT(MisalignedAddress, 1009, InvalidArgument, Usage);
DEFINE_HORIZON_RESULT(MisalignedSize, 1010, InvalidArgument, Usage);
DEFINE_HORIZON_RESULT(OutOfRange, 1021, InvalidArgument, Usage);
DEFINE_HORIZON_RESULT(Timeout, 1022, StatusChanged, Info);
};
DEFINE_HORIZON_RESULT(PortNameTooLong, 30, InvalidArgument, Usage);
DEFINE_HORIZON_RESULT(InvalidHandle, 1015, WrongArgument, Permanent);
DEFINE_HORIZON_RESULT(InvalidCombination, 1006, InvalidArgument, Usage);
DEFINE_HORIZON_RESULT(MisalignedAddress, 1009, InvalidArgument, Usage);
DEFINE_HORIZON_RESULT(MisalignedSize, 1010, InvalidArgument, Usage);
DEFINE_HORIZON_RESULT(OutOfRange, 1021, InvalidArgument, Usage);
DEFINE_HORIZON_RESULT(Timeout, 1022, StatusChanged, Info);
}; // namespace Result::OS
Loading