[flang-commits] [flang] [llvm] [flang] Implement external routine usage of hostnm() (PR #134900)

Eugene Epshteyn via flang-commits flang-commits at lists.llvm.org
Tue Apr 8 14:33:03 PDT 2025


================
@@ -264,6 +264,38 @@ int RTNAME(Chdir)(const char *name) {
 #endif
 }
 
+int FORTRAN_PROCEDURE_NAME(hostnm)(char *hn, int length) {
+  std::int32_t status{0};
+
+  if (!hn || length < 0) {
+    return EINVAL;
----------------
eugeneepshteyn wrote:

Yes and I already used it in `putenv` implementation

https://github.com/llvm/llvm-project/pull/134900


More information about the flang-commits mailing list