Skip to content

Commit dd81583

Browse files
committed
[Parse] Fix a couple typos in PR #12964
1 parent a2ff7f3 commit dd81583

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

lib/Basic/LangOptions.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -263,7 +263,7 @@ std::pair<bool, bool> LangOptions::setTarget(llvm::Triple triple) {
263263
addPlatformConditionValue(PlatformConditionKind::Runtime, "_Native");
264264

265265
// Set the "targetEnvironment" platform condition if targeting a simulator
266-
// environmet. Otherwise _no_ value is present for targetEnvironment; it's
266+
// environment. Otherwise _no_ value is present for targetEnvironment; it's
267267
// an optional disambiguating refinement of the triple.
268268
if (swift::tripleIsAnySimulator(Target))
269269
addPlatformConditionValue(PlatformConditionKind::TargetEnvironment,

lib/Parse/ParseIfConfig.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -550,7 +550,7 @@ static bool isVersionIfConfigCondition(Expr *Condition) {
550550
/// Get the identifier string from an \c Expr if it's an
551551
/// \c UnresolvedDeclRefExpr, otherwise the empty string.
552552
static StringRef getDeclRefStr(Expr *E) {
553-
if (auto *UDRE = cast<UnresolvedDeclRefExpr>(E)) {
553+
if (auto *UDRE = dyn_cast<UnresolvedDeclRefExpr>(E)) {
554554
return UDRE->getName().getBaseIdentifier().str();
555555
}
556556
return "";

0 commit comments

Comments
 (0)