On Fri, Sep 21, 2018 at 5:52 PM Andres Freund <andres@anarazel.de> wrote:
> Here's a very quick-and-dirty implementation of this approach. Some very
> very brief testing seems to indicate it works, although I'm sure not
> perfectly.
>
> The current duplication of the new functions doing the actual checking
> (like CheckMatchesFor(), CheckTailMatchesFor()) would probably need to
> be reduced. But I don't want to invest actual time before we decide that
> this could be something we'd actually want to pursue.
+1
And here is a quick-and-dirty variadic COMPLETE_WITH(...). Together:
else if (Matches("PREPARE", MatchAny, "AS"))
COMPLETE_WITH("SELECT", "UPDATE", "INSERT", "DELETE FROM");
+ * Making C pretty by making it ugly again.
Heh.
--
Thomas Munro
http://www.enterprisedb.com