2 Copyright 1988-2022 Free Software Foundation, Inc.
3 This is part of the GCC manual.
4 For copying conditions, see the copyright.rst file.
6 .. index:: GETCWD, system, working directory
10 GETCWD --- Get current working directory
11 ****************************************
13 .. function:: GETCWD(C)
15 Get current working directory.
18 The type shall be ``CHARACTER`` and of default kind.
21 (Optional) status flag. Returns 0 on success,
22 a system specific and nonzero error code otherwise.
31 .. code-block:: fortran
33 CALL GETCWD(C [, STATUS])
37 .. code-block:: fortran
40 CHARACTER(len=255) :: cwd