Changeset 421a287
- Timestamp:
- Jun 2, 2017, 4:59:26 PM (6 years ago)
- Branches:
- ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, deferred_resn, demangler, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, with_gc
- Children:
- a4683611
- Parents:
- 83e9bd3
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
doc/user/user.tex
r83e9bd3 r421a287 11 11 %% Created On : Wed Apr 6 14:53:29 2016 12 12 %% Last Modified By : Peter A. Buhr 13 %% Last Modified On : Thu Jun 1 22:46:09201714 %% Update Count : 212 613 %% Last Modified On : Fri Jun 2 10:07:51 2017 14 %% Update Count : 2128 15 15 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 16 16 … … 185 185 While the \CFA I/O looks similar to the \Index*[C++]{\CC{}} output style, there are important differences, such as automatic spacing between variables as in \Index*{Python} (see~\VRef{s:IOLibrary}). 186 186 187 This document is a user manual for the \CFA programming language, targeted at \CFA programmers. 187 This document is a programmer reference-manual for the \CFA programming language. 188 The manual covers the core features of the language and runtime-system, with simple examples illustrating syntax and semantics of each feature. 189 The manual does not teach programming, i.e., how to combine the new constructs to build complex programs. 190 A reader should already have an intermediate knowledge of control flow, data structures, and concurrency issues to understand the ideas presented as well as some experience programming in C/\CC. 188 191 Implementers may refer to the \CFA Programming Language Specification for details about the language syntax and semantics. 189 In its current state, this document covers the intended core features of the language.190 192 Changes to the syntax and additional features are expected to be included in later revisions. 191 193 … … 5273 5275 \begin{cfa}[aboveskip=0pt,belowskip=0pt] 5274 5276 // C unsafe allocation 5275 extern "C" { void * mallac( size_t size ); }§\indexc{memset}§ 5276 extern "C" { void * calloc( size_t dim, size_t size ); }§\indexc{calloc}§ 5277 extern "C" { void * realloc( void * ptr, size_t size ); }§\indexc{realloc}§ 5278 extern "C" { void * memalign( size_t align, size_t size ); }§\indexc{memalign}§ 5279 extern "C" { int posix_memalign( void ** ptr, size_t align, size_t size ); }§\indexc{posix_memalign}§ 5277 extern "C" { 5278 void * mallac( size_t size );§\indexc{memset}§ 5279 void * calloc( size_t dim, size_t size );§\indexc{calloc}§ 5280 void * realloc( void * ptr, size_t size );§\indexc{realloc}§ 5281 void * memalign( size_t align, size_t size );§\indexc{memalign}§ 5282 int posix_memalign( void ** ptr, size_t align, size_t size );§\indexc{posix_memalign}§ 5283 } 5280 5284 5281 5285 // §\CFA§ safe equivalents, i.e., implicit size specification … … 5302 5306 5303 5307 // C unsafe initialization/copy 5304 extern "C" { void * memset( void * dest, int c, size_t size ); } 5305 extern "C" { void * memcpy( void * dest, const void * src, size_t size ); } 5308 extern "C" { 5309 void * memset( void * dest, int c, size_t size ); 5310 void * memcpy( void * dest, const void * src, size_t size ); 5311 } 5306 5312 5307 5313 // §\CFA§ safe initialization/copy
Note: See TracChangeset
for help on using the changeset viewer.