dartist / dart-bignum

Other
14 stars 11 forks source link

Used Uint8List instead of List<int> for performance improvement. #31

Closed stevenroose closed 10 years ago

stevenroose commented 10 years ago

Used Uint8List instead of List for performance improvement.

The method is called fromBytes so it's likely that the parameter passed will be of type Uint8List. Now the List.setRange() implementation will copy the list element-wise, while Uint8List.setRange(), when passed another Uint8List, will use native code optimized to copy arbitrarily sized chunks of bytes.

adam-singer commented 10 years ago

lgtm thanks!

adam-singer commented 10 years ago

I'll publish 0.0.5 for you soon.

adam-singer commented 10 years ago

@stevenroose 0.0.6 is ready on pub.