| OLD | NEW |
| 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2016, 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 RUNTIME_VM_KERNEL_H_ | 5 #ifndef RUNTIME_VM_KERNEL_H_ |
| 6 #define RUNTIME_VM_KERNEL_H_ | 6 #define RUNTIME_VM_KERNEL_H_ |
| 7 | 7 |
| 8 #if !defined(DART_PRECOMPILED_RUNTIME) | 8 #if !defined(DART_PRECOMPILED_RUNTIME) |
| 9 #include "platform/assert.h" | 9 #include "platform/assert.h" |
| 10 #include "vm/allocation.h" | 10 #include "vm/allocation.h" |
| (...skipping 2391 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2402 virtual void AcceptStatementVisitor(StatementVisitor* visitor); | 2402 virtual void AcceptStatementVisitor(StatementVisitor* visitor); |
| 2403 virtual void VisitChildren(Visitor* visitor); | 2403 virtual void VisitChildren(Visitor* visitor); |
| 2404 | 2404 |
| 2405 bool IsConst() { return (flags_ & kFlagConst) == kFlagConst; } | 2405 bool IsConst() { return (flags_ & kFlagConst) == kFlagConst; } |
| 2406 bool IsFinal() { return (flags_ & kFlagFinal) == kFlagFinal; } | 2406 bool IsFinal() { return (flags_ & kFlagFinal) == kFlagFinal; } |
| 2407 | 2407 |
| 2408 String* name() { return name_; } | 2408 String* name() { return name_; } |
| 2409 DartType* type() { return type_; } | 2409 DartType* type() { return type_; } |
| 2410 InferredValue* inferred_value() { return inferred_value_; } | 2410 InferredValue* inferred_value() { return inferred_value_; } |
| 2411 Expression* initializer() { return initializer_; } | 2411 Expression* initializer() { return initializer_; } |
| 2412 TokenPosition equals_position() { return equals_position_; } |
| 2412 TokenPosition end_position() { return end_position_; } | 2413 TokenPosition end_position() { return end_position_; } |
| 2413 | 2414 |
| 2414 private: | 2415 private: |
| 2415 VariableDeclaration() : end_position_(TokenPosition::kNoSource) {} | 2416 VariableDeclaration() |
| 2417 : equals_position_(TokenPosition::kNoSourcePos), |
| 2418 end_position_(TokenPosition::kNoSource) {} |
| 2416 | 2419 |
| 2417 template <typename T> | 2420 template <typename T> |
| 2418 friend class List; | 2421 friend class List; |
| 2419 | 2422 |
| 2420 word flags_; | 2423 word flags_; |
| 2421 Ref<String> name_; | 2424 Ref<String> name_; |
| 2422 Child<DartType> type_; | 2425 Child<DartType> type_; |
| 2423 Child<InferredValue> inferred_value_; | 2426 Child<InferredValue> inferred_value_; |
| 2424 Child<Expression> initializer_; | 2427 Child<Expression> initializer_; |
| 2428 TokenPosition equals_position_; |
| 2425 TokenPosition end_position_; | 2429 TokenPosition end_position_; |
| 2426 | 2430 |
| 2427 DISALLOW_COPY_AND_ASSIGN(VariableDeclaration); | 2431 DISALLOW_COPY_AND_ASSIGN(VariableDeclaration); |
| 2428 }; | 2432 }; |
| 2429 | 2433 |
| 2430 | 2434 |
| 2431 class FunctionDeclaration : public Statement { | 2435 class FunctionDeclaration : public Statement { |
| 2432 public: | 2436 public: |
| 2433 static FunctionDeclaration* ReadFrom(Reader* reader); | 2437 static FunctionDeclaration* ReadFrom(Reader* reader); |
| 2434 | 2438 |
| (...skipping 732 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3167 | 3171 |
| 3168 kernel::Program* ReadPrecompiledKernelFromBuffer(const uint8_t* buffer, | 3172 kernel::Program* ReadPrecompiledKernelFromBuffer(const uint8_t* buffer, |
| 3169 intptr_t buffer_length); | 3173 intptr_t buffer_length); |
| 3170 | 3174 |
| 3171 | 3175 |
| 3172 | 3176 |
| 3173 } // namespace dart | 3177 } // namespace dart |
| 3174 | 3178 |
| 3175 #endif // !defined(DART_PRECOMPILED_RUNTIME) | 3179 #endif // !defined(DART_PRECOMPILED_RUNTIME) |
| 3176 #endif // RUNTIME_VM_KERNEL_H_ | 3180 #endif // RUNTIME_VM_KERNEL_H_ |
| OLD | NEW |