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

Side by Side Diff: client/dom/scripts/idlrenderer.py

Issue 9369062: Ensure 'raises' clauses on operations are saved in IDL database. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « client/dom/scripts/fremontcutbuilder.py ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/python 1 #!/usr/bin/python
2 # Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 2 # Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
3 # for details. All rights reserved. Use of this source code is governed by a 3 # for details. All rights reserved. Use of this source code is governed by a
4 # BSD-style license that can be found in the LICENSE file. 4 # BSD-style license that can be found in the LICENSE file.
5 5
6 from idlnode import * 6 from idlnode import *
7 7
8 8
9 def render(idl_node, indent_str=' '): 9 def render(idl_node, indent_str=' '):
10 output = [] 10 output = []
(...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after
132 w(node.ext_attrs) 132 w(node.ext_attrs)
133 if node.is_static: 133 if node.is_static:
134 w('static ') 134 w('static ')
135 if node.specials: 135 if node.specials:
136 w(node.specials, ' ') 136 w(node.specials, ' ')
137 w(' ') 137 w(' ')
138 w('%s ' % node.type.id) 138 w('%s ' % node.type.id)
139 w(node.id) 139 w(node.id)
140 w('(') 140 w('(')
141 w(node.arguments, ', ') 141 w(node.arguments, ', ')
142 wln(');') 142 w(')')
143 if node.raises:
144 w(' raises (%s)' % node.raises.id)
145 wln(';')
146
143 elif isinstance(node, IDLArgument): 147 elif isinstance(node, IDLArgument):
144 w(node.ext_attrs) 148 w(node.ext_attrs)
145 w('in ') 149 w('in ')
146 if node.is_optional: 150 if node.is_optional:
147 w('optional ') 151 w('optional ')
148 w('%s %s' % (node.type.id, node.id)) 152 w('%s %s' % (node.type.id, node.id))
149 else: 153 else:
150 raise TypeError("Expected str or IDLNode but %s found" % 154 raise TypeError("Expected str or IDLNode but %s found" %
151 type(node)) 155 type(node))
152 156
153 w(idl_node) 157 w(idl_node)
154 return ''.join(output) 158 return ''.join(output)
OLDNEW
« no previous file with comments | « client/dom/scripts/fremontcutbuilder.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698