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

Calm down -Werror=return-type #5649

Merged
merged 1 commit into from
Oct 19, 2023
Merged
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
2 changes: 2 additions & 0 deletions src/graphics/opengl/RenderTargetGL.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ namespace Graphics {
case RenderTarget::READ: return GL_READ_FRAMEBUFFER;
case RenderTarget::DRAW: return GL_DRAW_FRAMEBUFFER;
case RenderTarget::BOTH: return GL_FRAMEBUFFER;
// default value is never reached, calm down -Werror=return-type
default: return 42;
}
}

Expand Down
3 changes: 2 additions & 1 deletion src/pigui/PerfInfo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,8 @@ PerfInfo::CounterInfo &PerfInfo::GetCounter(CounterType ct)
case COUNTER_FPS: return m_fpsCounter;
case COUNTER_PHYS: return m_physCounter;
case COUNTER_PIGUI: return m_piguiCounter;
default: assert(0);
// default value is never reached, calm down -Werror=return-type
default: return m_fpsCounter;
}
}

Expand Down