Skip to content

fix GCC 15 build by including <cstdint>#508

Closed
gouzil wants to merge 3 commits into
pytorch:mainfrom
PFCCLab:fix/gcc_15_build
Closed

fix GCC 15 build by including <cstdint>#508
gouzil wants to merge 3 commits into
pytorch:mainfrom
PFCCLab:fix/gcc_15_build

Conversation

@gouzil

@gouzil gouzil commented Jun 2, 2026

Copy link
Copy Markdown

Summary

本 PR 修复 GCC 15 下的构建问题,在 gloo/types.h 中补充直接依赖的 <cstdint> 头文件。

Changes

  • gloo/types.h 中添加 #include <cstdint>

background

gloo/types.h 使用了固定宽度整数类型,但此前没有直接包含 <cstdint>。GCC 15 下该依赖不再能稳定通过其他头文件间接获得,因此会暴露缺失头文件导致的编译失败。

相关链接:

Copilot AI review requested due to automatic review settings June 2, 2026 16:13
@meta-cla

meta-cla Bot commented Jun 2, 2026

Copy link
Copy Markdown

Hi @gouzil!

Thank you for your pull request and welcome to our community.

Action Required

In order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you.

Process

In order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA.

Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with CLA signed. The tagging process may take up to 1 hour after signing. Please give it that time before contacting us about it.

If you have received this in error or have any questions, please contact us at cla@meta.com. Thanks!

@gouzil gouzil closed this Jun 2, 2026

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Note

Copilot was unable to run its full agentic suite in this review.

Updates Gloo headers to add missing standard library includes needed by recent changes and to normalize TCP transport device includes.

Changes:

  • Add <cstdint> include to gloo/types.h.
  • Add <array> include to gloo/transport/tcp/device.cc.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
gloo/types.h Adds <cstdint> to support fixed-width integer types usage in the header.
gloo/transport/tcp/device.cc Adds <array> include to support std::array usage in TCP device implementation.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 9 to 13
#include "gloo/transport/tcp/device.h"

#include <array>
#include <ifaddrs.h>
#include <netdb.h>
#include <netinet/in.h>
@gouzil gouzil deleted the fix/gcc_15_build branch June 3, 2026 13:39
@gouzil gouzil restored the fix/gcc_15_build branch June 3, 2026 13:53
@gouzil gouzil deleted the fix/gcc_15_build branch June 3, 2026 14:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants