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

Side by Side Diff: tools/dom/scripts/dartmetadata.py

Issue 597363002: Fixing treeshaking problem with 37 roll (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Back to proper treeshaking, swarm shakes out 70K back to where we were." Created 6 years, 2 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
OLDNEW
1 #!/usr/bin/python 1 #!/usr/bin/python
2 # Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 2 # Copyright (c) 2012, 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 """This module provides shared functionality to provide Dart metadata for 6 """This module provides shared functionality to provide Dart metadata for
7 DOM APIs. 7 DOM APIs.
8 """ 8 """
9 9
10 import copy 10 import copy
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after
126 ], 126 ],
127 127
128 'File.lastModifiedDate': [ 128 'File.lastModifiedDate': [
129 "@Creates('Null')", # JS date object. 129 "@Creates('Null')", # JS date object.
130 ], 130 ],
131 131
132 'FocusEvent.relatedTarget': [ 132 'FocusEvent.relatedTarget': [
133 "@Creates('Null')", 133 "@Creates('Null')",
134 ], 134 ],
135 135
136 'HTMLCanvasElement.getContext': [
137 "@Creates('CanvasRenderingContext2D|RenderingContext')",
138 "@Returns('CanvasRenderingContext2D|RenderingContext|Null')",
139 ],
140
136 'HTMLInputElement.valueAsDate': [ 141 'HTMLInputElement.valueAsDate': [
137 "@Creates('Null')", # JS date object. 142 "@Creates('Null')", # JS date object.
138 ], 143 ],
139 144
140 # Rather than have the result of an IDBRequest as a union over all possible 145 # Rather than have the result of an IDBRequest as a union over all possible
141 # results, we mark the result as instantiating any classes, and mark 146 # results, we mark the result as instantiating any classes, and mark
142 # each operation with the classes that it could cause to be asynchronously 147 # each operation with the classes that it could cause to be asynchronously
143 # instantiated. 148 # instantiated.
144 'IDBRequest.result': ["@Creates('Null')"], 149 'IDBRequest.result': ["@Creates('Null')"],
145 150
(...skipping 686 matching lines...) Expand 10 before | Expand all | Expand 10 after
832 pass 837 pass
833 else: 838 else:
834 _logger.warn('Unknown support_level - %s:%s' % (interface_id, member_id)) 839 _logger.warn('Unknown support_level - %s:%s' % (interface_id, member_id))
835 840
836 return annotations 841 return annotations
837 842
838 def Flush(self): 843 def Flush(self):
839 json_file = open(self._api_status_path, 'w+') 844 json_file = open(self._api_status_path, 'w+')
840 json.dump(self._types, json_file, indent=2, separators=(',', ': '), sort_key s=True) 845 json.dump(self._types, json_file, indent=2, separators=(',', ': '), sort_key s=True)
841 json_file.close() 846 json_file.close()
OLDNEW
« no previous file with comments | « sdk/lib/html/dart2js/html_dart2js.dart ('k') | tools/dom/templates/html/dart2js/html_dart2js.darttemplate » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698