davidje13 / SequenceDiagram

Javascript tool for generating sequence diagrams from code
https://sequence.davidje13.com/
GNU Lesser General Public License v3.0
123 stars 39 forks source link

Malformed autolabel can render as "NaN" #48

Closed davidje13 closed 6 years ago

davidje13 commented 6 years ago

The following code will render an auto-incrementing number as "NaN":

autolabel "<inc oops> <label>"
A -> B

This should be rejected by the parser. The same issue applies to the increment amount:

autolabel "<inc 1,oops> <label>"
A -> B
B -> A

And in particular, this causes <inc 1 1> (a mistype of <inc 1,1>, but perhaps a format which should be allowed) to be rendered incorrectly.