annotate src/share/vm/classfile/verifier.hpp @ 0:a61af66fc99e jdk7-b24

Initial load
author duke
date Sat, 01 Dec 2007 00:00:00 +0000
parents
children ad6585fd4087
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
a61af66fc99e Initial load
duke
parents:
diff changeset
1 /*
a61af66fc99e Initial load
duke
parents:
diff changeset
2 * Copyright 1998-2006 Sun Microsystems, Inc. All Rights Reserved.
a61af66fc99e Initial load
duke
parents:
diff changeset
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
a61af66fc99e Initial load
duke
parents:
diff changeset
4 *
a61af66fc99e Initial load
duke
parents:
diff changeset
5 * This code is free software; you can redistribute it and/or modify it
a61af66fc99e Initial load
duke
parents:
diff changeset
6 * under the terms of the GNU General Public License version 2 only, as
a61af66fc99e Initial load
duke
parents:
diff changeset
7 * published by the Free Software Foundation.
a61af66fc99e Initial load
duke
parents:
diff changeset
8 *
a61af66fc99e Initial load
duke
parents:
diff changeset
9 * This code is distributed in the hope that it will be useful, but WITHOUT
a61af66fc99e Initial load
duke
parents:
diff changeset
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
a61af66fc99e Initial load
duke
parents:
diff changeset
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
a61af66fc99e Initial load
duke
parents:
diff changeset
12 * version 2 for more details (a copy is included in the LICENSE file that
a61af66fc99e Initial load
duke
parents:
diff changeset
13 * accompanied this code).
a61af66fc99e Initial load
duke
parents:
diff changeset
14 *
a61af66fc99e Initial load
duke
parents:
diff changeset
15 * You should have received a copy of the GNU General Public License version
a61af66fc99e Initial load
duke
parents:
diff changeset
16 * 2 along with this work; if not, write to the Free Software Foundation,
a61af66fc99e Initial load
duke
parents:
diff changeset
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
a61af66fc99e Initial load
duke
parents:
diff changeset
18 *
a61af66fc99e Initial load
duke
parents:
diff changeset
19 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
a61af66fc99e Initial load
duke
parents:
diff changeset
20 * CA 95054 USA or visit www.sun.com if you need additional information or
a61af66fc99e Initial load
duke
parents:
diff changeset
21 * have any questions.
a61af66fc99e Initial load
duke
parents:
diff changeset
22 *
a61af66fc99e Initial load
duke
parents:
diff changeset
23 */
a61af66fc99e Initial load
duke
parents:
diff changeset
24
a61af66fc99e Initial load
duke
parents:
diff changeset
25 // The verifier class
a61af66fc99e Initial load
duke
parents:
diff changeset
26 class Verifier : AllStatic {
a61af66fc99e Initial load
duke
parents:
diff changeset
27 public:
a61af66fc99e Initial load
duke
parents:
diff changeset
28 enum { STACKMAP_ATTRIBUTE_MAJOR_VERSION = 50 };
a61af66fc99e Initial load
duke
parents:
diff changeset
29 typedef enum { ThrowException, NoException } Mode;
a61af66fc99e Initial load
duke
parents:
diff changeset
30
a61af66fc99e Initial load
duke
parents:
diff changeset
31 /**
a61af66fc99e Initial load
duke
parents:
diff changeset
32 * Verify the bytecodes for a class. If 'throw_exception' is true
a61af66fc99e Initial load
duke
parents:
diff changeset
33 * then the appropriate VerifyError or ClassFormatError will be thrown.
a61af66fc99e Initial load
duke
parents:
diff changeset
34 * Otherwise, no exception is thrown and the return indicates the
a61af66fc99e Initial load
duke
parents:
diff changeset
35 * error.
a61af66fc99e Initial load
duke
parents:
diff changeset
36 */
a61af66fc99e Initial load
duke
parents:
diff changeset
37 static bool verify(instanceKlassHandle klass, Mode mode, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
38
a61af66fc99e Initial load
duke
parents:
diff changeset
39 // Return false if the class is loaded by the bootstrap loader.
a61af66fc99e Initial load
duke
parents:
diff changeset
40 static bool should_verify_for(oop class_loader);
a61af66fc99e Initial load
duke
parents:
diff changeset
41
a61af66fc99e Initial load
duke
parents:
diff changeset
42 // Relax certain verifier checks to enable some broken 1.1 apps to run on 1.2.
a61af66fc99e Initial load
duke
parents:
diff changeset
43 static bool relax_verify_for(oop class_loader);
a61af66fc99e Initial load
duke
parents:
diff changeset
44
a61af66fc99e Initial load
duke
parents:
diff changeset
45 private:
a61af66fc99e Initial load
duke
parents:
diff changeset
46 static bool is_eligible_for_verification(instanceKlassHandle klass);
a61af66fc99e Initial load
duke
parents:
diff changeset
47 static symbolHandle inference_verify(
a61af66fc99e Initial load
duke
parents:
diff changeset
48 instanceKlassHandle klass, char* msg, size_t msg_len, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
49 };
a61af66fc99e Initial load
duke
parents:
diff changeset
50
a61af66fc99e Initial load
duke
parents:
diff changeset
51 class RawBytecodeStream;
a61af66fc99e Initial load
duke
parents:
diff changeset
52 class StackMapFrame;
a61af66fc99e Initial load
duke
parents:
diff changeset
53 class StackMapTable;
a61af66fc99e Initial load
duke
parents:
diff changeset
54
a61af66fc99e Initial load
duke
parents:
diff changeset
55 // Summary of verifier's memory usage:
a61af66fc99e Initial load
duke
parents:
diff changeset
56 // StackMapTable is stack allocated.
a61af66fc99e Initial load
duke
parents:
diff changeset
57 // StackMapFrame are resource allocated. There is one ResourceMark
a61af66fc99e Initial load
duke
parents:
diff changeset
58 // for each method.
a61af66fc99e Initial load
duke
parents:
diff changeset
59 // There is one mutable StackMapFrame (current_frame) which is updated
a61af66fc99e Initial load
duke
parents:
diff changeset
60 // by abstract bytecode interpretation. frame_in_exception_handler() returns
a61af66fc99e Initial load
duke
parents:
diff changeset
61 // a frame that has a mutable one-item stack (ready for pushing the
a61af66fc99e Initial load
duke
parents:
diff changeset
62 // catch type exception object). All the other StackMapFrame's
a61af66fc99e Initial load
duke
parents:
diff changeset
63 // are immutable (including their locals and stack arrays) after
a61af66fc99e Initial load
duke
parents:
diff changeset
64 // their constructions.
a61af66fc99e Initial load
duke
parents:
diff changeset
65 // locals/stack arrays in StackMapFrame are resource allocated.
a61af66fc99e Initial load
duke
parents:
diff changeset
66 // locals/stack arrays can be shared between StackMapFrame's, except
a61af66fc99e Initial load
duke
parents:
diff changeset
67 // the mutable StackMapFrame (current_frame).
a61af66fc99e Initial load
duke
parents:
diff changeset
68 // Care needs to be taken to make sure resource objects don't outlive
a61af66fc99e Initial load
duke
parents:
diff changeset
69 // the lifetime of their ResourceMark.
a61af66fc99e Initial load
duke
parents:
diff changeset
70
a61af66fc99e Initial load
duke
parents:
diff changeset
71 // These macros are used similarly to CHECK macros but also check
a61af66fc99e Initial load
duke
parents:
diff changeset
72 // the status of the verifier and return if that has an error.
a61af66fc99e Initial load
duke
parents:
diff changeset
73 #define CHECK_VERIFY(verifier) \
a61af66fc99e Initial load
duke
parents:
diff changeset
74 CHECK); if ((verifier)->has_error()) return; (0
a61af66fc99e Initial load
duke
parents:
diff changeset
75 #define CHECK_VERIFY_(verifier, result) \
a61af66fc99e Initial load
duke
parents:
diff changeset
76 CHECK_(result)); if ((verifier)->has_error()) return (result); (0
a61af66fc99e Initial load
duke
parents:
diff changeset
77
a61af66fc99e Initial load
duke
parents:
diff changeset
78 // A new instance of this class is created for each class being verified
a61af66fc99e Initial load
duke
parents:
diff changeset
79 class ClassVerifier : public StackObj {
a61af66fc99e Initial load
duke
parents:
diff changeset
80 private:
a61af66fc99e Initial load
duke
parents:
diff changeset
81 Thread* _thread;
a61af66fc99e Initial load
duke
parents:
diff changeset
82 symbolHandle _exception_type;
a61af66fc99e Initial load
duke
parents:
diff changeset
83 char* _message;
a61af66fc99e Initial load
duke
parents:
diff changeset
84 size_t _message_buffer_len;
a61af66fc99e Initial load
duke
parents:
diff changeset
85
a61af66fc99e Initial load
duke
parents:
diff changeset
86 void verify_method(methodHandle method, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
87 char* generate_code_data(methodHandle m, u4 code_length, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
88 void verify_exception_handler_table(u4 code_length, char* code_data, int& min, int& max, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
89 void verify_local_variable_table(u4 code_length, char* code_data, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
90
a61af66fc99e Initial load
duke
parents:
diff changeset
91 VerificationType cp_ref_index_to_type(
a61af66fc99e Initial load
duke
parents:
diff changeset
92 int index, constantPoolHandle cp, TRAPS) {
a61af66fc99e Initial load
duke
parents:
diff changeset
93 return cp_index_to_type(cp->klass_ref_index_at(index), cp, THREAD);
a61af66fc99e Initial load
duke
parents:
diff changeset
94 }
a61af66fc99e Initial load
duke
parents:
diff changeset
95
a61af66fc99e Initial load
duke
parents:
diff changeset
96 bool is_protected_access(
a61af66fc99e Initial load
duke
parents:
diff changeset
97 instanceKlassHandle this_class, klassOop target_class,
a61af66fc99e Initial load
duke
parents:
diff changeset
98 symbolOop field_name, symbolOop field_sig, bool is_method);
a61af66fc99e Initial load
duke
parents:
diff changeset
99
a61af66fc99e Initial load
duke
parents:
diff changeset
100 void verify_cp_index(constantPoolHandle cp, int index, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
101 void verify_cp_type(
a61af66fc99e Initial load
duke
parents:
diff changeset
102 int index, constantPoolHandle cp, unsigned int types, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
103 void verify_cp_class_type(int index, constantPoolHandle cp, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
104
a61af66fc99e Initial load
duke
parents:
diff changeset
105 u2 verify_stackmap_table(
a61af66fc99e Initial load
duke
parents:
diff changeset
106 u2 stackmap_index, u2 bci, StackMapFrame* current_frame,
a61af66fc99e Initial load
duke
parents:
diff changeset
107 StackMapTable* stackmap_table, bool no_control_flow, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
108
a61af66fc99e Initial load
duke
parents:
diff changeset
109 void verify_exception_handler_targets(
a61af66fc99e Initial load
duke
parents:
diff changeset
110 u2 bci, bool this_uninit, StackMapFrame* current_frame,
a61af66fc99e Initial load
duke
parents:
diff changeset
111 StackMapTable* stackmap_table, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
112
a61af66fc99e Initial load
duke
parents:
diff changeset
113 void verify_ldc(
a61af66fc99e Initial load
duke
parents:
diff changeset
114 int opcode, u2 index, StackMapFrame *current_frame,
a61af66fc99e Initial load
duke
parents:
diff changeset
115 constantPoolHandle cp, u2 bci, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
116
a61af66fc99e Initial load
duke
parents:
diff changeset
117 void verify_switch(
a61af66fc99e Initial load
duke
parents:
diff changeset
118 RawBytecodeStream* bcs, u4 code_length, char* code_data,
a61af66fc99e Initial load
duke
parents:
diff changeset
119 StackMapFrame* current_frame, StackMapTable* stackmap_table, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
120
a61af66fc99e Initial load
duke
parents:
diff changeset
121 void verify_field_instructions(
a61af66fc99e Initial load
duke
parents:
diff changeset
122 RawBytecodeStream* bcs, StackMapFrame* current_frame,
a61af66fc99e Initial load
duke
parents:
diff changeset
123 constantPoolHandle cp, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
124
a61af66fc99e Initial load
duke
parents:
diff changeset
125 void verify_invoke_init(
a61af66fc99e Initial load
duke
parents:
diff changeset
126 RawBytecodeStream* bcs, VerificationType ref_class_type,
a61af66fc99e Initial load
duke
parents:
diff changeset
127 StackMapFrame* current_frame, u4 code_length, bool* this_uninit,
a61af66fc99e Initial load
duke
parents:
diff changeset
128 constantPoolHandle cp, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
129
a61af66fc99e Initial load
duke
parents:
diff changeset
130 void verify_invoke_instructions(
a61af66fc99e Initial load
duke
parents:
diff changeset
131 RawBytecodeStream* bcs, u4 code_length, StackMapFrame* current_frame,
a61af66fc99e Initial load
duke
parents:
diff changeset
132 bool* this_uninit, VerificationType return_type,
a61af66fc99e Initial load
duke
parents:
diff changeset
133 constantPoolHandle cp, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
134
a61af66fc99e Initial load
duke
parents:
diff changeset
135 VerificationType get_newarray_type(u2 index, u2 bci, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
136 void verify_anewarray(
a61af66fc99e Initial load
duke
parents:
diff changeset
137 u2 index, constantPoolHandle cp, StackMapFrame* current_frame, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
138 void verify_return_value(
a61af66fc99e Initial load
duke
parents:
diff changeset
139 VerificationType return_type, VerificationType type, u2 offset, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
140
a61af66fc99e Initial load
duke
parents:
diff changeset
141 void verify_iload (u2 index, StackMapFrame* current_frame, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
142 void verify_lload (u2 index, StackMapFrame* current_frame, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
143 void verify_fload (u2 index, StackMapFrame* current_frame, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
144 void verify_dload (u2 index, StackMapFrame* current_frame, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
145 void verify_aload (u2 index, StackMapFrame* current_frame, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
146 void verify_istore(u2 index, StackMapFrame* current_frame, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
147 void verify_lstore(u2 index, StackMapFrame* current_frame, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
148 void verify_fstore(u2 index, StackMapFrame* current_frame, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
149 void verify_dstore(u2 index, StackMapFrame* current_frame, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
150 void verify_astore(u2 index, StackMapFrame* current_frame, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
151 void verify_iinc (u2 index, StackMapFrame* current_frame, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
152
a61af66fc99e Initial load
duke
parents:
diff changeset
153 bool name_in_supers(symbolOop ref_name, instanceKlassHandle current);
a61af66fc99e Initial load
duke
parents:
diff changeset
154
a61af66fc99e Initial load
duke
parents:
diff changeset
155 instanceKlassHandle _klass; // the class being verified
a61af66fc99e Initial load
duke
parents:
diff changeset
156 methodHandle _method; // current method being verified
a61af66fc99e Initial load
duke
parents:
diff changeset
157 VerificationType _this_type; // the verification type of the current class
a61af66fc99e Initial load
duke
parents:
diff changeset
158
a61af66fc99e Initial load
duke
parents:
diff changeset
159 public:
a61af66fc99e Initial load
duke
parents:
diff changeset
160 enum {
a61af66fc99e Initial load
duke
parents:
diff changeset
161 BYTECODE_OFFSET = 1,
a61af66fc99e Initial load
duke
parents:
diff changeset
162 NEW_OFFSET = 2
a61af66fc99e Initial load
duke
parents:
diff changeset
163 };
a61af66fc99e Initial load
duke
parents:
diff changeset
164
a61af66fc99e Initial load
duke
parents:
diff changeset
165 // constructor
a61af66fc99e Initial load
duke
parents:
diff changeset
166 ClassVerifier(instanceKlassHandle klass, char* msg, size_t msg_len, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
167
a61af66fc99e Initial load
duke
parents:
diff changeset
168 // destructor
a61af66fc99e Initial load
duke
parents:
diff changeset
169 ~ClassVerifier();
a61af66fc99e Initial load
duke
parents:
diff changeset
170
a61af66fc99e Initial load
duke
parents:
diff changeset
171 Thread* thread() { return _thread; }
a61af66fc99e Initial load
duke
parents:
diff changeset
172 methodHandle method() { return _method; }
a61af66fc99e Initial load
duke
parents:
diff changeset
173 instanceKlassHandle current_class() const { return _klass; }
a61af66fc99e Initial load
duke
parents:
diff changeset
174 VerificationType current_type() const { return _this_type; }
a61af66fc99e Initial load
duke
parents:
diff changeset
175
a61af66fc99e Initial load
duke
parents:
diff changeset
176 // Verifies the class. If a verify or class file format error occurs,
a61af66fc99e Initial load
duke
parents:
diff changeset
177 // the '_exception_name' symbols will set to the exception name and
a61af66fc99e Initial load
duke
parents:
diff changeset
178 // the message_buffer will be filled in with the exception message.
a61af66fc99e Initial load
duke
parents:
diff changeset
179 void verify_class(TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
180
a61af66fc99e Initial load
duke
parents:
diff changeset
181 // Return status modes
a61af66fc99e Initial load
duke
parents:
diff changeset
182 symbolHandle result() const { return _exception_type; }
a61af66fc99e Initial load
duke
parents:
diff changeset
183 bool has_error() const { return !(result().is_null()); }
a61af66fc99e Initial load
duke
parents:
diff changeset
184
a61af66fc99e Initial load
duke
parents:
diff changeset
185 // Called when verify or class format errors are encountered.
a61af66fc99e Initial load
duke
parents:
diff changeset
186 // May throw an exception based upon the mode.
a61af66fc99e Initial load
duke
parents:
diff changeset
187 void verify_error(u2 offset, const char* fmt, ...);
a61af66fc99e Initial load
duke
parents:
diff changeset
188 void verify_error(const char* fmt, ...);
a61af66fc99e Initial load
duke
parents:
diff changeset
189 void class_format_error(const char* fmt, ...);
a61af66fc99e Initial load
duke
parents:
diff changeset
190 void format_error_message(const char* fmt, int offset, va_list args);
a61af66fc99e Initial load
duke
parents:
diff changeset
191
a61af66fc99e Initial load
duke
parents:
diff changeset
192 klassOop load_class(symbolHandle name, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
193
a61af66fc99e Initial load
duke
parents:
diff changeset
194 int change_sig_to_verificationType(
a61af66fc99e Initial load
duke
parents:
diff changeset
195 SignatureStream* sig_type, VerificationType* inference_type, TRAPS);
a61af66fc99e Initial load
duke
parents:
diff changeset
196
a61af66fc99e Initial load
duke
parents:
diff changeset
197 VerificationType cp_index_to_type(int index, constantPoolHandle cp, TRAPS) {
a61af66fc99e Initial load
duke
parents:
diff changeset
198 return VerificationType::reference_type(
a61af66fc99e Initial load
duke
parents:
diff changeset
199 symbolHandle(THREAD, cp->klass_name_at(index)));
a61af66fc99e Initial load
duke
parents:
diff changeset
200 }
a61af66fc99e Initial load
duke
parents:
diff changeset
201
a61af66fc99e Initial load
duke
parents:
diff changeset
202 static bool _verify_verbose; // for debugging
a61af66fc99e Initial load
duke
parents:
diff changeset
203 };
a61af66fc99e Initial load
duke
parents:
diff changeset
204
a61af66fc99e Initial load
duke
parents:
diff changeset
205 inline int ClassVerifier::change_sig_to_verificationType(
a61af66fc99e Initial load
duke
parents:
diff changeset
206 SignatureStream* sig_type, VerificationType* inference_type, TRAPS) {
a61af66fc99e Initial load
duke
parents:
diff changeset
207 BasicType bt = sig_type->type();
a61af66fc99e Initial load
duke
parents:
diff changeset
208 switch (bt) {
a61af66fc99e Initial load
duke
parents:
diff changeset
209 case T_OBJECT:
a61af66fc99e Initial load
duke
parents:
diff changeset
210 case T_ARRAY:
a61af66fc99e Initial load
duke
parents:
diff changeset
211 {
a61af66fc99e Initial load
duke
parents:
diff changeset
212 symbolOop name = sig_type->as_symbol(CHECK_0);
a61af66fc99e Initial load
duke
parents:
diff changeset
213 *inference_type =
a61af66fc99e Initial load
duke
parents:
diff changeset
214 VerificationType::reference_type(symbolHandle(THREAD, name));
a61af66fc99e Initial load
duke
parents:
diff changeset
215 return 1;
a61af66fc99e Initial load
duke
parents:
diff changeset
216 }
a61af66fc99e Initial load
duke
parents:
diff changeset
217 case T_LONG:
a61af66fc99e Initial load
duke
parents:
diff changeset
218 *inference_type = VerificationType::long_type();
a61af66fc99e Initial load
duke
parents:
diff changeset
219 *++inference_type = VerificationType::long2_type();
a61af66fc99e Initial load
duke
parents:
diff changeset
220 return 2;
a61af66fc99e Initial load
duke
parents:
diff changeset
221 case T_DOUBLE:
a61af66fc99e Initial load
duke
parents:
diff changeset
222 *inference_type = VerificationType::double_type();
a61af66fc99e Initial load
duke
parents:
diff changeset
223 *++inference_type = VerificationType::double2_type();
a61af66fc99e Initial load
duke
parents:
diff changeset
224 return 2;
a61af66fc99e Initial load
duke
parents:
diff changeset
225 case T_INT:
a61af66fc99e Initial load
duke
parents:
diff changeset
226 case T_BOOLEAN:
a61af66fc99e Initial load
duke
parents:
diff changeset
227 case T_BYTE:
a61af66fc99e Initial load
duke
parents:
diff changeset
228 case T_CHAR:
a61af66fc99e Initial load
duke
parents:
diff changeset
229 case T_SHORT:
a61af66fc99e Initial load
duke
parents:
diff changeset
230 *inference_type = VerificationType::integer_type();
a61af66fc99e Initial load
duke
parents:
diff changeset
231 return 1;
a61af66fc99e Initial load
duke
parents:
diff changeset
232 case T_FLOAT:
a61af66fc99e Initial load
duke
parents:
diff changeset
233 *inference_type = VerificationType::float_type();
a61af66fc99e Initial load
duke
parents:
diff changeset
234 return 1;
a61af66fc99e Initial load
duke
parents:
diff changeset
235 default:
a61af66fc99e Initial load
duke
parents:
diff changeset
236 ShouldNotReachHere();
a61af66fc99e Initial load
duke
parents:
diff changeset
237 return 1;
a61af66fc99e Initial load
duke
parents:
diff changeset
238 }
a61af66fc99e Initial load
duke
parents:
diff changeset
239 }