Code compiles and passes tests without NO_STDLIB define
This commit is contained in:
parent
6ba83fd582
commit
9bd1104e5f
@ -12,6 +12,7 @@
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
#include "std_lib.h"
|
||||
#include "utility.h"
|
||||
|
||||
|
||||
|
||||
@ -5,6 +5,7 @@
|
||||
#ifndef CONST_FMT_NO_CPP_STD_LIB
|
||||
|
||||
#include <array>
|
||||
#include <cstring>
|
||||
|
||||
#else
|
||||
|
||||
|
||||
@ -20,8 +20,7 @@ template <std::size_t N>
|
||||
class ConstString {
|
||||
public:
|
||||
constexpr ConstString(const char (&content)[N]) noexcept {
|
||||
std::copy(&content[0], (&content[N-1] + 1),
|
||||
m_content.begin());
|
||||
std::copy(&content[0], (&content[N - 1] + 1), m_content.begin());
|
||||
}
|
||||
|
||||
constexpr char operator[](std::size_t index) const noexcept {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user