-
Notifications
You must be signed in to change notification settings - Fork 27.7k
C API pollutes the global namespace #40083
Copy link
Copy link
Closed
Labels
better-engineeringRelatively self-contained tasks for better engineering contributorsRelatively self-contained tasks for better engineering contributorsmodule: buildBuild system issuesBuild system issuesmodule: cppRelated to C++ APIRelated to C++ APItriagedThis issue has been looked at a team member, and triaged and prioritized into an appropriate moduleThis issue has been looked at a team member, and triaged and prioritized into an appropriate module
Metadata
Metadata
Assignees
Labels
better-engineeringRelatively self-contained tasks for better engineering contributorsRelatively self-contained tasks for better engineering contributorsmodule: buildBuild system issuesBuild system issuesmodule: cppRelated to C++ APIRelated to C++ APItriagedThis issue has been looked at a team member, and triaged and prioritized into an appropriate moduleThis issue has been looked at a team member, and triaged and prioritized into an appropriate module
🐛 Bug
libtorch/include/c10/util/logging_is_not_google_glog.hexposesERROR,FATAL, etc in the global namespace.This is included by
torch/script.h.This causes the conflict with a user code.
Expected behavior
Put them in some namespace.
Environment
build-hash: 4ff3872...
build-version: 1.5.0+cpu
cc @malfet @yf225 @glaringlee