[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug #61012] [mom] om.tmac: an empty argument to ".substring" produces a
From: |
Bjarni Ingi Gislason |
Subject: |
[bug #61012] [mom] om.tmac: an empty argument to ".substring" produces a warning |
Date: |
Wed, 4 Aug 2021 20:06:58 -0400 (EDT) |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Firefox/78.0 |
URL:
<https://savannah.gnu.org/bugs/?61012>
Summary: [mom] om.tmac: an empty argument to ".substring"
produces a warning
Project: GNU troff
Submitted by: bjarniig
Submitted on: Thu 05 Aug 2021 12:06:56 AM UTC
Category: Macro - mom
Severity: 3 - Normal
Item Group: Warning/Suspicious behaviour
Status: None
Privacy: Public
Assigned to: None
Open/Closed: Open
Discussion Lock: Any
Planned Release: None
_______________________________________________________
Details:
troff: backtrace: '/home/bg/git/groff/build/s-tmac/om.tmac':7037: macro
'HEADER_VERSO'
troff: backtrace: '/home/bg/git/groff/build/s-tmac/om.tmac':7345: macro
'PRINT_USERDEF_HDRFTR'
troff: backtrace: '/home/bg/git/groff/build/s-tmac/om.tmac':7080: macro
'PRINT_HDRFTR'
troff: backtrace: '/home/bg/git/groff/build/s-tmac/om.tmac':7434: trap-called
macro 'HEADER'
troff: backtrace: '/home/bg/git/groff/build/s-tmac/om.tmac':7858: macro
'DO_FOOTER'
troff: backtrace: '/home/bg/git/groff/build/s-tmac/om.tmac':7841: trap-called
macro 'FOOTER'
troff: backtrace: '/home/bg/git/groff/build/s-tmac/om.tmac':260: macro
'NEWPAGE'
troff: backtrace: '/home/bg/git/groff/build/s-tmac/om.tmac':5788: macro
'END_COVER'
troff: backtrace: '/home/bg/git/groff/build/s-tmac/om.tmac':5766: macro
'DO_COVER'
troff: backtrace: '/home/bg/git/groff/build/s-tmac/om.tmac':5873: macro
'START'
troff: backtrace: file '../contrib/mom/examples/slide-demo.mom':83
troff: ../contrib/mom/examples/slide-demo.mom:83: warning: start and end index
of substring out of range
HEADER_VERSO is an alias of HDRFTR_VERSO.
Code snippet:
. ds $QUAD_TYPE \\$1
. substring $QUAD_TYPE 0 0
. if '\\*[$QUAD_TYPE]'L' .nr #USERDEF_HDRFTR_VERSO_QUAD 1
If the argument to "substring" is empty,
a test for that would be appropriate.
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?61012>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/
- [bug #61012] [mom] om.tmac: an empty argument to ".substring" produces a warning,
Bjarni Ingi Gislason <=