Skip to main content

Stack Exchange Network

Stack Exchange network consists of 183 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange
1 vote

Why does bash $LINENO change inside an inner block in a function?

From one of the dustier corners of POSIX: The expansion of $LINENO inside a shell function is only relative to the function start if the shell is interactive -- if the shell is running a script, $...
mr.spuratic's user avatar
  • 10.4k

Only top scored, non community-wiki answers of a minimum length are eligible

Morty Proxy This is a proxified and sanitized view of the page, visit original site.