nmwsharp / nmwsharp/geometry-central

warning: control reaches end of non-void function in VectorHeatMethodSolver::computeLogMap

Open Beginner friendly
#256 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C++
Stars
1.3k
Forks
183
PR merge metrics
No merged PRs in 30d

Description

On line

https://github.com/nmwsharp/geometry-central/blob/019669ddabda05e0f71fa3587cfb3c1dadf19cb8/src/surface/vector_heat_method.cpp#L350

I get:
/work/src/geometrycentral/src/surface/vector_heat_method.cpp:351:1: warning: control reaches end of non-void function [-Wreturn-type

proposed fix (sames as line 695)

  throw std::logic_error("bad switch");
  return VertexData<Vector2>();

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Open src/surface/vector_heat_method.cpp around line 350 and compare the return path with the analogous code around line 695. Confirm the compiler warning in VectorHeatMethodSolver::computeLogMap, then ensure every control path returns appropriately and the warning is gone.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
computer-graphics
Issue type
Bug
Difficulty
1/5
Estimated time
Under an hour
Activity status
Quiet
Clarity
Clearly specified
Newbie friendliness
88/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.