12 2010 档案

摘要:C语言中和的一个细节,也许很多人都不知道 阅读全文
posted @ 2010-12-27 22:32 嗷嗷 阅读(376) 评论(2) 推荐(0) 编辑
摘要:讲一下IA32构架中的PAT如何选择memory type的 阅读全文
posted @ 2010-12-26 15:23 嗷嗷 阅读(878) 评论(0) 推荐(0) 编辑
摘要:大部分内容来至于IA32手册第三卷10.3 METHODS OF CACHING AVAILABLE英文部分是绝对正确的,因为是原文。中文部分是一些自己的总结与理解,凑活着看吧。IA32现在一共有5种caching type(也叫memory type)Table 10-2. Memory Types and Their PropertiesMemory Type and MnemonicCacheableWrite CacheableAllows Speculative ReadsMemory Ordering ModelStrong Uncacheable(UC)NoNoNoStrong 阅读全文
posted @ 2010-12-25 23:46 嗷嗷 阅读(3828) 评论(0) 推荐(0) 编辑
摘要:Changing the accessibility of a class member should never change the meaning of a program. 阅读全文
posted @ 2010-12-20 09:34 嗷嗷 阅读(281) 评论(9) 推荐(0) 编辑
摘要:(i = j) = k;的值是多少? 阅读全文
posted @ 2010-12-19 11:10 嗷嗷 阅读(508) 评论(1) 推荐(0) 编辑
摘要:主要是简单解释一下为什么要写这样一个函数,这两个const有什么意义。const char* c_str() const{return m_str;};1.首先说第二个const, 这个const意味this指针是一个const myString*, 所以对于变量const myString c_myStr(ss); 才能调用c_myStr.c_str();2.再说第一个const, 既然c_myStr是一个const类型的变量,自然是希望他不被改变。那么如果不加第一个const,那么c_str()的返回值就可以赋值给一个非const类型的变量,c_myStr将有可能变相地被改变。还有一点小提 阅读全文
posted @ 2010-12-16 11:32 嗷嗷 阅读(628) 评论(2) 推荐(0) 编辑

点击右上角即可分享
微信分享提示