<p dir="ltr" style="margin-top:0; margin-bottom:0;">You should however avoid to use process dictionaries if possible. </p>
<p dir="ltr" style="margin-top:0; margin-bottom:0;">It is handy to store things, but generally a sign that your code is missing something. </p>
<br>
<p dir="ltr" style="margin-top:0; margin-bottom:0;">For instance if you face some processes crashes, your process dictionary will be lost, while using states in OTP libs will be shown in crash report. Easier for debugging. </p>
<br>
<p dir="ltr" style="margin-top:0; margin-bottom:0;">Regards </p>
<br>
<p dir="ltr" style="margin-top:0; margin-bottom:0;">Envoyé depuis mon mobile </p><br><br>---- Donald Steven a écrit ----<br><br>
Merci Eric!<br>
<br>
<div class="moz-cite-prefix">On 12/22/2018 8.56 AM, Eric Pailleau
wrote:<br>
</div>
<blockquote type="cite"
cite="mid:0qiisqlqeps1llqk4mn9qnav.1545486989861@email.android.com">
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<p dir="ltr" style="margin-top:0; margin-bottom:0;">Hi, </p>
<p dir="ltr" style="margin-top:0; margin-bottom:0;">Process
dictionary is a dictionary for a process. </p>
<p dir="ltr" style="margin-top:0; margin-bottom:0;">If you call
each functions from different processes, they are independents.
</p>
<p dir="ltr" style="margin-top:0; margin-bottom:0;">From a single
process two functions cannot be called at same time. </p>
<br>
<p dir="ltr" style="margin-top:0; margin-bottom:0;">Envoyé depuis
mon mobile </p>
<br>
<br>
---- Donald Steven a écrit ----<br>
<br>
Do two function calls with the same name but one parameter
different <br>
<br>
(see below) share access to the same process dictionary or does
each <br>
<br>
have a distinct instance?<br>
<br>
<br>
<br>
<br>
<br>
Example:<br>
<br>
<br>
<br>
<br>
<br>
funA(param1, param2) -> do something.<br>
<br>
<br>
<br>
funA(param1, differentparam2) -> do something different.<br>
<br>
<br>
<br>
<br>
<br>
===<br>
<br>
<br>
<br>
<br>
<br>
I could just use an if statement within one function call, but I'd
like <br>
<br>
to know if they share the same process dictionary. Thanks.<br>
<br>
<br>
<br>
_______________________________________________<br>
<br>
erlang-questions mailing list<br>
<br>
<a href="mailto:erlang-questions@erlang.org"
moz-do-not-send="true">erlang-questions@erlang.org</a><br>
<br>
<a href="http://erlang.org/mailman/listinfo/erlang-questions"
moz-do-not-send="true">http://erlang.org/mailman/listinfo/erlang-questions</a><br>
<br>
</blockquote>
<br>