From 0cb0558dceb0ed685e6dcd249de6359f0e97c101 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Manuel=20P=C3=A9gouri=C3=A9-Gonnard?= <mpg@elzevir.fr>
Date: Mon, 29 Mar 2010 06:54:28 +0200
Subject: Be carful with primitives in attr and cctb.

---
 luatexbase-attr.dtx | 21 +++++++++++++++++++++
 1 file changed, 21 insertions(+)

(limited to 'luatexbase-attr.dtx')

diff --git a/luatexbase-attr.dtx b/luatexbase-attr.dtx
index 3d88b3a..0d8bfb6 100644
--- a/luatexbase-attr.dtx
+++ b/luatexbase-attr.dtx
@@ -250,6 +250,27 @@ See source file '\inFileName' for details.
 \fi
 %    \end{macrocode}
 %
+%    \subsubsection{Primitives needed}
+%
+%    Load \pk{luatexbase-compat}.
+%
+%    \begin{macrocode}
+\begingroup\expandafter\expandafter\expandafter\endgroup
+\expandafter\ifx\csname RequirePackage\endcsname\relax
+  \input luatexbase-compat.sty
+\else
+  \RequirePackage{luatexbase-compat}
+\fi
+%    \end{macrocode}
+%
+%    Make sure the primitives we need are available.
+%
+%    \begin{macrocode}
+\luatexbase@ensure@primitive{luaescapestring}
+\luatexbase@ensure@primitive{attributedef}
+\luatexbase@ensure@primitive{attribute}
+%    \end{macrocode}
+%
 %    \subsubsection{Load supporting Lua module}
 %
 %    First load \pk{luatexbase-loader} (hence \pk{luatexbase-compat}), then
-- 
cgit v1.2.3

