Regular expression to detect an extended-length path.
var RE_EXTENDED_LENGTH_PATH = require( '@stdlib/regexp/extended-length-path' );
Regular expression to detect an extended-length path (i.e., a Windows path which begins with the characters \\?\
).
var bool = RE_EXTENDED_LENGTH_PATH.test( '\\\\?\\C:\\foo\\bar' );
// returns true
var RE_EXTENDED_LENGTH_PATH = require( '@stdlib/regexp/extended-length-path' );
var bool;
var path;
path = '\\\\?\\C:\\foo\\bar';
bool = RE_EXTENDED_LENGTH_PATH.test( path );
// returns true
path = '\\\\?\\UNC\\server\\share';
bool = RE_EXTENDED_LENGTH_PATH.test( path );
// returns true
path = 'C:\\foo\\bar';
bool = RE_EXTENDED_LENGTH_PATH.test( path );
// returns false
path = '/c/foo/bar';
bool = RE_EXTENDED_LENGTH_PATH.test( path );
// returns false
path = '/foo/bar';
bool = RE_EXTENDED_LENGTH_PATH.test( path );
// returns false