next up previous contents index search.gif
Next: 2. Constants Up: 1. Pascal Tokens Previous: 1.6 Labels

1.7 Character strings

A character string (or string for short) is a sequence of zero or more characters from the ASCII character set, enclosed by single quotes, and on 1 line of the program source. A character set with nothing between the quotes ('') is an empty string.

Character strings

\begin{syntdiag}\setlength {\sdmidskip}{.5em}\sffamily\sloppy \synt{character\ s...
...}[b]\( \synt{quoted\ string} \\ \synt{control\ string} \)\end{rep}\end{syntdiag}

\begin{syntdiag}\setlength {\sdmidskip}{.5em}\sffamily\sloppy \synt{quoted\ stri...
...it*{'}
\begin{rep}[b]\synt{string\ character} \\ \end{rep}\lit*{'}\end{syntdiag}

\begin{syntdiag}\setlength {\sdmidskip}{.5em}\sffamily\sloppy \synt{string\ character}
\(
\tok{ Any character except ' or CR} \\
\lit*{''}
\)\end{syntdiag}

\begin{syntdiag}\setlength {\sdmidskip}{.5em}\sffamily\sloppy \synt{control\ str...
...gin{rep}[b]
\lit*{\char93 } \synt{unsigned\ integer} \\
\end{rep}\end{syntdiag}


root
1999-06-10