Package: flex
Version: 2.6.4-8
Severity: normal

Dear Maintainer,

Line numbers refering to the source .l file are generally out by one,
making it difficult to handle compiler error messages (especially when
gcc tries to be helpful by displaying the line, but instead shows the
wrong line) or to debug in gdb as gdb shows the wrong line.

Injecting an error into the code:
^#{s}+{D}+{s}+\"(\.|[^"\n])*\".*$ { li ne_info (yytext + 1); } // line 120

Produces:
../tools/qfcc/source/qc-lex.l:121:3: error: unknown type name ‘li’
  121 | ^#line{s}+{D}+{s}+\"(\.|[^"\n])*\".*$ { line_info (yytext + 5); }

-- System Information:
Debian Release: bookworm/sid
  APT prefers unstable
  APT policy: (500, 'unstable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 5.15.0-2-amd64 (SMP w/8 CPU threads)
Kernel taint flags: TAINT_PROPRIETARY_MODULE, TAINT_OOT_MODULE, 
TAINT_UNSIGNED_MODULE
Locale: LANG=en_AU.UTF-8, LC_CTYPE=en_AU.UTF-8 (charmap=UTF-8) (ignored: LC_ALL 
set to en_US.utf8), LANGUAGE=en_AU:en
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages flex depends on:
ii  debconf [debconf-2.0]  1.5.79
ii  libc6                  2.33-2
ii  m4                     1.4.18-5

Versions of packages flex recommends:
ii  clang-3.4 [c-compiler]  1:3.4.2-16
ii  gcc [c-compiler]        4:11.2.0-2
ii  gcc-10 [c-compiler]     10.3.0-13
ii  gcc-11 [c-compiler]     11.2.0-13
ii  gcc-4.6 [c-compiler]    4.6.4-7
ii  gcc-4.7 [c-compiler]    4.7.4-3
ii  gcc-4.8 [c-compiler]    4.8.5-4
ii  gcc-4.9 [c-compiler]    4.9.4-2
ii  gcc-5 [c-compiler]      5.5.0-12
ii  gcc-6 [c-compiler]      6.4.0-18
ii  gcc-8 [c-compiler]      8.4.0-6
ii  gcc-9 [c-compiler]      9.4.0-4+b1
ii  libfl-dev               2.6.4-8

Versions of packages flex suggests:
ii  bison            2:3.8.2+dfsg-1
ii  build-essential  12.9
pn  flex-doc         <none>

-- no debconf information

Reply via email to