浏览代码

Fixed bug introduced by experiment around concepts

tagfs
Ludovic 'Archivist' Lagouardette 4 年前
父节点
当前提交
1347811505
共有 3 个文件被更改,包括 9 次插入7 次删除
  1. +2
    -4
      Makefile
  2. +4
    -0
      include/gp/iterator.hpp
  3. +3
    -3
      include/gp/range.hpp

+ 2
- 4
Makefile 查看文件

@ -1,8 +1,6 @@
CXX= g++
CXX= clang++-10
CXXFLAGS= --std=c++20 -O0 -g -pthread -DGP_TESTS -DFUZZ_STRENGTH=500 -DNO_BENCH=0 -pedantic \
-frtti \
#-g -fprofile-instr-generate -fcoverage-mapping -Wno-unknown-attributes \
-frtti -fprofile-instr-generate -fcoverage-mapping -Wno-unknown-attributes \
-fsanitize=address -fno-omit-frame-pointer
all: tests

+ 4
- 0
include/gp/iterator.hpp 查看文件

@ -17,6 +17,10 @@ struct pointer_iterator final
typedef std::size_t difference_type;
static constexpr iterator_type_t iterator_type = iterator_type_t::contiguous_iterator;
constexpr pointer_iterator()
: data{nullptr}
{}
constexpr pointer_iterator(const pointer_iterator& oth)
: data{oth.data}
{}

+ 3
- 3
include/gp/range.hpp 查看文件

@ -3,13 +3,13 @@
#include "gp/algorithm/tmp_manip.hpp"
namespace gp{
k">template<typename T>
cm">/*template<typename T>
concept IsSubstractible = requires(T a, T b)
{
{a - b} -> std::integral;
};
};*/
template<typename it, bool Enable = IsSubstractible<it>>
template<typename it, bool Enable = std::is_integral_v<decltype(it{} - it{})>/* IsSubstractible<it> */>
class nameless_range;
template<typename it>

正在加载...
取消
保存