[flang] Work around clang-format issue by using "auto" where type is obvious.
authorpeter klausler <pklausler@nvidia.com>
Mon, 2 Apr 2018 17:59:42 +0000 (10:59 -0700)
committerpeter klausler <pklausler@nvidia.com>
Mon, 2 Apr 2018 18:01:31 +0000 (11:01 -0700)
Original-commit: flang-compiler/f18@7499bccaa938547d3af29c7b859f1fede2e718be
Reviewed-on: https://github.com/flang-compiler/f18/pull/38
Tree-same-pre-rewrite: false

flang/lib/parser/parse-tree.cc

index ebd9425..ee402fe 100644 (file)
@@ -30,7 +30,7 @@ ProcedureDesignator Designator::ConvertToProcedureDesignator() {
       visitors{
           [](ObjectName &n) -> ProcedureDesignator { return {std::move(n)}; },
           [](DataReference &dr) -> ProcedureDesignator {
-            if (Name * n{std::get_if<Name>(&dr.u)}) {
+            if (auto n = std::get_if<Name>(&dr.u)) {
               return {std::move(*n)};
             }
             StructureComponent &sc{