The Problem with Macros
May be unrelated, but that&#x27;s why I prefer the way JS approach this kind of problem: JS doesn&#x27;t have macros.<p>People use callback function to achieve almost the same thing<p><pre><code>  function doTexture(texture, fn) {
    beginTextureMode(texture)
    fn()
    endTextureMode()
  }
  
  doTexture(myTexture, () =&gt; {
    drawCircle()
    drawRectagle()
  })
</code></pre>
At the cost of being more verbose, we get the benefit of one thing less to learn; and simplicity is a powerful feature IMO.<p>I guess why this is less popular in lispy languages is because<p><pre><code>  1. macro
  2. callback functions introduce more indent levels :(</code></pre>