1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
//
// GENERATED FILE
//
use super::*;
use f2rust_std::*;
const CMDLEN: i32 = 255;
//$Procedure EDTCMD ( Edit a file using a specified text editor )
pub fn EDTCMD(CMD: &[u8], FILE: &[u8], ctx: &mut Context) -> f2rust_std::Result<()> {
let mut LOCCMD = [b' '; CMDLEN as usize];
//
// SPICELIB functions
//
//
// Local parameters
//
//
// Local variables
//
//
// Standard SPICE error handling.
//
if spicelib::RETURN(ctx) {
return Ok(());
} else {
spicelib::CHKIN(b"EDTCMD", ctx)?;
}
//
//
// SUN:
//
// Computer: Sun SPARCstation 2
// Operating System: Sun OS 4.1.2
// Fortran: Sun FORTRAN 1.3.1
//
// HP:
//
// Computer: HP 715/50
// Operating System: HP-UX 9.01
// Fortran: HP-UX.09.00.24
// HP-UX FORTRAN/9000
// Series 700 B2408A.09.00
// Series 800 B2409B.09.00
//
// NEXT:
//
// Computer: NeXT
// Operating System: NeXtStep 3.0, 3.2
// Fortran: Absoft Fortran V3.2
// NEXT (NeXT 3.0, Absoft Fortran 3.2):
//
// Computer: Alpha/OSF1
// Operating System: OSF1 V3.2
// Fortran: : DEC Fortran Compiler Driver V3.5-053
//
//
// Build the edit command to be passed to the system.
//
fstr::assign(&mut LOCCMD, CMD);
spicelib::SUFFIX(FILE, 1, &mut LOCCMD);
//
// For safety, append a null to the command. If the user has
// linked to a C version of the "system" function, this may
// save us much grief.
//
spicelib::SUFFIX(&intrinsics::CHAR(0), 0, &mut LOCCMD);
//
// Invoke the editor.
//
EXESYS(fstr::substr(&LOCCMD, 1..=spicelib::RTRIM(&LOCCMD)), ctx)?;
spicelib::CHKOUT(b"EDTCMD", ctx)?;
Ok(())
}