We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fa82965 commit 41e14edCopy full SHA for 41e14ed
lib/SIL/SILVerifier.cpp
@@ -4004,6 +4004,13 @@ class SILVerifier : public SILVerifierBase<SILVerifier> {
4004
require(!(isa<MethodInst>(branchArg) &&
4005
cast<MethodInst>(branchArg)->getMember().isForeign),
4006
"branch argument cannot be a witness_method or an objc method_inst");
4007
+ require(!(branchArg->getType().is<SILFunctionType>() &&
4008
+ branchArg->getType()
4009
+ .castTo<SILFunctionType>()
4010
+ ->getExtInfo()
4011
+ .getRepresentation() ==
4012
+ SILFunctionTypeRepresentation::ObjCMethod),
4013
+ "branch argument cannot be a objective-c method");
4014
return branchArg->getType() == bbArg->getType();
4015
}
4016
0 commit comments