// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/core/parseutils.c
// Function: gt_parse_description_range
int gt_parse_description_range(const char *description, GtRange *range)
{
  GtUword i, desclen;
  char *desc, *descptr;
  gt_assert(description && range);
  desc = gt_cstr_dup(description);
  desclen = strlen(desc);
  descptr = desc;
  /* ignore terminal '\n' */
  if (desclen && desc[desclen-1] == '\n') {
    desc[desclen-1] = '\0';
    desclen--;
  }
  /* ignore terminal '\r' */
  if (desclen && desc[desclen-1] == '\r') {
    desc[desclen-1] = '\0';
    desclen--;
  }
  /* find ':' */
  for (i = 0; i < desclen; i++) {
    if (desc[i] == ':')
      break;
  }
  if (i == desclen) {
    /* no ':' found */
    gt_free(descptr);
    return -1;
  }
  desc += i + 1;
  /* find '..' */
  i = 0;
  while (desc[i] != '\0') {
    if (desc[i-1] == '.' && desc[i] == '.')
      break;
    i++;
  }
  if (desc[i] == '\0') {
    /* no '..' found */
    gt_free(descptr);
    return -1;
  }
  /* parse range start */
  gt_assert(desc[i-1] == '.' && desc[i] == '.');
  desc[i-1] = '\0';
  if (gt_parse_uword(&range->start, desc)) {
    /* parsing failed */
    gt_free(descptr);
    return -1;
  }
  /* parse range end */
  desc += i + 1;
  if (gt_parse_uword(&range->end, desc)) {
    /* parsing failed */
    gt_free(descptr);
    return -1;
  }
  gt_free(descptr);
  return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
testq %rdi, %rdi
je 0x121b0
movq %rsi, %r14
testq %rsi, %rsi
je 0x121b0
callq 0x4f8ae
movq %rax, %rbx
movq %rax, %rdi
callq 0xb260
testq %rax, %rax
je 0x120dc
movb -0x1(%rbx,%rax), %cl
cmpb $0xa, %cl
jne 0x120cd
movb $0x0, -0x1(%rbx,%rax)
decq %rax
je 0x120dc
movb -0x1(%rbx,%rax), %cl
cmpb $0xd, %cl
jne 0x120de
movb $0x0, -0x1(%rbx,%rax)
decq %rax
jmp 0x120de
xorl %eax, %eax
leaq 0x2(%rbx), %r15
movq %rax, %rdx
negq %rdx
xorl %ecx, %ecx
xorl %esi, %esi
cmpq %rcx, %rdx
je 0x12104
cmpb $0x3a, (%rbx,%rsi)
je 0x120ff
incq %rsi
decq %rcx
jmp 0x120ec
addq %rcx, %rax
jne 0x12121
leaq 0xb9936(%rip), %rsi     # 0xcba41
movq %rbx, %rdi
movl $0x15b, %edx            # imm = 0x15B
callq 0xd249
pushq $-0x1
popq %rax
popq %rbx
popq %r14
popq %r15
retq
subq %rcx, %r15
movq %rbx, %rsi
subq %rcx, %rsi
incq %rsi
movb -0x1(%r15), %al
testb %al, %al
je 0x12145
cmpb $0x2e, %al
jne 0x12140
cmpb $0x2e, -0x2(%r15)
je 0x12156
incq %r15
jmp 0x1212d
leaq 0xb98f5(%rip), %rsi     # 0xcba41
movq %rbx, %rdi
movl $0x168, %edx            # imm = 0x168
jmp 0x12113
movb $0x0, -0x2(%r15)
movq %r14, %rdi
callq 0x117e9
testl %eax, %eax
je 0x12178
leaq 0xb98d3(%rip), %rsi     # 0xcba41
movq %rbx, %rdi
movl $0x170, %edx            # imm = 0x170
jmp 0x12113
addq $0x8, %r14
movq %r14, %rdi
movq %r15, %rsi
callq 0x117e9
leaq 0xb98b3(%rip), %rsi     # 0xcba41
movq %rbx, %rdi
testl %eax, %eax
je 0x1219f
movl $0x177, %edx            # imm = 0x177
jmp 0x12113
movl $0x17a, %edx            # imm = 0x17A
callq 0xd249
xorl %eax, %eax
jmp 0x1211b
movq 0x11be01(%rip), %rax    # 0x12dfb8
movq (%rax), %rdi
leaq 0xb7ea5(%rip), %rsi     # 0xca066
leaq 0xb9ad3(%rip), %rdx     # 0xcbc9b
leaq 0xb9ae1(%rip), %rcx     # 0xcbcb0
leaq 0xb986b(%rip), %r8      # 0xcba41
movl $0x146, %r9d            # imm = 0x146
xorl %eax, %eax
callq 0xb8c0
callq 0xb300