diff --git a/src/utils/general/ParseTools.cpp b/src/utils/general/ParseTools.cpp index 704585d3f..0043169e2 100644 --- a/src/utils/general/ParseTools.cpp +++ b/src/utils/general/ParseTools.cpp @@ -82,63 +82,6 @@ string vectorIntToStr(const vector &vec) { return str; } - -#if defined(__i386__) || defined(__x86_64__) -bool isHeaderLine(const string &line) { - if (line[0] == '>') { - return true; - } - if (line[0] == '!') { - return true; - } - if (line[0] == '#') { - return true; - } - - if(line.length() > 4) { - uint32_t peek = *(uint32_t*)line.c_str() | 0x20202020u; - const char* full_text = NULL; - bool require_space = false; - bool require_digit = false; - switch(peek) { - case 0x6f726863: - full_text = "chrom"; - require_space = true; - require_digit = false; - break; - case 0x20726863: - case 0x09726863: - full_text = "chr"; - require_space = require_digit = true; - break; - case 0x776f7262: - full_text = "browser"; - break; - case 0x63617274: - full_text = "track"; - break; - case 0x69736976: - full_text = "visibility"; - break; - default: - return false; - } - if(full_text) { - const char* ptr = NULL; - for(ptr = line.c_str(); *ptr && *full_text; ptr ++, full_text ++) { - char c = *ptr; - if(c >= 'A' && c <= 'Z') c += 32; - if(c != *full_text) return false; - } - if(require_space && !isspace(*(ptr++))) return false; - if(require_digit && !isdigit(*(ptr++))) return false; - return true; - } - } - - return false; -} -#else bool isHeaderLine(const string &line) { if (line[0] == '>') { return true; @@ -172,4 +115,3 @@ bool isHeaderLine(const string &line) { } return false; } -#endif