I have a 20-30 line C++ function which was taking a reference to an `int` for possible updation. Now I am replacing the member which was passed to it with a member of a member encapsulating more data, something like:

```
searchState.matchedOK = specificSearch(*pageIndices.GetStringIByRef(), searchState); //new, and overwritten.
searchState.matchedOK = specificSearch(pageOffsetInText, searchState); //old

```

I want to localise this modification to the lines and function called above because the old member should be removed once I have verified equivalence and beyond.

Is this possible with simple casts?

If you want code:

```
static bool specificSearch(int &matchLocation, const SearchSpecs &specs) {/**/}

```

and the recently added member:

```
inline unsigned int *GetStringIByRef() {return &stringI;}

```