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

Side by Side Diff: runtime/vm/object.h

Issue 10695137: Provide better error message when passing wrong number of arguments. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 5 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
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #ifndef VM_OBJECT_H_ 5 #ifndef VM_OBJECT_H_
6 #define VM_OBJECT_H_ 6 #define VM_OBJECT_H_
7 7
8 #include "include/dart_api.h" 8 #include "include/dart_api.h"
9 #include "platform/assert.h" 9 #include "platform/assert.h"
10 #include "platform/utils.h" 10 #include "platform/utils.h"
(...skipping 1442 matching lines...) Expand 10 before | Expand all | Expand 10 after
1453 return raw_ptr()->is_optimizable_; 1453 return raw_ptr()->is_optimizable_;
1454 } 1454 }
1455 void set_is_optimizable(bool value) const; 1455 void set_is_optimizable(bool value) const;
1456 1456
1457 bool is_native() const { return raw_ptr()->is_native_; } 1457 bool is_native() const { return raw_ptr()->is_native_; }
1458 void set_is_native(bool value) const; 1458 void set_is_native(bool value) const;
1459 1459
1460 bool HasOptimizedCode() const; 1460 bool HasOptimizedCode() const;
1461 1461
1462 intptr_t NumberOfParameters() const; 1462 intptr_t NumberOfParameters() const;
1463 intptr_t NumberOfImplicitParameters() const;
1463 1464
1464 bool AreValidArgumentCounts(int num_arguments, int num_named_arguments) const; 1465 bool AreValidArgumentCounts(int num_arguments,
srdjan 2012/07/12 00:06:37 Add comment what message_buffer contains and that
regis 2012/07/12 17:37:36 Done
1465 bool AreValidArguments(int num_arguments, const Array& argument_names) const; 1466 int num_named_arguments,
1467 char* message_buffer,
1468 intptr_t message_buffer_size) const;
1469 bool AreValidArguments(int num_arguments,
1470 const Array& argument_names,
1471 char* message_buffer,
1472 intptr_t message_buffer_size) const;
1466 1473
srdjan 2012/07/12 00:06:37 Instead of passing the and allocating the message_
regis 2012/07/12 17:37:36 Both functions now take a pointer to a String hand
1467 // Fully qualified name uniquely identifying the function under gdb and during 1474 // Fully qualified name uniquely identifying the function under gdb and during
1468 // ast printing. The special ':' character, if present, is replaced by '_'. 1475 // ast printing. The special ':' character, if present, is replaced by '_'.
1469 const char* ToFullyQualifiedCString() const; 1476 const char* ToFullyQualifiedCString() const;
1470 1477
1471 // Returns true if this function has parameters that are compatible with the 1478 // Returns true if this function has parameters that are compatible with the
1472 // parameters of the other function in order for this function to override the 1479 // parameters of the other function in order for this function to override the
1473 // other function. Parameter types are ignored. 1480 // other function. Parameter types are ignored.
1474 bool HasCompatibleParametersWith(const Function& other) const; 1481 bool HasCompatibleParametersWith(const Function& other) const;
1475 1482
1476 // Returns true if the type of this function is a subtype of the type of 1483 // Returns true if the type of this function is a subtype of the type of
(...skipping 3642 matching lines...) Expand 10 before | Expand all | Expand 10 after
5119 } 5126 }
5120 5127
5121 5128
5122 intptr_t Stackmap::SizeInBits() const { 5129 intptr_t Stackmap::SizeInBits() const {
5123 return (Smi::Value(raw_ptr()->bitmap_size_in_bytes_) * kBitsPerByte); 5130 return (Smi::Value(raw_ptr()->bitmap_size_in_bytes_) * kBitsPerByte);
5124 } 5131 }
5125 5132
5126 } // namespace dart 5133 } // namespace dart
5127 5134
5128 #endif // VM_OBJECT_H_ 5135 #endif // VM_OBJECT_H_
OLDNEW
« no previous file with comments | « runtime/vm/dart_api_impl_test.cc ('k') | runtime/vm/object.cc » ('j') | runtime/vm/object.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698