Skip to content

Commit 642859f

Browse files
Use // + #if 0/#endif to comment out a block of code.
Per the LLVM comment formatting guidelines.
1 parent 7c60d54 commit 642859f

File tree

2 files changed

+7
-6
lines changed

2 files changed

+7
-6
lines changed

Diff for: lib/IRGen/TypeLayoutVerifier.cpp

+3-3
Original file line numberDiff line numberDiff line change
@@ -149,8 +149,8 @@ irgen::emitTypeLayoutVerifier(IRGenFunction &IGF,
149149

150150
// Verify that the extra inhabitant representations are consistent.
151151

152-
/* TODO: Update for EnumPayload implementation changes.
153-
152+
// TODO: Update for EnumPayload implementation changes.
153+
#if 0
154154
auto xiBuf = IGF.createAlloca(fixedTI->getStorageType(),
155155
fixedTI->getFixedAlignment(),
156156
"extra-inhabitant");
@@ -212,7 +212,7 @@ irgen::emitTypeLayoutVerifier(IRGenFunction &IGF,
212212
llvm::Twine("extra inhabitant index calculation ")
213213
+ numberBuf.str());
214214
}
215-
*/
215+
#endif
216216
}
217217

218218
// TODO: Verify interesting layout properties specific to the kind of type,

Diff for: lib/SIL/Verifier.cpp

+4-3
Original file line numberDiff line numberDiff line change
@@ -1677,16 +1677,17 @@ class SILVerifier : public SILVerifierBase<SILVerifier> {
16771677
|| !isa<ExtensionDecl>(CMI->getMember().getDecl()->getDeclContext()),
16781678
"extension method cannot be dispatched natively");
16791679

1680-
/* TODO: We should enforce that ObjC methods are dispatched on ObjC
1681-
metatypes, but IRGen appears not to care right now.
1680+
// TODO: We should enforce that ObjC methods are dispatched on ObjC
1681+
// metatypes, but IRGen appears not to care right now.
1682+
#if 0
16821683
if (auto metaTy = operandType.getAs<AnyMetatypeType>()) {
16831684
bool objcMetatype
16841685
= metaTy->getRepresentation() == MetatypeRepresentation::ObjC;
16851686
bool objcMethod = CMI->getMember().isForeign;
16861687
require(objcMetatype == objcMethod,
16871688
"objc class methods must be invoked on objc metatypes");
16881689
}
1689-
*/
1690+
#endif
16901691
}
16911692

16921693
void checkSuperMethodInst(SuperMethodInst *CMI) {

0 commit comments

Comments
 (0)