码迷,mamicode.com
首页 >  
搜索关键字:endif    ( 913个结果
内部链接和外部链接以及const对象在头文件中的若干问题
首先我们看一段示例代码: t1.h [cpp] view plaincopyprint? #ifndef T1_H_  #define T1_H_  #include "t2.h"    #ifndef HHH  #define HHH      int da = 5;  #endif    #endif  #ifndef T1_H_ #defi...
分类:其他好文   时间:2014-09-20 08:53:17    阅读次数:270
error: unterminated #ifndef
error: unterminated #ifndef 分类: C语言学习 error: unterminated #ifndef 1,权限问题 2,少了#endif...
分类:其他好文   时间:2014-09-19 12:02:55    阅读次数:108
#ifdef __cplusplus extern "C" { #endif //一段代码 #ifdef __cplusplus } #endif
这样的代码到底是什么意思呢?首先,__cplusplus是cpp中的自定义宏,那么定义了这个宏的话表示这是一段cpp的代码,也就是说,上面的代码的含义是:如果这是一段cpp的代码,那么加入"extern "C"{" 和 " }"处理其中的代码,其中{ }内部的代码是通过extern"C"进行处理。要...
分类:其他好文   时间:2014-09-16 20:30:41    阅读次数:240
程序的编译过程
1.编译预处理(gcc -E source.E)产生source.E文件#define:宏定义,定义一个符号,在编译预处理的时候进行简单的替换#if/#endif:判断后面表达式的真假#ifdef/#ifndef/#endef:判断是否定义了某个宏定义2.编译(gcc -S source.E)产生s...
分类:其他好文   时间:2014-09-15 21:01:09    阅读次数:165
条件编译
1、ifdef #ifdef XXXXX ...... #endif如果XXXXX被定义了,则编译上述代码。 2、ifndef #ifndef XXXXX ...... #endif如果XXXXX没有被定义,则编译上述代码。 3、if #if XXXXX ..... #endif如果XXXXX被定义了,并且值为真,则编译上述代码。 4、if define #if define(X...
分类:其他好文   时间:2014-09-12 10:13:53    阅读次数:235
C语言中的调试宏
#ifdef DEBUG #define debug_printf(fmt, ...) printf(fmt, ##__VA_ARGS__) #else #define debug_printf(fmt, ...) #endif 其中##在没有参数的时候去掉前面的","号,否则在没有参数的时候,编译会报错。 #include #ifdef DEBUG #define debug_prin...
分类:编程语言   时间:2014-09-10 14:17:00    阅读次数:200
android 如何增大开机铃声
AudioMtkPolicyManager.cpp ICS 版本是AudioYusuPolicyManager.cpp #ifndef  BOOT_animation_volume #define boot_animation_volume (0.25) #endif 请把这里改为#define boot_animation_volume 增大,最大值为1...
分类:移动开发   时间:2014-09-10 10:55:10    阅读次数:316
Python框架之Django学习笔记(七)
标签eif/else {%if%}标签检查(evaluate)一个变量,如果这个变量为真(即,变量存在,非空,不是布尔值假),系统会显示在{%if%}和{%endif%}之间的任何内容,例如:1 {% if today_is_weekend %}2 Welcome to the weeke...
分类:编程语言   时间:2014-09-07 13:30:25    阅读次数:200
#ifdef __cplusplus extern "C" { #endif
1、在好多程序中我们会遇到下面代码段#ifdef__cplusplusextern"C"{#endif//c语法代码段#ifdef__cplusplus}#endif//首先应该知道,__cplusplus是CPP中的自定义宏,则表示这是一段cpp的代码,编译器按c++的方式编译系统.。如果这时候我...
分类:其他好文   时间:2014-09-07 13:28:35    阅读次数:240
调试输出
catch(Exception oEx) {#if DEBUG throw oEx;#endif return embedValue; }
分类:其他好文   时间:2014-09-05 23:40:22    阅读次数:216
913条   上一页 1 ... 80 81 82 83 84 ... 92 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!