Undefined control sequence only if I compile with an updated distribution











up vote
0
down vote

favorite












I'm trying to improve an answer of mine and I've found a solution which works perfectly on Overleaf (I looked at the log, not only what is displayed).



listfiles
documentclass[12pt,fleqn]{article}
usepackage{amsmath}
usepackage{environ}
usepackage{tikz}
usetikzlibrary{matrix}
usetikzlibrary{decorations.pathreplacing, calligraphy, calc}
tikzset{
mymatr/.style={
matrix of math nodes,
column sep = 10pt,
nodes={
anchor=text,
inner xsep=3pt
},
inner xsep=7pt,
ampersand replacement=&
}
}
NewEnviron{mybrak}[1][2]{%
begin{tikzpicture}[baseline=(mybase)]
matrix[mymatr](A){
BODY\
};
coordinate (mybase) at ($(A-1-1.text)!.5! (A-#1-1.text)$);
draw[thick]([xshift=-6.4pt]A-1-1.west) -- +(4.4pt,0);
foreach[evaluate=mystep as prev using int(mystep-1)] mystep in {2,...,#1}{
draw[thick]([xshift=-6pt]A-prev-1.west) -- ([xshift=-6pt]A-mystep-1.west) -- + (4pt,0);
}
end{tikzpicture}
}

NewEnviron{mycurly}[1][2]{%
begin{tikzpicture}[baseline=(mybase)]
matrix[mymatr](A){
BODY\
};
coordinate (mybase) at ($(A-1-1.text)!.5! (A-#1-1.text)$);
draw[line width=.9pt,decorate,decoration={calligraphic brace,amplitude=4pt, mirror}](A-1-1.west) -- (A-#1-1.west);
end{tikzpicture}
}


begin{document}
Environment who puts curly braces:
[
begin{mycurly}
frac{3}{4}x+y=2 \
e^{2x}+3y=4
end{mycurly}
]
if you have more than 2 equation, you have to indicate their number in the optional argument:
[
begin{mycurly}[3]
frac{3}{4}x+y=2 \
e^{2x}+3y=4\
sqrt{x+3}+5z=0
end{mycurly}
]
[
begin{mycurly}[4]
x+y=2 \
2x+3y=4 \
3x+5z=0 \
dfrac{7x}{x+9}+y+z=2
end{mycurly}
]
Environment who puts square brakets:
[
begin{mybrak}
frac{3}{4}x+y=2 \
e^{2x}+3y=4
end{mybrak}
]
if you have more than 2 equation, you have to indicate their number in the optional argument:
[
begin{mybrak}[3]
frac{3}{4}x+y=2 \
e^{2x}+3y=4\
sqrt{x+3}+5z=0
end{mybrak}
]
[
begin{mybrak}[4]
x+y=2 \
2x+3y=4 \
3x+5z=0 \
dfrac{7x}{x+9}+y+z=2
end{mybrak}
]
Please note you have to use verb|&| instead of verb|&| here:
[
f(x) =
begin{mycurly}[4]
dfrac{1}{3}x+y=2 & text{if }x<0 \
2x+3y=4 & text{if }0leq x<1\
3x+5z=0 & text{if }1leq x<2\
dfrac{7x}{x+9}+y+z=2 & text{if } x>2
end{mycurly}
]
[
f(x) =
begin{mycurly}[3]
2x+3y=4 & text{if } x<1\
3x+5z=0 & text{if }1leq x<2\
dfrac{7x}{x+9}+y+z=2 & text{if } x>2
end{mycurly}
]
It works also with the bracket type (even if I don't know if it is used in your country):
[
f(x) =
begin{mybrak}[4]
dfrac{1}{3}x+y=2 & text{if }x<0 \
2x+3y=4 & text{if }0leq x<1\
3x+5z=0 & text{if }1leq x<2\
dfrac{7x}{x+9}+y+z=2 & text{if } x>2
end{mybrak}
]
[
f(x) =
begin{mybrak}[3]
2x+3y=4 & text{if } x<1\
3x+5z=0 & text{if }1leq x<2\
dfrac{7x}{x+9}+y+z=2 & text{if } x>2
end{mybrak}
]
end{document}


with these versions of the packages:



 *File List*
article.cls 2014/09/29 v1.4h Standard LaTeX document class
fleqn.clo 2016/12/29 v1.2a Standard LaTeX option (flush left equations)
size12.clo 2014/09/29 v1.4h Standard LaTeX file (size option)
amsmath.sty 2016/11/05 v2.16a AMS math features
amstext.sty 2000/06/29 v2.01 AMS text
amsgen.sty 1999/11/30 v2.0 generic functions
amsbsy.sty 1999/11/29 v1.2d Bold Symbols
amsopn.sty 2016/03/08 v2.02 operator names
environ.sty 2014/05/04 v0.3 A new way to define environments
trimspaces.sty 2009/09/17 v1.1 Trim spaces around a token list
tikz.sty 2015/08/07 v3.0.1a (rcs-revision 1.151)
pgf.sty 2015/08/07 v3.0.1a (rcs-revision 1.15)
pgfrcs.sty 2015/08/07 v3.0.1a (rcs-revision 1.31)
everyshi.sty 2001/05/15 v3.00 EveryShipout Package (MS)
pgfrcs.code.tex
pgfcore.sty 2010/04/11 v3.0.1a (rcs-revision 1.7)
graphicx.sty 2017/06/01 v1.1a Enhanced LaTeX Graphics (DPC,SPQR)
keyval.sty 2014/10/28 v1.15 key=value parser (DPC)
graphics.sty 2017/06/25 v1.2c Standard LaTeX Graphics (DPC,SPQR)
trig.sty 2016/01/03 v1.10 sin cos tan (DPC)
graphics.cfg 2016/06/04 v1.11 sample graphics configuration
pdftex.def 2017/06/24 v1.0g Graphics/color driver for pdftex
pgfsys.sty 2014/07/09 v3.0.1a (rcs-revision 1.48)
pgfsys.code.tex
pgfsyssoftpath.code.tex 2013/09/09 (rcs-revision 1.9)
pgfsysprotocol.code.tex 2006/10/16 (rcs-revision 1.4)
xcolor.sty 2016/05/11 v2.12 LaTeX color extensions (UK)
color.cfg 2016/01/02 v1.6 sample color configuration
pgfcore.code.tex
pgfcomp-version-0-65.sty 2007/07/03 v3.0.1a (rcs-revision 1.7)
pgfcomp-version-1-18.sty 2007/07/23 v3.0.1a (rcs-revision 1.1)
pgffor.sty 2013/12/13 v3.0.1a (rcs-revision 1.25)
pgfkeys.sty
pgfkeys.code.tex
pgfmath.sty
pgfmath.code.tex
pgffor.code.tex
tikz.code.tex
spath3.sty 2016/02/19 v1.1 Functions for manipulating PGF soft paths
expl3.sty 2017/05/29 L3 programming layer (loader)
expl3-code.tex 2017/05/29 L3 programming layer
l3pdfmode.def 2017/03/18 v L3 Experimental driver: PDF mode
xparse.sty 2017/05/29 L3 Experimental document command parser
supp-pdf.mkii
epstopdf-base.sty 2016/05/15 v2.6 Base part for package epstopdf
infwarerr.sty 2016/05/16 v1.4 Providing info/warning/error messages (HO)
grfext.sty 2016/05/16 v1.2 Manage graphics extensions (HO)
kvdefinekeys.sty 2016/05/16 v1.4 Define keys (HO)
ltxcmds.sty 2016/05/16 v1.23 LaTeX kernel commands for general use (HO)
kvoptions.sty 2016/05/16 v3.12 Key value format for package options (HO)
kvsetkeys.sty 2016/05/16 v1.17 Key value parser (HO)
etexcmds.sty 2016/05/16 v1.6 Avoid name clashes with e-TeX commands (HO)
ifluatex.sty 2016/05/16 v1.4 Provides the ifluatex switch (HO)
pdftexcmds.sty 2017/03/19 v0.25 Utility functions of pdfTeX for LuaTeX (HO)
ifpdf.sty 2017/03/15 v3.2 Provides the ifpdf switch
epstopdf-sys.cfg 2010/07/13 v1.3 Configuration of (r)epstopdf for TeX Live
***********


But if I try on my computer, with the updated versions of the packages:



 *File List*
article.cls 2014/09/29 v1.4h Standard LaTeX document class
fleqn.clo 2016/12/29 v1.2a Standard LaTeX option (flush left equations)
size12.clo 2014/09/29 v1.4h Standard LaTeX file (size option)
amsmath.sty 2017/09/02 v2.17a AMS math features
amstext.sty 2000/06/29 v2.01 AMS text
amsgen.sty 1999/11/30 v2.0 generic functions
amsbsy.sty 1999/11/29 v1.2d Bold Symbols
amsopn.sty 2016/03/08 v2.02 operator names
environ.sty 2014/05/04 v0.3 A new way to define environments
trimspaces.sty 2009/09/17 v1.1 Trim spaces around a token list
tikz.sty 2015/08/07 v3.0.1a (rcs-revision 1.151)
pgf.sty 2015/08/07 v3.0.1a (rcs-revision 1.15)
pgfrcs.sty 2015/08/07 v3.0.1a (rcs-revision 1.31)
everyshi.sty 2001/05/15 v3.00 EveryShipout Package (MS)
pgfrcs.code.tex
pgfcore.sty 2010/04/11 v3.0.1a (rcs-revision 1.7)
graphicx.sty 2017/06/01 v1.1a Enhanced LaTeX Graphics (DPC,SPQR)
keyval.sty 2014/10/28 v1.15 key=value parser (DPC)
graphics.sty 2017/06/25 v1.2c Standard LaTeX Graphics (DPC,SPQR)
trig.sty 2016/01/03 v1.10 sin cos tan (DPC)
graphics.cfg 2016/06/04 v1.11 sample graphics configuration
pdftex.def 2018/01/08 v1.0l Graphics/color driver for pdftex
pgfsys.sty 2014/07/09 v3.0.1a (rcs-revision 1.48)
pgfsys.code.tex
pgfsyssoftpath.code.tex 2013/09/09 (rcs-revision 1.9)
pgfsysprotocol.code.tex 2006/10/16 (rcs-revision 1.4)
xcolor.sty 2016/05/11 v2.12 LaTeX color extensions (UK)
color.cfg 2016/01/02 v1.6 sample color configuration
pgfcore.code.tex
pgfcomp-version-0-65.sty 2007/07/03 v3.0.1a (rcs-revision 1.7)
pgfcomp-version-1-18.sty 2007/07/23 v3.0.1a (rcs-revision 1.1)
pgffor.sty 2013/12/13 v3.0.1a (rcs-revision 1.25)
pgfkeys.sty
pgfkeys.code.tex
pgfmath.sty
pgfmath.code.tex
pgffor.code.tex
tikz.code.tex
spath3.sty 2016/02/19 v1.1 Functions for manipulating PGF soft paths
expl3.sty 2018-11-19 L3 programming layer (loader)
expl3-code.tex 2018-11-19 L3 programming layer
l3pdfmode.def 2018-11-19 v L3 Experimental driver: PDF mode
xparse.sty 2018-10-17 L3 Experimental document command parser
supp-pdf.mkii
epstopdf-base.sty 2016/05/15 v2.6 Base part for package epstopdf
infwarerr.sty 2016/05/16 v1.4 Providing info/warning/error messages (HO)
grfext.sty 2016/05/16 v1.2 Manage graphics extensions (HO)
kvdefinekeys.sty 2016/05/16 v1.4 Define keys (HO)
ltxcmds.sty 2016/05/16 v1.23 LaTeX kernel commands for general use (HO)
kvoptions.sty 2016/05/16 v3.12 Key value format for package options (HO)
kvsetkeys.sty 2016/05/16 v1.17 Key value parser (HO)
etexcmds.sty 2016/05/16 v1.6 Avoid name clashes with e-TeX commands (HO)
ifluatex.sty 2016/05/16 v1.4 Provides the ifluatex switch (HO)
pdftexcmds.sty 2018/09/10 v0.29 Utility functions of pdfTeX for LuaTeX (HO)
ifpdf.sty 2018/09/07 v3.3 Provides the ifpdf switch
epstopdf-sys.cfg 2010/07/13 v1.3 Configuration of (r)epstopdf for TeX Live
***********


I get the error (followed by many others):



! Undefined control sequence.
<argument> g__prg_map_int

l.54 end{mycurly}


The error seems to be in the calligraphy library of TikZ, but it has not been changed since 2016/02/19.



How can I solve this error?










share|improve this question


















  • 1




    I can reproduce the issue. My guess is that the calligraphy library uses either now deprecated or removed commands or internal commands that were never meant for use outside of the kernel itself and changed without notice.
    – moewe
    18 mins ago












  • @moewe That's my guess, too. Do you think there could be an alternative solution?
    – CarLaTeX
    16 mins ago






  • 1




    The author is aware that he uses "inappropriate" commands (see the comments below tex.stackexchange.com/a/408381, especially tex.stackexchange.com/questions/408378/…) and wanted to take action at some time.
    – TeXnician
    9 mins ago












  • No idea, sorry. I guess one of the expl3 or TikZ experts will swing by soon to have a look. Maybe even the author of the library himself (but as always, if he doesn't respond here, please report the bug properly should it turn out it is one).
    – moewe
    8 mins ago















up vote
0
down vote

favorite












I'm trying to improve an answer of mine and I've found a solution which works perfectly on Overleaf (I looked at the log, not only what is displayed).



listfiles
documentclass[12pt,fleqn]{article}
usepackage{amsmath}
usepackage{environ}
usepackage{tikz}
usetikzlibrary{matrix}
usetikzlibrary{decorations.pathreplacing, calligraphy, calc}
tikzset{
mymatr/.style={
matrix of math nodes,
column sep = 10pt,
nodes={
anchor=text,
inner xsep=3pt
},
inner xsep=7pt,
ampersand replacement=&
}
}
NewEnviron{mybrak}[1][2]{%
begin{tikzpicture}[baseline=(mybase)]
matrix[mymatr](A){
BODY\
};
coordinate (mybase) at ($(A-1-1.text)!.5! (A-#1-1.text)$);
draw[thick]([xshift=-6.4pt]A-1-1.west) -- +(4.4pt,0);
foreach[evaluate=mystep as prev using int(mystep-1)] mystep in {2,...,#1}{
draw[thick]([xshift=-6pt]A-prev-1.west) -- ([xshift=-6pt]A-mystep-1.west) -- + (4pt,0);
}
end{tikzpicture}
}

NewEnviron{mycurly}[1][2]{%
begin{tikzpicture}[baseline=(mybase)]
matrix[mymatr](A){
BODY\
};
coordinate (mybase) at ($(A-1-1.text)!.5! (A-#1-1.text)$);
draw[line width=.9pt,decorate,decoration={calligraphic brace,amplitude=4pt, mirror}](A-1-1.west) -- (A-#1-1.west);
end{tikzpicture}
}


begin{document}
Environment who puts curly braces:
[
begin{mycurly}
frac{3}{4}x+y=2 \
e^{2x}+3y=4
end{mycurly}
]
if you have more than 2 equation, you have to indicate their number in the optional argument:
[
begin{mycurly}[3]
frac{3}{4}x+y=2 \
e^{2x}+3y=4\
sqrt{x+3}+5z=0
end{mycurly}
]
[
begin{mycurly}[4]
x+y=2 \
2x+3y=4 \
3x+5z=0 \
dfrac{7x}{x+9}+y+z=2
end{mycurly}
]
Environment who puts square brakets:
[
begin{mybrak}
frac{3}{4}x+y=2 \
e^{2x}+3y=4
end{mybrak}
]
if you have more than 2 equation, you have to indicate their number in the optional argument:
[
begin{mybrak}[3]
frac{3}{4}x+y=2 \
e^{2x}+3y=4\
sqrt{x+3}+5z=0
end{mybrak}
]
[
begin{mybrak}[4]
x+y=2 \
2x+3y=4 \
3x+5z=0 \
dfrac{7x}{x+9}+y+z=2
end{mybrak}
]
Please note you have to use verb|&| instead of verb|&| here:
[
f(x) =
begin{mycurly}[4]
dfrac{1}{3}x+y=2 & text{if }x<0 \
2x+3y=4 & text{if }0leq x<1\
3x+5z=0 & text{if }1leq x<2\
dfrac{7x}{x+9}+y+z=2 & text{if } x>2
end{mycurly}
]
[
f(x) =
begin{mycurly}[3]
2x+3y=4 & text{if } x<1\
3x+5z=0 & text{if }1leq x<2\
dfrac{7x}{x+9}+y+z=2 & text{if } x>2
end{mycurly}
]
It works also with the bracket type (even if I don't know if it is used in your country):
[
f(x) =
begin{mybrak}[4]
dfrac{1}{3}x+y=2 & text{if }x<0 \
2x+3y=4 & text{if }0leq x<1\
3x+5z=0 & text{if }1leq x<2\
dfrac{7x}{x+9}+y+z=2 & text{if } x>2
end{mybrak}
]
[
f(x) =
begin{mybrak}[3]
2x+3y=4 & text{if } x<1\
3x+5z=0 & text{if }1leq x<2\
dfrac{7x}{x+9}+y+z=2 & text{if } x>2
end{mybrak}
]
end{document}


with these versions of the packages:



 *File List*
article.cls 2014/09/29 v1.4h Standard LaTeX document class
fleqn.clo 2016/12/29 v1.2a Standard LaTeX option (flush left equations)
size12.clo 2014/09/29 v1.4h Standard LaTeX file (size option)
amsmath.sty 2016/11/05 v2.16a AMS math features
amstext.sty 2000/06/29 v2.01 AMS text
amsgen.sty 1999/11/30 v2.0 generic functions
amsbsy.sty 1999/11/29 v1.2d Bold Symbols
amsopn.sty 2016/03/08 v2.02 operator names
environ.sty 2014/05/04 v0.3 A new way to define environments
trimspaces.sty 2009/09/17 v1.1 Trim spaces around a token list
tikz.sty 2015/08/07 v3.0.1a (rcs-revision 1.151)
pgf.sty 2015/08/07 v3.0.1a (rcs-revision 1.15)
pgfrcs.sty 2015/08/07 v3.0.1a (rcs-revision 1.31)
everyshi.sty 2001/05/15 v3.00 EveryShipout Package (MS)
pgfrcs.code.tex
pgfcore.sty 2010/04/11 v3.0.1a (rcs-revision 1.7)
graphicx.sty 2017/06/01 v1.1a Enhanced LaTeX Graphics (DPC,SPQR)
keyval.sty 2014/10/28 v1.15 key=value parser (DPC)
graphics.sty 2017/06/25 v1.2c Standard LaTeX Graphics (DPC,SPQR)
trig.sty 2016/01/03 v1.10 sin cos tan (DPC)
graphics.cfg 2016/06/04 v1.11 sample graphics configuration
pdftex.def 2017/06/24 v1.0g Graphics/color driver for pdftex
pgfsys.sty 2014/07/09 v3.0.1a (rcs-revision 1.48)
pgfsys.code.tex
pgfsyssoftpath.code.tex 2013/09/09 (rcs-revision 1.9)
pgfsysprotocol.code.tex 2006/10/16 (rcs-revision 1.4)
xcolor.sty 2016/05/11 v2.12 LaTeX color extensions (UK)
color.cfg 2016/01/02 v1.6 sample color configuration
pgfcore.code.tex
pgfcomp-version-0-65.sty 2007/07/03 v3.0.1a (rcs-revision 1.7)
pgfcomp-version-1-18.sty 2007/07/23 v3.0.1a (rcs-revision 1.1)
pgffor.sty 2013/12/13 v3.0.1a (rcs-revision 1.25)
pgfkeys.sty
pgfkeys.code.tex
pgfmath.sty
pgfmath.code.tex
pgffor.code.tex
tikz.code.tex
spath3.sty 2016/02/19 v1.1 Functions for manipulating PGF soft paths
expl3.sty 2017/05/29 L3 programming layer (loader)
expl3-code.tex 2017/05/29 L3 programming layer
l3pdfmode.def 2017/03/18 v L3 Experimental driver: PDF mode
xparse.sty 2017/05/29 L3 Experimental document command parser
supp-pdf.mkii
epstopdf-base.sty 2016/05/15 v2.6 Base part for package epstopdf
infwarerr.sty 2016/05/16 v1.4 Providing info/warning/error messages (HO)
grfext.sty 2016/05/16 v1.2 Manage graphics extensions (HO)
kvdefinekeys.sty 2016/05/16 v1.4 Define keys (HO)
ltxcmds.sty 2016/05/16 v1.23 LaTeX kernel commands for general use (HO)
kvoptions.sty 2016/05/16 v3.12 Key value format for package options (HO)
kvsetkeys.sty 2016/05/16 v1.17 Key value parser (HO)
etexcmds.sty 2016/05/16 v1.6 Avoid name clashes with e-TeX commands (HO)
ifluatex.sty 2016/05/16 v1.4 Provides the ifluatex switch (HO)
pdftexcmds.sty 2017/03/19 v0.25 Utility functions of pdfTeX for LuaTeX (HO)
ifpdf.sty 2017/03/15 v3.2 Provides the ifpdf switch
epstopdf-sys.cfg 2010/07/13 v1.3 Configuration of (r)epstopdf for TeX Live
***********


But if I try on my computer, with the updated versions of the packages:



 *File List*
article.cls 2014/09/29 v1.4h Standard LaTeX document class
fleqn.clo 2016/12/29 v1.2a Standard LaTeX option (flush left equations)
size12.clo 2014/09/29 v1.4h Standard LaTeX file (size option)
amsmath.sty 2017/09/02 v2.17a AMS math features
amstext.sty 2000/06/29 v2.01 AMS text
amsgen.sty 1999/11/30 v2.0 generic functions
amsbsy.sty 1999/11/29 v1.2d Bold Symbols
amsopn.sty 2016/03/08 v2.02 operator names
environ.sty 2014/05/04 v0.3 A new way to define environments
trimspaces.sty 2009/09/17 v1.1 Trim spaces around a token list
tikz.sty 2015/08/07 v3.0.1a (rcs-revision 1.151)
pgf.sty 2015/08/07 v3.0.1a (rcs-revision 1.15)
pgfrcs.sty 2015/08/07 v3.0.1a (rcs-revision 1.31)
everyshi.sty 2001/05/15 v3.00 EveryShipout Package (MS)
pgfrcs.code.tex
pgfcore.sty 2010/04/11 v3.0.1a (rcs-revision 1.7)
graphicx.sty 2017/06/01 v1.1a Enhanced LaTeX Graphics (DPC,SPQR)
keyval.sty 2014/10/28 v1.15 key=value parser (DPC)
graphics.sty 2017/06/25 v1.2c Standard LaTeX Graphics (DPC,SPQR)
trig.sty 2016/01/03 v1.10 sin cos tan (DPC)
graphics.cfg 2016/06/04 v1.11 sample graphics configuration
pdftex.def 2018/01/08 v1.0l Graphics/color driver for pdftex
pgfsys.sty 2014/07/09 v3.0.1a (rcs-revision 1.48)
pgfsys.code.tex
pgfsyssoftpath.code.tex 2013/09/09 (rcs-revision 1.9)
pgfsysprotocol.code.tex 2006/10/16 (rcs-revision 1.4)
xcolor.sty 2016/05/11 v2.12 LaTeX color extensions (UK)
color.cfg 2016/01/02 v1.6 sample color configuration
pgfcore.code.tex
pgfcomp-version-0-65.sty 2007/07/03 v3.0.1a (rcs-revision 1.7)
pgfcomp-version-1-18.sty 2007/07/23 v3.0.1a (rcs-revision 1.1)
pgffor.sty 2013/12/13 v3.0.1a (rcs-revision 1.25)
pgfkeys.sty
pgfkeys.code.tex
pgfmath.sty
pgfmath.code.tex
pgffor.code.tex
tikz.code.tex
spath3.sty 2016/02/19 v1.1 Functions for manipulating PGF soft paths
expl3.sty 2018-11-19 L3 programming layer (loader)
expl3-code.tex 2018-11-19 L3 programming layer
l3pdfmode.def 2018-11-19 v L3 Experimental driver: PDF mode
xparse.sty 2018-10-17 L3 Experimental document command parser
supp-pdf.mkii
epstopdf-base.sty 2016/05/15 v2.6 Base part for package epstopdf
infwarerr.sty 2016/05/16 v1.4 Providing info/warning/error messages (HO)
grfext.sty 2016/05/16 v1.2 Manage graphics extensions (HO)
kvdefinekeys.sty 2016/05/16 v1.4 Define keys (HO)
ltxcmds.sty 2016/05/16 v1.23 LaTeX kernel commands for general use (HO)
kvoptions.sty 2016/05/16 v3.12 Key value format for package options (HO)
kvsetkeys.sty 2016/05/16 v1.17 Key value parser (HO)
etexcmds.sty 2016/05/16 v1.6 Avoid name clashes with e-TeX commands (HO)
ifluatex.sty 2016/05/16 v1.4 Provides the ifluatex switch (HO)
pdftexcmds.sty 2018/09/10 v0.29 Utility functions of pdfTeX for LuaTeX (HO)
ifpdf.sty 2018/09/07 v3.3 Provides the ifpdf switch
epstopdf-sys.cfg 2010/07/13 v1.3 Configuration of (r)epstopdf for TeX Live
***********


I get the error (followed by many others):



! Undefined control sequence.
<argument> g__prg_map_int

l.54 end{mycurly}


The error seems to be in the calligraphy library of TikZ, but it has not been changed since 2016/02/19.



How can I solve this error?










share|improve this question


















  • 1




    I can reproduce the issue. My guess is that the calligraphy library uses either now deprecated or removed commands or internal commands that were never meant for use outside of the kernel itself and changed without notice.
    – moewe
    18 mins ago












  • @moewe That's my guess, too. Do you think there could be an alternative solution?
    – CarLaTeX
    16 mins ago






  • 1




    The author is aware that he uses "inappropriate" commands (see the comments below tex.stackexchange.com/a/408381, especially tex.stackexchange.com/questions/408378/…) and wanted to take action at some time.
    – TeXnician
    9 mins ago












  • No idea, sorry. I guess one of the expl3 or TikZ experts will swing by soon to have a look. Maybe even the author of the library himself (but as always, if he doesn't respond here, please report the bug properly should it turn out it is one).
    – moewe
    8 mins ago













up vote
0
down vote

favorite









up vote
0
down vote

favorite











I'm trying to improve an answer of mine and I've found a solution which works perfectly on Overleaf (I looked at the log, not only what is displayed).



listfiles
documentclass[12pt,fleqn]{article}
usepackage{amsmath}
usepackage{environ}
usepackage{tikz}
usetikzlibrary{matrix}
usetikzlibrary{decorations.pathreplacing, calligraphy, calc}
tikzset{
mymatr/.style={
matrix of math nodes,
column sep = 10pt,
nodes={
anchor=text,
inner xsep=3pt
},
inner xsep=7pt,
ampersand replacement=&
}
}
NewEnviron{mybrak}[1][2]{%
begin{tikzpicture}[baseline=(mybase)]
matrix[mymatr](A){
BODY\
};
coordinate (mybase) at ($(A-1-1.text)!.5! (A-#1-1.text)$);
draw[thick]([xshift=-6.4pt]A-1-1.west) -- +(4.4pt,0);
foreach[evaluate=mystep as prev using int(mystep-1)] mystep in {2,...,#1}{
draw[thick]([xshift=-6pt]A-prev-1.west) -- ([xshift=-6pt]A-mystep-1.west) -- + (4pt,0);
}
end{tikzpicture}
}

NewEnviron{mycurly}[1][2]{%
begin{tikzpicture}[baseline=(mybase)]
matrix[mymatr](A){
BODY\
};
coordinate (mybase) at ($(A-1-1.text)!.5! (A-#1-1.text)$);
draw[line width=.9pt,decorate,decoration={calligraphic brace,amplitude=4pt, mirror}](A-1-1.west) -- (A-#1-1.west);
end{tikzpicture}
}


begin{document}
Environment who puts curly braces:
[
begin{mycurly}
frac{3}{4}x+y=2 \
e^{2x}+3y=4
end{mycurly}
]
if you have more than 2 equation, you have to indicate their number in the optional argument:
[
begin{mycurly}[3]
frac{3}{4}x+y=2 \
e^{2x}+3y=4\
sqrt{x+3}+5z=0
end{mycurly}
]
[
begin{mycurly}[4]
x+y=2 \
2x+3y=4 \
3x+5z=0 \
dfrac{7x}{x+9}+y+z=2
end{mycurly}
]
Environment who puts square brakets:
[
begin{mybrak}
frac{3}{4}x+y=2 \
e^{2x}+3y=4
end{mybrak}
]
if you have more than 2 equation, you have to indicate their number in the optional argument:
[
begin{mybrak}[3]
frac{3}{4}x+y=2 \
e^{2x}+3y=4\
sqrt{x+3}+5z=0
end{mybrak}
]
[
begin{mybrak}[4]
x+y=2 \
2x+3y=4 \
3x+5z=0 \
dfrac{7x}{x+9}+y+z=2
end{mybrak}
]
Please note you have to use verb|&| instead of verb|&| here:
[
f(x) =
begin{mycurly}[4]
dfrac{1}{3}x+y=2 & text{if }x<0 \
2x+3y=4 & text{if }0leq x<1\
3x+5z=0 & text{if }1leq x<2\
dfrac{7x}{x+9}+y+z=2 & text{if } x>2
end{mycurly}
]
[
f(x) =
begin{mycurly}[3]
2x+3y=4 & text{if } x<1\
3x+5z=0 & text{if }1leq x<2\
dfrac{7x}{x+9}+y+z=2 & text{if } x>2
end{mycurly}
]
It works also with the bracket type (even if I don't know if it is used in your country):
[
f(x) =
begin{mybrak}[4]
dfrac{1}{3}x+y=2 & text{if }x<0 \
2x+3y=4 & text{if }0leq x<1\
3x+5z=0 & text{if }1leq x<2\
dfrac{7x}{x+9}+y+z=2 & text{if } x>2
end{mybrak}
]
[
f(x) =
begin{mybrak}[3]
2x+3y=4 & text{if } x<1\
3x+5z=0 & text{if }1leq x<2\
dfrac{7x}{x+9}+y+z=2 & text{if } x>2
end{mybrak}
]
end{document}


with these versions of the packages:



 *File List*
article.cls 2014/09/29 v1.4h Standard LaTeX document class
fleqn.clo 2016/12/29 v1.2a Standard LaTeX option (flush left equations)
size12.clo 2014/09/29 v1.4h Standard LaTeX file (size option)
amsmath.sty 2016/11/05 v2.16a AMS math features
amstext.sty 2000/06/29 v2.01 AMS text
amsgen.sty 1999/11/30 v2.0 generic functions
amsbsy.sty 1999/11/29 v1.2d Bold Symbols
amsopn.sty 2016/03/08 v2.02 operator names
environ.sty 2014/05/04 v0.3 A new way to define environments
trimspaces.sty 2009/09/17 v1.1 Trim spaces around a token list
tikz.sty 2015/08/07 v3.0.1a (rcs-revision 1.151)
pgf.sty 2015/08/07 v3.0.1a (rcs-revision 1.15)
pgfrcs.sty 2015/08/07 v3.0.1a (rcs-revision 1.31)
everyshi.sty 2001/05/15 v3.00 EveryShipout Package (MS)
pgfrcs.code.tex
pgfcore.sty 2010/04/11 v3.0.1a (rcs-revision 1.7)
graphicx.sty 2017/06/01 v1.1a Enhanced LaTeX Graphics (DPC,SPQR)
keyval.sty 2014/10/28 v1.15 key=value parser (DPC)
graphics.sty 2017/06/25 v1.2c Standard LaTeX Graphics (DPC,SPQR)
trig.sty 2016/01/03 v1.10 sin cos tan (DPC)
graphics.cfg 2016/06/04 v1.11 sample graphics configuration
pdftex.def 2017/06/24 v1.0g Graphics/color driver for pdftex
pgfsys.sty 2014/07/09 v3.0.1a (rcs-revision 1.48)
pgfsys.code.tex
pgfsyssoftpath.code.tex 2013/09/09 (rcs-revision 1.9)
pgfsysprotocol.code.tex 2006/10/16 (rcs-revision 1.4)
xcolor.sty 2016/05/11 v2.12 LaTeX color extensions (UK)
color.cfg 2016/01/02 v1.6 sample color configuration
pgfcore.code.tex
pgfcomp-version-0-65.sty 2007/07/03 v3.0.1a (rcs-revision 1.7)
pgfcomp-version-1-18.sty 2007/07/23 v3.0.1a (rcs-revision 1.1)
pgffor.sty 2013/12/13 v3.0.1a (rcs-revision 1.25)
pgfkeys.sty
pgfkeys.code.tex
pgfmath.sty
pgfmath.code.tex
pgffor.code.tex
tikz.code.tex
spath3.sty 2016/02/19 v1.1 Functions for manipulating PGF soft paths
expl3.sty 2017/05/29 L3 programming layer (loader)
expl3-code.tex 2017/05/29 L3 programming layer
l3pdfmode.def 2017/03/18 v L3 Experimental driver: PDF mode
xparse.sty 2017/05/29 L3 Experimental document command parser
supp-pdf.mkii
epstopdf-base.sty 2016/05/15 v2.6 Base part for package epstopdf
infwarerr.sty 2016/05/16 v1.4 Providing info/warning/error messages (HO)
grfext.sty 2016/05/16 v1.2 Manage graphics extensions (HO)
kvdefinekeys.sty 2016/05/16 v1.4 Define keys (HO)
ltxcmds.sty 2016/05/16 v1.23 LaTeX kernel commands for general use (HO)
kvoptions.sty 2016/05/16 v3.12 Key value format for package options (HO)
kvsetkeys.sty 2016/05/16 v1.17 Key value parser (HO)
etexcmds.sty 2016/05/16 v1.6 Avoid name clashes with e-TeX commands (HO)
ifluatex.sty 2016/05/16 v1.4 Provides the ifluatex switch (HO)
pdftexcmds.sty 2017/03/19 v0.25 Utility functions of pdfTeX for LuaTeX (HO)
ifpdf.sty 2017/03/15 v3.2 Provides the ifpdf switch
epstopdf-sys.cfg 2010/07/13 v1.3 Configuration of (r)epstopdf for TeX Live
***********


But if I try on my computer, with the updated versions of the packages:



 *File List*
article.cls 2014/09/29 v1.4h Standard LaTeX document class
fleqn.clo 2016/12/29 v1.2a Standard LaTeX option (flush left equations)
size12.clo 2014/09/29 v1.4h Standard LaTeX file (size option)
amsmath.sty 2017/09/02 v2.17a AMS math features
amstext.sty 2000/06/29 v2.01 AMS text
amsgen.sty 1999/11/30 v2.0 generic functions
amsbsy.sty 1999/11/29 v1.2d Bold Symbols
amsopn.sty 2016/03/08 v2.02 operator names
environ.sty 2014/05/04 v0.3 A new way to define environments
trimspaces.sty 2009/09/17 v1.1 Trim spaces around a token list
tikz.sty 2015/08/07 v3.0.1a (rcs-revision 1.151)
pgf.sty 2015/08/07 v3.0.1a (rcs-revision 1.15)
pgfrcs.sty 2015/08/07 v3.0.1a (rcs-revision 1.31)
everyshi.sty 2001/05/15 v3.00 EveryShipout Package (MS)
pgfrcs.code.tex
pgfcore.sty 2010/04/11 v3.0.1a (rcs-revision 1.7)
graphicx.sty 2017/06/01 v1.1a Enhanced LaTeX Graphics (DPC,SPQR)
keyval.sty 2014/10/28 v1.15 key=value parser (DPC)
graphics.sty 2017/06/25 v1.2c Standard LaTeX Graphics (DPC,SPQR)
trig.sty 2016/01/03 v1.10 sin cos tan (DPC)
graphics.cfg 2016/06/04 v1.11 sample graphics configuration
pdftex.def 2018/01/08 v1.0l Graphics/color driver for pdftex
pgfsys.sty 2014/07/09 v3.0.1a (rcs-revision 1.48)
pgfsys.code.tex
pgfsyssoftpath.code.tex 2013/09/09 (rcs-revision 1.9)
pgfsysprotocol.code.tex 2006/10/16 (rcs-revision 1.4)
xcolor.sty 2016/05/11 v2.12 LaTeX color extensions (UK)
color.cfg 2016/01/02 v1.6 sample color configuration
pgfcore.code.tex
pgfcomp-version-0-65.sty 2007/07/03 v3.0.1a (rcs-revision 1.7)
pgfcomp-version-1-18.sty 2007/07/23 v3.0.1a (rcs-revision 1.1)
pgffor.sty 2013/12/13 v3.0.1a (rcs-revision 1.25)
pgfkeys.sty
pgfkeys.code.tex
pgfmath.sty
pgfmath.code.tex
pgffor.code.tex
tikz.code.tex
spath3.sty 2016/02/19 v1.1 Functions for manipulating PGF soft paths
expl3.sty 2018-11-19 L3 programming layer (loader)
expl3-code.tex 2018-11-19 L3 programming layer
l3pdfmode.def 2018-11-19 v L3 Experimental driver: PDF mode
xparse.sty 2018-10-17 L3 Experimental document command parser
supp-pdf.mkii
epstopdf-base.sty 2016/05/15 v2.6 Base part for package epstopdf
infwarerr.sty 2016/05/16 v1.4 Providing info/warning/error messages (HO)
grfext.sty 2016/05/16 v1.2 Manage graphics extensions (HO)
kvdefinekeys.sty 2016/05/16 v1.4 Define keys (HO)
ltxcmds.sty 2016/05/16 v1.23 LaTeX kernel commands for general use (HO)
kvoptions.sty 2016/05/16 v3.12 Key value format for package options (HO)
kvsetkeys.sty 2016/05/16 v1.17 Key value parser (HO)
etexcmds.sty 2016/05/16 v1.6 Avoid name clashes with e-TeX commands (HO)
ifluatex.sty 2016/05/16 v1.4 Provides the ifluatex switch (HO)
pdftexcmds.sty 2018/09/10 v0.29 Utility functions of pdfTeX for LuaTeX (HO)
ifpdf.sty 2018/09/07 v3.3 Provides the ifpdf switch
epstopdf-sys.cfg 2010/07/13 v1.3 Configuration of (r)epstopdf for TeX Live
***********


I get the error (followed by many others):



! Undefined control sequence.
<argument> g__prg_map_int

l.54 end{mycurly}


The error seems to be in the calligraphy library of TikZ, but it has not been changed since 2016/02/19.



How can I solve this error?










share|improve this question













I'm trying to improve an answer of mine and I've found a solution which works perfectly on Overleaf (I looked at the log, not only what is displayed).



listfiles
documentclass[12pt,fleqn]{article}
usepackage{amsmath}
usepackage{environ}
usepackage{tikz}
usetikzlibrary{matrix}
usetikzlibrary{decorations.pathreplacing, calligraphy, calc}
tikzset{
mymatr/.style={
matrix of math nodes,
column sep = 10pt,
nodes={
anchor=text,
inner xsep=3pt
},
inner xsep=7pt,
ampersand replacement=&
}
}
NewEnviron{mybrak}[1][2]{%
begin{tikzpicture}[baseline=(mybase)]
matrix[mymatr](A){
BODY\
};
coordinate (mybase) at ($(A-1-1.text)!.5! (A-#1-1.text)$);
draw[thick]([xshift=-6.4pt]A-1-1.west) -- +(4.4pt,0);
foreach[evaluate=mystep as prev using int(mystep-1)] mystep in {2,...,#1}{
draw[thick]([xshift=-6pt]A-prev-1.west) -- ([xshift=-6pt]A-mystep-1.west) -- + (4pt,0);
}
end{tikzpicture}
}

NewEnviron{mycurly}[1][2]{%
begin{tikzpicture}[baseline=(mybase)]
matrix[mymatr](A){
BODY\
};
coordinate (mybase) at ($(A-1-1.text)!.5! (A-#1-1.text)$);
draw[line width=.9pt,decorate,decoration={calligraphic brace,amplitude=4pt, mirror}](A-1-1.west) -- (A-#1-1.west);
end{tikzpicture}
}


begin{document}
Environment who puts curly braces:
[
begin{mycurly}
frac{3}{4}x+y=2 \
e^{2x}+3y=4
end{mycurly}
]
if you have more than 2 equation, you have to indicate their number in the optional argument:
[
begin{mycurly}[3]
frac{3}{4}x+y=2 \
e^{2x}+3y=4\
sqrt{x+3}+5z=0
end{mycurly}
]
[
begin{mycurly}[4]
x+y=2 \
2x+3y=4 \
3x+5z=0 \
dfrac{7x}{x+9}+y+z=2
end{mycurly}
]
Environment who puts square brakets:
[
begin{mybrak}
frac{3}{4}x+y=2 \
e^{2x}+3y=4
end{mybrak}
]
if you have more than 2 equation, you have to indicate their number in the optional argument:
[
begin{mybrak}[3]
frac{3}{4}x+y=2 \
e^{2x}+3y=4\
sqrt{x+3}+5z=0
end{mybrak}
]
[
begin{mybrak}[4]
x+y=2 \
2x+3y=4 \
3x+5z=0 \
dfrac{7x}{x+9}+y+z=2
end{mybrak}
]
Please note you have to use verb|&| instead of verb|&| here:
[
f(x) =
begin{mycurly}[4]
dfrac{1}{3}x+y=2 & text{if }x<0 \
2x+3y=4 & text{if }0leq x<1\
3x+5z=0 & text{if }1leq x<2\
dfrac{7x}{x+9}+y+z=2 & text{if } x>2
end{mycurly}
]
[
f(x) =
begin{mycurly}[3]
2x+3y=4 & text{if } x<1\
3x+5z=0 & text{if }1leq x<2\
dfrac{7x}{x+9}+y+z=2 & text{if } x>2
end{mycurly}
]
It works also with the bracket type (even if I don't know if it is used in your country):
[
f(x) =
begin{mybrak}[4]
dfrac{1}{3}x+y=2 & text{if }x<0 \
2x+3y=4 & text{if }0leq x<1\
3x+5z=0 & text{if }1leq x<2\
dfrac{7x}{x+9}+y+z=2 & text{if } x>2
end{mybrak}
]
[
f(x) =
begin{mybrak}[3]
2x+3y=4 & text{if } x<1\
3x+5z=0 & text{if }1leq x<2\
dfrac{7x}{x+9}+y+z=2 & text{if } x>2
end{mybrak}
]
end{document}


with these versions of the packages:



 *File List*
article.cls 2014/09/29 v1.4h Standard LaTeX document class
fleqn.clo 2016/12/29 v1.2a Standard LaTeX option (flush left equations)
size12.clo 2014/09/29 v1.4h Standard LaTeX file (size option)
amsmath.sty 2016/11/05 v2.16a AMS math features
amstext.sty 2000/06/29 v2.01 AMS text
amsgen.sty 1999/11/30 v2.0 generic functions
amsbsy.sty 1999/11/29 v1.2d Bold Symbols
amsopn.sty 2016/03/08 v2.02 operator names
environ.sty 2014/05/04 v0.3 A new way to define environments
trimspaces.sty 2009/09/17 v1.1 Trim spaces around a token list
tikz.sty 2015/08/07 v3.0.1a (rcs-revision 1.151)
pgf.sty 2015/08/07 v3.0.1a (rcs-revision 1.15)
pgfrcs.sty 2015/08/07 v3.0.1a (rcs-revision 1.31)
everyshi.sty 2001/05/15 v3.00 EveryShipout Package (MS)
pgfrcs.code.tex
pgfcore.sty 2010/04/11 v3.0.1a (rcs-revision 1.7)
graphicx.sty 2017/06/01 v1.1a Enhanced LaTeX Graphics (DPC,SPQR)
keyval.sty 2014/10/28 v1.15 key=value parser (DPC)
graphics.sty 2017/06/25 v1.2c Standard LaTeX Graphics (DPC,SPQR)
trig.sty 2016/01/03 v1.10 sin cos tan (DPC)
graphics.cfg 2016/06/04 v1.11 sample graphics configuration
pdftex.def 2017/06/24 v1.0g Graphics/color driver for pdftex
pgfsys.sty 2014/07/09 v3.0.1a (rcs-revision 1.48)
pgfsys.code.tex
pgfsyssoftpath.code.tex 2013/09/09 (rcs-revision 1.9)
pgfsysprotocol.code.tex 2006/10/16 (rcs-revision 1.4)
xcolor.sty 2016/05/11 v2.12 LaTeX color extensions (UK)
color.cfg 2016/01/02 v1.6 sample color configuration
pgfcore.code.tex
pgfcomp-version-0-65.sty 2007/07/03 v3.0.1a (rcs-revision 1.7)
pgfcomp-version-1-18.sty 2007/07/23 v3.0.1a (rcs-revision 1.1)
pgffor.sty 2013/12/13 v3.0.1a (rcs-revision 1.25)
pgfkeys.sty
pgfkeys.code.tex
pgfmath.sty
pgfmath.code.tex
pgffor.code.tex
tikz.code.tex
spath3.sty 2016/02/19 v1.1 Functions for manipulating PGF soft paths
expl3.sty 2017/05/29 L3 programming layer (loader)
expl3-code.tex 2017/05/29 L3 programming layer
l3pdfmode.def 2017/03/18 v L3 Experimental driver: PDF mode
xparse.sty 2017/05/29 L3 Experimental document command parser
supp-pdf.mkii
epstopdf-base.sty 2016/05/15 v2.6 Base part for package epstopdf
infwarerr.sty 2016/05/16 v1.4 Providing info/warning/error messages (HO)
grfext.sty 2016/05/16 v1.2 Manage graphics extensions (HO)
kvdefinekeys.sty 2016/05/16 v1.4 Define keys (HO)
ltxcmds.sty 2016/05/16 v1.23 LaTeX kernel commands for general use (HO)
kvoptions.sty 2016/05/16 v3.12 Key value format for package options (HO)
kvsetkeys.sty 2016/05/16 v1.17 Key value parser (HO)
etexcmds.sty 2016/05/16 v1.6 Avoid name clashes with e-TeX commands (HO)
ifluatex.sty 2016/05/16 v1.4 Provides the ifluatex switch (HO)
pdftexcmds.sty 2017/03/19 v0.25 Utility functions of pdfTeX for LuaTeX (HO)
ifpdf.sty 2017/03/15 v3.2 Provides the ifpdf switch
epstopdf-sys.cfg 2010/07/13 v1.3 Configuration of (r)epstopdf for TeX Live
***********


But if I try on my computer, with the updated versions of the packages:



 *File List*
article.cls 2014/09/29 v1.4h Standard LaTeX document class
fleqn.clo 2016/12/29 v1.2a Standard LaTeX option (flush left equations)
size12.clo 2014/09/29 v1.4h Standard LaTeX file (size option)
amsmath.sty 2017/09/02 v2.17a AMS math features
amstext.sty 2000/06/29 v2.01 AMS text
amsgen.sty 1999/11/30 v2.0 generic functions
amsbsy.sty 1999/11/29 v1.2d Bold Symbols
amsopn.sty 2016/03/08 v2.02 operator names
environ.sty 2014/05/04 v0.3 A new way to define environments
trimspaces.sty 2009/09/17 v1.1 Trim spaces around a token list
tikz.sty 2015/08/07 v3.0.1a (rcs-revision 1.151)
pgf.sty 2015/08/07 v3.0.1a (rcs-revision 1.15)
pgfrcs.sty 2015/08/07 v3.0.1a (rcs-revision 1.31)
everyshi.sty 2001/05/15 v3.00 EveryShipout Package (MS)
pgfrcs.code.tex
pgfcore.sty 2010/04/11 v3.0.1a (rcs-revision 1.7)
graphicx.sty 2017/06/01 v1.1a Enhanced LaTeX Graphics (DPC,SPQR)
keyval.sty 2014/10/28 v1.15 key=value parser (DPC)
graphics.sty 2017/06/25 v1.2c Standard LaTeX Graphics (DPC,SPQR)
trig.sty 2016/01/03 v1.10 sin cos tan (DPC)
graphics.cfg 2016/06/04 v1.11 sample graphics configuration
pdftex.def 2018/01/08 v1.0l Graphics/color driver for pdftex
pgfsys.sty 2014/07/09 v3.0.1a (rcs-revision 1.48)
pgfsys.code.tex
pgfsyssoftpath.code.tex 2013/09/09 (rcs-revision 1.9)
pgfsysprotocol.code.tex 2006/10/16 (rcs-revision 1.4)
xcolor.sty 2016/05/11 v2.12 LaTeX color extensions (UK)
color.cfg 2016/01/02 v1.6 sample color configuration
pgfcore.code.tex
pgfcomp-version-0-65.sty 2007/07/03 v3.0.1a (rcs-revision 1.7)
pgfcomp-version-1-18.sty 2007/07/23 v3.0.1a (rcs-revision 1.1)
pgffor.sty 2013/12/13 v3.0.1a (rcs-revision 1.25)
pgfkeys.sty
pgfkeys.code.tex
pgfmath.sty
pgfmath.code.tex
pgffor.code.tex
tikz.code.tex
spath3.sty 2016/02/19 v1.1 Functions for manipulating PGF soft paths
expl3.sty 2018-11-19 L3 programming layer (loader)
expl3-code.tex 2018-11-19 L3 programming layer
l3pdfmode.def 2018-11-19 v L3 Experimental driver: PDF mode
xparse.sty 2018-10-17 L3 Experimental document command parser
supp-pdf.mkii
epstopdf-base.sty 2016/05/15 v2.6 Base part for package epstopdf
infwarerr.sty 2016/05/16 v1.4 Providing info/warning/error messages (HO)
grfext.sty 2016/05/16 v1.2 Manage graphics extensions (HO)
kvdefinekeys.sty 2016/05/16 v1.4 Define keys (HO)
ltxcmds.sty 2016/05/16 v1.23 LaTeX kernel commands for general use (HO)
kvoptions.sty 2016/05/16 v3.12 Key value format for package options (HO)
kvsetkeys.sty 2016/05/16 v1.17 Key value parser (HO)
etexcmds.sty 2016/05/16 v1.6 Avoid name clashes with e-TeX commands (HO)
ifluatex.sty 2016/05/16 v1.4 Provides the ifluatex switch (HO)
pdftexcmds.sty 2018/09/10 v0.29 Utility functions of pdfTeX for LuaTeX (HO)
ifpdf.sty 2018/09/07 v3.3 Provides the ifpdf switch
epstopdf-sys.cfg 2010/07/13 v1.3 Configuration of (r)epstopdf for TeX Live
***********


I get the error (followed by many others):



! Undefined control sequence.
<argument> g__prg_map_int

l.54 end{mycurly}


The error seems to be in the calligraphy library of TikZ, but it has not been changed since 2016/02/19.



How can I solve this error?







tikz-pgf errors calligraphy






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked 21 mins ago









CarLaTeX

28.1k445121




28.1k445121








  • 1




    I can reproduce the issue. My guess is that the calligraphy library uses either now deprecated or removed commands or internal commands that were never meant for use outside of the kernel itself and changed without notice.
    – moewe
    18 mins ago












  • @moewe That's my guess, too. Do you think there could be an alternative solution?
    – CarLaTeX
    16 mins ago






  • 1




    The author is aware that he uses "inappropriate" commands (see the comments below tex.stackexchange.com/a/408381, especially tex.stackexchange.com/questions/408378/…) and wanted to take action at some time.
    – TeXnician
    9 mins ago












  • No idea, sorry. I guess one of the expl3 or TikZ experts will swing by soon to have a look. Maybe even the author of the library himself (but as always, if he doesn't respond here, please report the bug properly should it turn out it is one).
    – moewe
    8 mins ago














  • 1




    I can reproduce the issue. My guess is that the calligraphy library uses either now deprecated or removed commands or internal commands that were never meant for use outside of the kernel itself and changed without notice.
    – moewe
    18 mins ago












  • @moewe That's my guess, too. Do you think there could be an alternative solution?
    – CarLaTeX
    16 mins ago






  • 1




    The author is aware that he uses "inappropriate" commands (see the comments below tex.stackexchange.com/a/408381, especially tex.stackexchange.com/questions/408378/…) and wanted to take action at some time.
    – TeXnician
    9 mins ago












  • No idea, sorry. I guess one of the expl3 or TikZ experts will swing by soon to have a look. Maybe even the author of the library himself (but as always, if he doesn't respond here, please report the bug properly should it turn out it is one).
    – moewe
    8 mins ago








1




1




I can reproduce the issue. My guess is that the calligraphy library uses either now deprecated or removed commands or internal commands that were never meant for use outside of the kernel itself and changed without notice.
– moewe
18 mins ago






I can reproduce the issue. My guess is that the calligraphy library uses either now deprecated or removed commands or internal commands that were never meant for use outside of the kernel itself and changed without notice.
– moewe
18 mins ago














@moewe That's my guess, too. Do you think there could be an alternative solution?
– CarLaTeX
16 mins ago




@moewe That's my guess, too. Do you think there could be an alternative solution?
– CarLaTeX
16 mins ago




1




1




The author is aware that he uses "inappropriate" commands (see the comments below tex.stackexchange.com/a/408381, especially tex.stackexchange.com/questions/408378/…) and wanted to take action at some time.
– TeXnician
9 mins ago






The author is aware that he uses "inappropriate" commands (see the comments below tex.stackexchange.com/a/408381, especially tex.stackexchange.com/questions/408378/…) and wanted to take action at some time.
– TeXnician
9 mins ago














No idea, sorry. I guess one of the expl3 or TikZ experts will swing by soon to have a look. Maybe even the author of the library himself (but as always, if he doesn't respond here, please report the bug properly should it turn out it is one).
– moewe
8 mins ago




No idea, sorry. I guess one of the expl3 or TikZ experts will swing by soon to have a look. Maybe even the author of the library himself (but as always, if he doesn't respond here, please report the bug properly should it turn out it is one).
– moewe
8 mins ago










1 Answer
1






active

oldest

votes

















up vote
1
down vote













In the process of tightening up some expl3 concepts, a few internal commands were removed. Here, one was used by a third-party package. Until the code there is altered, one can use



usepackage{expl3}
ExplSyntaxOn
int_new:N g__prg_map_int
ExplSyntaxOff


before



usetikzlibrary{decorations.pathreplacing, calligraphy, calc}




share





















    Your Answer








    StackExchange.ready(function() {
    var channelOptions = {
    tags: "".split(" "),
    id: "85"
    };
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function() {
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled) {
    StackExchange.using("snippets", function() {
    createEditor();
    });
    }
    else {
    createEditor();
    }
    });

    function createEditor() {
    StackExchange.prepareEditor({
    heartbeatType: 'answer',
    convertImagesToLinks: false,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: null,
    bindNavPrevention: true,
    postfix: "",
    imageUploader: {
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    },
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    });


    }
    });














    draft saved

    draft discarded


















    StackExchange.ready(
    function () {
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f463282%2fundefined-control-sequence-only-if-i-compile-with-an-updated-distribution%23new-answer', 'question_page');
    }
    );

    Post as a guest















    Required, but never shown

























    1 Answer
    1






    active

    oldest

    votes








    1 Answer
    1






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes








    up vote
    1
    down vote













    In the process of tightening up some expl3 concepts, a few internal commands were removed. Here, one was used by a third-party package. Until the code there is altered, one can use



    usepackage{expl3}
    ExplSyntaxOn
    int_new:N g__prg_map_int
    ExplSyntaxOff


    before



    usetikzlibrary{decorations.pathreplacing, calligraphy, calc}




    share

























      up vote
      1
      down vote













      In the process of tightening up some expl3 concepts, a few internal commands were removed. Here, one was used by a third-party package. Until the code there is altered, one can use



      usepackage{expl3}
      ExplSyntaxOn
      int_new:N g__prg_map_int
      ExplSyntaxOff


      before



      usetikzlibrary{decorations.pathreplacing, calligraphy, calc}




      share























        up vote
        1
        down vote










        up vote
        1
        down vote









        In the process of tightening up some expl3 concepts, a few internal commands were removed. Here, one was used by a third-party package. Until the code there is altered, one can use



        usepackage{expl3}
        ExplSyntaxOn
        int_new:N g__prg_map_int
        ExplSyntaxOff


        before



        usetikzlibrary{decorations.pathreplacing, calligraphy, calc}




        share












        In the process of tightening up some expl3 concepts, a few internal commands were removed. Here, one was used by a third-party package. Until the code there is altered, one can use



        usepackage{expl3}
        ExplSyntaxOn
        int_new:N g__prg_map_int
        ExplSyntaxOff


        before



        usetikzlibrary{decorations.pathreplacing, calligraphy, calc}





        share











        share


        share










        answered 5 mins ago









        Joseph Wright

        201k21551876




        201k21551876






























            draft saved

            draft discarded




















































            Thanks for contributing an answer to TeX - LaTeX Stack Exchange!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid



            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.


            To learn more, see our tips on writing great answers.





            Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


            Please pay close attention to the following guidance:


            • Please be sure to answer the question. Provide details and share your research!

            But avoid



            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.


            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f463282%2fundefined-control-sequence-only-if-i-compile-with-an-updated-distribution%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            Accessing regular linux commands in Huawei's Dopra Linux

            Can't connect RFCOMM socket: Host is down

            Kernel panic - not syncing: Fatal Exception in Interrupt