Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(29)

Side by Side Diff: src/messages.js

Issue 185653004: Experimental parser: merge to r19637 (Closed) Base URL: https://v8.googlecode.com/svn/branches/experimental/parser
Patch Set: Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/messages.cc ('k') | src/mips/assembler-mips.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 apply_non_function: ["Function.prototype.apply was called on ", "%0 ", ", which is a ", "%1", " and not a function"], 71 apply_non_function: ["Function.prototype.apply was called on ", "%0 ", ", which is a ", "%1", " and not a function"],
72 apply_wrong_args: ["Function.prototype.apply: Arguments list has wrong type"], 72 apply_wrong_args: ["Function.prototype.apply: Arguments list has wrong type"],
73 invalid_in_operator_use: ["Cannot use 'in' operator to search for '", "% 0", "' in ", "%1"], 73 invalid_in_operator_use: ["Cannot use 'in' operator to search for '", "% 0", "' in ", "%1"],
74 instanceof_function_expected: ["Expecting a function in instanceof check, but got ", "%0"], 74 instanceof_function_expected: ["Expecting a function in instanceof check, but got ", "%0"],
75 instanceof_nonobject_proto: ["Function has non-object prototype '", "%0", " ' in instanceof check"], 75 instanceof_nonobject_proto: ["Function has non-object prototype '", "%0", " ' in instanceof check"],
76 undefined_or_null_to_object: ["Cannot convert undefined or null to object"], 76 undefined_or_null_to_object: ["Cannot convert undefined or null to object"],
77 reduce_no_initial: ["Reduce of empty array with no initial value"] , 77 reduce_no_initial: ["Reduce of empty array with no initial value"] ,
78 getter_must_be_callable: ["Getter must be a function: ", "%0"], 78 getter_must_be_callable: ["Getter must be a function: ", "%0"],
79 setter_must_be_callable: ["Setter must be a function: ", "%0"], 79 setter_must_be_callable: ["Setter must be a function: ", "%0"],
80 value_and_accessor: ["Invalid property. A property cannot both hav e accessors and be writable or have a value, ", "%0"], 80 value_and_accessor: ["Invalid property. A property cannot both hav e accessors and be writable or have a value, ", "%0"],
81 proto_object_or_null: ["Object prototype may only be an Object or nul l"], 81 proto_object_or_null: ["Object prototype may only be an Object or nul l: ", "%0"],
82 property_desc_object: ["Property description must be an object: ", "% 0"], 82 property_desc_object: ["Property description must be an object: ", "% 0"],
83 redefine_disallowed: ["Cannot redefine property: ", "%0"], 83 redefine_disallowed: ["Cannot redefine property: ", "%0"],
84 define_disallowed: ["Cannot define property:", "%0", ", object is not extensible."], 84 define_disallowed: ["Cannot define property:", "%0", ", object is not extensible."],
85 non_extensible_proto: ["%0", " is not extensible"], 85 non_extensible_proto: ["%0", " is not extensible"],
86 handler_non_object: ["Proxy.", "%0", " called with non-object as ha ndler"], 86 handler_non_object: ["Proxy.", "%0", " called with non-object as ha ndler"],
87 proto_non_object: ["Proxy.", "%0", " called with non-object as pr ototype"], 87 proto_non_object: ["Proxy.", "%0", " called with non-object as pr ototype"],
88 trap_function_expected: ["Proxy.", "%0", " called with non-function for '", "%1", "' trap"], 88 trap_function_expected: ["Proxy.", "%0", " called with non-function for '", "%1", "' trap"],
89 handler_trap_missing: ["Proxy handler ", "%0", " has no '", "%1", "' trap"], 89 handler_trap_missing: ["Proxy handler ", "%0", " has no '", "%1", "' trap"],
90 handler_trap_must_be_callable: ["Proxy handler ", "%0", " has non-callable '", "%1", "' trap"], 90 handler_trap_must_be_callable: ["Proxy handler ", "%0", " has non-callable '", "%1", "' trap"],
91 handler_returned_false: ["Proxy handler ", "%0", " returned false from '", "%1", "' trap"], 91 handler_returned_false: ["Proxy handler ", "%0", " returned false from '", "%1", "' trap"],
92 handler_returned_undefined: ["Proxy handler ", "%0", " returned undefined f rom '", "%1", "' trap"], 92 handler_returned_undefined: ["Proxy handler ", "%0", " returned undefined f rom '", "%1", "' trap"],
93 proxy_prop_not_configurable: ["Proxy handler ", "%0", " returned non-configu rable descriptor for property '", "%2", "' from '", "%1", "' trap"], 93 proxy_prop_not_configurable: ["Proxy handler ", "%0", " returned non-configu rable descriptor for property '", "%2", "' from '", "%1", "' trap"],
94 proxy_non_object_prop_names: ["Trap '", "%1", "' returned non-object ", "%0" ], 94 proxy_non_object_prop_names: ["Trap '", "%1", "' returned non-object ", "%0" ],
95 proxy_repeated_prop_name: ["Trap '", "%1", "' returned repeated property name '", "%2", "'"], 95 proxy_repeated_prop_name: ["Trap '", "%1", "' returned repeated property name '", "%2", "'"],
96 invalid_weakmap_key: ["Invalid value used as weak map key"], 96 invalid_weakmap_key: ["Invalid value used as weak map key"],
97 invalid_weakset_value: ["Invalid value used in weak set"], 97 invalid_weakset_value: ["Invalid value used in weak set"],
98 not_date_object: ["this is not a Date object."], 98 not_date_object: ["this is not a Date object."],
99 observe_non_object: ["Object.", "%0", " cannot ", "%0", " non-objec t"], 99 observe_non_object: ["Object.", "%0", " cannot ", "%0", " non-objec t"],
100 observe_non_function: ["Object.", "%0", " cannot deliver to non-funct ion"], 100 observe_non_function: ["Object.", "%0", " cannot deliver to non-funct ion"],
101 observe_callback_frozen: ["Object.observe cannot deliver to a frozen fun ction object"], 101 observe_callback_frozen: ["Object.observe cannot deliver to a frozen fun ction object"],
102 observe_invalid_accept: ["Object.observe accept must be an array of str ings."], 102 observe_invalid_accept: ["Object.observe accept must be an array of str ings."],
103 observe_type_non_string: ["Invalid changeRecord with non-string 'type' p roperty"], 103 observe_type_non_string: ["Invalid changeRecord with non-string 'type' p roperty"],
104 observe_perform_non_string: ["Invalid non-string changeType"], 104 observe_perform_non_string: ["Invalid non-string changeType"],
105 observe_perform_non_function: ["Cannot perform non-function"], 105 observe_perform_non_function: ["Cannot perform non-function"],
106 observe_notify_non_notifier: ["notify called on non-notifier object"], 106 observe_notify_non_notifier: ["notify called on non-notifier object"],
107 proto_poison_pill: ["Generic use of __proto__ accessor not allowed "],
108 not_typed_array: ["this is not a typed array."], 107 not_typed_array: ["this is not a typed array."],
109 invalid_argument: ["invalid_argument"], 108 invalid_argument: ["invalid_argument"],
110 data_view_not_array_buffer: ["First argument to DataView constructor must b e an ArrayBuffer"], 109 data_view_not_array_buffer: ["First argument to DataView constructor must b e an ArrayBuffer"],
111 constructor_not_function: ["Constructor ", "%0", " requires 'new'"], 110 constructor_not_function: ["Constructor ", "%0", " requires 'new'"],
112 not_a_promise: ["%0", " is not a promise"], 111 not_a_promise: ["%0", " is not a promise"],
113 resolver_not_a_function: ["Promise resolver ", "%0", " is not a function "], 112 resolver_not_a_function: ["Promise resolver ", "%0", " is not a function "],
114 promise_cyclic: ["Chaining cycle detected for promise ", "%0"], 113 promise_cyclic: ["Chaining cycle detected for promise ", "%0"],
115 array_functions_on_frozen: ["Cannot modify frozen array elements"], 114 array_functions_on_frozen: ["Cannot modify frozen array elements"],
116 array_functions_change_sealed: ["Cannot add/remove sealed array elements"], 115 array_functions_change_sealed: ["Cannot add/remove sealed array elements"],
116 first_argument_not_regexp: ["First argument to ", "%0", " must not be a re gular expression"],
117 // RangeError 117 // RangeError
118 invalid_array_length: ["Invalid array length"], 118 invalid_array_length: ["Invalid array length"],
119 invalid_array_buffer_length: ["Invalid array buffer length"], 119 invalid_array_buffer_length: ["Invalid array buffer length"],
120 invalid_string_length: ["Invalid string length"],
120 invalid_typed_array_offset: ["Start offset is too large:"], 121 invalid_typed_array_offset: ["Start offset is too large:"],
121 invalid_typed_array_length: ["Invalid typed array length"], 122 invalid_typed_array_length: ["Invalid typed array length"],
122 invalid_typed_array_alignment: ["%0", "of", "%1", "should be a multiple of", " %3"], 123 invalid_typed_array_alignment: ["%0", " of ", "%1", " should be a multiple of ", "%2"],
123 typed_array_set_source_too_large: 124 typed_array_set_source_too_large:
124 ["Source is too large"], 125 ["Source is too large"],
125 typed_array_set_negative_offset: 126 typed_array_set_negative_offset:
126 ["Start offset is negative"], 127 ["Start offset is negative"],
127 invalid_data_view_offset: ["Start offset is outside the bounds of the buf fer"], 128 invalid_data_view_offset: ["Start offset is outside the bounds of the buf fer"],
128 invalid_data_view_length: ["Invalid data view length"], 129 invalid_data_view_length: ["Invalid data view length"],
129 invalid_data_view_accessor_offset: 130 invalid_data_view_accessor_offset:
130 ["Offset is outside the bounds of the DataView" ], 131 ["Offset is outside the bounds of the DataView" ],
131 132
132 stack_overflow: ["Maximum call stack size exceeded"], 133 stack_overflow: ["Maximum call stack size exceeded"],
(...skipping 13 matching lines...) Expand all
146 no_input_to_regexp: ["No input to ", "%0"], 147 no_input_to_regexp: ["No input to ", "%0"],
147 invalid_json: ["String '", "%0", "' is not valid JSON"], 148 invalid_json: ["String '", "%0", "' is not valid JSON"],
148 circular_structure: ["Converting circular structure to JSON"], 149 circular_structure: ["Converting circular structure to JSON"],
149 called_on_non_object: ["%0", " called on non-object"], 150 called_on_non_object: ["%0", " called on non-object"],
150 called_on_null_or_undefined: ["%0", " called on null or undefined"], 151 called_on_null_or_undefined: ["%0", " called on null or undefined"],
151 array_indexof_not_defined: ["Array.getIndexOf: Argument undefined"], 152 array_indexof_not_defined: ["Array.getIndexOf: Argument undefined"],
152 object_not_extensible: ["Can't add property ", "%0", ", object is not extensible"], 153 object_not_extensible: ["Can't add property ", "%0", ", object is not extensible"],
153 illegal_access: ["Illegal access"], 154 illegal_access: ["Illegal access"],
154 invalid_preparser_data: ["Invalid preparser data for function ", "%0"], 155 invalid_preparser_data: ["Invalid preparser data for function ", "%0"],
155 strict_mode_with: ["Strict mode code may not include a with state ment"], 156 strict_mode_with: ["Strict mode code may not include a with state ment"],
156 strict_catch_variable: ["Catch variable may not be eval or arguments i n strict mode"], 157 strict_eval_arguments: ["Unexpected eval or arguments in strict mode"] ,
157 too_many_arguments: ["Too many arguments in function call (only 327 66 allowed)"], 158 too_many_arguments: ["Too many arguments in function call (only 327 66 allowed)"],
158 too_many_parameters: ["Too many parameters in function definition (o nly 32766 allowed)"], 159 too_many_parameters: ["Too many parameters in function definition (o nly 32766 allowed)"],
159 too_many_variables: ["Too many variables declared (only 131071 allo wed)"], 160 too_many_variables: ["Too many variables declared (only 131071 allo wed)"],
160 strict_param_name: ["Parameter name eval or arguments is not allow ed in strict mode"],
161 strict_param_dupe: ["Strict mode function may not have duplicate p arameter names"], 161 strict_param_dupe: ["Strict mode function may not have duplicate p arameter names"],
162 strict_var_name: ["Variable name may not be eval or arguments in strict mode"],
163 strict_function_name: ["Function name may not be eval or arguments in strict mode"],
164 strict_octal_literal: ["Octal literals are not allowed in strict mode ."], 162 strict_octal_literal: ["Octal literals are not allowed in strict mode ."],
165 strict_duplicate_property: ["Duplicate data property in object literal not allowed in strict mode"], 163 strict_duplicate_property: ["Duplicate data property in object literal not allowed in strict mode"],
166 accessor_data_property: ["Object literal may not have data and accessor property with the same name"], 164 accessor_data_property: ["Object literal may not have data and accessor property with the same name"],
167 accessor_get_set: ["Object literal may not have multiple get/set accessors with the same name"], 165 accessor_get_set: ["Object literal may not have multiple get/set accessors with the same name"],
168 strict_lhs_assignment: ["Assignment to eval or arguments is not allowe d in strict mode"],
169 strict_lhs_postfix: ["Postfix increment/decrement may not have eval or arguments operand in strict mode"],
170 strict_lhs_prefix: ["Prefix increment/decrement may not have eval or arguments operand in strict mode"],
171 strict_reserved_word: ["Use of future reserved word in strict mode"],
172 strict_delete: ["Delete of an unqualified identifier in strict mode."], 166 strict_delete: ["Delete of an unqualified identifier in strict mode."],
173 strict_delete_property: ["Cannot delete property '", "%0", "' of ", "%1 "], 167 strict_delete_property: ["Cannot delete property '", "%0", "' of ", "%1 "],
174 strict_const: ["Use of const in strict mode."], 168 strict_const: ["Use of const in strict mode."],
175 strict_function: ["In strict mode code, functions can only be de clared at top level or immediately within another function." ], 169 strict_function: ["In strict mode code, functions can only be de clared at top level or immediately within another function." ],
176 strict_read_only_property: ["Cannot assign to read only property '", "%0", "' of ", "%1"], 170 strict_read_only_property: ["Cannot assign to read only property '", "%0", "' of ", "%1"],
177 strict_cannot_assign: ["Cannot assign to read only '", "%0", "' in st rict mode"], 171 strict_cannot_assign: ["Cannot assign to read only '", "%0", "' in st rict mode"],
178 strict_poison_pill: ["'caller', 'callee', and 'arguments' propertie s may not be accessed on strict mode functions or the arguments objects for call s to them"], 172 strict_poison_pill: ["'caller', 'callee', and 'arguments' propertie s may not be accessed on strict mode functions or the arguments objects for call s to them"],
179 strict_caller: ["Illegal access to a strict mode caller functi on."], 173 strict_caller: ["Illegal access to a strict mode caller functi on."],
180 unprotected_let: ["Illegal let declaration in unprotected statem ent context."], 174 unprotected_let: ["Illegal let declaration in unprotected statem ent context."],
181 unprotected_const: ["Illegal const declaration in unprotected stat ement context."], 175 unprotected_const: ["Illegal const declaration in unprotected stat ement context."],
182 cant_prevent_ext_external_array_elements: ["Cannot prevent extension of an obj ect with external array elements"], 176 cant_prevent_ext_external_array_elements: ["Cannot prevent extension of an obj ect with external array elements"],
183 redef_external_array_element: ["Cannot redefine a property of an object with external array elements"], 177 redef_external_array_element: ["Cannot redefine a property of an object with external array elements"],
184 harmony_const_assign: ["Assignment to constant variable."], 178 harmony_const_assign: ["Assignment to constant variable."],
185 symbol_to_string: ["Conversion from symbol to string"], 179 symbol_to_string: ["Cannot convert a Symbol value to a string"],
180 symbol_to_primitive: ["Cannot convert a Symbol wrapper object to a p rimitive value"],
186 invalid_module_path: ["Module does not export '", "%0", "', or expor t is not itself a module"], 181 invalid_module_path: ["Module does not export '", "%0", "', or expor t is not itself a module"],
187 module_type_error: ["Module '", "%0", "' used improperly"], 182 module_type_error: ["Module '", "%0", "' used improperly"],
188 module_export_undefined: ["Export '", "%0", "' is not defined in module" ] 183 module_export_undefined: ["Export '", "%0", "' is not defined in module" ]
189 }; 184 };
190 185
191 186
192 function FormatString(format, args) { 187 function FormatString(format, args) {
193 var result = ""; 188 var result = "";
194 var arg_num = 0; 189 var arg_num = 0;
195 for (var i = 0; i < format.length; i++) { 190 for (var i = 0; i < format.length; i++) {
(...skipping 742 matching lines...) Expand 10 before | Expand all | Expand 10 after
938 if (!constructor) return false; 933 if (!constructor) return false;
939 return GET_PRIVATE(this, CallSiteFunctionKey) === constructor; 934 return GET_PRIVATE(this, CallSiteFunctionKey) === constructor;
940 } 935 }
941 936
942 function CallSiteToString() { 937 function CallSiteToString() {
943 var fileName; 938 var fileName;
944 var fileLocation = ""; 939 var fileLocation = "";
945 if (this.isNative()) { 940 if (this.isNative()) {
946 fileLocation = "native"; 941 fileLocation = "native";
947 } else { 942 } else {
948 if (this.isEval()) { 943 fileName = this.getScriptNameOrSourceURL();
949 fileName = this.getScriptNameOrSourceURL(); 944 if (!fileName && this.isEval()) {
950 if (!fileName) { 945 fileLocation = this.getEvalOrigin();
951 fileLocation = this.getEvalOrigin(); 946 fileLocation += ", "; // Expecting source position to follow.
952 fileLocation += ", "; // Expecting source position to follow.
953 }
954 } else {
955 fileName = this.getFileName();
956 } 947 }
957 948
958 if (fileName) { 949 if (fileName) {
959 fileLocation += fileName; 950 fileLocation += fileName;
960 } else { 951 } else {
961 // Source code does not originate from a file and is not native, but we 952 // Source code does not originate from a file and is not native, but we
962 // can still get the source position inside the source string, e.g. in 953 // can still get the source position inside the source string, e.g. in
963 // an eval string. 954 // an eval string.
964 fileLocation += "<anonymous>"; 955 fileLocation += "<anonymous>";
965 } 956 }
(...skipping 390 matching lines...) Expand 10 before | Expand all | Expand 10 after
1356 %GetAndClearOverflowedStackTrace(this); 1347 %GetAndClearOverflowedStackTrace(this);
1357 }; 1348 };
1358 1349
1359 %DefineOrRedefineAccessorProperty( 1350 %DefineOrRedefineAccessorProperty(
1360 boilerplate, 'stack', getter, setter, DONT_ENUM); 1351 boilerplate, 'stack', getter, setter, DONT_ENUM);
1361 1352
1362 return boilerplate; 1353 return boilerplate;
1363 } 1354 }
1364 1355
1365 var kStackOverflowBoilerplate = SetUpStackOverflowBoilerplate(); 1356 var kStackOverflowBoilerplate = SetUpStackOverflowBoilerplate();
OLDNEW
« no previous file with comments | « src/messages.cc ('k') | src/mips/assembler-mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698