Changeset 9509d67a for doc/theses/colby_parsons_MMAth/text/CFA_intro.tex
- Timestamp:
- Sep 11, 2023, 12:55:43 PM (13 months ago)
- Branches:
- master
- Children:
- c8ec58e
- Parents:
- 3ee8853
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
doc/theses/colby_parsons_MMAth/text/CFA_intro.tex
r3ee8853 r9509d67a 9 9 \CFA is a layer over C, is transpiled\footnote{Source to source translator.} to C, and is largely considered to be an extension of C. 10 10 Beyond C, it adds productivity features, extended libraries, an advanced type-system, and many control-flow/concurrency constructions. 11 However, \CFA stays true to the C programming style, with most code revolving around @struct@ 's and routines, and respects the same rules as C.11 However, \CFA stays true to the C programming style, with most code revolving around @struct@s and routines, and respects the same rules as C. 12 12 \CFA is not object oriented as it has no notion of @this@ (receiver) and no structures with methods, but supports some object oriented ideas including constructors, destructors, and limited nominal inheritance. 13 13 While \CFA is rich with interesting features, only the subset pertinent to this work is discussed here. … … 17 17 References in \CFA are a layer of syntactic sugar over pointers to reduce the number of syntactic ref/deref operations needed with pointer usage. 18 18 Pointers in \CFA differ from C and \CC in their use of @0p@ instead of C's @NULL@ or \CC's @nullptr@. 19 References can contain 0p in \CFA, which is the equivalent of a null reference. 19 20 Examples of references are shown in \VRef[Listing]{l:cfa_ref}. 20 21 … … 64 65 This feature is also implemented in Pascal~\cite{Pascal}. 65 66 It can exist as a stand-alone statement or wrap a routine body to expose aggregate fields. 67 If exposed fields share a name, the type system will attempt to disambiguate them based on type. 68 If the type system is unable to disambiguate the fields then the user must qualify those names to avoid a compilation error. 66 69 Examples of the @with@ statement are shown in \VRef[Listing]{l:cfa_with}. 67 70
Note: See TracChangeset
for help on using the changeset viewer.