From 07801f7ec3e3482aba8553fd75f9f190ac3f9f0a Mon Sep 17 00:00:00 2001
From: Norbert Preining <norbert@preining.info>
Date: Fri, 13 Aug 2021 03:00:43 +0000
Subject: CTAN sync 202108130300

---
 macros/latex/contrib/fancyvrb/latex/fancyvrb.sty | 24 ++++++++++++++++++------
 1 file changed, 18 insertions(+), 6 deletions(-)

(limited to 'macros/latex/contrib/fancyvrb/latex/fancyvrb.sty')

diff --git a/macros/latex/contrib/fancyvrb/latex/fancyvrb.sty b/macros/latex/contrib/fancyvrb/latex/fancyvrb.sty
index 2efbf7d248..1211daa44e 100644
--- a/macros/latex/contrib/fancyvrb/latex/fancyvrb.sty
+++ b/macros/latex/contrib/fancyvrb/latex/fancyvrb.sty
@@ -13,9 +13,9 @@
 %%   verbatim environments and commands and extensive documentation.
 %%
 \NeedsTeXFormat{LaTeX2e}
-\def\fileversion{3.7}
-\def\filedate{2021/01/20}
-\ProvidesPackage{fancyvrb}[2021/01/20 v3.7 verbatim text (tvz,hv)]
+\def\fileversion{3.8}
+\def\filedate{2021/08/12}
+\ProvidesPackage{fancyvrb}[2021/08/12 v3.8 verbatim text (tvz,hv)]
 %\message{Style option: `fancyvrb' v\fileversion \space  <\filedate> (tvz)}
 \csname fancyvrb@loaded\endcsname
 \let\fancyvrb@loaded\endinput
@@ -1001,6 +1001,7 @@
 \newcounter{FancyVerbLine}
 \define@key{FV}{firstnumber}[auto]{%
   \def\@tempa{#1}\def\@tempb{auto}%
+  \def\FV@FirstNumber{#1}%             added 2021-08-12
   \ifx\@tempa\@tempb
     \def\FV@SetLineNo{%
       \c@FancyVerbLine\FV@CodeLineNo%
@@ -1137,9 +1138,20 @@
     \gdef\FV@TheVerbatim{}%
     \def\FV@ProcessLine##1{%
       \expandafter\gdef\expandafter\FV@TheVerbatim\expandafter{%
-        \FV@TheVerbatim\FV@ProcessLine{##1}}}%
-    \gdef\FV@TheVerbatim{}%
-    \FV@Scan}
+%        \FV@TheVerbatim\FV@ProcessLine{##1}}}%    2021-08-12
+%    \gdef\FV@TheVerbatim{}%
+         \FV@TheVerbatim\advance\c@FancyVerbLine\@ne\FV@ProcessLine{##1}}}%
+     \gdef\FV@TheVerbatim{%
+       \edef\@tempa{\FV@FirstNumber}%
+       \def\@tempb{auto}%
+       \ifx\@tempa\@tempb%
+         \c@FancyVerbLine\FV@CodeLineNo%
+       \else%
+         \c@FancyVerbLine\FV@FirstNumber%
+         \advance\c@FancyVerbLine\m@ne%
+       \fi%
+     }%    
+  \FV@Scan}
 \def\FVE@SaveVerbatim{%
   \expandafter\global\expandafter\let
   \csname FV@SV@\SaveVerbatim@Name\endcsname\FV@TheVerbatim
-- 
cgit v1.2.3

