From: wolf Date: Mon, 15 Apr 2002 10:21:50 +0000 (+0000) Subject: Fix thinko with the first line of a program. X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6fe35abdb1e614f2a168404cf25a607b0a2f692e;p=dealii-svn.git Fix thinko with the first line of a program. git-svn-id: https://svn.dealii.org/trunk@5654 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/doc/tutorial/chapter-2.step-by-step/program2html b/deal.II/doc/tutorial/chapter-2.step-by-step/program2html index 7d80541ba4..75c80af247 100644 --- a/deal.II/doc/tutorial/chapter-2.step-by-step/program2html +++ b/deal.II/doc/tutorial/chapter-2.step-by-step/program2html @@ -18,7 +18,7 @@ $state = $comment_mode; print "

\n"; -while (<>) { +do { # substitute special characters s/&/&/g; s/) { { print " $_"; } -} +} while (<>); if ($state == $program_mode) { print "\n"; diff --git a/deal.II/doc/tutorial/chapter-2.step-by-step/program2plain b/deal.II/doc/tutorial/chapter-2.step-by-step/program2plain index 18e34b3d2f..2187b4d953 100644 --- a/deal.II/doc/tutorial/chapter-2.step-by-step/program2plain +++ b/deal.II/doc/tutorial/chapter-2.step-by-step/program2plain @@ -20,17 +20,17 @@ print <) { +do { # ignore comment lines - next if m!^\s*//!; - - # substitute special characters - s/&/&/g; - s//>/g; - s/\t/ /g; - - print " $_"; -} + if ( ! m!^\s*//! ) { + # substitute special characters + s/&/&/g; + s//>/g; + s/\t/ /g; + + print " $_"; + } +} while (<>); print "\n

\n\n";