Closed scabug closed 13 years ago
Imported From: https://issues.scala-lang.org/browse/SI-4208?orig=1 Reporter: @paulp Attachments:
@lindydonna said: Toni, are you the right person to handle this? If not, please re-assign or tell me to re-assign.
@cunei said:
This seems to be a genuine bug in Ghostscript: the problem disappears removing the lines between begin
and end
in the following section (lines 8394 to 8399 as of r24170):
\begin{lstlisting}
Byte <-> java.lang.Byte
Short <-> java.lang.Short
Char <-> java.lang.Character
Int <-> java.lang.Integer
Long <-> java.lang.Long
Float <-> java.lang.Float
Double <-> java.lang.Double
Boolean <-> java.lang.Boolean
\end{lstlisting}
The issue reappears again if at least two non-empty lines of text (any text) are inserted between the begin
and end
. I will ask Fabien to try Ghostscript 9.00, we'll see whether there's any improvement.
@cunei said: Correction, lines 8394 to 9399 are:
\begin{lstlisting}
Byte -> Short
Short -> Int
Char -> Int
Int -> Long
Long -> Float
Float -> Double
\end{lstlisting}
The issue is as described above.
@cunei said: reduced version of problematic tex source file
@cunei said: Luxi Mono font
@cunei said: (In r24193) Ugly workaround to address a LaTeX issue introduced in r23753.
Failure in the sense that TeX gets confused for reasons unknown. See #4208 for further information.
@cunei said: After some investigation, it turns out this is a LaTeX failure; a TeX wizard may be required to fully understand what is going on. I am enclosing a reduced version of the TeX source that exhibit the problem (see ticket attachments); removing some random line from this small file seems sufficient to make the example typeset again.
The anomaly in the spec source was introduced in the spec file in r23753. I added an ugly workaround in r24193, but it would clearly be preferable to understand the root cause of the matter. Any suggestion is appreciated.
@cunei said: (In r24195) Slightly better looking ugly workaround, see #4208.
@lexspoon said: It looks like a bug that occurs when a listing crosses a page break. There's nothing special about the listing itself, and if I put a \clearpage before it, the thing builds fine. Give that, the least bad thing to do right now might be to put a \clearpage before any listing that has the problem. Additionally, for longer listings, it might be better to put them inside a float so that they won't possibly cross a page boundary.
To prevent people from following a dead end, I can also add that surrounding the listing with \begin{samepage}...\end{samepage} didn't fix the problem.
The ideal fix would be in the Listings package itself. I don't have time right now to look into that, but perhaps someone else does. Also, I'll email Brooks Moses, the most recent maintainer I can find for the Listings package, and include a link to this bug report and minified sample file.
Now that I see spec changes I guess I should open a ticket for the absence of fresh specifications.
http://www.scala-lang.org/node/212/pdfs
Has not had new scala references for a while.