function emptyLike( x ) {
	var ndims;
	var len;
	var buf;
	var ord;
	var sh;
	var st;
	var dt;

	dt = getDType( x );
	sh = getShape( x, true );
	ord = getOrder( x );

	ndims = sh.length;
	if ( ndims > 0 ) {
		len = numel( sh );
		st = shape2strides( sh, ord );
	} else {
		// For 0-dimensional arrays, the buffer should contain a single element...
		len = 1;
		st = [ 0 ];
	}
	if ( dt === 'binary' ) {
		buf = allocUnsafe( len );
	} else {
		buf = emptyArray( len, dt );
	}
	return new x.constructor( dt, buf, sh, st, strides2offset( sh, st ), ord );
}
Creates an uninitialized ndarray having the same shape and data type as a provided ndarray.

@param {ndarray} x - input array
@throws {TypeError} first argument must have a recognized data type
@returns {ndarray} ndarray

@example
var zeros = require( '@stdlib/ndarray/base/zeros' );

var x = zeros( 'float32', [ 2, 2 ], 'row-major' );
// returns <ndarray>

var y = emptyLike( x );
// returns <ndarray>

var sh = y.shape;
// returns [ 2, 2 ]

var dt = y.dtype;
// returns 'float32'