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

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

Issue 59283007: List scripts in library and display script source (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years 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 | « runtime/bin/vmservice/client/web/index.html ('k') | runtime/vm/object.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 (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 2343 matching lines...) Expand 10 before | Expand all | Expand 10 after
2354 2354
2355 class Script : public Object { 2355 class Script : public Object {
2356 public: 2356 public:
2357 RawString* url() const { return raw_ptr()->url_; } 2357 RawString* url() const { return raw_ptr()->url_; }
2358 bool HasSource() const; 2358 bool HasSource() const;
2359 RawString* Source() const; 2359 RawString* Source() const;
2360 RawString* GenerateSource() const; // Generates source code from Tokenstream. 2360 RawString* GenerateSource() const; // Generates source code from Tokenstream.
2361 RawScript::Kind kind() const { 2361 RawScript::Kind kind() const {
2362 return static_cast<RawScript::Kind>(raw_ptr()->kind_); 2362 return static_cast<RawScript::Kind>(raw_ptr()->kind_);
2363 } 2363 }
2364 const char* GetKindAsCString() const;
2364 intptr_t line_offset() const { return raw_ptr()->line_offset_; } 2365 intptr_t line_offset() const { return raw_ptr()->line_offset_; }
2365 intptr_t col_offset() const { return raw_ptr()->col_offset_; } 2366 intptr_t col_offset() const { return raw_ptr()->col_offset_; }
2366 2367
2367 RawTokenStream* tokens() const { return raw_ptr()->tokens_; } 2368 RawTokenStream* tokens() const { return raw_ptr()->tokens_; }
2368 2369
2369 void Tokenize(const String& private_key) const; 2370 void Tokenize(const String& private_key) const;
2370 2371
2371 RawString* GetLine(intptr_t line_number) const; 2372 RawString* GetLine(intptr_t line_number) const;
2372 RawString* GetSnippet(intptr_t from_token_pos, 2373 RawString* GetSnippet(intptr_t from_token_pos,
2373 intptr_t to_token_pos) const; 2374 intptr_t to_token_pos) const;
(...skipping 4061 matching lines...) Expand 10 before | Expand all | Expand 10 after
6435 6436
6436 6437
6437 RawObject* MegamorphicCache::GetTargetFunction(const Array& array, 6438 RawObject* MegamorphicCache::GetTargetFunction(const Array& array,
6438 intptr_t index) { 6439 intptr_t index) {
6439 return array.At((index * kEntryLength) + kTargetFunctionIndex); 6440 return array.At((index * kEntryLength) + kTargetFunctionIndex);
6440 } 6441 }
6441 6442
6442 } // namespace dart 6443 } // namespace dart
6443 6444
6444 #endif // VM_OBJECT_H_ 6445 #endif // VM_OBJECT_H_
OLDNEW
« no previous file with comments | « runtime/bin/vmservice/client/web/index.html ('k') | runtime/vm/object.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698