Skip to content

Compiler Warnings: Non-Void Function does not return a value #3323

@dgovil

Description

@dgovil

Description of Issue

When building USD with Clang (using Apple Clang 16 from Xcode 16, but should reproduce with other compilers), there are several functions that do not return a value. I am building with python3 ./build_scripts/build_usd.py ~/Downloads/usd --build-variant debug --no-imaging -vvv.

I think this would be a good first issue for someone to tackle and get used to building USD.

The warning is replicated below:

[675/4632] Building CXX object pxr/base/tf/CMakeFiles/tf.dir/mallocTag.cpp.o
/Users/dhruvgovil/Projects/usd/pxr/base/tf/mallocTag.cpp:583:5: warning: non-void function does not return a value [-Wreturn-type]
  583 |     }
      |     ^
1 warning generated.
/Users/dhruvgovil/Projects/usd/pxr/base/tf/mallocTag.cpp:583:5: warning: non-void function does not return a value [-Wreturn-type]
  583 |     }
      |     ^
1 warning generated.

Metadata

Metadata

Assignees

No one assigned

    Labels

    good first issueIndicates a good issue for first-time contributorsneeds reviewIssue needing input/review by the repo maintainer (Pixar)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions