| Index: sdk/lib/convert/utf.dart
|
| diff --git a/sdk/lib/convert/utf.dart b/sdk/lib/convert/utf.dart
|
| index 8e480f80333904569054ec0557754049fac40049..2f513b05ccc8fcabf11e53e2f22177a4fe4883ce 100644
|
| --- a/sdk/lib/convert/utf.dart
|
| +++ b/sdk/lib/convert/utf.dart
|
| @@ -133,8 +133,13 @@ class _Utf8Encoder {
|
| _Utf8Encoder() : this.withBufferSize(_DEFAULT_BYTE_BUFFER_SIZE);
|
|
|
| _Utf8Encoder.withBufferSize(int bufferSize)
|
| - // TODO(11971, floitsch): use Uint8List instead of normal lists.
|
| - : _buffer = new List<int>(bufferSize);
|
| + : _buffer = _createBuffer(bufferSize);
|
| +
|
| + // TODO(11971): Always use Uint8List.
|
| + /**
|
| + * Allow an implementation to pick the most efficient way of storing bytes.
|
| + */
|
| + external static List<int> _createBuffer(int size);
|
|
|
| /**
|
| * Tries to combine the given [leadingSurrogate] with the [nextCodeUnit] and
|
|
|