第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號(hào)安全,請(qǐng)及時(shí)綁定郵箱和手機(jī)立即綁定
已解決430363個(gè)問(wèn)題,去搜搜看,總會(huì)有你想問(wèn)的

C #include 循環(huán)引用問(wèn)題, 頭文件循環(huán)引用

C #include 循環(huán)引用問(wèn)題, 頭文件循環(huán)引用

C++
慕桂英3389331 2019-02-06 21:47:15
關(guān)于在C中出現(xiàn)的循環(huán)引用問(wèn)題, 目的希望學(xué)習(xí)到如何規(guī)避頭文件循環(huán)引用出現(xiàn)的這類錯(cuò)誤.大概邏輯描述main.c : 是程序入口, a.h,b.h,c.h 為頭文件;其中a.h 中 include c.h; c.h include b.h ;b.h include a.h運(yùn)行程序報(bào)錯(cuò),相關(guān)代碼main.c#include <stdio.h>#include "a.h"int main(int argc, const char * argv[]) {    printf("Hello ! \n");    return 0; }a.h#ifndef a_h#define a_h#include "c.h"struct sem{     struct eve *evet;};#endif /* a_h */b.h#ifndef b_h#define b_h#include "a.h"struct pan{     struct sem semt;};struct dev{     int x; };#endif /* b_h */c.h#ifndef c_h#define c_h#include "b.h"struct eve{     struct dev *devt;};#endif /* c_h */期待給出自己遇到的關(guān)于頭文件循環(huán)引用的例子和解決方法,有理有據(jù);之所以問(wèn)題發(fā)出來(lái)希望幫助更多遇到類似問(wèn)題的人,同時(shí)希望答案相對(duì)全面一些.
查看完整描述

1 回答

  • 1 回答
  • 0 關(guān)注
  • 1613 瀏覽

添加回答

舉報(bào)

0/150
提交
取消
微信客服

購(gòu)課補(bǔ)貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動(dòng)學(xué)習(xí)伙伴

公眾號(hào)

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號(hào)