[ObjC Availability] Add missing const to getVersion function of ObjCAvailabilityCheckExpr class

Add missing const to `getVersion` function of `ObjCAvailabilityCheckExpr` class.

This feels like a bug on the original change D22171. We cannot really call this function from a const object pointer because the function is not marked as const.

This diff adds the missing const specifier to fix the issue.

Reviewed By: manmanren

Differential Revision: https://reviews.llvm.org/D112119
This commit is contained in:
Chaoshuai Lu 2022-01-24 14:51:37 -08:00 committed by Kyungwoo Lee
parent fe0c5309c4
commit f1c9e7bdc9
1 changed files with 1 additions and 1 deletions

View File

@ -1706,7 +1706,7 @@ public:
/// This may be '*', in which case this should fold to true.
bool hasVersion() const { return !VersionToCheck.empty(); }
VersionTuple getVersion() { return VersionToCheck; }
VersionTuple getVersion() const { return VersionToCheck; }
child_range children() {
return child_range(child_iterator(), child_iterator());