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

Issue 10869005: Retry r11091 with explicit template instatiation to keep the linker happy. (Closed)

Created:
8 years, 4 months ago by siva
Modified:
8 years, 4 months ago
CC:
reviews_dartlang.org, vm-dev_dartlang.org
Visibility:
Public.

Description

Retry r11091 with explicit template instatiation to keep the linker happy. Committed: https://code.google.com/p/dart/source/detail?r=11118

Patch Set 1 #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+25 lines, -23 lines) Patch
M vm/object.cc View 5 chunks +12 lines, -20 lines 2 comments Download
M vm/raw_object_snapshot.cc View 1 chunk +10 lines, -1 line 0 comments Download
M vm/snapshot.cc View 2 chunks +3 lines, -2 lines 0 comments Download

Messages

Total messages: 4 (0 generated)
siva
TBR=cshapiro
8 years, 4 months ago (2012-08-22 00:17:27 UTC) #1
cshapiro
lgtm
8 years, 4 months ago (2012-08-22 01:59:20 UTC) #2
Florian Schneider
DBC: https://chromiumcodereview.appspot.com/10869005/diff/1/vm/object.cc File vm/object.cc (right): https://chromiumcodereview.appspot.com/10869005/diff/1/vm/object.cc#newcode1687 vm/object.cc:1687: // Force instantiation of template version to work ...
8 years, 4 months ago (2012-08-22 08:18:15 UTC) #3
siva
8 years, 4 months ago (2012-08-22 15:17:02 UTC) #4
https://chromiumcodereview.appspot.com/10869005/diff/1/vm/object.cc
File vm/object.cc (right):

https://chromiumcodereview.appspot.com/10869005/diff/1/vm/object.cc#newcode1687
vm/object.cc:1687: // Force instantiation of template version to work around ld
problems.
The function is pretty big and would look pretty odd in the header file not to
mention the potential inlining that may happen resulting in larger code.

This seems to be a problem only in some old versions of 'ld' on linux which the
buildbot is running. I would prefer if we update the build bot machines to a
newer and more saner version of 'ld' so that we don't have to make such weird
code work arounds.

On 2012/08/22 08:18:15, Florian Schneider wrote:
> I think explicit instantiation can be avoided if you put the implementation of
> template Class::New in the header file. e.g. at the end to avoid cluttering up
> the class declaration.

Powered by Google App Engine
This is Rietveld 408576698