Commit graph

7682 commits

Author SHA1 Message Date
Stan Manilov 0648e2622b Add example int doc for Iterable.expand
The expand function is not trivial and an example helps flesh out its
behaviour.

BUG=
R=floitsch@google.com

Review URL: https://codereview.chromium.org/2154933002 .
2016-08-05 10:34:38 -07:00
Florian Loitsch 99e5328eac Revert "Return futures on Stream.cancel when possible."
This reverts commit 395e7aaa69.

Review URL: https://codereview.chromium.org/2213193004 .
2016-08-05 14:32:14 +02:00
Florian Loitsch 395e7aaa69 Return futures on Stream.cancel when possible.
Deprecate returning `null`.

Also, fixes cases where transformations on a stream didn't forward the cancel future

Fixes #26777.

BUG= http://dartbug.com/26777.
R=lrn@google.com

Review URL: https://codereview.chromium.org/2202533003 .
2016-08-05 13:58:45 +02:00
Sigmund Cherem 0eee4027a6 Delete dart_backend from compiler.
R=sra@google.com

Review URL: https://codereview.chromium.org/2213673002 .
2016-08-04 15:57:04 -07:00
Todd Turnidge 74ad64038a Allow weird characters (like ?) to appear in devfs filenames.
Closes #27011

BUG=
R=johnmccutchan@google.com

Review URL: https://codereview.chromium.org/2208223002 .
2016-08-03 15:43:37 -07:00
Jacob Richman 36c9514f04 Use Point<num> in dart:html for strong mode
Strong mode is (as of recently) inferring a stricter type (e.g., Point<double>) and causing breaking changes.

patch from issue 2211493003 at patchset 1 (http://crrev.com/2211493003#ps1)

BUG=

Review URL: https://codereview.chromium.org/2211563002 .
2016-08-03 14:09:10 -07:00
Jacob Richman 7f2950916e Fix so that logic to enable private user define @JS classes does not impact codegen for dart:html native classes where private classes are not an issue.
BUG=
R=alanknight@google.com

Review URL: https://codereview.chromium.org/2195453002 .
2016-08-03 14:03:39 -07:00
Danny Tuppeny e76537e4eb Fix formatting of comment in HttpHeaders class (#26937) 2016-07-27 19:44:20 +02:00
Jacob Richman a711a35021 Fix missing line for js_util in dart_server.platform
BUG=
R=sra@google.com

Review URL: https://codereview.chromium.org/2181403002 .
2016-07-26 10:26:29 -07:00
Jacob Richman 31f1f9caf3 TBR. Shouldn't have referenced JSObject in dart2js. Accidentally left it in porting code from dartium.
BUG=

Review URL: https://codereview.chromium.org/2186433002 .
2016-07-25 18:55:31 -07:00
Devon Carew e0e96ad99a Fix some markdown issues in library docs (related to https://github.com/dart-lang/dartdoc/issues/968).
BUG=
R=keertip@google.com

Review URL: https://codereview.chromium.org/2175293004 .
2016-07-25 11:01:27 -07:00
Jacob Richman 96ca5db7e5 Add JSNative utility class with static methods methods to efficiently manipulate typed JSInterop objects in cases where the member name is not known statically. These methods would be extension methods on JSObject if Dart supported extension methods. Update package js to export these methods. Implement in Dart2JS. Implement JS$ in dart2js.
BUG=
R=alanknight@google.com, sra@google.com

Review URL: https://codereview.chromium.org/2150313003 .
2016-07-25 09:59:01 -07:00
William Hesse ca49303576 Revert "Add fast-mode Uri class."
This reverts commit 00090a0c72.

Revert "Add fast-mode Uri class."

This reverts commit 323ca7e410.

Revert "Fix regression for the one case where we deliberately don't follow the RFC."

This reverts commit b39e048c4b.

Revert "Cache hashCode in Uri implementations to improve performance when used as, e.g., Map key."

This reverts commit a11ad27723.

BUG=https://github.com/dart-lang/sdk/issues/26917
TBR=keertip@google.com

Review URL: https://codereview.chromium.org/2167663002 .
2016-07-20 14:32:52 +02:00
Harry Terkelsen faaff39aa9 Record that MediaStream creates MediaStreamTracks
BUG=
R=alanknight@google.com

Review URL: https://codereview.chromium.org/2168473002 .
2016-07-19 17:00:04 -07:00
Jacob Richman e010460709 Utility class of static methods to efficiently manipulate typed JSInterop objects in a dynamic manner. Fix for @JS classes that are _private. Bug #25038 @JS on a _Private class in Dartium
Tests are in the separate Dart2JS CL

BUG=
R=alanknight@google.com

Review URL: https://codereview.chromium.org/2158493003 .
2016-07-19 10:37:20 -07:00
William Hesse bde8d3efc6 Revert "Don't call _ensureRequestAnimationFrame in Dartium."
This reverts commit bf8eeef6a0.

Revert "Fix animationFrameRequest for dartium."

This reverts commit 3daaf3849f.

BUG=https://github.com/dart-lang/sdk/issues/26906

Review URL: https://codereview.chromium.org/2159183003 .
2016-07-19 13:56:36 +02:00
Keerti Parthasarathy 69a8b11f67 Fix for uri replace whene uri has fragment. Was adding a second '#'.
BUG=
R=het@google.com

Review URL: https://codereview.chromium.org/2158933003 .
2016-07-18 16:31:43 -07:00
Alan Knight 30b489578d Revert "Reapply zone tasks."
This reverts commit 6a7c037aa6.

BUG=

Review URL: https://codereview.chromium.org/2162643002 .
2016-07-18 13:12:36 -07:00
Alan Knight e610d803b1 Update test status for webgl extension tests, fix one typo in extension name
BUG=

Review URL: https://codereview.chromium.org/2152393002 .
2016-07-15 15:00:15 -07:00
Alan Knight b9316f9882 Recognize WEBGL extensions on Firefox (copy with regenerated files)
Both of the following objects need to map to Dart type 'AngleInstancedArrays'

    [object ANGLEInstancedArrays]
    [object ANGLE_instanced_arrays]

Fixes https://github.com/dart-lang/sdk/issues/26850

BUG=

patch from issue 2147093002 at patchset 1 (http://crrev.com/2147093002#ps1)

R=sra@google.com

Review URL: https://codereview.chromium.org/2150003002 .
2016-07-15 12:48:22 -07:00
Stephen Adams 1eee3c7dc7 dart2js js_runtime: faster code for floor() & ceil()
Within the [-2^31, 2^31) range it is faster to truncate and correct at boundaries than call Math.ceil/Math.floor.

Each call to toInt() has been specialized to the calling operator (ceil, floor, ~/ etc).

This makes the conversion faster (values are already integral) and lets us put the name of the operation and original operands in conversion errors, e.g

(a / b).floor();  // b == 0
Unsupported operation: Infinity
-->
Unsupported operation: Infinity.floor()

a ~/ b;   // b == 0
Unsupported operation: Infinity
-->
Unsupported operation: Result of truncating division is Infinity: 132 ~/ 0

R=sigmund@google.com

Review URL: https://codereview.chromium.org/1405113003 .

Downside: an extra 400 bytes
2016-07-15 12:27:59 -07:00
Todd Turnidge 3a51fceaba First cut at _spawnUri rpc in the vm service.
BUG=
R=johnmccutchan@google.com

Review URL: https://codereview.chromium.org/2072543002 .
2016-07-11 14:25:27 -07:00
Florian Loitsch badabcc53a Don't use => on void functions.
Fixes #26740
BUG= http://dartbug.com/26740
R=sra@google.com

Review URL: https://codereview.chromium.org/2118633002 .
2016-07-11 14:20:12 +02:00
Florian Loitsch 9413d62bf6 More documentation for zones.
R=lrn@google.com

Review URL: https://codereview.chromium.org/2082553003 .
2016-07-11 13:21:08 +02:00
Florian Loitsch 9a851032c9 Copy Dart-configuration detection from dart script to pub.
Fixes #26621.
BUG= http://dartbug.com/26621
R=whesse@google.com

Review URL: https://codereview.chromium.org/2134733002 .
2016-07-08 16:23:10 +02:00
Lasse R.H. Nielsen bb96f28921 Update documentation for Stream.listen.
Addresses issue #25967
BUG= http://dartbug.com/25967
R=floitsch@google.com

Review URL: https://codereview.chromium.org/2119153002.
2016-07-06 09:17:18 +02:00
Florian Loitsch bf8eeef6a0 Don't call _ensureRequestAnimationFrame in Dartium.
Review URL: https://codereview.chromium.org/2117103004 .
2016-07-05 19:50:49 +02:00
Florian Loitsch 3daaf3849f Fix animationFrameRequest for dartium.
Review URL: https://codereview.chromium.org/2124863002 .
2016-07-05 19:22:27 +02:00
Florian Loitsch 6a7c037aa6 Reapply zone tasks.
This reverts commit 34d3c37233.

Committed: f746f8f77e

R=lrn@google.com

Review URL: https://codereview.chromium.org/2119243002 .

Reverted: dae3922915
2016-07-05 17:33:09 +02:00
Florian Loitsch dae3922915 Revert "Reapply zone tasks."
This reverts commit f746f8f77e.

Review URL: https://codereview.chromium.org/2123593002 .
2016-07-04 21:58:15 +02:00
Florian Loitsch f746f8f77e Reapply zone tasks.
This reverts commit 34d3c37233.

Review URL: https://codereview.chromium.org/2119243002 .
2016-07-04 19:55:58 +02:00
Lasse R.H. Nielsen a11ad27723 Cache hashCode in Uri implementations to improve performance when used as, e.g., Map key.
Most URI strings are short, but this still gives a 10%-20% improvement on doing repeated lookup in a large map of URIs in the VM, ~100% speedup in dart2js.

Addresses feature request #18162
BUG= http://dartbug.com/18162
R=floitsch@google.com

Review URL: https://codereview.chromium.org/2119833002 .
2016-07-04 10:19:41 +02:00
Florian Loitsch 34d3c37233 Revert zone tasks.
Revert "Add tasks to zones."

This reverts commit 85cccde717.

Revert "Make Dom events run through zone tasks."

This reverts commit 6d1f6b2af6.

Revert "Add zone task support for request-anim."

This reverts commit 726b9f8dc7.

Revert "Add zone task support to http-requests."

This reverts commit b40cfcb57f.

Revert "Update status file for jsshell."

This reverts commit 5e05ee9b5f.

Review URL: https://codereview.chromium.org/2120063002 .
2016-07-01 22:36:52 -07:00
Florian Loitsch b40cfcb57f Add zone task support to http-requests.
R=alanknight@google.com, lrn@google.com

Review URL: https://codereview.chromium.org/2042033002 .
2016-07-01 19:44:19 -07:00
Florian Loitsch 726b9f8dc7 Add zone task support for request-anim.
R=lrn@google.com

Review URL: https://codereview.chromium.org/2039963003 .
2016-07-01 19:43:36 -07:00
Florian Loitsch 6d1f6b2af6 Make Dom events run through zone tasks.
R=jacobr@google.com, lrn@google.com

Review URL: https://codereview.chromium.org/2022263002 .
2016-07-01 19:43:06 -07:00
Florian Loitsch 85cccde717 Add tasks to zones.
R=lrn@google.com, misko@google.com

Review URL: https://codereview.chromium.org/1848933002 .
2016-07-01 19:42:22 -07:00
Todd Turnidge f7242f2137 Reimplement devfs in dart. Implementation now writes to disk.
BUG=
R=johnmccutchan@google.com

Review URL: https://codereview.chromium.org/2120473004 .
2016-07-01 14:57:32 -07:00
Brian Wilkerson cacabb3085 Fix typos in docs
Review URL: https://codereview.chromium.org/2119483002 .
2016-06-30 10:08:54 -07:00
Lasse R.H. Nielsen b39e048c4b Fix regression for the one case where we deliberately don't follow the RFC.
The new code didn't have that exception.

Also optimize some string operations when it's possible.

R=eernst@google.com

Review URL: https://codereview.chromium.org/2117453002 .
2016-06-30 14:52:23 +02:00
Lasse R.H. Nielsen 00090a0c72 Add fast-mode Uri class.
Optimize parser and make it recognize a class of URIs that don't need extra
handling: no escapes, no funny characters, already (nearly or completely)
normalized.
Have a class specifically for those URIs which retains the original
input string without having allocate any further strings.

R=floitsch@google.com

Review URL: https://codereview.chromium.org/2086613003.
2016-06-30 12:20:15 +02:00
Jacob Richman dead24a756 Make allowInterop a generic method.
BUG=
R=jmesserly@google.com

Review URL: https://codereview.chromium.org/2102893002 .
2016-06-29 14:23:37 -07:00
Florian Loitsch d28687f1f7 Add documentation to List.filled to warn of common mistake.
R=lrn@google.com

Review URL: https://codereview.chromium.org/2100943003 .
2016-06-28 17:30:38 -07:00
Lasse R.H. Nielsen ddf35f2d56 Fix bug in BytesBuilder. Add tests.
Fixes issue #26772

BUG= http://dartbug.com/26772
R=floitsch@google.com

Review URL: https://codereview.chromium.org/2100103002 .
2016-06-28 14:34:53 +02:00
Stephen Adams 716898c227 Shorter encoding for zero optional arguments.
R=het@google.com

Review URL: https://codereview.chromium.org/2092243002 .

Addresses: https://github.com/dart-lang/sdk/issues/26754
2016-06-27 13:23:43 -07:00
Stephen Adams 909ec27b10 Code changes to avoid Firefox debug 'error' lint warnings.
Firefox produces many SyntaxErrors and TypeErrors for what are really
linter issues.

Improve compile-time and run-time codegen to avoid these warnings.

BUG=
R=het@google.com

Review URL: https://codereview.chromium.org/2072883004 .
2016-06-17 13:05:28 -07:00
Zach Anderson 22e449ba09 Fix Windows time zone name extraction. Update API docs
On Windows, the OS provides a full name for the time zone
rather than an abbreviation. Further the string may
contain non-ASCII characters, so a conversion is
necessary. This CL updates the API docs to match the
actual behavior, and fixes the string conversion problem.

fixes #17085

R=asiva@google.com

Review URL: https://codereview.chromium.org/2069783002 .
2016-06-14 13:51:19 -07:00
Zachary Anderson 678cb048ed Adds blocking file locks.
Fixes #26665

R=sgjesse@google.com

Review URL: https://codereview.chromium.org/2050413002 .
2016-06-13 07:58:09 -07:00
John McCutchan 1a4c2005cc DevFS initial implementation.
This cl implements an experimental filesystem maintained in the vm, called dart-devfs.  This will allow service protocol users to read and write source files while the vm is running.  This is needed for the reload support for flutter.

R=turnidge@google.com

Review URL: https://codereview.chromium.org/2059883003 .
2016-06-10 12:33:50 -07:00
Johnni Winther 40108f661d Update Windows build output path in .bat files
R=asiva@google.com, whesse@google.com

Review URL: https://codereview.chromium.org/2035313004 .
2016-06-07 10:43:13 +02:00