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

Issue 10068019: Fix ApiDoc to work with new dart:html code. Tweak dart:html generator to generate clearer @domName … (Closed)

Created:
8 years, 8 months ago by Jacob
Modified:
8 years, 8 months ago
Reviewers:
nweiz, sra1, Bob Nystrom
CC:
reviews_dartlang.org
Visibility:
Public.

Description

Fix ApiDoc to work with new dart:html code. Tweak dart:html generator to generate clearer @domName annotations. BUG= TEST= Committed: https://code.google.com/p/dart/source/detail?r=6505

Patch Set 1 #

Total comments: 16

Patch Set 2 : Code review fix #

Patch Set 3 : #

Patch Set 4 : Code review fixes #

Unified diffs Side-by-side diffs Delta from patch set Stats (+6941 lines, -448 lines) Patch
M lib/dartdoc/dartdoc.dart View 1 chunk +5 lines, -3 lines 0 comments Download
M lib/dartdoc/utils.dart View 1 chunk +7 lines, -2 lines 0 comments Download
M lib/dom/scripts/dartdomgenerator.py View 2 chunks +3 lines, -3 lines 0 comments Download
M lib/dom/scripts/dartgenerator.py View 1 2 1 chunk +7 lines, -2 lines 0 comments Download
M lib/dom/scripts/idlnode.py View 1 2 4 chunks +16 lines, -11 lines 0 comments Download
M lib/dom/scripts/systemhtml.py View 1 2 5 chunks +20 lines, -10 lines 0 comments Download
A + lib/dom/templates/html/interface/interface.darttemplate View 1 chunk +2 lines, -3 lines 0 comments Download
M lib/dom/templates/html/interface/interface_CSSStyleDeclaration.darttemplate View 1 chunk +1 line, -0 lines 0 comments Download
M lib/dom/templates/html/interface/interface_Document.darttemplate View 1 chunk +1 line, -0 lines 0 comments Download
M lib/dom/templates/html/interface/interface_DocumentFragment.darttemplate View 1 chunk +1 line, -0 lines 0 comments Download
M lib/dom/templates/html/interface/interface_Element.darttemplate View 1 chunk +1 line, -0 lines 0 comments Download
M lib/dom/templates/html/interface/interface_Event.darttemplate View 1 chunk +1 line, -0 lines 0 comments Download
M lib/dom/templates/html/interface/interface_EventTarget.darttemplate View 1 chunk +2 lines, -0 lines 0 comments Download
M lib/dom/templates/html/interface/interface_MouseEvent.darttemplate View 1 chunk +1 line, -0 lines 0 comments Download
M lib/dom/templates/html/interface/interface_Node.darttemplate View 1 chunk +9 lines, -0 lines 0 comments Download
M lib/dom/templates/html/interface/interface_NodeList.darttemplate View 1 chunk +1 line, -0 lines 0 comments Download
M lib/dom/templates/html/interface/interface_NodeSelector.darttemplate View 1 chunk +1 line, -0 lines 0 comments Download
M lib/dom/templates/html/interface/interface_Point.darttemplate View 1 chunk +1 line, -0 lines 0 comments Download
M lib/dom/templates/html/interface/interface_SVGElement.darttemplate View 1 chunk +1 line, -0 lines 0 comments Download
M lib/dom/templates/html/interface/interface_SVGSVGElement.darttemplate View 1 chunk +1 line, -0 lines 0 comments Download
M lib/dom/templates/html/interface/interface_Storage.darttemplate View 1 chunk +1 line, -0 lines 0 comments Download
M lib/dom/templates/html/interface/interface_Text.darttemplate View 1 chunk +1 line, -0 lines 0 comments Download
M lib/dom/templates/html/interface/interface_WebSocket.darttemplate View 1 chunk +1 line, -0 lines 0 comments Download
M lib/dom/templates/html/interface/interface_Window.darttemplate View 1 chunk +1 line, -2 lines 0 comments Download
M lib/dom/templates/html/interface/interface_XMLHttpRequest.darttemplate View 1 chunk +1 line, -0 lines 0 comments Download
M lib/html/dartium/html_dartium.dart View 593 chunks +3412 lines, -102 lines 0 comments Download
M lib/html/frog/html_frog.dart View 593 chunks +3412 lines, -102 lines 0 comments Download
M utils/apidoc/apidoc.dart View 2 chunks +8 lines, -0 lines 0 comments Download
M utils/apidoc/html_diff.dart View 10 chunks +22 lines, -208 lines 0 comments Download

Messages

Total messages: 11 (0 generated)
Jacob
nweiz please review html_diff.dart rnystrom please review dartdoc and apidoc sra please review generator tweaks ...
8 years, 8 months ago (2012-04-12 17:38:03 UTC) #1
Bob Nystrom
Dart code changes LGTM, assuming you ran apidoc locally and everything checked out OK. Thanks ...
8 years, 8 months ago (2012-04-12 17:54:06 UTC) #2
sra1
https://chromiumcodereview.appspot.com/10068019/diff/1/lib/dom/scripts/dartgenerator.py File lib/dom/scripts/dartgenerator.py (right): https://chromiumcodereview.appspot.com/10068019/diff/1/lib/dom/scripts/dartgenerator.py#newcode113 lib/dom/scripts/dartgenerator.py:113: for member in interface.operations + interface.constants + interface.attributes: line ...
8 years, 8 months ago (2012-04-12 17:58:21 UTC) #3
nweiz
https://chromiumcodereview.appspot.com/10068019/diff/1/utils/apidoc/html_diff.dart File utils/apidoc/html_diff.dart (left): https://chromiumcodereview.appspot.com/10068019/diff/1/utils/apidoc/html_diff.dart#oldcode257 utils/apidoc/html_diff.dart:257: if (htmlMember.name == 'get:on') { Why don't we need ...
8 years, 8 months ago (2012-04-12 19:40:51 UTC) #4
sra1
I'm lgtm provided we keep the doc gen and code gen concerns separate, i.e. with ...
8 years, 8 months ago (2012-04-13 01:02:35 UTC) #5
Jacob
https://chromiumcodereview.appspot.com/10068019/diff/1/lib/dom/scripts/dartgenerator.py File lib/dom/scripts/dartgenerator.py (right): https://chromiumcodereview.appspot.com/10068019/diff/1/lib/dom/scripts/dartgenerator.py#newcode113 lib/dom/scripts/dartgenerator.py:113: for member in interface.operations + interface.constants + interface.attributes: On ...
8 years, 8 months ago (2012-04-13 08:56:01 UTC) #6
nweiz
https://chromiumcodereview.appspot.com/10068019/diff/1/utils/apidoc/html_diff.dart File utils/apidoc/html_diff.dart (right): https://chromiumcodereview.appspot.com/10068019/diff/1/utils/apidoc/html_diff.dart#newcode130 utils/apidoc/html_diff.dart:130: if (tags.containsKey('domName')) { On 2012/04/13 08:56:01, Jacob wrote: > ...
8 years, 8 months ago (2012-04-13 18:48:09 UTC) #7
Jacob
https://chromiumcodereview.appspot.com/10068019/diff/1/utils/apidoc/html_diff.dart File utils/apidoc/html_diff.dart (right): https://chromiumcodereview.appspot.com/10068019/diff/1/utils/apidoc/html_diff.dart#newcode130 utils/apidoc/html_diff.dart:130: if (tags.containsKey('domName')) { On 2012/04/13 18:48:09, nweiz wrote: > ...
8 years, 8 months ago (2012-04-16 07:44:39 UTC) #8
Bob Nystrom
On 2012/04/16 07:44:39, Jacob wrote: > In general I agree that lower nesting levels are ...
8 years, 8 months ago (2012-04-16 16:39:29 UTC) #9
Jacob
On 2012/04/16 16:39:29, Bob Nystrom wrote: > On 2012/04/16 07:44:39, Jacob wrote: > > In ...
8 years, 8 months ago (2012-04-16 16:42:09 UTC) #10
nweiz
8 years, 8 months ago (2012-04-16 17:58:15 UTC) #11
lgtm

On 2012/04/16 16:42:09, Jacob wrote:
> On 2012/04/16 16:39:29, Bob Nystrom wrote:
> > On 2012/04/16 07:44:39, Jacob wrote:
> > > In general I agree that lower nesting levels are better. However, I also
> > believe
> > > simple conditionals are better than more complex conditionals and having
> fewer
> > > returns nested in the middle of a function is better.
> > 
> > Given a language that has try/catch/finally and garbage collection (which
Dart
> > has), I personally prefer early returns over nesting. I think early returns
> are
> > problematic in languages where resource management can be tricky, but I
don't
> > think we have that problem in Dart. Given that, I prefer the simpler flow
> > control that early returns give you.
> 
> A bunch of early returns right at the top of a function are fine.  What I
> dislike is early returns strewn throughout a function.  They give the illusion
> of simpler control flow when the control flow is no simpler than if there were
> nested blocks.

I disagree, but I'm not going to press on the issue any harder.

Powered by Google App Engine
This is Rietveld 408576698