aboutsummaryrefslogtreecommitdiff
path: root/src/io.cpp
diff options
context:
space:
mode:
authorEven Rouault <even.rouault@spatialys.com>2018-12-04 16:22:44 +0100
committerEven Rouault <even.rouault@spatialys.com>2018-12-04 17:05:32 +0100
commit57b00a63c6caee1a53961d542904f7c9b1f014c9 (patch)
tree599ca27d29cda4519687ca324f96b2662ba456f9 /src/io.cpp
parentd06c1c55c1c3fc7209abdbdfbf2e3cf34f18cf98 (diff)
downloadPROJ-57b00a63c6caee1a53961d542904f7c9b1f014c9.tar.gz
PROJ-57b00a63c6caee1a53961d542904f7c9b1f014c9.zip
Improve management of 'deprecated' suffix in object names
Diffstat (limited to 'src/io.cpp')
-rw-r--r--src/io.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/io.cpp b/src/io.cpp
index e0f74f10..f396f1df 100644
--- a/src/io.cpp
+++ b/src/io.cpp
@@ -1449,6 +1449,10 @@ PropertyMap &WKTParser::Private::buildProperties(const WKTNodeNNPtr &node) {
if (!nodeChildren.empty()) {
const auto &nodeName(nodeP->value());
auto name(stripQuotes(nodeChildren[0]));
+ if (ends_with(name, " (deprecated)")) {
+ name.resize(name.size() - strlen(" (deprecated)"));
+ properties->set(common::IdentifiedObject::DEPRECATED_KEY, true);
+ }
const char *tableNameForAlias = nullptr;
if (ci_equal(nodeName, WKTConstants::GEOGCS)) {