Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DNM] Try eliminate incorrect clang-tidy by aws #9749

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions dbms/src/Common/StackTrace.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
#include <Common/StackTrace.h>
#include <common/demangle.h>
#include <execinfo.h>

StackTrace::StackTrace()
{
frames_size = backtrace(frames, STACK_TRACE_MAX_DEPTH);
Expand Down
2 changes: 1 addition & 1 deletion dbms/src/Common/StackTrace.h
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,6 @@ class StackTrace

private:
using Frame = void *;
Frame frames[STACK_TRACE_MAX_DEPTH];
Frame frames[STACK_TRACE_MAX_DEPTH] = {};
size_t frames_size;
};
4 changes: 2 additions & 2 deletions dbms/src/Interpreters/InterpreterDescribeQuery.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ BlockInputStreamPtr InterpreterDescribeQuery::executeImpl()
ColumnDefaults column_defaults;
StoragePtr table;

auto table_expression = typeid_cast<const ASTTableExpression *>(ast.table_expression.get());
const auto * table_expression = typeid_cast<const ASTTableExpression *>(ast.table_expression.get());

if (table_expression->subquery)
{
Expand All @@ -82,7 +82,7 @@ BlockInputStreamPtr InterpreterDescribeQuery::executeImpl()
{
if (table_expression->table_function)
{
auto table_function = typeid_cast<const ASTFunction *>(table_expression->table_function.get());
const auto * table_function = typeid_cast<const ASTFunction *>(table_expression->table_function.get());
/// Get the table function
TableFunctionPtr table_function_ptr = TableFunctionFactory::instance().get(table_function->name, context);
/// Run it and remember the result
Expand Down
2 changes: 1 addition & 1 deletion dbms/src/Storages/DeltaMerge/SegmentReadTask.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -790,7 +790,7 @@ GlobalSegmentID SegmentReadTask::getGlobalSegmentID() const
void SegmentReadTask::finishPagesPacketStream(
std::unique_ptr<grpc::ClientReader<disaggregated::PagesPacket>> & stream_resp)
{
if unlikely (stream_resp == nullptr)
if (unlikely(stream_resp == nullptr))
return;

auto status = stream_resp->Finish();
Expand Down
1 change: 1 addition & 0 deletions release-linux-llvm/scripts/fix_compile_commands.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ def main():
data = check_files(data, args.load_diff_files_from)
json.dump(data, open(args.file_path, 'w'), indent=4)
print('process {} elements'.format(len(data)))
print('{}'.format(json.dumps(data, indent=4)))


if __name__ == '__main__':
Expand Down