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

Unified Diff: runtime/vm/object.h

Issue 419103003: Handle load errors in deferred code (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 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 side-by-side diff with in-line comments
Download patch
Index: runtime/vm/object.h
===================================================================
--- runtime/vm/object.h (revision 38636)
+++ runtime/vm/object.h (working copy)
@@ -2634,10 +2634,12 @@
void SetLoadInProgress() const;
bool Loaded() const { return raw_ptr()->load_state_ == RawLibrary::kLoaded; }
void SetLoaded() const;
- bool LoadError() const {
+ bool LoadFailed() const {
return raw_ptr()->load_state_ == RawLibrary::kLoadError;
}
- void SetLoadError() const;
+ RawObject* LoadError() const { return raw_ptr()->load_error_; }
Ivan Posva 2014/07/31 18:29:05 RawInstance* here and other related places.
hausner 2014/07/31 21:12:45 Done.
+ void SetLoadError(const Object& error) const;
+ RawObject* TransitiveLoadError() const;
static intptr_t InstanceSize() {
return RoundedAllocationSize(sizeof(RawLibrary));
@@ -4366,9 +4368,11 @@
virtual RawString* DictionaryName() const { return name(); }
RawArray* imports() const { return raw_ptr()->imports_; }
- intptr_t num_imports() const { return raw_ptr()->num_imports_; }
+ int32_t num_imports() const { return raw_ptr()->num_imports_; }
RawLibrary* importer() const { return raw_ptr()->importer_; }
+ RawObject* LoadError() const;
Ivan Posva 2014/07/31 18:29:05 Thinking about this more as I go through the CL. C
hausner 2014/07/31 21:12:45 Leaving the name but changing to type Instance, as
+
bool ContainsLibrary(const Library& library) const;
RawLibrary* GetLibrary(int index) const;
void AddImport(const Namespace& import) const;

Powered by Google App Engine
This is Rietveld 408576698