Ignore:
Timestamp:
Nov 21, 2017, 1:30:00 PM (5 years ago)
Author:
Thierry Delisle <tdelisle@…>
Branches:
aaron-thesis, arm-eh, 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, resolv-new, with_gc
Children:
9f10d1f2
Parents:
5f91d65
Message:

Ran ispell on the thesis

File:
1 edited

Legend:

Unmodified
Added
Removed
  • doc/proposals/concurrency/text/cforall.tex

    r5f91d65 r07c1e595  
    11% ======================================================================
    22% ======================================================================
    3 \chapter{Cforall Overview}
     3\chapter{\CFA Overview}
    44% ======================================================================
    55% ======================================================================
     
    1212\section{References}
    1313
    14 Like \CC, \CFA introduces rebindable references providing multiple dereferecing as an alternative to pointers. In regards to concurrency, the semantic difference between pointers and references are not particularly relevant, but since this document uses mostly references, here is a quick overview of the semantics:
     14Like \CC, \CFA introduces rebind-able references providing multiple dereferencing as an alternative to pointers. In regards to concurrency, the semantic difference between pointers and references are not particularly relevant, but since this document uses mostly references, here is a quick overview of the semantics:
    1515\begin{cfacode}
    1616int x, *p1 = &x, **p2 = &p1, ***p3 = &p2,
     
    2626sizeof(&ar[1]) == sizeof(int *);        //is true, i.e., the size of a reference
    2727\end{cfacode}
    28 The important take away from this code example is that references offer a handle to an object, much like pointers, but which is automatically dereferenced for convinience.
     28The important take away from this code example is that references offer a handle to an object, much like pointers, but which is automatically dereferenced for convenience.
    2929
    3030\section{Overloading}
     
    8282}
    8383int main() {
    84         S x = {10}, y = {100};          //implict calls: ?{}(x, 10), ?{}(y, 100)
     84        S x = {10}, y = {100};          //implicit calls: ?{}(x, 10), ?{}(y, 100)
    8585        ...                                                     //use x and y
    8686        ^x{};  ^y{};                            //explicit calls to de-initialize
    8787        x{20};  y{200};                         //explicit calls to reinitialize
    8888        ...                                                     //reuse x and y
    89 }                                                               //implict calls: ^?{}(y), ^?{}(x)
     89}                                                               //implicit calls: ^?{}(y), ^?{}(x)
    9090\end{cfacode}
    9191The language guarantees that every object and all their fields are constructed. Like \CC, construction of an object is automatically done on allocation and destruction of the object is done on deallocation. Allocation and deallocation can occur on the stack or on the heap.
Note: See TracChangeset for help on using the changeset viewer.