Dalsi problem

Jindrich Michal xmichal1 at aisa.fi.muni.cz
Mon Jul 28 21:21:12 CEST 2003


Tak a tady mam dalsi problem. Vubec nevim, kde muze byt.

\gdef\xtrue{T}
\gdef\xfalse{F}

%Toto makro by melo zjistovat pritomnost substringu ve stringu
% #1 subsring, #2 string
\gdef\IsSubstrInStr#1#2{%
  \gdef\isis##1#1##2\endisis{%
    \gdef\fstsubstr{##1}
    \gdef\sndsubstr{##2}
    \gdef\newstr{##1##2}
    \gdef\oldstr{#2}
    \gdef\nic{}}%
  \isis #2#1\endisis
  \ifx\newstr\oldstr
    \ifx\sndsubstr\nic \xfalse \else \xtrue \fi
  \else \xtrue \fi
}%


\def\temp{\IsSubstrInStr {a}{bcd}} % A tohle nefunguje. Proc?
\edef\tempa{\temp}
\tempa

%Hlasi Undefined control sequence

\IsSubstrInStr{a}{bcd} % Tohle funguje





More information about the csTeX mailing list