docs: public boolean isLeavingCurrentStreet(String prevName, String name) {
          if (InstructionsHelper.isNameSimilar(name, prevName)) {
              return false;
          }
  
          // If flags are changing, there might be a chance we find these flags on a different edge
          boolean checkFlag = currentEdge.getFlags() != prevEdge.getFlags();
          for (EdgeIteratorState edge : allowedOutgoingEdges) {
              String edgeName = edge.getName();
              IntsRef edgeFlag = edge.getFlags();
              // leave the current street || enter a different street
              if (isTheSameStreet(prevName, prevEdge.getFlags(), edgeName, edgeFlag, checkFlag)
                      || isTheSameStreet(name, currentEdge.getFlags(), edgeName, edgeFlag, checkFlag)) {
                  return true;
              }
          }
          return false;
      }