[pkg-d-commits] [ldc] 45/74: clang-format files touched in d01a91f7 [nfc]
Matthias Klumpp
mak at moszumanska.debian.org
Thu Jul 13 20:54:17 UTC 2017
This is an automated email from the git hooks/post-receive script.
mak pushed a commit to annotated tag v1.3.0-beta2
in repository ldc.
commit 747f7a3dfae6959d8279d464ea0a1bc642963b92
Author: David Nadlinger <code at klickverbot.at>
Date: Tue May 23 21:49:34 2017 +0100
clang-format files touched in d01a91f7 [nfc]
Some housekeeping on files that recently saw large changes anyway.
---
.clang-format | 1 +
driver/cache.cpp | 19 ++++++++-----------
driver/cl_options.cpp | 21 +++++++++++----------
driver/configfile.cpp | 26 ++++++++++++++------------
driver/linker.cpp | 20 ++++++++++----------
driver/toobj.cpp | 3 +--
gen/llvmhelpers.cpp | 25 ++++++++++++++-----------
gen/modules.cpp | 11 ++++++-----
gen/optimizer.cpp | 15 +++++++--------
gen/passes/GarbageCollect2Stack.cpp | 10 +++++-----
gen/pgo.cpp | 10 ++++++----
gen/runtime.cpp | 13 ++++++++-----
gen/toir.cpp | 8 ++++----
13 files changed, 95 insertions(+), 87 deletions(-)
diff --git a/.clang-format b/.clang-format
index 9913057..4518c15 100644
--- a/.clang-format
+++ b/.clang-format
@@ -1,2 +1,3 @@
BasedOnStyle: LLVM
SortIncludes: false
+FixNamespaceComments: false
diff --git a/driver/cache.cpp b/driver/cache.cpp
index a06939e..6266584 100644
--- a/driver/cache.cpp
+++ b/driver/cache.cpp
@@ -128,9 +128,8 @@ llvm::cl::opt<unsigned> pruneInterval(
llvm::cl::value_desc("dur"), llvm::cl::init(20 * 60));
llvm::cl::opt<unsigned> pruneExpiration(
"cache-prune-expiration",
- llvm::cl::desc(
- "Sets the pruning expiration time of cache files to "
- "<dur> seconds (default: 1 week). Implies -cache-prune."),
+ llvm::cl::desc("Sets the pruning expiration time of cache files to "
+ "<dur> seconds (default: 1 week). Implies -cache-prune."),
llvm::cl::value_desc("dur"), llvm::cl::init(7 * 24 * 3600));
llvm::cl::opt<unsigned> pruneSizeLimitPercentage(
"cache-prune-maxpercentage",
@@ -219,8 +218,7 @@ void storeCacheFileName(llvm::StringRef cacheObjectHash,
// Because the compiler version is part of the hash, differences in the
// default settings between compiler versions are already taken care of.
// (Note: config and response files may also add compiler flags.)
-void outputIR2ObjRelevantCmdlineArgs(llvm::raw_ostream &hash_os)
-{
+void outputIR2ObjRelevantCmdlineArgs(llvm::raw_ostream &hash_os) {
// Use a "whitelist" of cmdline args that do not need to be added to the hash,
// and add all others. There is no harm (other than missed cache
// opportunities) in adding commandline arguments that also change the hashed
@@ -272,13 +270,13 @@ void outputIR2ObjRelevantCmdlineArgs(llvm::raw_ostream &hash_os)
if (arg[1] == 'o' && arg[2] == 'd')
continue;
// All "-cache..." options can be ignored
- if (strncmp(arg+1, "cache", 5) == 0)
+ if (strncmp(arg + 1, "cache", 5) == 0)
continue;
// Ignore "-lib"
if (arg[1] == 'l' && arg[2] == 'i' && arg[3] == 'b' && !arg[4])
continue;
// All effects of -d-version... are already included in the IR hash.
- if (strncmp(arg+1, "d-version", 9) == 0)
+ if (strncmp(arg + 1, "d-version", 9) == 0)
continue;
// All effects of -unittest are already included in the IR hash.
if (strcmp(arg + 1, "unittest") == 0) {
@@ -314,8 +312,7 @@ void outputIR2ObjRelevantCmdlineArgs(llvm::raw_ostream &hash_os)
// Output to `hash_os` all environment flags that influence object code output
// in ways that are not observable in the pre-LLVM passes IR used for hashing.
-void outputIR2ObjRelevantEnvironmentOpts(llvm::raw_ostream &hash_os)
-{
+void outputIR2ObjRelevantEnvironmentOpts(llvm::raw_ostream &hash_os) {
// There are no relevant environment options at the moment.
}
@@ -477,8 +474,8 @@ void recoverObjectFile(llvm::StringRef cacheObjectHash,
void pruneCache() {
if (!opts::cacheDir.empty() && isPruningEnabled()) {
- ::pruneCache(opts::cacheDir.data(), opts::cacheDir.size(),
- pruneInterval, pruneExpiration, pruneSizeLimitInBytes,
+ ::pruneCache(opts::cacheDir.data(), opts::cacheDir.size(), pruneInterval,
+ pruneExpiration, pruneSizeLimitInBytes,
pruneSizeLimitPercentage);
}
}
diff --git a/driver/cl_options.cpp b/driver/cl_options.cpp
index 313266a..5ada148 100644
--- a/driver/cl_options.cpp
+++ b/driver/cl_options.cpp
@@ -223,8 +223,9 @@ static cl::opt<bool, true> unittest("unittest", cl::ZeroOrMore,
cl::location(global.params.useUnitTests));
cl::opt<std::string>
- cacheDir("cache", cl::desc("Enable compilation cache, using <cache dir> to "
- "store cache files (experimental)"),
+ cacheDir("cache",
+ cl::desc("Enable compilation cache, using <cache dir> to "
+ "store cache files (experimental)"),
cl::value_desc("cache dir"), cl::ZeroOrMore);
static StringsAdapter strImpPathStore("J", global.params.fileImppath);
@@ -277,13 +278,14 @@ cl::list<std::string> transitions(
cl::desc(
"Help with language change identified by <idents>, use ? for list"));
-cl::list<std::string> linkerSwitches("L",
- cl::desc("Pass <linkerflag> to the linker"),
- cl::value_desc("linkerflag"), cl::Prefix);
+cl::list<std::string>
+ linkerSwitches("L", cl::desc("Pass <linkerflag> to the linker"),
+ cl::value_desc("linkerflag"), cl::Prefix);
-cl::list<std::string> ccSwitches("Xcc", cl::CommaSeparated,
- cl::desc("Pass <ccflag> to GCC/Clang for linking"),
- cl::value_desc("ccflag"));
+cl::list<std::string>
+ ccSwitches("Xcc", cl::CommaSeparated,
+ cl::desc("Pass <ccflag> to GCC/Clang for linking"),
+ cl::value_desc("ccflag"));
cl::opt<std::string>
moduleDeps("deps", cl::ValueOptional, cl::ZeroOrMore,
@@ -304,8 +306,7 @@ cl::opt<std::string>
cl::desc("Target a specific cpu type (-mcpu=help for details)"));
cl::list<std::string>
- mAttrs("mattr", cl::CommaSeparated,
- cl::value_desc("a1,+a2,-a3,..."),
+ mAttrs("mattr", cl::CommaSeparated, cl::value_desc("a1,+a2,-a3,..."),
cl::desc("Target specific attributes (-mattr=help for details)"));
cl::opt<std::string> mTargetTriple("mtriple", cl::ZeroOrMore,
diff --git a/driver/configfile.cpp b/driver/configfile.cpp
index 700ba34..f695dbe 100644
--- a/driver/configfile.cpp
+++ b/driver/configfile.cpp
@@ -56,21 +56,23 @@ static bool ReadPathFromRegistry(llvm::SmallString<128> &p) {
HKEY hkey;
bool res = false;
// FIXME: Version number should be a define.
- if (RegOpenKeyEx(HKEY_LOCAL_MACHINE, _T("SOFTWARE\\ldc-developers\\LDC\\0.11.0"),
- NULL, KEY_QUERY_VALUE, &hkey) == ERROR_SUCCESS) {
+ if (RegOpenKeyEx(HKEY_LOCAL_MACHINE,
+ _T("SOFTWARE\\ldc-developers\\LDC\\0.11.0"), NULL,
+ KEY_QUERY_VALUE, &hkey) == ERROR_SUCCESS) {
DWORD length;
- if (RegGetValue(hkey, NULL, _T("Path"), RRF_RT_REG_SZ, NULL, NULL, &length) ==
- ERROR_SUCCESS) {
+ if (RegGetValue(hkey, NULL, _T("Path"), RRF_RT_REG_SZ, NULL, NULL,
+ &length) == ERROR_SUCCESS) {
TCHAR *data = static_cast<TCHAR *>(_alloca(length * sizeof(TCHAR)));
- if (RegGetValue(hkey, NULL, _T("Path"), RRF_RT_REG_SZ, NULL, data, &length) ==
- ERROR_SUCCESS) {
+ if (RegGetValue(hkey, NULL, _T("Path"), RRF_RT_REG_SZ, NULL, data,
+ &length) == ERROR_SUCCESS) {
#if UNICODE
#if LDC_LLVM_VER >= 400
using UTF16 = llvm::UTF16;
#endif
std::string out;
res = llvm::convertUTF16ToUTF8String(
- llvm::ArrayRef<UTF16>(reinterpret_cast<UTF16 *>(data), length), out);
+ llvm::ArrayRef<UTF16>(reinterpret_cast<UTF16 *>(data), length),
+ out);
p = out;
#else
p = std::string(data);
@@ -84,8 +86,7 @@ static bool ReadPathFromRegistry(llvm::SmallString<128> &p) {
}
#endif
-
-bool ConfigFile::locate(std::string& pathstr) {
+bool ConfigFile::locate(std::string &pathstr) {
// temporary configuration
llvm::SmallString<128> p;
@@ -169,7 +170,7 @@ bool ConfigFile::locate(std::string& pathstr) {
return false;
}
-bool ConfigFile::read(const char *explicitConfFile, const char* section) {
+bool ConfigFile::read(const char *explicitConfFile, const char *section) {
std::string pathstr;
// explicitly provided by user in command line?
if (explicitConfFile) {
@@ -180,8 +181,9 @@ bool ConfigFile::read(const char *explicitConfFile, const char* section) {
if (sys::fs::exists(clPath)) {
pathstr = clPath;
} else {
- fprintf(stderr, "Warning: configuration file '%s' not found, falling "
- "back to default\n",
+ fprintf(stderr,
+ "Warning: configuration file '%s' not found, falling "
+ "back to default\n",
clPath.c_str());
}
}
diff --git a/driver/linker.cpp b/driver/linker.cpp
index 36199d5..bad8a3d 100644
--- a/driver/linker.cpp
+++ b/driver/linker.cpp
@@ -202,8 +202,8 @@ std::string getLTOdylibPath() {
void addDarwinLTOFlags(std::vector<std::string> &args) {
std::string dylibPath = getLTOdylibPath();
if (!dylibPath.empty()) {
- args.push_back("-lto_library");
- args.push_back(std::move(dylibPath));
+ args.push_back("-lto_library");
+ args.push_back(std::move(dylibPath));
}
}
@@ -356,13 +356,13 @@ static int linkObjToBinaryGcc(bool sharedLib) {
// additional linker and cc switches (preserve order across both lists)
for (unsigned ilink = 0, icc = 0;;) {
unsigned linkpos = ilink < opts::linkerSwitches.size()
- ? opts::linkerSwitches.getPosition(ilink)
- : std::numeric_limits<unsigned>::max();
+ ? opts::linkerSwitches.getPosition(ilink)
+ : std::numeric_limits<unsigned>::max();
unsigned ccpos = icc < opts::ccSwitches.size()
- ? opts::ccSwitches.getPosition(icc)
- : std::numeric_limits<unsigned>::max();
+ ? opts::ccSwitches.getPosition(icc)
+ : std::numeric_limits<unsigned>::max();
if (linkpos < ccpos) {
- const std::string& p = opts::linkerSwitches[ilink++];
+ const std::string &p = opts::linkerSwitches[ilink++];
// Don't push -l and -L switches using -Xlinker, but pass them indirectly
// via GCC. This makes sure user-defined paths take precedence over
// GCC's builtin LIBRARY_PATHs.
@@ -370,8 +370,8 @@ static int linkObjToBinaryGcc(bool sharedLib) {
// the linker and must be passed to the driver.
auto str = llvm::StringRef(p);
if (!(str.startswith("-l") || str.startswith("-L") ||
- str.startswith("-Wl,") ||
- str.startswith("-shared") || str.startswith("-static"))) {
+ str.startswith("-Wl,") || str.startswith("-shared") ||
+ str.startswith("-static"))) {
args.push_back("-Xlinker");
}
args.push_back(p);
@@ -616,7 +616,7 @@ static int linkObjToBinaryMSVC(bool sharedLib) {
args.push_back(str);
};
- for (const auto& str : opts::linkerSwitches) {
+ for (const auto &str : opts::linkerSwitches) {
addSwitch(str);
}
diff --git a/driver/toobj.cpp b/driver/toobj.cpp
index ff09cb6..8b96573 100644
--- a/driver/toobj.cpp
+++ b/driver/toobj.cpp
@@ -429,8 +429,7 @@ void writeModule(llvm::Module *m, const char *filename) {
// Use cached object code if possible.
// TODO: combine LDC's cache and LTO (the advantage is skipping the IR
// optimization).
- const bool useIR2ObjCache =
- !opts::cacheDir.empty() && outputObj && !doLTO;
+ const bool useIR2ObjCache = !opts::cacheDir.empty() && outputObj && !doLTO;
llvm::SmallString<32> moduleHash;
if (useIR2ObjCache) {
llvm::SmallString<128> cacheDir(opts::cacheDir.c_str());
diff --git a/gen/llvmhelpers.cpp b/gen/llvmhelpers.cpp
index 2245a51..1f6b3e4 100644
--- a/gen/llvmhelpers.cpp
+++ b/gen/llvmhelpers.cpp
@@ -71,8 +71,8 @@ bool isTargetWindowsMSVC() {
}
/******************************************************************************
-* Global context
-******************************************************************************/
+ * Global context
+ ******************************************************************************/
static llvm::ManagedStatic<llvm::LLVMContext> GlobalContext;
llvm::LLVMContext &getGlobalContext() { return *GlobalContext; }
@@ -1416,9 +1416,10 @@ bool isLLVMUnsigned(Type *t) { return t->isunsigned() || t->ty == Tpointer; }
void printLabelName(std::ostream &target, const char *func_mangle,
const char *label_name) {
- target << gTargetMachine->getMCAsmInfo()->getPrivateGlobalPrefix()
+ target << gTargetMachine->getMCAsmInfo()
+ ->getPrivateGlobalPrefix()
#if LDC_LLVM_VER >= 400
- .str()
+ .str()
#endif
<< func_mangle << "_" << label_name;
}
@@ -1619,9 +1620,9 @@ DValue *DtoSymbolAddress(Loc &loc, Type *type, Declaration *decl) {
fatal();
}
DtoResolveFunction(fdecl);
- return new DFuncValue(fdecl, fdecl->llvmInternal != LLVMva_arg
- ? DtoCallee(fdecl)
- : nullptr);
+ const auto llValue =
+ fdecl->llvmInternal != LLVMva_arg ? DtoCallee(fdecl) : nullptr;
+ return new DFuncValue(fdecl, llValue);
}
if (SymbolDeclaration *sdecl = decl->isSymbolDeclaration()) {
@@ -1657,8 +1658,9 @@ llvm::Constant *DtoConstSymbolAddress(Loc &loc, Declaration *decl) {
// needed for the current hacky implementation of
// AssocArrayLiteralExp::toElem, which requires on error
// gagging to check for constantness of the initializer.
- error(loc, "cannot use address of non-global variable '%s' "
- "as constant initializer",
+ error(loc,
+ "cannot use address of non-global variable '%s' as constant "
+ "initializer",
vd->toChars());
if (!global.gag) {
fatal();
@@ -1725,8 +1727,9 @@ llvm::GlobalVariable *getOrCreateGlobal(const Loc &loc, llvm::Module &module,
llvm::GlobalVariable *existing = module.getGlobalVariable(name, true);
if (existing) {
if (existing->getType()->getElementType() != type) {
- error(loc, "Global variable type does not match previous "
- "declaration with same mangled name: %s",
+ error(loc,
+ "Global variable type does not match previous declaration with "
+ "same mangled name: %s",
name.str().c_str());
fatal();
}
diff --git a/gen/modules.cpp b/gen/modules.cpp
index 04b8467..dd803a2 100644
--- a/gen/modules.cpp
+++ b/gen/modules.cpp
@@ -70,8 +70,9 @@ void Module::checkAndAddOutputFile(File *file) {
auto i = files.find(key);
if (i != files.end()) {
Module *previousMod = i->second;
- ::error(Loc(), "Output file '%s' for module '%s' collides with previous "
- "module '%s'. See the -oq option",
+ ::error(Loc(),
+ "Output file '%s' for module '%s' collides with previous "
+ "module '%s'. See the -oq option",
key.c_str(), toPrettyChars(), previousMod->toPrettyChars());
fatal();
}
@@ -290,7 +291,8 @@ llvm::Function *buildRegisterDSO(RegistryStyle style,
{
IRBuilder<> b(entryBB);
- const auto loadedFlag = b.CreateTrunc(b.CreateLoad(dsoInitialized), b.getInt1Ty());
+ const auto loadedFlag =
+ b.CreateTrunc(b.CreateLoad(dsoInitialized), b.getInt1Ty());
const auto condEval =
b.CreateICmp(llvm::ICmpInst::ICMP_EQ, loadedFlag, isShutdown);
b.CreateCondBr(condEval, initBB, endBB);
@@ -687,8 +689,7 @@ void registerModuleInfo(Module *m) {
const char *mangle = mangleBuf.peekString();
if (style == RegistryStyle::legacyLinkedList) {
- const auto miCtor =
- build_module_reference_and_ctor(mangle, moduleInfoSym);
+ const auto miCtor = build_module_reference_and_ctor(mangle, moduleInfoSym);
AppendFunctionToLLVMGlobalCtorsDtors(miCtor, 65535, true);
} else {
emitModuleRefToSection(style, mangle, moduleInfoSym);
diff --git a/gen/optimizer.cpp b/gen/optimizer.cpp
index a74d5d3..0a1ad15 100644
--- a/gen/optimizer.cpp
+++ b/gen/optimizer.cpp
@@ -133,10 +133,10 @@ bool willCrossModuleInline() {
#if LDC_LLVM_VER >= 307
return enableCrossModuleInlining == llvm::cl::BOU_TRUE;
#else
-// Cross-module inlining is disabled for <3.7 because we don't emit symbols in
-// COMDAT any groups pre-LLVM3.7. With cross-module inlining enabled, without
-// COMDAT any there are multiple-def linker errors when linking druntime.
-// See supportsCOMDAT().
+ // Cross-module inlining is disabled for <3.7 because we don't emit symbols in
+ // COMDAT any groups pre-LLVM3.7. With cross-module inlining enabled, without
+ // COMDAT any there are multiple-def linker errors when linking druntime.
+ // See supportsCOMDAT().
return false;
#endif
}
@@ -456,10 +456,9 @@ void verifyModule(llvm::Module *m) {
Logger::println("Verification passed!");
}
-// Output to `hash_os` all optimization settings that influence object code output
-// and that are not observable in the IR.
-// This is used to calculate the hash use for caching that uniquely identifies
-// the object file output.
+// Output to `hash_os` all optimization settings that influence object code
+// output and that are not observable in the IR. This is used to calculate the
+// hash use for caching that uniquely identifies the object file output.
void outputOptimizationSettings(llvm::raw_ostream &hash_os) {
hash_os << optimizeLevel;
hash_os << willInline();
diff --git a/gen/passes/GarbageCollect2Stack.cpp b/gen/passes/GarbageCollect2Stack.cpp
index a55c188..2ad8ee9 100644
--- a/gen/passes/GarbageCollect2Stack.cpp
+++ b/gen/passes/GarbageCollect2Stack.cpp
@@ -123,12 +123,11 @@ public:
Instruction *Begin = &(*BB.begin());
// FIXME: set alignment on alloca?
- return new AllocaInst(
- Ty,
+ return new AllocaInst(Ty,
#if LDC_LLVM_VER >= 500
- BB.getModule()->getDataLayout().getAllocaAddrSpace(),
+ BB.getModule()->getDataLayout().getAllocaAddrSpace(),
#endif
- ".nongc_mem", Begin);
+ ".nongc_mem", Begin);
}
explicit FunctionInfo(ReturnType::Type returnType) : ReturnType(returnType) {}
@@ -840,7 +839,8 @@ bool isSafeToStackAllocateArray(
/// the attribute has to be removed before promoting the memory to the
/// stack. The affected instructions are added to RemoveTailCallInsts. If
/// the function returns false, these entries are meaningless.
-bool isSafeToStackAllocate(BasicBlock::iterator Alloc, Value *V, DominatorTree &DT,
+bool isSafeToStackAllocate(BasicBlock::iterator Alloc, Value *V,
+ DominatorTree &DT,
SmallVector<CallInst *, 4> &RemoveTailCallInsts) {
assert(isa<PointerType>(V->getType()) && "Allocated value is not a pointer?");
diff --git a/gen/pgo.cpp b/gen/pgo.cpp
index 31f60b1..6333eb7 100644
--- a/gen/pgo.cpp
+++ b/gen/pgo.cpp
@@ -928,15 +928,17 @@ void CodeGenPGO::loadRegionCounts(llvm::IndexedInstrProfReader *PGOReader,
IF_LOG Logger::println(
"Ignoring profile data: hash mismatch for function: %s",
FuncName.c_str());
- warning(fd->loc, "Ignoring profile data for function '%s' ('%s'): "
- "control-flow hash mismatch",
+ warning(fd->loc,
+ "Ignoring profile data for function '%s' ('%s'): "
+ "control-flow hash mismatch",
const_cast<FuncDeclaration *>(fd)->toPrettyChars(),
FuncName.c_str());
} else if (IPE == llvm::instrprof_error::malformed) {
IF_LOG Logger::println("Profile data is malformed for function: %s",
FuncName.c_str());
- warning(fd->loc, "Ignoring profile data for function '%s' ('%s'): "
- "control-flow hash mismatch",
+ warning(fd->loc,
+ "Ignoring profile data for function '%s' ('%s'): "
+ "control-flow hash mismatch",
const_cast<FuncDeclaration *>(fd)->toPrettyChars(),
FuncName.c_str());
} else {
diff --git a/gen/runtime.cpp b/gen/runtime.cpp
index 5efc4ad..dafbbfe 100644
--- a/gen/runtime.cpp
+++ b/gen/runtime.cpp
@@ -96,8 +96,9 @@ static void checkForImplicitGCCall(const Loc &loc, const char *name) {
if (binary_search(&GCNAMES[0],
&GCNAMES[sizeof(GCNAMES) / sizeof(std::string)], name)) {
- error(loc, "No implicit garbage collector calls allowed with -nogc "
- "option enabled: %s",
+ error(loc,
+ "No implicit garbage collector calls allowed with -nogc "
+ "option enabled: %s",
name);
fatal();
}
@@ -305,8 +306,9 @@ static void buildRuntimeModule() {
//////////////////////////////////////////////////////////////////////////////
// Construct some attribute lists used below (possibly multiple times)
- AttrSet NoAttrs, Attr_NoAlias(NoAttrs, LLAttributeSet::ReturnIndex,
- llvm::Attribute::NoAlias),
+ AttrSet NoAttrs,
+ Attr_NoAlias(NoAttrs, LLAttributeSet::ReturnIndex,
+ llvm::Attribute::NoAlias),
Attr_NoUnwind(NoAttrs, LLAttributeSet::FunctionIndex,
llvm::Attribute::NoUnwind),
Attr_ReadOnly(NoAttrs, LLAttributeSet::FunctionIndex,
@@ -711,7 +713,8 @@ static void buildRuntimeModule() {
{objectTy});
// void _d_dso_registry(void* data)
- // (the argument is really a pointer to rt.sections_elf_shared.CompilerDSOData)
+ // (the argument is really a pointer to
+ // rt.sections_elf_shared.CompilerDSOData)
createFwdDecl(LINKc, voidTy, {"_d_dso_registry"}, {voidPtrTy});
//////////////////////////////////////////////////////////////////////////////
diff --git a/gen/toir.cpp b/gen/toir.cpp
index e155bb3..1dc45ee 100644
--- a/gen/toir.cpp
+++ b/gen/toir.cpp
@@ -1698,8 +1698,9 @@ public:
// struct invariants
else if (global.params.useInvariants && condty->ty == Tpointer &&
condty->nextOf()->ty == Tstruct &&
- (invdecl = static_cast<TypeStruct *>(condty->nextOf())
- ->sym->inv) != nullptr) {
+ (invdecl =
+ static_cast<TypeStruct *>(condty->nextOf())->sym->inv) !=
+ nullptr) {
Logger::print("calling struct invariant");
DtoResolveFunction(invdecl);
DFuncValue invfunc(invdecl, DtoCallee(invdecl), DtoRVal(cond));
@@ -2217,8 +2218,7 @@ public:
}
cval = DtoBitCast(cval, dgty->getContainedType(0));
- LLValue *castfptr =
- DtoBitCast(DtoCallee(fd), dgty->getContainedType(1));
+ LLValue *castfptr = DtoBitCast(DtoCallee(fd), dgty->getContainedType(1));
result = new DImValue(e->type, DtoAggrPair(cval, castfptr, ".func"));
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-d/ldc.git
More information about the pkg-d-commits
mailing list