Index: runtime/vm/code_generator.cc |
diff --git a/runtime/vm/code_generator.cc b/runtime/vm/code_generator.cc |
index e66fd701992f80324c57297194cfd372cdbff386..0a207de71a5df68920f4bbeb5741de86c09a8019 100644 |
--- a/runtime/vm/code_generator.cc |
+++ b/runtime/vm/code_generator.cc |
@@ -148,7 +148,7 @@ DEFINE_RUNTIME_ENTRY(AllocateArray, 2) { |
// Helper returning the token position of the Dart caller. |
-static intptr_t GetCallerLocation() { |
+static TokenPosition GetCallerLocation() { |
DartFrameIterator iterator; |
StackFrame* caller_frame = iterator.NextFrame(); |
ASSERT(caller_frame != NULL); |
@@ -208,7 +208,7 @@ DEFINE_RUNTIME_ENTRY(InstantiateType, 2) { |
type = type.InstantiateFrom(instantiator, &bound_error, NULL, Heap::kOld); |
if (!bound_error.IsNull()) { |
// Throw a dynamic type error. |
- const intptr_t location = GetCallerLocation(); |
+ const TokenPosition location = GetCallerLocation(); |
String& bound_error_message = String::Handle( |
String::New(bound_error.ToErrorCString())); |
Exceptions::CreateAndThrowTypeError( |
@@ -247,7 +247,7 @@ DEFINE_RUNTIME_ENTRY(InstantiateTypeArguments, 2) { |
&bound_error); |
if (!bound_error.IsNull()) { |
// Throw a dynamic type error. |
- const intptr_t location = GetCallerLocation(); |
+ const TokenPosition location = GetCallerLocation(); |
String& bound_error_message = String::Handle( |
String::New(bound_error.ToErrorCString())); |
Exceptions::CreateAndThrowTypeError( |
@@ -476,7 +476,7 @@ DEFINE_RUNTIME_ENTRY(Instanceof, 4) { |
} |
if (!result.value() && !bound_error.IsNull()) { |
// Throw a dynamic type error only if the instanceof test fails. |
- const intptr_t location = GetCallerLocation(); |
+ const TokenPosition location = GetCallerLocation(); |
String& bound_error_message = String::Handle( |
String::New(bound_error.ToErrorCString())); |
Exceptions::CreateAndThrowTypeError( |
@@ -523,7 +523,7 @@ DEFINE_RUNTIME_ENTRY(TypeCheck, 5) { |
} |
if (!is_instance_of) { |
// Throw a dynamic type error. |
- const intptr_t location = GetCallerLocation(); |
+ const TokenPosition location = GetCallerLocation(); |
const AbstractType& src_type = AbstractType::Handle(src_instance.GetType()); |
String& src_type_name = String::Handle(src_type.UserVisibleName()); |
String& dst_type_name = String::Handle(); |
@@ -576,7 +576,7 @@ DEFINE_RUNTIME_ENTRY(TypeCheck, 5) { |
// Arg0: bad object. |
// Return value: none, throws TypeError or AssertionError. |
DEFINE_RUNTIME_ENTRY(NonBoolTypeError, 1) { |
- const intptr_t location = GetCallerLocation(); |
+ const TokenPosition location = GetCallerLocation(); |
const Instance& src_instance = Instance::CheckedHandle(arguments.ArgAt(0)); |
if (src_instance.IsNull()) { |
@@ -613,7 +613,7 @@ DEFINE_RUNTIME_ENTRY(NonBoolTypeError, 1) { |
// Arg2: type of destination being assigned to. |
// Return value: none, throws an exception. |
DEFINE_RUNTIME_ENTRY(BadTypeError, 3) { |
- const intptr_t location = GetCallerLocation(); |
+ const TokenPosition location = GetCallerLocation(); |
const Instance& src_value = Instance::CheckedHandle(arguments.ArgAt(0)); |
const String& dst_name = String::CheckedHandle(arguments.ArgAt(1)); |
const AbstractType& dst_type = |
@@ -1381,7 +1381,7 @@ DEFINE_RUNTIME_ENTRY(StackOverflow, 0) { |
// Variable locations and number are unknown when precompiling. |
const int num_vars = |
FLAG_precompilation ? 0 : frame->NumLocalVariables(); |
- intptr_t unused; |
+ TokenPosition unused = TokenPosition::kNoSource; |
for (intptr_t v = 0; v < num_vars; v++) { |
frame->VariableAt(v, &var_name, &unused, &unused, &var_value); |
} |