Changeset 6aa84e0 for doc


Ignore:
Timestamp:
Sep 20, 2021, 11:46:19 AM (3 years ago)
Author:
Andrew Beach <ajbeach@…>
Branches:
ADT, ast-experimental, enum, forall-pointer-decay, master, pthread-emulation, qualifiedEnum
Children:
6cc87c0
Parents:
432bffe
Message:

Andrew MMath: Removed (updated one) the remaining \todo items.

Location:
doc/theses/andrew_beach_MMath
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • doc/theses/andrew_beach_MMath/existing.tex

    r432bffe r6aa84e0  
    4949asterisk (@*@) is replaced with a ampersand (@&@);
    5050this includes cv-qualifiers (\snake{const} and \snake{volatile})
    51 %\todo{Should I go into even more detail on cv-qualifiers.}
    5251and multiple levels of reference.
    5352
  • doc/theses/andrew_beach_MMath/features.tex

    r432bffe r6aa84e0  
    129129\section{Virtuals}
    130130\label{s:virtuals}
    131 %\todo{Maybe explain what "virtual" actually means.}
     131A common feature in many programming languages is a tool to pair code
     132(behaviour) with data.
     133In \CFA this is done with the virtual system,
     134which allow type information to be abstracted away, recovered and allow
     135operations to be performed on the abstract objects.
     136
    132137Virtual types and casts are not part of \CFA's EHM nor are they required for
    133138an EHM.
     
    488493Since it is so general, a more specific handler can be defined,
    489494overriding the default behaviour for the specific exception types.
    490 %\todo{Examples?}
     495
     496For example, consider an error reading a configuration file.
     497This is most likely a problem with the configuration file @config_error@,
     498but the function could have been passed the wrong file name @arg_error@.
     499In this case the function could raise one exception and then, if it is
     500unhandled, raise the other.
     501This is not usual behaviour for either exception so changing the
     502default handler will be done locally:
     503\begin{cfa}
     504{
     505        void defaultTerminationHandler(config_error &) {
     506                throw (arg_error){arg_vt};
     507        }
     508        throw (config_error){config_vt};
     509}
     510\end{cfa}
    491511
    492512\subsection{Resumption}
     
    551571the just handled exception came from, and continues executing after it,
    552572not after the try statement.
    553 %\todo{Examples?}
     573
     574For instance, a resumption used to send messages to the logger may not
     575need to be handled at all. Putting the following default handler
     576at the global scope can make handling the exception optional by default.
     577\begin{cfa}
     578void defaultResumptionHandler(log_message &) {
     579    // Nothing, it is fine not to handle logging.
     580}
     581// ... No change at raise sites. ...
     582throwResume (log_message){strlit_log, "Begin event processing."}
     583\end{cfa}
    554584
    555585\subsubsection{Resumption Marking}
  • doc/theses/andrew_beach_MMath/implement.tex

    r432bffe r6aa84e0  
    5050The problem is that a type ID may appear in multiple TUs that compose a
    5151program (see \autoref{ss:VirtualTable}), so the initial solution would seem
    52 to be make it external in each translation unit. Hovever, the type ID must
     52to be make it external in each translation unit. However, the type ID must
    5353have a declaration in (exactly) one of the TUs to create the storage.
    5454No other declaration related to the virtual type has this property, so doing
     
    167167\subsection{Virtual Table}
    168168\label{ss:VirtualTable}
    169 %\todo{Clarify virtual table type vs. virtual table instance.}
    170169Each virtual type has a virtual table type that stores its type ID and
    171170virtual members.
    172 Each virtual type instance is bound to a table instance that is filled with
    173 the values of virtual members.
    174 Both the layout of the fields and their value are decided by the rules given
     171An instance of a virtual type is bound to a virtual table instance,
     172which have the values of the virtual members.
     173Both the layout of the fields (in the virtual table type)
     174and their value (in the virtual table instance) are decided by the rules given
    175175below.
    176176
  • doc/theses/andrew_beach_MMath/intro.tex

    r432bffe r6aa84e0  
    4444\input{termhandle.pstex_t}
    4545\end{center}
    46 %\todo{What does the right half of termination.fig mean?}
     46\todo*{Can I make the new diagrams fit the old style?}
    4747
    4848Resumption exception handling searches the stack for a handler and then calls
  • doc/theses/andrew_beach_MMath/performance.tex

    r432bffe r6aa84e0  
    312312\CFA, \Cpp and Java.
    313313% To be exact, the Match All and Match None cases.
    314 %\todo{Not true in Python.}
    315 The most likely explanation is that, since exceptions
    316 are rarely considered to be the common case, the more optimized languages
    317 make that case expensive to improve other cases.
     314The most likely explination is that,
     315the generally faster languages have made ``common cases fast" at the expense
     316of the rarer cases. Since exceptions are considered rare, they are made
     317expensive to help speed up common actions, such as entering and leaving try
     318statements.
     319Python on the other hand, while generally slower than the other languages,
     320uses exceptions more and has not scarified their performance.
    318321In addition, languages with high-level representations have a much
    319322easier time scanning the stack as there is less to decode.
Note: See TracChangeset for help on using the changeset viewer.