Merged
compilation issue fixed #5798
hsqnbAdd on Aug 31
compilation issue fixed #5798
Merged
hsqnbAdd on Aug 31
hsqnb
hsqnbCollaborators
Aug 31

fix(interface): Add missing cstdint header in pre_def

The pre_def.h uses uint8_t (via BinDataPtr typedef) but does not
include that defines it. This causes compilation failures
on strict toolchains where is not transitively included.

Changes:

  • Add #include to framework/src/interface/inner/pre_def.h

Related Issue: #3172

likedislike
Pull Request has been successfully merged by CANN-robot.
(Thank you for hsqnb's contribution.)
hsqnbhsqnbCollaborators
Aug 31 Created pull request, commit 07a401d5
hsqnbhsqnbCollaborators
Aug 31 Associated issue: [Bug-Report|缺陷反馈]: pre_def.h missing causes compilation failure after GCC upgrade
atomgit-bot
atomgit-bot
Aug 31 Comments:

变更摘要

该 PR 修复了 framework/src/interface/inner/pre_def.h 在严格编译工具链下的编译失败问题:pre_def.h 通过 BinDataPtr typedef 使用了 uint8_t,但此前未显式包含定义该类型的 <cstdint> 头文件,仅依赖其他头文件的传递性包含,在严格工具链上会导致编译报错。此改动在 pre_def.h 中新增 #include <cstdint>,使类型定义有明确的依赖来源。

主要改动

  • 新增 <cstdint> 头文件引用: 在 framework/src/interface/inner/pre_def.h 的 #pragma once 之后、<vector> 之前添加 #include <cstdint>,确保 uint8_t 等类型在编译时始终可见。
  • 消除对传递包含的隐式依赖: 通过在头文件中直接声明标准库类型依赖,避免严格工具链因 <cstdint> 未被传递包含而导致的编译失败,提升该头文件的可移植性与自包含性。
likedislike
Incorrect?
atomgit-bot
atomgit-bot
Aug 31 Comments:

代码审查

✅ 未发现问题

likedislike
Incorrect?
CANN-robotCANN-robotCollaborators
Aug 31 Added label: cann-cla/yes
CANN-robot
CANN-robotCollaborators
Aug 31 Comments:

Thanks for your pull-request.
The full list of commands accepted by me can be found at here.
You can get sig-info at here.
You can self-configure the PR merge rules for this repository. For more details, please refer to Here.
For more, you also can visit HICANN.


PR Approval Progress

✅ Congratulations! All modules have met the lgtm and approve requirements.

Module Approval Details

module lgtm status approve status
framework/src/interface/inner ✅ DCGDDD, gaoxiang618 (2/2) ✅ gaoxiang618 (1/1)

💡 Tip:

  • Committer can comment /approve or /lgtm
  • Commenting /approve implies both code review (lgtm) and intent to merge (approve)
likedislike
CANN-robot
CANN-robotCollaborators
Aug 31 Comments:

CLA Signature Pass

hsqnb, thanks for your pull request. All authors of the commits have signed the CLA. 👍

likedislike
CANN-robotCANN-robotCollaborators
Aug 31 Set xinweiliu,cam_bxh,dai-zhentao,lululu40888,shi-dingkun,gguuaanngg,codehjp423,gaoxiang618,wangzheng97,DCGDDD,syfeng,jason_yuan_ye,foundea,ym-HW,hw_zhangzhiqi,yinjie27_,congqiannan,zhangyuebing,tsungl4,gaoxingwang,zhiweiyuan,caodongdong,make_pto,zhoubotcam,linjiashu,wangbing110,WenboCodes as approver
CANN-robotCANN-robotCollaborators
Aug 31 Set gaoxiang618,DCGDDD,yinjie27_,tsungl4,make_pto,linjiashu as approver
hsqnb
hsqnbCollaborators
Aug 31 Comments:

compile

likedislike
hsqnbhsqnbCollaborators
Aug 31 Pre merge succeeded (commit_id: 938b495da93b3a2eb34f4725f3f74a63c4746d0b)
hsqnbhsqnbCollaborators
Aug 31 Pre merge succeeded (commit_id: 20535ae3ffc72d3b3282f3c05b34a4a2190a4233)
CANN-robotCANN-robotCollaborators
Aug 31 Added label: ci-pipeline-running
CANN-robotCANN-robotCollaborators
Aug 31 Removed label: ci-pipeline-running
CANN-robotCANN-robotCollaborators
Aug 31 Added label: ci-pipeline-passed
gaoxiang618
gaoxiang618Collaborators
Aug 31 Comments:

/lgtm
/approve

likedislike
CANN-robotCANN-robotCollaborators
Aug 31 Added label: approved
杨旭
杨旭Collaborators
Aug 31 Comments:

/lgtm

likedislike
CANN-robotCANN-robotCollaborators
Aug 31 Added label: lgtm
CANN-robotCANN-robotCollaborators
Aug 31 Merged pull request