On 07/30/2017 07:13 PM, Henning Hraban Ramm wrote: > [...] > But I’d like to show a lot of similar examples to explain several options. > Therefore, if I’d like to simplify my code, but this doesn’t work: > > \def\CodeExample#1{% > \startbuffer[zB] > #1 > \stopbuffer > \typebuffer[zB] > \getbuffer[zB] > } > > \CodeExample{\framed[frame=off,leftframe=on,rulethickness=1em,framecolor=blue]{Klotz > am Bein}} > > Compilation just stops, maybe some infinite loop?
This is what I get from your sample above. > Simpler: > > \def\CodeExample#1{% > \startTEX > #1 > \stopTEX > #1 > } > > Stops with the error: Without or without definitions, there should be no expansion inside \starttyping...\stoptyping. Even with some expansion, I get an infinite loop: \starttext \setuptyping[TEX][escape=yes] \def\CodeExample#1{% \startTEX /BTEX #1/ETEX \stopTEX #1 } \CodeExample{\framed[frame=off,leftframe=on,rulethickness=1em,framecolor=blue]{Klotz am Bein}} \stoptext Pablo -- http://www.ousia.tk ___________________________________________________________________________________ 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://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___________________________________________________________________________________