⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 instructions2.doc172.html

📁 Jvm 规范说明。The Java Virtual Machine was designed to support the Java programming language. Some concep
💻 HTML
字号:
<html><head><title>VM Spec  </title></head><body BGCOLOR=#eeeeff text=#000000 LINK=#0000ff VLINK=#000077 ALINK=#ff0000> <a href="VMSpecTOC.doc.html">Contents</a> | <a href="Instructions2.doc171.html">Prev</a> | <a href="Instructions2.doc173.html">Next</a> | <a href="Mnemonics.doc.html">Index</a><hr><br> <a name="putstatic"></a><h2>putstatic</h2><a name="69979"></a>The constant pool item is resolved <a href="ConstantPool.doc.html#49425">(&#167;5.2)</a>, determining both the class field and its width. The type of a <i>value</i> stored by a <i>putstatic </i>instruction must be compatible with the descriptor of the field <a href="ClassFile.doc.html#14152">(&#167;4.3.2)</a> of the class instance being stored into. If the field descriptor type is <code>byte</code>, <code>char</code>, <code>short</code>, or <code>int</code>, then the <i>value</i> must be an <code>int</code>. If the field descriptor type is <code>float</code>, <code>long</code>, or <code>double</code>, then the <i>value</i> must be a <code>float</code>, <code>long</code>, or <code>double</code>, respectively. If the field descriptor type is a reference type, then the <i>value</i> must be of a type that is assignment compatible <a href="Concepts.doc.html#19674">(&#167;2.6.6)</a> with the field descriptor type.<p><a name="69986"></a>The <i>value</i> is popped from the operand stack, and the class field is set to <i>value</i>.<p><a name="putstatic.Linking"></a><b>Linking Exceptions</b><br><a name="135940"></a>During resolution of the <code>CONSTANT_Fieldref</code> constant pool item, any of the exceptions documented in <a href="ConstantPool.doc.html#49425">&#167;5.2</a> can be thrown.<p><a name="108678"></a>Otherwise, if the specified field exists but is not a <code>static</code> field (class variable), <i>putstatic</i> throws an <code>Incompatible-Class</code><code>-ChangeError</code>.<p><a name="putstatic.Notes"></a><b>Notes</b><br><a name="69989"></a>The <i>putstatic</i> instruction operates on both one- and two-word wide fields.<p><a name="69990"></a><p><hr><!-- This inserts footnotes--><p><a href="VMSpecTOC.doc.html">Contents</a> | <a href="Instructions2.doc171.html">Prev</a> | <a href="Instructions2.doc173.html">Next</a> | <a href="Mnemonics.doc.html">Index</a><p><font size=-1>Java Virtual Machine Specification (HTML generated by dkramer on February 25, 1997)<br><i><a href="Copyright.doc.html">Copyright &#169 1996 Sun Microsystems, Inc.</a>All rights reserved</i><br>Please send any comments or corrections to <a href="mailto:doug.kramer@sun.com">doug.kramer@sun.com</a></font></body></html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -