Sha256: 150010919f09c03465bb526b1dcf2ee06b1b449c09eb577b085368297fa857ee

Contents?: true

Size: 186 Bytes

Versions: 43

Compression:

Stored size: 186 Bytes

Contents

module.exports = function xorInplace (a, b) {
  var length = Math.min(a.length, b.length)

  for (var i = 0; i < length; ++i) {
    a[i] = a[i] ^ b[i]
  }

  return a.slice(0, length)
}

Version data entries

43 entries across 42 versions & 15 rubygems

Version Path
brwy_rails-0.0.3 test/dummy/node_modules/buffer-xor/inplace.js
brwy_rails-0.0.2 test/dummy/node_modules/buffer-xor/inplace.js
brwy_rails-0.0.1 test/dummy/node_modules/buffer-xor/inplace.js