它将进程 id 转换为列表。
语法
Pid_to_list(processid)
参数
processid −这是需要转换为列表的进程 id。
返回值
从进程 id 返回列表。
-module(helloworld).
-export([start/0, call/2]).
call(Arg1, Arg2) ->
io:format("~p ~p~n", [Arg1, Arg2]).
start() ->
Pid = spawn(?MODULE, call, ["hello", "process"]),
io:fwrite("~p~n",[pid_to_list(Pid)]).
当我们运行上面的程序时,我们将得到以下结果。
"<0.55.0>"
"hello" "process"
Erlang 进程 registered 方法 Erlang 分布式编程 spawn 节点方法
展开全部