HomePhabricator

[NFC][DA] Remove duplicate code in checkSrcSubscript and checkDstSubscript

Authored by dancgr on Dec 27 2019, 7:05 AM.

Description

[NFC][DA] Remove duplicate code in checkSrcSubscript and checkDstSubscript

Summary:
[DA] Move common code in checkSrcSubscript and checkDstSubscript to a
new function checkSubscript. This avoids duplicate code and possible
out of sync in the future.

Reviewers: sebpop, jmolloy, reames

Reviewed By: sebpop

Subscribers: bmahjour, hiraditya, llvm-commits, amehsan

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D71087

Patch by zhongduo.

Details