ISO Cè¯è¨€æ ‡å‡†çš„æ›´æ–°
部分翻译自 ISO C Standard Update
作者Arjun Bijanki是Visual C++编译器的test lead,而且是Microsoft在Cæ ‡å‡†å§”å‘˜ä¼šçš„ä»£è¡¨ã€‚
C1x (0<=x<=9)将是下一个版本的Cè¯è¨€æ ‡å‡†ï¼ŒISOå›½é™…æ ‡å‡†åŒ–å§”å‘˜ä¼šWG14,C Programming Language刚刚结æŸäº†åœ¨å¤å¨å¤·çš„åˆä¸€æ¬¡åŠå¹´ä¼šè®®ï¼Œåœ¨ä¼šä¸Šå§”员会æˆå‘˜è®¨è®ºäº†ä¸‹ä¸€ç‰ˆæœ¬çš„Cè¯è¨€ï¼Œéžå®˜æ–¹ç§°ä¸ºC1x的未æ¥å‘展,å‚è§è¿™é‡Œã€‚
对C程åºå‘˜æ¥è¯´ï¼Œæ•´éƒ¨æ–‡æ¡£éƒ½å€¼å¾—一看,但是希望在C1x当ä¸çš„新的概念引起大家的注æ„:
12. Trust the programmer, as a goal, is outdated in respect to the security and safety programming communities. While it should not be totally disregarded as a facet of the spirit of C, the C1X version of the C Standard should take into account that programmers need the ability to check their work.
12. 信任程åºå‘˜ï¼Œä»Žå®‰å…¨çš„编程角度上æ¥è¯´å·²ç»è¿‡æ—¶äº†ã€‚虽然说作为C的精神的一个é‡è¦æ–¹é¢è¿™ä¸ªåŽŸåˆ™å¹¶ä¸åº”该被完全å¦å®šï¼Œä½†æ˜¯C1x有责任给程åºå‘˜ä¸€ä¸ªæ£€æŸ¥è‡ªå·±å·¥ä½œçš„机会。
13. Unlike for C9X, the consensus at the London meeting was that there should be no invention, without exception. Only those features that have a history and are in common use by a commercial implementation should be considered. Also there must be care to standardize these features in a way that would make the Standard and the commercial implementation compatible.
13. ä¸åƒC9x,伦敦会议的一致æ„è§æ˜¯(在C1x当ä¸)完全ä¸åº”该有任何的新å‘明。åªæœ‰ç»è¿‡åŽ†å²è€ƒéªŒå’Œåœ¨å•†ä¸šå®žçŽ°å½“ä¸å¾—到广泛应用的特性æ‰ä¼šè¢«è€ƒè™‘ã€‚è€Œä¸”åœ¨æ ‡å‡†åŒ–çš„æ—¶å€™éœ€è¦æ³¨æ„和商业实现的兼容。
14. Migration of an existing code base is an issue. The ability to mix and match C89, C99, and C1X based code is a feature that should be considered for each proposal.
14. 对已有代ç çš„å‡çº§æ˜¯ä¸€ä¸ªè€ƒè™‘æ–¹é¢ã€‚æ¯ä¸€ä¸ªæ案都应该具有将基于C89, C99å’ŒC1X的代ç æ•´åˆçš„能力。
代ç å‡çº§æ˜¯æ¯‹åº¸ç½®ç–‘çš„é‡è¦ – 我甚至认为这是基本的需求。但是我å‘现å¦å¤–两项更有æ„æ€ã€‚第12æ¡åæ˜ äº†å·¥ä¸šç•Œåœ¨è¿‘10å¹´æ¥å¯¹äºŽå®‰å…¨æ€§æ–¹é¢çš„æŒç»å…³æ³¨ï¼Œå§”员会开始拥抱这个设想是éžå¸¸ä¼Ÿå¤§çš„ã€‚å› æ¤å§”员会在 TR 24731 (边界检查接å£ï¼ŒåŒ…括了在VS 2005当ä¸å¤§å¤šæ•°_s系列的函数)上é¢çš„努力也就也ä¸è®©äººæ„外了。
委员会也è¦æ±‚编译器厂商æ供它们被最广泛应用的è¯è¨€æ‰©å±•ä»¥ä¾¿å§”员会考虑。在众多实现(例如Visual C++ å’Œ GCC)当ä¸å…±äº«çš„很多特性,åƒæ‰©å±•å±žæ€§(extended attributes)和线程局部å˜å‚¨(thread local storage),将被é‡ç‚¹è€ƒå¯Ÿã€‚还有一些情况,实现之å‰è¯æ³•å¯èƒ½æœ‰åŒºåˆ«ï¼Œä½†æ˜¯åº•å±‚的概念是一致的。æ£å¦‚ #13所说,委员会会尽力去对他们ä¿æŒå…¼å®¹ã€‚
对于微软为什么没有在Visual C++当ä¸å®Œæ•´çš„实现C99,Arjun Bijanki的解释是实现哪些功能是基于用户æå‡ºçš„éœ€æ±‚çš„ã€‚æ ¹æ®ç”¨æˆ·çš„需求,Visual C++å·²ç»å®žçŽ°äº†å¯å˜é•¿å‚æ•°å®(variadic macros),long long类型,__pragma, __FUNCTION__, å’Œ__restrict。他希望能够å¬åˆ°æ›´å¤šæ¥è‡ªCè¯è¨€ç”¨æˆ·çš„需求,而且许诺会在明年4月份的下一次会议åŽç»™å‡ºå…³äºŽCæ ‡å‡†æ›´è¿›ä¸€æ¥çš„更新。