summaryrefslogtreecommitdiff
path: root/spm-slides.tex
diff options
context:
space:
mode:
authorHui Lan <lanhui@zjnu.edu.cn>2019-05-07 09:00:58 +0800
committerHui Lan <lanhui@zjnu.edu.cn>2019-05-07 09:00:58 +0800
commit5548190bac15a87c00ba59b01e764548275366fc (patch)
treebeb00af60176ea347eb13bd6fee273ce947ec670 /spm-slides.tex
parent2ef2273e8974013ad43b3caaa5e5389466e141cf (diff)
Add an example of insufficient comments from Jin Xiongrong and Xu Yuze code.
Diffstat (limited to 'spm-slides.tex')
-rw-r--r--spm-slides.tex10
1 files changed, 10 insertions, 0 deletions
diff --git a/spm-slides.tex b/spm-slides.tex
index b86316d..9e64b63 100644
--- a/spm-slides.tex
+++ b/spm-slides.tex
@@ -833,6 +833,16 @@ catch: memory leaks, off-by-one errors, insufficient comments,
insufficient API documentation, security vulnerabilities, compliments
...
+Example of insufficient comments:
+
+{\small
+\begin{verbatim}
+ for item in A.iter(sentence):
+ return True
+ return False
+\end{verbatim}
+}
+
{\bf Important} to have more eyeballs.