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

Issue 10574046: Remove static fields in the namer. (Closed)

Created:
8 years, 6 months ago by floitsch
Modified:
8 years, 6 months ago
Reviewers:
ahe
CC:
reviews_dartlang.org
Visibility:
Public.

Description

Remove static fields in the namer. Committed: https://code.google.com/p/dart/source/detail?r=8965

Patch Set 1 #

Patch Set 2 : Move OPERATOR_EQUALS into Elements. #

Patch Set 3 : Remove spurious "else". #

Total comments: 6

Patch Set 4 : Address comments. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+22 lines, -18 lines) Patch
M lib/compiler/implementation/elements/elements.dart View 1 2 3 1 chunk +4 lines, -1 line 0 comments Download
M lib/compiler/implementation/emitter.dart View 1 5 chunks +5 lines, -5 lines 0 comments Download
M lib/compiler/implementation/enqueue.dart View 1 chunk +2 lines, -1 line 0 comments Download
M lib/compiler/implementation/namer.dart View 1 2 3 2 chunks +7 lines, -7 lines 0 comments Download
M lib/compiler/implementation/ssa/builder.dart View 1 1 chunk +1 line, -1 line 0 comments Download
M lib/compiler/implementation/ssa/closure.dart View 1 chunk +1 line, -1 line 0 comments Download
M lib/compiler/implementation/ssa/codegen.dart View 1 chunk +1 line, -1 line 0 comments Download
M lib/compiler/implementation/ssa/optimize.dart View 1 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 4 (0 generated)
floitsch
The namer should not have any static state. Ideally we should be able to switch ...
8 years, 6 months ago (2012-06-20 19:24:01 UTC) #1
ahe
LGTM, this is definitely better. I think we generally use camelCase for instance variables. https://chromiumcodereview.appspot.com/10574046/diff/4001/lib/compiler/implementation/elements/elements.dart ...
8 years, 6 months ago (2012-06-20 19:45:52 UTC) #2
floitsch
wrt camelCase. I considered this, but in the end I see those variables as static ...
8 years, 6 months ago (2012-06-20 20:29:30 UTC) #3
ahe
8 years, 6 months ago (2012-06-20 21:03:51 UTC) #4
Just commit as is. Renaming from HACKER_STYLE to camelCase is easy if we decide
to do so.

Cheers,
Peter

On 2012/06/20 20:29:30, floitsch wrote:
> wrt camelCase.
> I considered this, but in the end I see those variables as static final
> variables. Yes they are actually instance variables, but that's just so we can
> exchange the namer more easily.
> I will wait with committing, so we can discuss this.
> 
>
https://chromiumcodereview.appspot.com/10574046/diff/4001/lib/compiler/implem...
> File lib/compiler/implementation/elements/elements.dart (right):
> 
>
https://chromiumcodereview.appspot.com/10574046/diff/4001/lib/compiler/implem...
> lib/compiler/implementation/elements/elements.dart:957: const
> SourceString('operator\$eq');
> On 2012/06/20 19:45:52, ahe wrote:
> > Total nit: raw string would be nicer for grep'ing.
> 
> good argument.
> done.
> 
>
https://chromiumcodereview.appspot.com/10574046/diff/4001/lib/compiler/implem...
> File lib/compiler/implementation/namer.dart (right):
> 
>
https://chromiumcodereview.appspot.com/10574046/diff/4001/lib/compiler/implem...
> lib/compiler/implementation/namer.dart:35: final String
STATIC_CLOSURE_NAME_NAME
> = '\$name';
> On 2012/06/20 19:45:52, ahe wrote:
> > Raw string?
> 
> Done.
> 
>
https://chromiumcodereview.appspot.com/10574046/diff/4001/lib/compiler/implem...
> lib/compiler/implementation/namer.dart:36: final SourceString
> CLOSURE_INVOCATION_NAME = const SourceString('\$call');
> On 2012/06/20 19:45:52, ahe wrote:
> > Ditto.
> 
> Done.

Powered by Google App Engine
This is Rietveld 408576698