Documentation for open_port/2

Kostis Sagonas kostis@REDACTED
Tue Feb 28 17:38:22 CET 2006


The documentation of erlang:open_port/2 reads:

------------------------------------------------------------
open_port(PortName, PortSettings) -> port()

Types:

PortName = {spawn, Command} | {fd, In, Out}
 Command = string()
 In = Out = int()
PortSettings = [Opt]
 Opt = {packet, N} | stream | {line, L} | {cd, Dir} | {env, Env} | exit_status | use_stdio | nouse_stdio | stderr_to_stdout | in | out | binary | eof
  N = 1 | 2 | 4
  L = int()
  Dir = string()
  Env = [{Name, Val}]
   Name = string()
   Val = string() | false
------------------------------------------------------------

Which of the "string()" above should read "atom()"  ?

Can they be used interchangeably?

Kostis




More information about the erlang-questions mailing list