Changeset 53ba273 for doc/refrat
- Timestamp:
- Apr 6, 2016, 10:08:32 PM (9 years ago)
- Branches:
- ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, ctor, deferred_resn, demangler, enum, forall-pointer-decay, gc_noraii, jacob/cs343-translation, jenkins-sandbox, master, memory, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, string, with_gc
- Children:
- 3d9b5da, 78885b5
- Parents:
- 3cfe27f
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
doc/refrat/refrat.tex
r3cfe27f r53ba273 1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -*- Mode: Latex -*- %%%%%%%%%%%%%%%%%%%%%%%%%%%% 2 %% 3 %% Cforall Version 1.0.0 Copyright (C) 2016 University of Waterloo 4 %% 5 %% The contents of this file are covered under the licence agreement in the 6 %% file "LICENCE" distributed with Cforall. 7 %% 8 %% refrat.tex -- 9 %% 10 %% Author : Peter A. Buhr 11 %% Created On : Wed Apr 6 14:52:25 2016 12 %% Last Modified By : Peter A. Buhr 13 %% Last Modified On : Wed Apr 6 21:57:27 2016 14 %% Update Count : 2 15 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 16 1 17 % requires tex packages: texlive-base texlive-latex-base tex-common texlive-humanities texlive-latex-extra texlive-fonts-recommended 2 18 … … 5 21 6 22 % Latex packages used in the document. 7 8 23 \usepackage{fullpage,times} 9 24 \usepackage{xspace} … … 23 38 % Names used in the document. 24 39 25 \newcommand{\CFA}{C$\ forall$\xspace} % set language symbolic name40 \newcommand{\CFA}{C$\mathbf\forall$\xspace} % set language symbolic name 26 41 \newcommand{\CFL}{Cforall\xspace} % set language text name 27 42 \newcommand{\CC}{C\kern-.1em\hbox{+\kern-.25em+}\xspace} % CC symbolic name … … 151 166 % CFA based on ANSI C 152 167 \lstdefinelanguage{CFA}[ANSI]{C}% 153 {morekeywords={asm,_Alignas,_Alignof,_At,_Atomic,_Bool,catch,catchResume,choose,_Complex,trait,disable,dtype,enable, 154 fallthru,finally,forall,ftype,_Generic,_Imaginary,inline,lvalue,_Noreturn,otype,restrict,_Static_assert, 155 _Thread_local,throw,throwResume,try,}, 168 {morekeywords={_Alignas,_Alignof,__alignof,__alignof__,asm,__asm,__asm__,_At,_Atomic,__attribute,__attribute__,auto, 169 _Bool,catch,catchResume,choose,_Complex,__complex,__complex__,__const,__const__,disable,dtype,enable,__extension__, 170 fallthru,finally,forall,ftype,_Generic,_Imaginary,inline,__label__,lvalue,_Noreturn,otype,restrict,_Static_assert, 171 _Thread_local,throw,throwResume,trait,try,typeof,__typeof,__typeof__,}, 156 172 }% 157 173 … … 163 179 xleftmargin=\parindent, 164 180 escapechar=@, 181 mathescape=true, 165 182 keepspaces=true, 166 183 showstringspaces=false, 167 184 showlines=true, 185 aboveskip=6pt, 186 belowskip=4pt, 168 187 }% 169 188 … … 171 190 % replace/adjust listings characters that look bad in sanserif 172 191 \lst@CCPutMacro 173 \lst@ProcessOther{"2D}{\lst@ttfamily{-{}}{{\ttfamily\upshape -}}} % replace minus 192 \lst@ProcessOther{"22}{\lst@ttfamily{"}{\raisebox{0.3ex}{\ttfamily\upshape "}}} % replace double quote 193 \lst@ProcessOther{"27}{\lst@ttfamily{'}{\raisebox{0.3ex}{\ttfamily\upshape '\hspace*{-2pt}}}} % replace single quote 194 \lst@ProcessOther{"2D}{\lst@ttfamily{-}{\ttfamily\upshape -}} % replace minus 174 195 \lst@ProcessOther{"3C}{\lst@ttfamily{<}{\texttt{<}}} % replace less than 175 196 \lst@ProcessOther{"3E}{\lst@ttfamily{<}{\texttt{>}}} % replace greater than 176 197 \lst@ProcessOther{"5E}{\raisebox{0.4ex}{$\scriptstyle\land\,$}} % replace circumflex 177 \lst@ProcessLetter{"5F}{\lst@ttfamily{\char95}{{\makebox[1.2ex][c]{\rule{1ex}{0.1ex}}}}} % replace underscore 198 \lst@ProcessOther{"5F}{\lst@ttfamily{\char95}{{\makebox[1.2ex][c]{\rule{1ex}{0.1ex}}}}} % replace underscore 199 \lst@ProcessOther{"60}{\lst@ttfamily{`}{\raisebox{0.3ex}{\ttfamily\upshape \hspace*{-2pt}`}}} % replace backquote 178 200 \lst@ProcessOther{"7E}{\raisebox{0.3ex}{$\scriptstyle\sim\,$}} % replace tilde 179 201 %\lst@ProcessOther{"7E}{\raisebox{-.4ex}[1ex][0pt]{\textasciitilde}} % lower tilde … … 3843 3865 ``\lstinline$Safe_pointer$ acts like a pointer to \lstinline$int$''. 3844 3866 \begin{lstlisting} 3845 trait ptr_to( type P | pointer( P ), otype T ) {@\impl{ptr_to}@@\use{pointer}@3867 trait ptr_to( otype P | pointer( P ), otype T ) {@\impl{ptr_to}@@\use{pointer}@ 3846 3868 lvalue T *?( P ); 3847 3869 lvalue T ?[?]( P, long int ); 3848 3870 }; 3849 trait ptr_to_const( type P | pointer( P ), otype T ) {@\impl{ptr_to_const}@3871 trait ptr_to_const( otype P | pointer( P ), otype T ) {@\impl{ptr_to_const}@ 3850 3872 const lvalue T *?( P ); 3851 3873 const lvalue T ?[?]( P, long int );@\use{pointer}@ 3852 3874 }; 3853 trait ptr_to_volatile( type P | pointer( P ), otype T ) }@\impl{ptr_to_volatile}@3875 trait ptr_to_volatile( otype P | pointer( P ), otype T ) }@\impl{ptr_to_volatile}@ 3854 3876 volatile lvalue T *?( P ); 3855 3877 volatile lvalue T ?[?]( P, long int );@\use{pointer}@ 3856 3878 }; 3857 trait ptr_to_const_volatile( type P | pointer( P ), otype T ) }@\impl{ptr_to_const_volatile}@3879 trait ptr_to_const_volatile( otype P | pointer( P ), otype T ) }@\impl{ptr_to_const_volatile}@ 3858 3880 const volatile lvalue T *?( P );@\use{pointer}@ 3859 3881 const volatile lvalue T ?[?]( P, long int ); … … 3865 3887 ``\lstinline$ptr_to$'' specifications. 3866 3888 \begin{lstlisting} 3867 trait m_l_ptr_to( type P | m_l_pointer( P ),@\use{m_l_pointer}@@\impl{m_l_ptr_to}@ otype T | ptr_to( P, T )@\use{ptr_to}@ {3889 trait m_l_ptr_to( otype P | m_l_pointer( P ),@\use{m_l_pointer}@@\impl{m_l_ptr_to}@ otype T | ptr_to( P, T )@\use{ptr_to}@ { 3868 3890 P ?=?( P *, T * ); 3869 3891 T * ?=?( T **, P ); 3870 3892 }; 3871 trait m_l_ptr_to_const( type P | m_l_pointer( P ),@\use{m_l_pointer}@@\impl{m_l_ptr_to_const}@ otype T | ptr_to_const( P, T )@\use{ptr_to_const}@) {3893 trait m_l_ptr_to_const( otype P | m_l_pointer( P ),@\use{m_l_pointer}@@\impl{m_l_ptr_to_const}@ otype T | ptr_to_const( P, T )@\use{ptr_to_const}@) { 3872 3894 P ?=?( P *, const T * ); 3873 3895 const T * ?=?( const T **, P ); 3874 3896 }; 3875 trait m_l_ptr_to_volatile( type P | m_l_pointer( P ),@\use{m_l_pointer}@@\impl{m_l_ptr_to_volatile}@ otype T | ptr_to_volatile( P, T )) {@\use{ptr_to_volatile}@3897 trait m_l_ptr_to_volatile( otype P | m_l_pointer( P ),@\use{m_l_pointer}@@\impl{m_l_ptr_to_volatile}@ otype T | ptr_to_volatile( P, T )) {@\use{ptr_to_volatile}@ 3876 3898 P ?=?( P *, volatile T * ); 3877 3899 volatile T * ?=?( volatile T **, P ); 3878 3900 }; 3879 trait m_l_ptr_to_const_volatile( type P | ptr_to_const_volatile( P ),@\use{ptr_to_const_volatile}@@\impl{m_l_ptr_to_const_volatile}@3880 type T | m_l_ptr_to_volatile( P, T ) | m_l_ptr_to_const( P )) {@\use{m_l_ptr_to_const}@@\use{m_l_ptr_to_volatile}@3901 trait m_l_ptr_to_const_volatile( otype P | ptr_to_const_volatile( P ),@\use{ptr_to_const_volatile}@@\impl{m_l_ptr_to_const_volatile}@ 3902 otype T | m_l_ptr_to_volatile( P, T ) | m_l_ptr_to_const( P )) {@\use{m_l_ptr_to_const}@@\use{m_l_ptr_to_volatile}@ 3881 3903 P ?=?( P *, const volatile T * ); 3882 3904 const volatile T * ?=?( const volatile T **, P );
Note: See TracChangeset
for help on using the changeset viewer.