ISO/IEC 14882 2017 5edition个人翻译 8 表达式

写在开头:
这个系列的翻译会不定时跟进,因为是为了找出Cpperference中没有看懂的地方而做的标准翻译,不会一次性翻译某一块内容,只能说看到哪翻译到哪,下次继续…
由于本人水平有限翻译的不恰当(错误)的地方还请指出!谢谢!
要讨论的同学,老师们可以直接在评论区留言(本人不经常逛CSDN可能回复不会很即时请见谅)
更快的联系方式:可以移步我的cpperference的讨论页中留言或是在讨论页的签名处有直接联系方式
最后谢谢各位看客来看本人的撇脚翻译!


ISO/IEC 14882 2017 5edition个人翻译

8 Expressions

介绍

12

In some contexts, an expression only appears for its side effects. Such an expression is called a discarded-value expression. The array-to-pointer (7.2) and function-to-pointer (7.3) standard conversions are not applied.


在有些代码中(原义为在一些上下文中),一个表达式只体现其副作用的,这样的表达式就是弃值表达式。数组向指针转换和函数向函数指针的标准转换是不会进行的。


8.2.9

6

Any expression can be explicitly converted to type cv void, in which case it becomes a discarded-value expression (Clause 8) . [ Note: However, if the value is in a temporary object (15.2) , the destructor for that object is not executed until the usual time, and the value of the object is preserved for the purpose of executing the destructor. — end note ]


任何一个显示转化为可含有cv制定副的void类型的表达式会变成一个亡值表达式[注意:虽然如此,如果这个值是在零时对象中,直到常规时间,该对象的析构函数都不会被执行,该对象的这个值是为了执行虚构函数而被保留的。


8.19

1

The comma operat or groups left - to- right .
expression :
    assignment-expression
    expression , assignment-expression
A pair of expressions separated by a comma is evaluated left-to-right; the left expression is a discarded-value expression (Clause 8) . Every value computation and side effect associated with the left expression is sequenced before every value computation and side effect associated with the right expression. The type and value of the result are the type and value of the right operand; the result is of the same value category as its right operand, and is a bit-field if its right operand is a bit-field. If the right operand is a temporary expression (15.2) , the result is a temporary expression.


逗号操作或逗号组是从左到右结合的
一组表达式被逗号分离是从左到右依次求值的,其中左表达式是一个弃值表达式,左边的求值和副作用产生总是先于右边的,表达式的值和表达式的类型都是右造作数的相关值和类型或位域,如果右操作表达式是一个零时表达式,那么整个表达式的值类别是一个零时表达式。


  • 1
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值