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

Issue 11299009: Support type literals as compile-time constants. (Closed)

Created:
8 years, 1 month ago by karlklose
Modified:
8 years, 1 month ago
Reviewers:
floitsch, ngeoffray
CC:
reviews_dartlang.org
Visibility:
Public.

Description

Support type literals as compile-time constants. Committed: https://code.google.com/p/dart/source/detail?r=15154

Patch Set 1 #

Total comments: 18

Patch Set 2 : Address review comments. #

Patch Set 3 : #

Total comments: 14

Patch Set 4 : Address comments. #

Total comments: 2

Patch Set 5 : Address comments. #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+160 lines, -129 lines) Patch
M sdk/lib/_internal/compiler/implementation/compile_time_constants.dart View 1 2 5 chunks +24 lines, -1 line 0 comments Download
M sdk/lib/_internal/compiler/implementation/constants.dart View 1 4 chunks +21 lines, -4 lines 0 comments Download
M sdk/lib/_internal/compiler/implementation/elements/elements.dart View 1 1 chunk +5 lines, -0 lines 0 comments Download
M sdk/lib/_internal/compiler/implementation/js_backend/backend.dart View 1 2 3 2 chunks +3 lines, -0 lines 0 comments Download
M sdk/lib/_internal/compiler/implementation/js_backend/constant_emitter.dart View 1 2 3 1 chunk +22 lines, -0 lines 1 comment Download
M sdk/lib/_internal/compiler/implementation/js_backend/js_backend.dart View 1 2 3 4 1 chunk +1 line, -0 lines 0 comments Download
A + sdk/lib/_internal/compiler/implementation/js_backend/runtime_types.dart View 1 2 3 4 3 chunks +38 lines, -5 lines 0 comments Download
M sdk/lib/_internal/compiler/implementation/resolved_visitor.dart View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
D sdk/lib/_internal/compiler/implementation/runtime_types.dart View 1 2 3 4 1 chunk +0 lines, -94 lines 0 comments Download
M sdk/lib/_internal/compiler/implementation/ssa/builder.dart View 1 2 3 3 chunks +8 lines, -13 lines 0 comments Download
M sdk/lib/_internal/compiler/implementation/ssa/codegen.dart View 1 2 3 1 chunk +3 lines, -1 line 0 comments Download
M sdk/lib/_internal/compiler/implementation/ssa/optimize.dart View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
M sdk/lib/_internal/compiler/implementation/ssa/ssa.dart View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M sdk/lib/_internal/compiler/implementation/universe/universe.dart View 1 2 3 4 3 chunks +1 line, -4 lines 0 comments Download
M tests/co19/co19-dart2dart.status View 1 2 3 4 1 chunk +0 lines, -2 lines 0 comments Download
M tests/co19/co19-dart2js.status View 1 2 3 1 chunk +0 lines, -2 lines 0 comments Download
A tests/language/first_class_types_constants_test.dart View 1 chunk +28 lines, -0 lines 0 comments Download
M tests/language/language.status View 1 2 3 4 2 chunks +3 lines, -0 lines 0 comments Download

Messages

Total messages: 8 (0 generated)
karlklose
8 years, 1 month ago (2012-11-15 14:50:58 UTC) #1
ngeoffray
http://codereview.chromium.org/11299009/diff/1/sdk/lib/_internal/compiler/implementation/constants.dart File sdk/lib/_internal/compiler/implementation/constants.dart (right): http://codereview.chromium.org/11299009/diff/1/sdk/lib/_internal/compiler/implementation/constants.dart#newcode46 sdk/lib/_internal/compiler/implementation/constants.dart:46: bool get isType => false; bool isType() => false ...
8 years, 1 month ago (2012-11-15 16:07:24 UTC) #2
floitsch
LGTM once Nicolas' comments are addressed. https://codereview.chromium.org/11299009/diff/1/sdk/lib/_internal/compiler/implementation/constants.dart File sdk/lib/_internal/compiler/implementation/constants.dart (right): https://codereview.chromium.org/11299009/diff/1/sdk/lib/_internal/compiler/implementation/constants.dart#newcode322 sdk/lib/_internal/compiler/implementation/constants.dart:322: int get hashCode; ...
8 years, 1 month ago (2012-11-16 13:53:31 UTC) #3
karlklose
PTAL. I removed getting unsafeNames from the namer and added a special case for 'dynamic' ...
8 years, 1 month ago (2012-11-19 15:08:58 UTC) #4
ngeoffray
More comments http://codereview.chromium.org/11299009/diff/5010/sdk/lib/_internal/compiler/implementation/compile_time_constants.dart File sdk/lib/_internal/compiler/implementation/compile_time_constants.dart (right): http://codereview.chromium.org/11299009/diff/5010/sdk/lib/_internal/compiler/implementation/compile_time_constants.dart#newcode407 sdk/lib/_internal/compiler/implementation/compile_time_constants.dart:407: if (!enabledRuntimeTypeSupport) { Instead of having a ...
8 years, 1 month ago (2012-11-19 16:54:09 UTC) #5
karlklose
http://codereview.chromium.org/11299009/diff/5010/sdk/lib/_internal/compiler/implementation/compile_time_constants.dart File sdk/lib/_internal/compiler/implementation/compile_time_constants.dart (right): http://codereview.chromium.org/11299009/diff/5010/sdk/lib/_internal/compiler/implementation/compile_time_constants.dart#newcode407 sdk/lib/_internal/compiler/implementation/compile_time_constants.dart:407: if (!enabledRuntimeTypeSupport) { As discussed offline, I'll leave that ...
8 years, 1 month ago (2012-11-20 14:04:38 UTC) #6
ngeoffray
LGTM with one comment http://codereview.chromium.org/11299009/diff/5024/sdk/lib/_internal/compiler/implementation/resolution/resolution.dart File sdk/lib/_internal/compiler/implementation/resolution/resolution.dart (right): http://codereview.chromium.org/11299009/diff/5024/sdk/lib/_internal/compiler/implementation/resolution/resolution.dart#newcode12 sdk/lib/_internal/compiler/implementation/resolution/resolution.dart:12: import '../runtime_types.dart'; This doesn't look ...
8 years, 1 month ago (2012-11-20 14:13:19 UTC) #7
floitsch
8 years, 1 month ago (2012-11-20 16:25:43 UTC) #8
LGTM.

https://codereview.chromium.org/11299009/diff/9009/sdk/lib/_internal/compiler...
File sdk/lib/_internal/compiler/implementation/js_backend/constant_emitter.dart
(right):

https://codereview.chromium.org/11299009/diff/9009/sdk/lib/_internal/compiler...
sdk/lib/_internal/compiler/implementation/js_backend/constant_emitter.dart:215:
typeName = element.name.slowToString();
Discuss with Erik if (and potentially how) this should be minified.
Not in this CL, though.

Powered by Google App Engine
This is Rietveld 408576698