ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* Error message wrong when \component is used
@ 2010-10-12 12:59 Robin.Kirkham
  2010-10-12 13:03 ` Steffen Wolfrum
  0 siblings, 1 reply; 3+ messages in thread
From: Robin.Kirkham @ 2010-10-12 12:59 UTC (permalink / raw)
  To: ntg-context

Dear all,

I find that when there is an error (at least, "undefined control sequence") in a file included using \component, the supposedly erroneous lines printed are from the calling file, not the file where the error actually is (although the line number seems correct, and there are clues where the error really lies).

Minimal example ...

file1.tex:
\startproduct file1
\starttext
Bla bla bla.
Bla bla bla.
Bla bla bla.
\component file2
\stoptext
\stopproduct

file2.tex:
\startcomponent file2
Bleh bleh bleh.
Bleh bleh bleh.
Bleh bleh bleh.
\zorg
\stopcomponent

When I run "context file1" I get an error:
... 
ConTeXt  ver: 2010.10.12 01:03 MKIV  fmt: 2010.10.12  int: english/english
...
systems         : begin file file1 at line 1
systems         : begin file file2 at line 6
(file2.tex
! Undefined control sequence.

system          > error on line 5 in file file1.tex: Undefined control sequence ...

1     \startproduct file1
2     \starttext
3     Bla bla bla.
4     Bla bla bla.
5 >>  Bla bla bla.
6     \component file2
7     \stoptext
8     \stopproduct

l.5 \zorg

If I replace \component with \input in file1.tex, all works correctly and the error ("\zorg") is correctly pointed out.

Best,

Robin
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Error message wrong when \component is used
  2010-10-12 12:59 Error message wrong when \component is used Robin.Kirkham
@ 2010-10-12 13:03 ` Steffen Wolfrum
  0 siblings, 0 replies; 3+ messages in thread
From: Steffen Wolfrum @ 2010-10-12 13:03 UTC (permalink / raw)
  To: mailing list for ConTeXt users



Why do you use start-/stoptext inside start-/stopproduct?

Steffen



Am 12.10.2010 um 14:59 schrieb <Robin.Kirkham@csiro.au> <Robin.Kirkham@csiro.au>:

> file1.tex:
> \startproduct file1
> \starttext
> Bla bla bla.
> Bla bla bla.
> Bla bla bla.
> \component file2
> \stoptext
> \stopproduct

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Error message wrong when \component is used
       [not found] <mailman.640.1286895475.4222.ntg-context@ntg.nl>
@ 2010-10-12 23:14 ` Robin.Kirkham
  0 siblings, 0 replies; 3+ messages in thread
From: Robin.Kirkham @ 2010-10-12 23:14 UTC (permalink / raw)
  To: ntg-context

From: Steffen Wolfrum <context@st.estfiles.de>

> Date: 13 October 2010 12:03:37 AM AEDT
> To: mailing list for ConTeXt users <ntg-context@ntg.nl>
> Subject: Re: [NTG-context] Error message wrong when \component is used
> Reply-To: mailing list for ConTeXt users <ntg-context@ntg.nl>
> 
> Why do you use start-/stoptext inside start-/stopproduct?
> 
> Steffen

Hi Steffen,

By mistake!  8-)

However, if I take out the start-/stoptext, it makes no difference, Context is still printing text from the wrong file in the error message:

file1.tex:
\startproduct file1
Bla bla bla.
Bla bla bla.
Bla bla bla.
\component file2
\stopproduct

file2.tex:
\startcomponent file2
Bleh bleh bleh.
Bleh bleh bleh.
Bleh bleh bleh.
\zorg
\stopcomponent

and I get:

...
systems         : begin file file1 at line 1
systems         : begin file file2 at line 5
(file2.tex
! Undefined control sequence.

system          > error on line 5 in file file1.tex: Undefined control sequence ...

1     \startproduct file1
2     Bla bla bla.
3     Bla bla bla.
4     Bla bla bla.
5 >>  \component file2
6     \stopproduct

l.5 \zorg
         
? q
OK, entering \batchmode
MTXrun | fatal error: return code: 1%

Robin

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-10-12 23:14 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-10-12 12:59 Error message wrong when \component is used Robin.Kirkham
2010-10-12 13:03 ` Steffen Wolfrum
     [not found] <mailman.640.1286895475.4222.ntg-context@ntg.nl>
2010-10-12 23:14 ` Robin.Kirkham

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).