Fix style

This commit is contained in:
Robert Schulze 2023-01-03 20:01:58 +00:00
parent 210af0d119
commit e4b2ed6d6f
No known key found for this signature in database
GPG Key ID: 26703B55FB13728A

View File

@ -23,9 +23,10 @@ namespace {
struct HasNonDeterministicFunctionsMatcher struct HasNonDeterministicFunctionsMatcher
{ {
struct Data { struct Data
{
ContextPtr context; ContextPtr context;
bool has_non_deterministic_functions; bool has_non_deterministic_functions = false;
}; };
static bool needChildVisit(const ASTPtr &, const ASTPtr &) { return true; } static bool needChildVisit(const ASTPtr &, const ASTPtr &) { return true; }
@ -50,9 +51,9 @@ using HasNonDeterministicFunctionsVisitor = InDepthNodeVisitor<HasNonDeterminist
bool astContainsNonDeterministicFunctions(ASTPtr ast, ContextPtr context) bool astContainsNonDeterministicFunctions(ASTPtr ast, ContextPtr context)
{ {
HasNonDeterministicFunctionsMatcher::Data data{context, false}; HasNonDeterministicFunctionsMatcher::Data finder_data{context};
HasNonDeterministicFunctionsVisitor(data).visit(ast); HasNonDeterministicFunctionsVisitor(finder_data).visit(ast);
return data.has_non_deterministic_functions; return finder_data.has_non_deterministic_functions;
} }
namespace namespace