浏览代码

Namespace renamed to 'sg'.

main
offa 7 年前
父节点
当前提交
d6649fd3b1
共有 2 个文件被更改,包括 2 次插入4 次删除
  1. +1
    -1
      include/scope_guard.h
  2. +1
    -3
      test/ScopeGuardTest.cpp

+ 1
- 1
include/scope_guard.h 查看文件

@@ -3,7 +3,7 @@

#include <utility>

namespace guards
namespace sg
{

template<class Deleter>

+ 1
- 3
test/ScopeGuardTest.cpp 查看文件

@@ -2,14 +2,12 @@
#include "scope_guard.h"
#include <catch.hpp>

using namespace guards;

TEST_CASE("deleter called on destruction", "[ScopeGuard]")
{
bool executed = false;

{
auto guard = scope_guard([&executed] { executed = true; });
auto guard = sg::scope_guard([&executed] { executed = true; });
static_cast<void>(guard);
}


正在加载...
取消
保存