CI updates
This commit is contained in:
@@ -429,9 +429,11 @@ struct TestTriBool {
|
||||
assert(a);
|
||||
assert(bool(a));
|
||||
assert((a ? true : false));
|
||||
assert((!a ? false : true));
|
||||
} else {
|
||||
assert(!a);
|
||||
assert(!bool(a));
|
||||
assert((a ? false : true));
|
||||
assert((!a ? true : false));
|
||||
}
|
||||
assert(!a.isStrictFalse());
|
||||
|
||||
@@ -340,7 +340,8 @@ int upx_lzma_compress(const upx_bytep src, unsigned src_len, upx_bytep dst, unsi
|
||||
progress.cb = cb; // progress.Init()
|
||||
|
||||
NCompress::NLZMA::CEncoder enc;
|
||||
const PROPID propIDs[8] = {
|
||||
constexpr unsigned NPROPS = 8;
|
||||
static const PROPID propIDs[NPROPS] = {
|
||||
NCoderPropID::kPosStateBits, // 0 pb _posStateBits(2)
|
||||
NCoderPropID::kLitPosBits, // 1 lp _numLiteralPosStateBits(0)
|
||||
NCoderPropID::kLitContextBits, // 2 lc _numLiteralContextBits(3)
|
||||
@@ -350,8 +351,7 @@ int upx_lzma_compress(const upx_bytep src, unsigned src_len, upx_bytep dst, unsi
|
||||
NCoderPropID::kMatchFinderCycles, // 6 mfc _matchFinderCycles, _cutValue
|
||||
NCoderPropID::kMatchFinder // 7 mf
|
||||
};
|
||||
PROPVARIANT pr[8];
|
||||
const unsigned nprops = 8;
|
||||
PROPVARIANT pr[NPROPS];
|
||||
if (!prepare_result(res, src_len, method, level, lcconf))
|
||||
goto error;
|
||||
pr[0].vt = pr[1].vt = pr[2].vt = pr[3].vt = pr[4].vt = pr[5].vt = pr[6].vt = VT_UI4;
|
||||
@@ -368,7 +368,7 @@ int upx_lzma_compress(const upx_bytep src, unsigned src_len, upx_bytep dst, unsi
|
||||
pr[7].bstrVal = ACC_PCAST(BSTR, ACC_UNCONST_CAST(wchar_t *, matchfinder));
|
||||
|
||||
try {
|
||||
if (enc.SetCoderProperties(propIDs, pr, nprops) != S_OK)
|
||||
if (enc.SetCoderProperties(propIDs, pr, NPROPS) != S_OK)
|
||||
goto error;
|
||||
// encode properties in LZMA-style (5 bytes)
|
||||
if (enc.WriteCoderProperties(&os) != S_OK)
|
||||
|
||||
+1
-1
@@ -193,7 +193,7 @@ typedef upx_int64_t upx_off_t;
|
||||
#define very_unlikely __acc_very_unlikely
|
||||
|
||||
// cosmetic: explicitly annotate some functions which may throw exceptions
|
||||
// note: noexcept(false) is the default for all C++ functions anyway
|
||||
// note that noexcept(false) is the default for all C++ functions anyway
|
||||
#define may_throw noexcept(false)
|
||||
|
||||
#define COMPILE_TIME_ASSERT(e) ACC_COMPILE_TIME_ASSERT(e)
|
||||
|
||||
+3
-3
@@ -186,8 +186,8 @@ forceinline Result ptr_static_cast(const From *ptr) noexcept {
|
||||
return static_cast<Result>(static_cast<const void *>(ptr));
|
||||
}
|
||||
|
||||
// helper classes so we don't leak memory on exceptions; NOT thread-safe
|
||||
template <class T> // T is "Type **"
|
||||
// helper classes so we don't leak memory on exceptions
|
||||
template <class T> // T is "SomeType **"
|
||||
struct ObjectDeleter final {
|
||||
static_assert(std::is_pointer_v<T>);
|
||||
static_assert(std::is_pointer_v<std::remove_pointer_t<T> >);
|
||||
@@ -202,7 +202,7 @@ struct ObjectDeleter final {
|
||||
}
|
||||
}
|
||||
};
|
||||
template <class T> // T is "Type **"
|
||||
template <class T> // T is "SomeType **"
|
||||
struct ArrayDeleter final {
|
||||
static_assert(std::is_pointer_v<T>);
|
||||
static_assert(std::is_pointer_v<std::remove_pointer_t<T> >);
|
||||
|
||||
Reference in New Issue
Block a user