-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* workflow * constness / static swap * removed StaticArray add * removed StaticArray add * re-defined StaticArray add * pre commit * tests -> static assertion; more constness
- Loading branch information
Showing
31 changed files
with
361 additions
and
387 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
// ============================================================ | ||
// class SwapBytes enables static byte swapping | ||
// (no memory reallocation) | ||
// ============================================================ | ||
// created by Manfred Sorgo | ||
#pragma once | ||
#ifndef SWAPBYTES_H | ||
#define SWAPBYTES_H | ||
|
||
#include <BAS/coding.h> | ||
|
||
class SwapBytes | ||
{ | ||
protected: | ||
SwapBytes() = default; | ||
static void swapBytes(PTR pA, PTR pB, PTR pS, size_t size); | ||
NOCOPY(SwapBytes) | ||
}; | ||
|
||
#endif // H_ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
#include <BAS/NtpArray.h> | ||
// #include <BAS/NtpArray.h> | ||
|
||
Ntp::Ntp( | ||
const ElementName& name, | ||
const INT32 type, | ||
const size_t pos | ||
): | ||
type(type), | ||
pos(pos) | ||
{ | ||
Mem::cpy(this->name, name); | ||
} | ||
// Ntp::Ntp( | ||
// const ElementName& name, | ||
// const INT32 type, | ||
// const size_t pos | ||
// ): | ||
// type(type), | ||
// pos(pos) | ||
// { | ||
// Mem::cpy(this->name, name); | ||
// } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
#include <BAS/SwapBytes.h> | ||
|
||
#include <cstring> | ||
|
||
void SwapBytes::swapBytes(const PTR pA, const PTR pB, const PTR pS, const size_t size) | ||
{ | ||
std::memcpy(pS, pB, size); | ||
std::memcpy(pB, pA, size); | ||
std::memcpy(pA, pS, size); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.