Fix crash when bond tenor length is 0
make the error message more clear.
Minor formatting issues (indentation etc).
Remove unused, commented-out code.
Merge pull request #164.