The lingua franca of LaTeX
Random LaTeX question: Does anyone have any tips for writing LaTeX code to avoid typos or other mistakes? I.e., using the fact that LaTeX is a programming language and not just markup language to catch mistakes?<p>I started adding what basically are assertions to my TeX files. These have caught a fair number of errors. I also periodically run &quot;static analysis&quot; scripts to catch writing and coding errors but these tends to have many false positives in my experience. E.g., chktex and these: <a href="http:&#x2F;&#x2F;matt.might.net&#x2F;articles&#x2F;shell-scripts-for-passive-voice-weasel-words-duplicates&#x2F;" rel="nofollow">http:&#x2F;&#x2F;matt.might.net&#x2F;articles&#x2F;shell-scripts-for-passive-voi...</a><p>But I&#x27;m thinking there may be good coding styles or habits that could prevent errors too. Any ideas?