/**
 * Subclass of jDataView with a getUint64 method.
 */
define([
           'jDataView'
       ],
       function( jDataView ) {

var DataView = function() {
    jDataView.apply( this, arguments );
};
DataView.prototype = new jDataView( new ArrayBuffer() );

/**
 * Get a 53-bit integer from 64 bits and approximate the number if it overflows.
 */
DataView.prototype.getUint64Approx = function( byteOffset, littleEndian ) {
    var b = this._getBytes(8, byteOffset, littleEndian);
    var result = b[0] * Math.pow(2,56) + b[1]*Math.pow(2,48) + b[2]*Math.pow(2,40) + b[3]*Math.pow(2,32) +  b[4]*Math.pow(2, 24) + (b[5]<<16) + (b[6]<<8) + b[7];

    if( b[0] || b[1]&224 ) {
        result = new Number(result);
        result.overflow = true;
    }

    return result;
};

/**
 * Get a 53-bit integer from 64 bits and die if it overflows.
 */
DataView.prototype.getUint64 = function( byteOffset, littleEndian ) {
    var result = this.getUint64Approx( byteOffset, littleEndian );
    if( result.overflow )
        throw 'integer overflow';
    return result;
};


return DataView;

});
@@ -196,16 +196,27 @@
 s );%0A%7D;%0A
+%0Atry %7B%0A    
 DataView
@@ -263,16 +263,30 @@
 fer() );
+%0A%7D catch(e) %7B%7D
 %0A%0A/**%0A *

make JBrowse/Model/DataView not crash on load in browsers that don't have typed arrays