日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程语言 > java >内容正文

java

促销 java_原始促销 [Java]

發布時間:2024/7/5 java 33 豆豆
生活随笔 收集整理的這篇文章主要介紹了 促销 java_原始促销 [Java] 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

JLS在這里不會“提升到更大的數據類型”,因為它不會為轉移運算符執行二進制數字提升.這由

JLS, Section 15.19涵蓋.

Unary numeric promotion (§5.6.1) is performed on each operand separately. (Binary numeric promotion (§5.6.2) is not performed on the operands.)

一元數字促銷將字節a提升為int.文字4L沒有改變,但無論如何它只需要是一個整體類型.

It is a compile-time error if the type of each of the operands of a shift operator, after unary numeric promotion, is not a primitive integral type.

然后,對于移位,僅使用至少5個有效位來移位int.

If the promoted type of the left-hand operand is int, then only the five lowest-order bits of the right-hand operand are used as the shift distance. It is as if the right-hand operand were subjected to a bitwise logical AND operator & (§15.22.1) with the mask value 0x1f (0b11111). The shift distance actually used is therefore always in the range 0 to 31, inclusive.

運算符的結果是int,而不是long,因此可以在沒有編譯器錯誤的情況下將其賦值給int.

The type of the shift expression is the promoted type of the left-hand operand.

總結

以上是生活随笔為你收集整理的促销 java_原始促销 [Java]的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。