cse15l-lab-reports

Lab Report Week 3-4

Code Change 1

1. The screenshot of the code change diff from Github

2022-01-28 (2)

https://github.com/HuimengLu/markdown-parse/blob/main/another-file.md

3. The symptom of that failure-inducing input

2022-01-28 (6)

4. the relationship between the bug, the symptom, and the failure-inducing input

Before the change, the bug is that as long as there is no bracket, the program will produce an error and stop functioning (which is symptom here). So I added a no-bracket detector here. When no bracket is detected, the loop breaks, but the program will still function normally.

Code Change 2

1. The screenshot of the code change diff from Github

2022-01-28 (3)

https://github.com/HuimengLu/markdown-parse/blob/main/new-markdown.md

3. The symptom of that failure-inducing input

2022-01-28 (7)

4. the relationship between the bug, the symptom, and the failure-inducing input

Before the change, the bug is that as long as there is no parenthese, the program will produce an error and stop functioning (which is symptom here). So I added a no-parenthese detector here. When no parenthese is detected, the loop breaks, but the program will still function normally.

Code Change 3

1. The screenshot of the code change diff from Github

2022-01-28 (4)

https://github.com/HuimengLu/markdown-parse/blob/main/one-more.md

3. The symptom of that failure-inducing input

2022-01-28 (8)

4. the relationship between the bug, the symptom, and the failure-inducing input

The symptom here is that [This is not a link]random words(httplink! some-page) is not a valid URL, but the program printed it out. The bug is that even if the brackets and the parentheses are seperated by words, the program still views it as an URL. We fixed the bug by adding a space-detector between the brackets and the parentheses.