#2219 tex2ooo literals format

None
closed
nobody
5
2012-12-15
2011-07-02
Hielos
No

Hello, I like maxima very much. I found the tex2ooo module just recently. I hope that this is useful for the community.
I found two bugs:

(%i1) load("tex2ooo");
STYLE-WARNING: redefining QUOTE-% in DEFUN
;
; caught STYLE-WARNING:
; Too many arguments (1) to FORMAT "": uses at most 0.
; See also:
; The ANSI Standard, Section 22.3.10.2
STYLE-WARNING: redefining TEX1 in DEFUN
STYLE-WARNING: redefining TEX-STRING in DEFUN
STYLE-WARNING: redefining TEX-CHAR in DEFUN
STYLE-WARNING: redefining TEX-STRIPDOLLAR in DEFUN
STYLE-WARNING: redefining TEXNUMFORMAT in DEFUN
STYLE-WARNING: redefining TEX-PAREN in DEFUN
STYLE-WARNING: redefining TEX-ARRAY in DEFUN
STYLE-WARNING: redefining TEX-MEXPT in DEFUN
STYLE-WARNING: redefining TEX-SQRT in DEFUN
STYLE-WARNING: redefining TEX-CUBRT in DEFUN
STYLE-WARNING: redefining TEX-MQUOTIENT in DEFUN
STYLE-WARNING: redefining TEX-MATRIX in DEFUN
STYLE-WARNING: redefining TEX-LSUM in DEFUN
STYLE-WARNING: redefining TEX-SUM in DEFUN
STYLE-WARNING: redefining TEX-INT in DEFUN
STYLE-WARNING: redefining TEX-LIMIT in DEFUN
STYLE-WARNING: redefining TEX-AT in DEFUN
STYLE-WARNING: redefining TEX-MBOX in DEFUN
STYLE-WARNING: redefining TEX-CHOOSE in DEFUN
STYLE-WARNING: redefining TEX-MPLUS in DEFUN
STYLE-WARNING: redefining TEX-MCOND in DEFUN
STYLE-WARNING: redefining TEX-MDO in DEFUN
STYLE-WARNING: redefining TEX-MDOIN in DEFUN
STYLE-WARNING: redefining TEXMDO in DEFUN
STYLE-WARNING: redefining TEXMDOIN in DEFUN
;
; caught STYLE-WARNING:
; Too many arguments (1) to FORMAT "": uses at most 0.
; See also:
; The ANSI Standard, Section 22.3.10.2
STYLE-WARNING: redefining TEX-MLABLE in DEFUN
;
; caught WARNING:
; error in FORMAT: string ended before directive was found
; ~
; ^

; in: LAMBDA NIL
; (FORMAT NIL "~" (* 3 (CADR MAXIMA::X)))
;
; caught ERROR:
; (in macroexpansion of (FORMATTER "~"))
; (hint: For more precise location, try *BREAK-ON-SIGNALS*.)
; error in FORMAT: string ended before directive was found
; ~
; ^
STYLE-WARNING: redefining TEX-SPACEOUT in DEFUN
;
; compilation unit finished
; caught 1 ERROR condition
; caught 1 WARNING condition
; caught 2 STYLE-WARNING conditions
(%o1) /usr/share/maxima/5.24.0/share/contrib/tex2ooo.lisp
(%i2) tex(%Delta);
%Delta
(%o2) false
(%i3) tex(t[1]);
true _{1}
(%o3) false

I don't know any lisp, but it seems that the programmer tried to translate %Delta to %DELTA, and I don't know why t[1] becomes true _1 (it should be t_1). To be clear, I expected something like this:
(%i2) tex(%Delta);
%DELTA
(%o2) false
(%i3) tex(t[1]);
true _{1}
(%o3) false

Discussion

  • Robert Dodier
    Robert Dodier
    2012-12-15

    • status: open --> closed
    • milestone: --> None
     
  • Robert Dodier
    Robert Dodier
    2012-12-15

    I don't understand what is the desired output for tex(%Delta). Seems like it should just be %Delta (which is the actual output).

    As for tex(t[1]) => true_1, that is a bug in src/mactex.lisp which was fixed a while ago (commit a27147a23b0), but the same fix was not applied to tex2ooo. I've merged that commit into tex2ooo.lisp (commit 62b55e2) which fixes the problem with tex(t[1]). Therefore closing this report.