« first day (3741 days earlier)      last day (31 days later) » 

7:51 AM
@PhelypeOleinik no, you're right, my memory was tricking me again :( Yesterday evening was no good day for me and my TeX skills :)
 
8:39 AM
quack
 
8:57 AM
\int_new:N \l__bitset_tmpa_int
\prg_new_protected_conditional:Npnn \__bitset_test_int:n #1 { TF }
  {
    \tex_afterassignment:D \__bitset_test_int:w
    \l__bitset_tmpa_int = 0 \tl_trim_spaces_apply:nN {#1} \tl_to_str:n
    \__bitset_test_int_end:
    \use_i:nnn \if_false:
    \__bitset_test_int_end:
    \if_int_compare:w \c_zero_int < \l__bitset_tmpa_int
      \prg_return_true:
    \else:
      \prg_return_false:
    \fi:
  }
\cs_new_eq:NN \__bitset_test_int_end: \exp_stop_f:
\cs_new_protected:Npn \__bitset_test_int:w #1 \__bitset_test_int_end: {}
@PhelypeOleinik ^^^ a slightly faster variant of your test...
(takes roughly 40% of the time of your test to test 123 and 12a)
 
@Skillmon I have lots of tea and cookies here (but no popcorn) ;-)
 
@UlrikeFischer ooh
 
@PauloCereda Eendenvlees
 
@UlrikeFischer good idea, I'll go and make me a coffee :)
 
@campa just wondering, why did you delete your answer to that flashcard vs align question yesterday?
 
9:12 AM
@Skillmon Will commit shortly
 
@JosephWright also, maybe the name should be changed to test_number, as it doesn't really test for an int in the meaning of expl3, as that would also be a valid \numexpr.
 
@Skillmon or perhaps test_digits? @JosephWright
 
@UlrikeFischer it's internal, so I guess it's not too bad if the name doesn't fit perfectly, but test_int sounds wrong... So, yes, that would be fine, too :)
 
9:28 AM
@daleif I wasn't entirely happy with it. The overfull \hbox kept showing up and I had no time to work out where the issue is. I'll look into it later.
@daleif And I wasn't completely sure that I had picked out the best \hbox\bgroup\vbox\bgroup orgy ;-)
 
9:45 AM
@campa that seems fair.
 
In the following file
\documentclass[12pt]{scrlttr2}
\begin{document}
\begin{letter}{}
  \opening{To whom it may concern}
\closing{Yours sincerely,}
\end{letter}
\end{document}
I get the error
 LaTeX Error: There's no line here to end.
Why does this error happen, exactly? It goes if I put anything inside the second arg of \begin{letter}.
 
@FaheemMitha Use \begin{letter}{\strut}
 
@campa Actually, \phantom{} works. And doesn't seem to add anything, as far as I can see.
But my question is, what does this error mean?
 
@FaheemMitha Uh, I had looked into it but I honestly forgot. You get that error when you have `\` in vertical mode. Was the test for emptiness of the recipient not entirely safe? Could be, but I might be wrong.
 
@campa Ok. I just thought it would be helpful to know why it happens.
 
9:55 AM
I meant \\ in vertical mode
 
Helpful and instructive. Should ask a question?
@campa Where does `\\` appear?
 
@FaheemMitha Newlines are used when the recipient's address is set.
 
@campa I see.
This is probably not the best place to ask for an analysis. Should I ask a question? It might be a dupe.
 
@FaheemMitha There are a couple of related questions but as far as I can see no one investigates the cause. It might be worth a question, though I think it's more an "academic" issue.
 
@campa An "academic" issue?
BTW, the same error appears with the vanilla letter class.
 
10:01 AM
@FaheemMitha Well, how often does it happen that you write a letter without an addressee? :-) That's what I meant. As TeX question it's legitimate and interesting.
 
@campa Actually, I did have one. That's why I'm asking the question.
Not all letters need an address. What does \strut do?
@campa So you think it's a reasonable question to ask?
 
@JairoA.delRio oh no
 
@FaheemMitha \strut introduces a \strutbox, basically a box with zero width but height and depth of a parenthesis.
 
@campa Ok.
I'll go ahead and ask a question. It's a simple enough question.
 
@FaheemMitha There are some related question but I haven't found anything describing exactly why it goes wrong. I think it's worth a question.
 
10:07 AM
@campa Ok. Thank you.
 
user image
3
 
@Skillmon Congratulations.
 
@PauloCereda Hans told me ducks were once popular in Dutch food. A really weird remark considering I was asking for clarification concerning MetaPost :D
 
@JairoA.delRio ducks are an interesting subject. :)
3
 
@PauloCereda As TeX (and Lua imho) are :)
 
10:14 AM
@JairoA.delRio quack :)
 
@campa Asked question.
 
@FaheemMitha I've managed to restrict the issue: the macro \opening executes among other things \@addrfield, and this types the addressee followed by a \\, which will cause the error if the addressee is empty. But there are still some details I'm disentangling...
 
@campa Are you planning to write an answer?
I was thinking of asking the author of KOMA-script to allow blank addresses.
Not sure it's worth the trouble, though.
 
@FaheemMitha I might, but there is this nasty thing called "work" which also requires some time :-) I won't be able to write one until the late afternoon. Maybe someone else will answer first
 
@campa This person being @DavidCarlisle :)
 
10:29 AM
@PauloCereda I was counting on that ;-)
 
@campa he needs teh rep points. :)
 
@campa Ok.
I didn't know you could ask TeX to produce an error stack. That's like a traceback?
 
@FaheemMitha no, it shows the surrounding lines in which the error was found
 
@PauloCereda Ok. The surrounding lines in the TeX source code?
 
@FaheemMitha yes
 
10:35 AM
@PauloCereda I see. Thank you for explaining.
 
@FaheemMitha NP, David cheats by reading code. :)
 
I'm not 100% on his explanation. He flagged toname. But isn't toaddress the culprit?
 
@PauloCereda didn't see this thread first:-)
@FaheemMitha I didn't flag anything I just showed you what tex reported. The name is probably the first line of the address.
@PauloCereda not really it is more like a stack trace
@PauloCereda no
@PauloCereda no I didn't look at the code just at the stack trace (context lines) of the error. \errorcontextlines controls how many levels of expansion to unwind in the error message not how many source lines are shown.
 
@DavidCarlisle Probably. But what about the other \\ later on?
 
@FaheemMitha Always stop at the first error. There is no "later on".
 
10:49 AM
@DavidCarlisle vvv
> TeX will show only the top and bottom pairs of context lines together with up to \errorcontextlines additional two-line items. (If anything has thereby been omitted, you'll also see '...'.)
 
@DavidCarlisle Oh.
 
@DavidCarlisle sorry, this does not sound like stacktrace
 
@PauloCereda well looking at it you see all the macros that were expanded to get from the source line to the eventual error, so literally you see the current input stack of macro replacement texts that are not completed. You do not see more lines of the original source
 
@DavidCarlisle okay, so blame the TeXbook text.
@FaheemMitha sorry, I stand corrected. ^^
 
@PauloCereda No problem.
 
10:58 AM
Mar 26 '12 at 19:37, by David Carlisle
@Canageek moral of the story: never read the documentation, bad things happen
 
@DavidCarlisle ooh
 
@PauloCereda Is \errorcontextlines mentioned in the TeXBook? What does it say?
 
@FaheemMitha as @PauloCereda says, it says this:
\ddanger If you use \TeX\ format packages designed by others, your
error messages may involve many inscrutable two-line levels of macro
context. By setting ^|\errorcontextlines||=0| at the beginning of your file,
you can reduce the amount of information that is reported;
\TeX\ will show only the top and bottom pairs of context lines
together with up to |\errorcontextlines| additional two-line items. \ (If
anything has thereby been omitted, you'll also see `|...|'.) \ Chances
are good that you can spot the source of an error even when most of a
 
@DavidCarlisle \oops
@DavidCarlisle thank you <3
 
latex sets it to -1
 
11:04 AM
@DavidCarlisle What does -1 do?
 
@FaheemMitha it shows as little internal detail as possible
 
@DavidCarlisle Oh, so not even the top and bottom pairs of context lines?
 
@FaheemMitha you always get the error message and the original source line but not the intermediate internal expansions. I forget now when it differs from 0 I think it is the handling of showing argument values, it is in any case the smallest error messages possible
 
@DavidCarlisle More context is generally useful. I'll keep it in mind in the future.
 
@FaheemMitha it is simpler for you to try than ask.
By default you get
! LaTeX Error: There's no line here to end.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...

l.5   \opening{}

? x
If you set it to 0 you get
! LaTeX Error: There's no line here to end.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...

...
l.5   \opening{}

?
so one extra level of ... so not that useful.
 
11:09 AM
Ok.
 
@DavidCarlisle backpropagation in a nutshell?
 
@PauloCereda we didn't want to have to admit quite what \latex@error does to format the error message (command names with so many spaces in the name tex does not log them) that is the extra ... in the errorcontextlines=0 case
 
@DavidCarlisle ooh so can we blame @UlrikeFischer?
 
@PauloCereda Alan, I think.
 
@DavidCarlisle ooh Turing :)
 
11:12 AM
@PauloCereda nope this one % \changes{v1.1a}{1994/05/16}{(ASAJ) Completely new error interface.}
 
@DavidCarlisle ooh
 
such a readable command name:
%    %<-------------------do not delete this space!------------------->%
\@err@                                                                 %
}}%
@PauloCereda the command starts \@err and ends at the %
 
@DavidCarlisle ooh 65 spaces
 
@FaheemMitha The code executed at \begin{letter} checks if the argument is empty: if it is not, it grabs everything up to the next \\ and uses that as toname, the rest is treated as toaddress. If the argument is empty then both are empty and the error occurs.
 
@campa So having a non-empty toname suffices?
What's that second \\ in the traceback?
 
12:04 PM
@FaheemMitha The box is typeset twice, hence the two errors. I've added an answer.
 
12:31 PM
@daleif Alright, I've (more or less) got it. The overfull \hbox is an artifact of not having declared three flashcards. It's not really worth fixing it, so I removed the related comment and un-deleted my answer.
 
1:00 PM
@campa Thank you. There are two errors?
 
@FaheemMitha When you compile your code you get the error twice
 
@campa Oh? I didn't notice that.
 
 
1 hour later…
yo'
2:09 PM
user image
3
 
2:33 PM
@yo' Maybe @DavidCarlisle could write the alltehthings package?
 
yo'
@samcarter_says_quack oh definitely :)
 
@samcarter_says_quack and blame me for the typo?
 
@UlrikeFischer yes (and sorry for the ping)
 
3:30 PM
@UlrikeFischer We are pretty sure we want \pdf_destination:nnnn without any 'content', right?
@UlrikeFischer Also, are you happy with \pdf_destination:nn having two rather different possible types of arguments?
 
3:43 PM
@JosephWright well for me in hyperref it is the right thing. And imho it is also more logical: a destination doesn't have "content".
 
@UlrikeFischer OK, altering the backend
 
@JosephWright I thought you needed the content there for one of the backends.
@JosephWright you mean the fit, fith, xyz etc and the scale factor?
 
@UlrikeFischer Not if we decide there is no content: I can construct an empty space at the backend level
@UlrikeFischer Yes
@UlrikeFischer I do wonder if we need \mode_leave_vertical:?
 
3:59 PM
Jul 24 '17 at 15:28, by Paulo Cereda
@samcarter you are mean <3
@JosephWright on all destination whatsits?
 
@JosephWright it works without it (I tested ...) and some of the hyperref code would error if it would be suddenly added.
 
@UlrikeFischer Ah
@UlrikeFischer That makes life a bit more interesting, I guess: I need to think a little
 
@JosephWright strictly speaking, the \__bitset_test_digits_end: macro isn't necessary and could as well be \exp_stop_f: directly (since #1 is \detokenized, there is no possibility to reduce stability this way).
 
@JosephWright this here is more or less the problem: it errors with the \leavevmode:
\documentclass{article}
\usepackage{hyperref}
\makeatletter
\Hy@WrapperDef\new@pdflink#1{%
  \ifhmode
    \@savsf\spacefactor
  \fi
  \Hy@SaveLastskip
  \Hy@VerboseAnchor{#1}%
  \Hy@pstringdef\Hy@pstringDest{\HyperDestNameFilter{#1}}%
  \leavevmode\Hy@DestName\Hy@pstringDest\@pdfview
  \Hy@RestoreLastskip
  \ifhmode
    \spacefactor\@savsf
  \fi
}
\makeatother
\begin{document}

aaa

\refstepcounter{section}

xxx

\end{document}
 
4:21 PM
@JosephWright well personnally I think that all this arguments (including the fitr + width +..) is of the same type and describe an instruction how to display the page. It is okay to do the fitr with a special command as it is a box, but I don't see a reason why zoom should be special.
 
4:50 PM
@PauloCereda ohh :)
 
5:07 PM
@UlrikeFischer youd have to put it first and drop the ifhmode tests but I'm not sure always doing \leavevmode is the right thing
\documentclass{article}
\usepackage{hyperref}
\makeatletter
\Hy@WrapperDef\new@pdflink#1{%
  \leavevmode
    \@savsf\spacefactor
  \Hy@SaveLastskip
  \Hy@VerboseAnchor{#1}%
  \Hy@pstringdef\Hy@pstringDest{\HyperDestNameFilter{#1}}%
  \Hy@DestName\Hy@pstringDest\@pdfview
  \Hy@RestoreLastskip
    \spacefactor\@savsf
}
\makeatother
\begin{document}

aaa

\refstepcounter{section}

xxx

\end{document}
@UlrikeFischer ^
 
@DavidCarlisle yes, but as you said: it is not clear if one wants to leave vmode for all the various locations where the hyperref code inserts destination. Also this is not a place where @JosephWright can inject the \leavevmode. The backend would rely on hyperref behaving.
 
5:39 PM
@UlrikeFischer OK, then the question is are we safe with \box_move_... and even more so with \tex_kern:D
@DavidCarlisle, @UlrikeFischer I do wish we could have an interface for \kern
 
@JosephWright probably not, do you have an example?
 
@JosephWright why don't we have an interface for it?
 
@JosephWright is it already implemented? I could run a test (but as long as it doesn't error and give a 0-size box it should be fine, it didn't work at all previously with pdftex, so nobody can complain that it changed ...)
 
@DavidCarlisle Not at the moment: I guess I should check how hyperref does stuff
@UlrikeFischer Yes
@Skillmon It's 'typesetting'
 
@JosephWright so is boxing up stuff.
@JosephWright also, what about packages written in expl3 that use code to typeset things? I never understood why 'typesetting' is not included in expl3.
 
5:52 PM
@JosephWright specials in vmode are usually wrong but leavevmode isn't necessarily the best way to avoid it \vbox{<special>\hbox{...}...} might want to be \vbox{\hbox{<special>...}...} rather than \vbox{\leavevmode<special>\hbox{...}...}
 
@DavidCarlisle Indeed
@Skillmon Er, yes: talk to Chris ;)
@Skillmon Well, it's complicated ...
 
@JosephWright oh no
 
@Skillmon At least in part as the typesetting end of things hasn't to-date been needed for 'kernel stuff'
 
@JosephWright but even without typesetting we should probably have basic allocation and kern (dimen) arithmetic to match l3skip
 
@JosephWright pdflatex works fine, but xelatex errors:
! You can't use `\lower' in vertical mode.
\box_move_down:nn #1#2->\tex_lower:D
                                     \__box_dim_eval:n {#1}#2
 
6:00 PM
hmm that isn't quite what I meant (as they are there..)
 
@DavidCarlisle I refer the gentleman to my previous answer
@UlrikeFischer Ah, that's what I was afraid of ... I'll think a bit more
5 mins ago, by Joseph Wright
@Skillmon Er, yes: talk to Chris ;)
 
@JosephWright can't you put it into a \hbox as I did?
 
@UlrikeFischer Sure, I was just aiming to avoid boxes that are not needed ... I'll think a bit
 
@JosephWright oh no
 
@UlrikeFischer Probably: need to decide at what level it lives
@UlrikeFischer I think you are right: I'll go with that :)
@UlrikeFischer Try now :)
 
6:38 PM
@JosephWright sorry had to prepare dinner, I will check now.
 
@UlrikeFischer oh no?
 
@PauloCereda Wiener Reisfleisch. No ducks involved ;-)
 
@UlrikeFischer phew :)
 
@UlrikeFischer there is always tomorrow
 
6:59 PM
@DavidCarlisle /quacks sadly
3
 
@JosephWright oh
@DavidCarlisle oh no
 
@JosephWright you won't feel a thing...
 
@JosephWright I get a missing number error with xelatex:
\__kernel_backend_literal:n #1->\__kernel_backend_literal:e {\exp_not:n {#1}}
#1<-pdf:dest (section.1)[@thispage/FitR @pdf_section.1_llx @pdf_200.75pt_lly @x
pos @ypos]

! Missing number, treated as zero.
<to be read again>
                   s
<argument> s
            ection.1
\__pdf_backend_destination_aux:nnnn ..._kern:D -#2
                                                  \scan_stop:
 
@UlrikeFischer Hmm, I must have mixed up the arguments
@UlrikeFischer Should now be fixed
 
@JosephWright no error, but the destination doesn't look right. it creates this:
[3 0 R/FitR 7 0 R 8 0 R 333.77 683.21]
the object 7 0 is fine, but 8 0 is null:
8 0 obj
null
endobj
 
7:05 PM
@UlrikeFischer Just dvipdfmx, right?
 
@JosephWright yes (I didn't test dvips yet, will do now)
 
@UlrikeFischer Fixed I think
@UlrikeFischer We will get there soon :)
 
@JosephWright latex has also the missing number error.
 
@UlrikeFischer Oh drat
 
@JosephWright dvips now: /D [5 0 R /FitR 133.768 683.215 333.768 883.215] all good ;-)
@JosephWright I'm not sure if everything is good. I get different values:
pdflatex /D [5 0 R /FitR 133.768 633.325 333.768 833.325]
xelatex     [3 0 R/FitR  133.77  433.33 333.77 633.33]
dvips   /D  [4 0 R /FitR 133.8   444.240021 333.72 644.28]
Why are the dvi backend by 200 down?
 
 
2 hours later…
9:18 PM
@JosephWright something is wrong if a destination has a depth, then it inserts space with xelatex and latex+dvips:
\documentclass{article}
\usepackage{l3pdf}
\begin{document}
abc

\ExplSyntaxOn
x\pdf_destination:nnnn {test2}{150bp}{100bp}{200bp}
\ExplSyntaxOff

\end{document}
 
@UlrikeFischer Drat
 
 
1 hour later…
10:32 PM
@barbarabeeton Thanks
 

« first day (3741 days earlier)      last day (31 days later) »