-
Notifications
You must be signed in to change notification settings - Fork 3.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
36975: opt: remove top-level statement check, clean up pgerror APIs r=RaduBerinde a=RaduBerinde @knz I did some minor pgerror changes in the first commits. They are in this PR because without them, the last commit would cause error mismatches in some tests. #### pgerror: clean up API The various public-facing functions in pgerror have a number of inconsistencies: - some functions start with `New`, others don't - the `f` suffix isn't used consistently (like `Unimplemented`, which caused unnecessary `Sprintf`s in some callers) - some functions contain `Error`, others don't. This commit cleans this up: - we remove `Error` because it is redundant with the package name - we remove `New` for all wrappers - we make all wrappers have `f` and non-`f` versions. Release note: None #### pgerror: add `unimplemented:` consistently Some of the `Unimplemented*` functions prepend `unimplemented: ` and some don't. Making them all prepend it (leaving most usecases unchanged) Release note: None #### opt: remove top-level statement type check The planning code has a "fast path" to avoid using the optimizer if the top-level statement is not supported. This is no longer necessary because the optimizer implements all important statement types. This was shortcutting the recent work to use the optimizer for more statements. Release note: None Co-authored-by: Radu Berinde <radu@cockroachlabs.com>
- Loading branch information
Showing
263 changed files
with
1,388 additions
and
1,404 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.