<div dir="ltr">Why are you trying to monitor with B.  Why not just do:<br><br><div>test() -></div><div>    x(),<br></div><div>   do_something(),<br></div><div>    y(),</div><div>    z().<br><br></div><div>-wes<br></div>
<br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Thu, Oct 10, 2013 at 2:02 AM, Tyron Zerafa <span dir="ltr"><<a href="mailto:tyron.zerafa@gmail.com" target="_blank">tyron.zerafa@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi,<div>  </div><div>    I would like to monitor a process and suspend the execution of certain functions to perform some other computation before. For instance consider a process A which executing the following simple function.</div>

<div><br></div><div>test() -></div><div>    x(),</div><div>    y(),</div><div>    z().</div><div><br></div><div>I would like to initiate a process, B, that monitors the execution of A. </div><div>I want B to:</div><div>

  1) stop A before function y is executed</div><div>  2) execute some logic</div><div>  3) resumes the execution of A (by executing Y and Z)</div><div><br></div><div>So far, I have been following <a href="http://erlang.org/pipermail/erlang-questions/2003-January/006679.html" target="_blank">this post</a> and managed to determine when the y() function call was being done, but cannot suspend its execution. Any ideas how I can achieve this? </div>

<div><br></div><div>Thanks</div><span class="HOEnZb"><font color="#888888"><div>Tyron<br></div></font></span></div>
<br>_______________________________________________<br>
erlang-questions mailing list<br>
<a href="mailto:erlang-questions@erlang.org">erlang-questions@erlang.org</a><br>
<a href="http://erlang.org/mailman/listinfo/erlang-questions" target="_blank">http://erlang.org/mailman/listinfo/erlang-questions</a><br>
<br></blockquote></div><br></div>