tursodatabase / libsql-shell-go

7 stars 7 forks source link

Fix/dont suggestion keyworks when everything is accepted #92

Closed luisfvieirasilva closed 1 year ago

luisfvieirasilva commented 1 year ago

Description

For the case select 1 from t<TAB> our autocompletion were suggesting all SQLite keywords that starts with t because SQLite accept everything as a table name. The solution is to find all rules that contains the last token,then we check if some rule is any_name, that is the rule that says "accept anything here". In this cases, we suggest nothing