canonical / sqlair

Friendly type mapping for SQL databases
Apache License 2.0
17 stars 9 forks source link

Replace parseFullName with parseGoObject #19

Closed Aflynn50 closed 1 year ago

Aflynn50 commented 1 year ago

This PR replaces parseFullName with the more specific parseGoObject. Previously, parseFullName was intended for use parsing columns and go objects but we decided it made more sense to have two separate functions.

By using parseGoObject we can also be more specific with how we parse input expressions. We will parse an input expression as long as the character after the $ is a name byte. We ignore the character before the $.

The errors returned by parseInputExpression also now include an approximate position of the error. We intend to provide an approximate position for all errors in future PRs.