[PATCH] D111392: [flang] Add runtime interface for GET_ENVIRONMENT_VARIABLE
Diana Picus via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Oct 12 01:30:39 PDT 2021
This revision was automatically updated to reflect the committed changes.
Closed by commit rG02602c02a301: [flang] Add runtime interface for GET_ENVIRONMENT_VARIABLE (authored by rovka).
Changed prior to commit:
https://reviews.llvm.org/D111392?vs=378143&id=378917#toc
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D111392/new/
https://reviews.llvm.org/D111392
Files:
flang/include/flang/Runtime/command.h
Index: flang/include/flang/Runtime/command.h
===================================================================
--- flang/include/flang/Runtime/command.h
+++ flang/include/flang/Runtime/command.h
@@ -35,6 +35,21 @@
// Try to get the significant length of the n'th argument.
// Returns 0 if it doesn't manage.
std::int64_t RTNAME(ArgumentLength)(std::int32_t n);
+
+// 16.9.84 GET_ENVIRONMENT_VARIABLE
+// We're breaking up the interface into several different functions, since most
+// of the parameters are optional.
+
+// Try to get the value of the environment variable specified by NAME.
+// Returns a STATUS as described in the standard.
+std::int32_t RTNAME(EnvVariableValue)(const Descriptor &name,
+ const Descriptor *value = nullptr, bool trim_name = true,
+ const Descriptor *errmsg = nullptr);
+
+// Try to get the significant length of the environment variable specified by
+// NAME. Returns 0 if it doesn't manage.
+std::int64_t RTNAME(EnvVariableLength)(
+ const Descriptor &name, bool trim_name = true);
}
} // namespace Fortran::runtime
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D111392.378917.patch
Type: text/x-patch
Size: 1070 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20211012/12b58585/attachment.bin>
More information about the llvm-commits
mailing list