Latest news 2021-06-05: New blog post: Dickimaw Books Site Account.

Bug Tracker

ID 165🔗
Date: 2020-06-30 09:40:28
Status Closed (Fixed)
Category tracklang
Version v1.4
Summary Error message: ! Extra \else.

Sign in to subscribe to notifications about this report.

Description

When one loads Sanskrit with polyglossia, and glossaries package, one gets the following error message:
! Extra \else.
\@tracklang@ifundef ...\relax #2\else #3\fi \else 
                                                  \expandafter \ifx \csname ...
l.13094 {}
          
? 
It looks like a tracklang problem, possibly related to the fact that as Sanskrit can be written in a variety of scripts no script is defined for the Sanskrit language.

See also [TeX.SX Link].

MWE

Download (285B)

\documentclass{article}
\usepackage{polyglossia}
\setdefaultlanguage{english}
\setotherlanguage{sanskrit}
%\setotherlanguage{quechua}
\newfontfamily\sanskritfont{Latin Modern Roman}[Ligatures=TeX]
\usepackage{glossaries-extra}
\makeglossaries
\begin{document}
Something
\end{document}

Evaluation

This seems to be a problem with \IfTrackedLanguageFileExists. The problem can be demonstrated with a simpler LaTeX MWE:

\documentclass{article}
\usepackage[sanskrit]{tracklang}
\begin{document}
\AnyTrackedLanguages
{%
  \ForEachTrackedDialect{\thisdialect}{%
    \IfTrackedLanguageFileExists{\thisdialect}{}{}{}{}%
  }%
}
Something
\end{document}

Or Plain TeX:

\input tracklang
\TrackPredefinedDialect{sanskrit}

\AnyTrackedLanguages
{%
  \ForEachTrackedDialect{\thisdialect}{%
    \IfTrackedLanguageFileExists{\thisdialect}{}{}{}{}%
  }%
}
Something
\bye

It looks like the problem stems from a spurious {\fi} in \@tracklang@test@if@file@exists@for@langII (within the generic TeX code tracklang.tex).

Now fixed in tracklang version 1.5 (2020-06-30).

Comments

0 comments.


Add Comment

Name (optional):

Are you human? Please confirm the bug report ID (which can be found at the top of this page) or login if you have an account.

Comment:

You can use the following markup:

Block:

[pre]Displayed verbatim[/pre]
[quote]block quote[/quote]

In line:

[tt]code[/tt]
[file]file/package/class name[/file]
[em]emphasized text[/em]
[b]bold text[/b]
[url]web address[/url] [sup]superscript[/sup]
[sub]subscript[/sub]

Ordered list:
[ol]
[li]first item[/li]
[li]second item[/li]
[/ol]

Unordered list:
[ul]
[li]first item[/li]
[li]second item[/li]
[/ul]

You can use the Preview button to review your message formatting before submitting.

Page permalink: https://www.dickimaw-books.com/bugtracker.php?key=165