You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For every AltLabel in every point not matching a primary waypoint label (most of the time) in every valid region/highway combo in every .list, we smash case 3 times:
.lower() to compare to list labels
.upper() to add to labels_in_use
.upper() to check membership in unused_alt_labels & remove/erase
.upper() all alt_labels at once during Waypoint construction
.strip('+') here too
populate unused alt labels: don't smash case or .strip('+') anymore
clean up alt_labels handling in TravelerList ctor
.upper() all alt_route_names at once during Route construction
don't smash case in TravelerList ctor (one line above Note: deprecated route name)
clean up DUPLICATE_LABEL datacheck
similarly .lower() root during Route construction
make sure not lowered again during root_hash insertion
.lower() all roots at once during ConnectedRoute construction
change .lower() to .upper() as appropriate (not roots) globally
Similarly:
Another idea that may help speed up .list processing:
Store an upper_label pre-stripped of leading + or * characters for each Waypoint upon construction, to avoid having to repeat this process every time we iterate through a route for a valid region/highway combo. Maybe this is a bit rich for my blood though, if the eventual idea is to implement hash tables for waypoint labels? #278.
For every AltLabel in every point not matching a primary waypoint label (most of the time) in every valid region/highway combo in every .list, we smash case 3 times:
labels_in_useunused_alt_labels& remove/eraseRemoving this redundancy can gain us some efficiency and clean up the code pending hash tables for waypoint labels? #278.
Similarly, for every valid region/highway combo, we smash case on all
alt_route_namesuntil we matchroute_entry.Removing this redundancy can gain us some efficiency and clean up the code pending Output log for unused altRouteNames #230.
To be addressed in tandem with #316.
ToDo:
alt_labelsat once during Waypoint constructionalt_labelshandling in TravelerList ctoralt_route_namesat once during Route constructionNote: deprecated route name)rootduring Route constructionroot_hashinsertionrootsat once during ConnectedRoute constructionSimilarly:
Another idea that may help speed up .list processing:
upper_labelpre-stripped of leading+or*characters for each Waypoint upon construction, to avoid having to repeat this process every time we iterate through a route for a valid region/highway combo.Maybe this is a bit rich for my blood though, if the eventual idea is to implement hash tables for waypoint labels? #278.