<html>
  <head>
    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <div class="moz-cite-prefix">On 09/25/2017 10:16 PM, dploop wrote:<br>
    </div>
    <blockquote cite="mid:2017092613160028835810@163.com" type="cite">
      <meta http-equiv="content-type" content="text/html; charset=utf-8">
      <style>body { line-height: 1.5; }blockquote { margin-top: 0px; margin-bottom: 0px; margin-left: 0.5em; }div.foxdiv20170926130500390717 { }body { font-size: 10.5pt; font-family: 微软雅黑; color: rgb(0, 0, 0); line-height: 1.5; }</style>
      <div><span style="font-size: 10.5pt; line-height: 1.5;
          background-color: window;">> "</span><span
          style="font-size: 10.5pt; line-height: 1.5; background-color:
          window;">Obsessing over a rocket shape doesn't seem as
          important as the absence of any guard expression usage here. 
          Guards are unfortunately often ignored by Erlang programmers,
          though they are the one thing in Erlang without side-effects."</span></div>
      <div><span style="font-size: 10.5pt; line-height: 1.5;
          background-color: window;"><br>
        </span></div>
      <div><span style="font-size: 10.5pt; line-height: 1.5;
          background-color: window;">is_integer, is_zero is just a
          simplified example, and by coincidence, they can use in the
          guard. But in most situations you can't use guard, for example
          in game industry when player want to buy equipment, you should
          check if his coin is sufficient, and then you should check the
          number of equipment is right and then you  should check if the
          equipment is valid to exchange and so on. The complex business
          logic can't be easily solved by guard, and Nested Cases is
          inevitable.</span></div>
    </blockquote>
    <br>
    Complex business logic can be solved by guard expressions and the
    only potential difference is declaring more variables or more
    function clauses, depending on how the problem is abstracted. 
    Guards are specifically for logic, so why not use them to express
    that logic?
  </body>
</html>