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

Issue 10918203: Stop treating finals as const (Closed)

Created:
8 years, 3 months ago by hausner
Modified:
8 years, 3 months ago
Reviewers:
regis
CC:
reviews_dartlang.org
Visibility:
Public.

Description

Stop treating finals as const Toplevel final variables and static final fields are no longer considered compile-time constants. Committed: https://code.google.com/p/dart/source/detail?r=12289

Patch Set 1 #

Total comments: 3

Patch Set 2 : #

Patch Set 3 : #

Unified diffs Side-by-side diffs Delta from patch set Stats (+41 lines, -52 lines) Patch
M runtime/vm/ast.h View 1 2 1 chunk +1 line, -1 line 0 comments Download
M runtime/vm/parser.cc View 1 2 18 chunks +23 lines, -40 lines 0 comments Download
M tests/co19/co19-runtime.status View 1 2 4 chunks +16 lines, -5 lines 0 comments Download
M tests/language/language.status View 1 2 2 chunks +1 line, -6 lines 0 comments Download

Messages

Total messages: 4 (0 generated)
hausner
8 years, 3 months ago (2012-09-12 23:38:41 UTC) #1
regis
LGTM http://codereview.chromium.org/10918203/diff/1/runtime/vm/parser.cc File runtime/vm/parser.cc (right): http://codereview.chromium.org/10918203/diff/1/runtime/vm/parser.cc#newcode868 runtime/vm/parser.cc:868: // exception. The field should instead be set ...
8 years, 3 months ago (2012-09-12 23:46:57 UTC) #2
hausner
Thank you. http://codereview.chromium.org/10918203/diff/1/runtime/vm/parser.cc File runtime/vm/parser.cc (right): http://codereview.chromium.org/10918203/diff/1/runtime/vm/parser.cc#newcode868 runtime/vm/parser.cc:868: // exception. The field should instead be ...
8 years, 3 months ago (2012-09-12 23:51:54 UTC) #3
regis
8 years, 3 months ago (2012-09-12 23:59:04 UTC) #4
http://codereview.chromium.org/10918203/diff/1/runtime/vm/parser.cc
File runtime/vm/parser.cc (right):

http://codereview.chromium.org/10918203/diff/1/runtime/vm/parser.cc#newcode868
runtime/vm/parser.cc:868: // exception. The field should instead be set to null
after an exception.
On 2012/09/12 23:51:54, hausner wrote:
> No. The comment refers to the code under condition 'if (field.value ===
> sentinel)'.
> 
> On 2012/09/12 23:46:58, regis wrote:
> > This contradicts the comment on line 814 stating that the field is reset to
> null
> > before throwing.
> 

I stand corrected :-)
Btw, there was an email discussion on this topic on Aug 15 entitled "lazy
initialization of finals".

Powered by Google App Engine
This is Rietveld 408576698