Skip to content

Commit d9cf437

Browse files
committed
[AddressLowering] NFC: Added const variant.
Of existing function getProjectedStorage.
1 parent e3428ae commit d9cf437

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

lib/SILOptimizer/Mandatory/AddressLowering.h

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -265,6 +265,12 @@ class ValueStorageMap {
265265
/// Given storage for a projection, return the projected storage by following
266266
/// single level of projected storage. The returned storage may
267267
/// recursively be a another projection.
268+
const ValueStoragePair &
269+
getProjectedStorage(const ValueStorage &storage) const {
270+
assert(storage.isProjection());
271+
return valueVector[storage.projectedStorageID];
272+
}
273+
268274
ValueStoragePair &getProjectedStorage(const ValueStorage &storage) {
269275
assert(storage.isProjection());
270276
return valueVector[storage.projectedStorageID];

0 commit comments

Comments
 (0)