作业帮 > 综合 > 作业

在编写数据结构实现各种排序算法的过程中,在编译的时候显示我vc中的list.h有错误,双击那个错误的时候跳出来的页面也是

来源:学生作业帮 编辑:拍题作业网作业帮 分类:综合作业 时间:2024/06/10 07:13:45
在编写数据结构实现各种排序算法的过程中,在编译的时候显示我vc中的list.h有错误,双击那个错误的时候跳出来的页面也是我vc中list.h文件部分的代码,如下:
#if !defined(_LIST_)
#define _LIST_
#pragma pack(1)
//
typedef struct _LIST
{
LPLINK Tail; //... List Tail pointer.
LPLINK Head; //... List Head pointer.
DWORD Length; //... List Length.
} LIST;
typedef LIST *LPLIST;
#ifndef NO_INLINE
#ifndef INLINE
#define INLINE __inline
#endif
显示的错误就是
“\c++\vc6\vc6\vc6cn\vc98\include\list.h(37) : error C2146: syntax error : missing ';' before identifier 'Length'
e:\学习资料\c++\vc6\vc6\vc6cn\vc98\include\list.h(37) : error C2501: 'DWORD' : missing storage-class or type specifiers
e:\学习资料\c++\vc6\vc6\vc6cn\vc98\include\list.h(37) : error C2501: 'Length' : missing storage-class or type specifiers
e:\学习资料\c++\vc6\vc6\vc6cn\vc98\include\list.h(53) : error C2146: syntax error : missing ';' before identifier 'GetPrevLink'
e:\学习资料\c++\vc6\vc6\vc6cn\vc98\include\list.h(53) : error C2433: 'WINAPI' : 'inline' not permitted on data declarations
e:\学习资料\c++\vc6\vc6\vc6cn\vc98\include\list.h(53) : fatal error C1004: unexpected end of file found
执行 cl.exe 时出错.”
是什么原因呢,求高手帮忙
在list.h的前面加上#include