Opened 6 years ago
Closed 6 years ago
#17995 closed enhancement (fixed)
[PATCH] Add sort method for mapcss
| Reported by: | taylor.smock | Owned by: | Don-vip |
|---|---|---|---|
| Priority: | normal | Milestone: | 19.08 |
| Component: | Core | Version: | |
| Keywords: | mapcss sort | Cc: |
Description
It would be good to have a sort implementation in order to stably compare lists.
For example,
way[ref][join(";", sort(parent_tags("ref"))) != join(";", sort(split(";", tag("ref"))))] { throwError: tr("Possible mismatched refs"); }
In this case, the first sort on the parent_tags isn't wholly necessary (documentation indicates that it is sorted), but in the second sort (for the ref on the way), it is necessary, since OSM contributors may add refs like ref=A9;A8;B42.
Attachments (4)
Change History (8)
by , 6 years ago
| Attachment: | 17995.patch added |
|---|
comment:1 by , 6 years ago
| Summary: | [PATCH] Add sort method for mapcss → [WIP PATCH] Add sort method for mapcss |
|---|
by , 6 years ago
| Attachment: | 17995.3.patch added |
|---|
Overload function so that it works with lists from other functions
by , 6 years ago
| Attachment: | 17995.4.patch added |
|---|
Use sort and sort_list to differentiate between a string array and a string list.
comment:2 by , 6 years ago
| Summary: | [WIP PATCH] Add sort method for mapcss → [PATCH] Add sort method for mapcss |
|---|
comment:3 by , 6 years ago
| Keywords: | sort added |
|---|---|
| Milestone: | → 19.08 |
| Owner: | changed from to |
| Status: | new → assigned |



Add mapcss sort method and test