Skip to content

Commit 2005065

Browse files
committed
improve docs
1 parent f2acfda commit 2005065

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

doc/specs/stdlib_system.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -654,26 +654,26 @@ Experimental
654654

655655
### Description
656656

657-
It gets the current working directory associated with the process calling this subroutine.
657+
This subroutine retrieves the current working directory, the running process is executing from.
658658
It is designed to work across multiple platforms. On Windows, paths with both forward `/` and backward `\` slashes are accepted.
659659

660660
### Syntax
661661

662-
`call [[stdlib_system(module):get_cwd(subroutine)]] (cwd, err)`
662+
`call [[stdlib_system(module):get_cwd(subroutine)]] (cwd [, err])`
663663

664664
### Class
665665

666666
Subroutine
667667

668668
### Arguments
669669

670-
`cwd`: Shall be a character string containing the path of the current working directory (cwd). It is an `intent(out)` argument.
670+
`cwd`: Shall be a character string for receiving the path of the current working directory (cwd). It is an `intent(out)` argument.
671671

672-
`err`: Shall be of type `state_type`, for error handling. It is an `intent(out)` argument.
672+
`err`(optional): Shall be of type `state_type`, and is used for error handling. It is an `intent(out)` argument.
673673

674674
### Return values
675675

676-
The `err` is set accordingly.
676+
`err` is an optional state return flag. On error if not requested, an `FS_ERROR` will trigger an error stop.
677677

678678
### Example
679679

@@ -691,12 +691,12 @@ Experimental
691691

692692
### Description
693693

694-
It sets the current working directory associated with the process calling this subroutine.
694+
This subrotine sets the current working directory the process is executing from.
695695
It is designed to work across multiple platforms. On Windows, paths with both forward `/` and backward `\` slashes are accepted.
696696

697697
### Syntax
698698

699-
`call [[stdlib_system(module):set_cwd(subroutine)]] (path, err)`
699+
`call [[stdlib_system(module):set_cwd(subroutine)]] (path [, err])`
700700

701701
### Class
702702

@@ -706,11 +706,11 @@ Subroutine
706706

707707
`path`: Shall be a character string containing the path of the directory. It is an `intent(in)` argument.
708708

709-
`err`: Shall be of type `state_type`, for error handling. It is an `intent(out)` argument.
709+
`err`(optional): Shall be of type `state_type`, and is used for error handling. It is an `intent(out)` argument.
710710

711711
### Return values
712712

713-
The `err` is set accordingly.
713+
`err` is an optional state return flag. On error if not requested, an `FS_ERROR` will trigger an error stop.
714714

715715
### Example
716716

0 commit comments

Comments
 (0)