List<LocationMemento> getPreviousLocations() {
			List<LocationMemento> previousLocations = new ArrayList<>();
			for (int i = 0; i < currentLocation; i++) {
				previousLocations.add(list.get(i));
			}
			Collections.reverse(previousLocations);
			return previousLocations;
		}
Find the previous history LocationMemento that contains a different function. If no such
LocationMemento is found, null is returned.

@param navigatable the navigatable being navigated
@param moveTo true means after finding, get current location to it. false to just find
           and do nothing
@return previous LocationMemento, or null if no previous function found
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/core/navigation/NavigationHistoryPlugin.java