Issue #131 - add documented `lint` function for use by editors/IDEs

It returns a map with data about warnings, rather than formatted
strings that combine everything and require parsing to split it up.