| OLD | NEW |
| 1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 232 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 243 void FlattenString(Handle<String> string) { | 243 void FlattenString(Handle<String> string) { |
| 244 CALL_HEAP_FUNCTION_VOID(string->GetIsolate(), string->TryFlatten()); | 244 CALL_HEAP_FUNCTION_VOID(string->GetIsolate(), string->TryFlatten()); |
| 245 } | 245 } |
| 246 | 246 |
| 247 | 247 |
| 248 Handle<String> FlattenGetString(Handle<String> string) { | 248 Handle<String> FlattenGetString(Handle<String> string) { |
| 249 CALL_HEAP_FUNCTION(string->GetIsolate(), string->TryFlatten(), String); | 249 CALL_HEAP_FUNCTION(string->GetIsolate(), string->TryFlatten(), String); |
| 250 } | 250 } |
| 251 | 251 |
| 252 | 252 |
| 253 void TruncateString(Handle<String> string) { |
| 254 CALL_HEAP_FUNCTION_VOID(string->GetIsolate(), string->TryTruncate()); |
| 255 } |
| 256 |
| 257 |
| 258 Handle<String> TruncateGetString(Handle<String> string) { |
| 259 CALL_HEAP_FUNCTION(string->GetIsolate(), string->TryTruncate(), String); |
| 260 } |
| 261 |
| 262 |
| 263 void FlattenOrTruncateString(Handle<String> string) { |
| 264 CALL_HEAP_FUNCTION_VOID(string->GetIsolate(), string->TryFlattenOrTruncate()); |
| 265 } |
| 266 |
| 267 |
| 253 Handle<Object> SetPrototype(Handle<JSFunction> function, | 268 Handle<Object> SetPrototype(Handle<JSFunction> function, |
| 254 Handle<Object> prototype) { | 269 Handle<Object> prototype) { |
| 255 ASSERT(function->should_have_prototype()); | 270 ASSERT(function->should_have_prototype()); |
| 256 CALL_HEAP_FUNCTION(function->GetIsolate(), | 271 CALL_HEAP_FUNCTION(function->GetIsolate(), |
| 257 Accessors::FunctionSetPrototype(*function, | 272 Accessors::FunctionSetPrototype(*function, |
| 258 *prototype, | 273 *prototype, |
| 259 NULL), | 274 NULL), |
| 260 Object); | 275 Object); |
| 261 } | 276 } |
| 262 | 277 |
| (...skipping 703 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 966 | 981 |
| 967 bool CompileOptimized(Handle<JSFunction> function, | 982 bool CompileOptimized(Handle<JSFunction> function, |
| 968 int osr_ast_id, | 983 int osr_ast_id, |
| 969 ClearExceptionFlag flag) { | 984 ClearExceptionFlag flag) { |
| 970 CompilationInfo info(function); | 985 CompilationInfo info(function); |
| 971 info.SetOptimizing(osr_ast_id); | 986 info.SetOptimizing(osr_ast_id); |
| 972 return CompileLazyHelper(&info, flag); | 987 return CompileLazyHelper(&info, flag); |
| 973 } | 988 } |
| 974 | 989 |
| 975 } } // namespace v8::internal | 990 } } // namespace v8::internal |
| OLD | NEW |