invalid types 'int[int]' for array subscript是什么原因
一个项目的代码从linux上成功编译,现在要移植到solaris下,可是却不能成功编译,出现以下错误,啥原因啊?
/rnccn_vob_3/adm/mib_build/src/adm_omc_utilities.h:24: error: expected unqualified-id before numeric constant
/rnccn_vob_3/adm/mib_build/src/adm_omc_mib_build_main.cc: In function 'int adm_omc_mib_build_process(int, char**)':
/rnccn_vob_3/adm/mib_build/src/adm_omc_mib_build_main.cc:146: error: invalid types 'int[int]' for array subscript
/rnccn_vob_3/adm/mib_build/src/adm_omc_mib_build_main.cc:146: error: 'adm_umts_trace' was not declared in this scope
头文件为:
#include <stdlib.h>
#include <stdio.h>
#include "adm_cmca_data.h"
#include "adm_sepe_tge_data.h"
// ----------------------------------------------------------------------------
// Types And Function Prototypes
// ----------------------------------------------------------------------------
enum operation_mode_t {BUILDING, CONVERTING, DEBUGGING};
enum input_file_type_t {ASCII, BINARY};
// ----------------------------------------------------------------------------
// Global Data And Variables
// ----------------------------------------------------------------------------
const int MAX_POOL_SIZE = 1024 * 1000;
extern int GLOBAL_STATUS;
extern const char ERR[256][256];
// ----------------------------------------------------------------------------
// Prototypes
// ----------------------------------------------------------------------------
extern u16 cmca_adm_interfaces_init();
extern adm_bool_t is_mib_nominal();
// ----------------------------------------------------------------------------
// Macros
// ----------------------------------------------------------------------------
#define ADM_OMC_PRINT(MSG) \
printf##MSG; \
printf("\n")
#endif
.cc中是这么用的
ADM_UMTS_CATCH(GLOBAL_STATUS == 0, -GLOBAL_STATUS, ERR[52], APPTR_LEVEL_INTERNAL);