iffyio commented on code in PR #1483:
URL: 
https://github.com/apache/datafusion-sqlparser-rs/pull/1483#discussion_r1820110841


##########
src/dialect/postgresql.rs:
##########
@@ -230,15 +230,18 @@ pub fn parse_comment(parser: &mut Parser) -> 
Result<Statement, ParserError> {
 }
 
 pub fn parse_create(parser: &mut Parser) -> Option<Result<Statement, 
ParserError>> {
-    let name = parser.maybe_parse(|parser| -> Result<ObjectName, ParserError> {
+    if let Ok(name) = parser.maybe_parse(|parser| -> Result<ObjectName, 
ParserError> {

Review Comment:
   Ah should this rather return the error? since the error would be a recursion 
error, so that the return type fot `parse_create` becomes 
`Result<Option<Result<statement`



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to