- Timestamp:
- May 21, 2017, 11:38:21 PM (8 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:
- 4adbe45
- Parents:
- 917ab04
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
doc/user/user.tex
r917ab04 r0ed8759 11 11 %% Created On : Wed Apr 6 14:53:29 2016 12 12 %% Last Modified By : Peter A. Buhr 13 %% Last Modified On : Sun May 21 23: 16:45201714 %% Update Count : 18 1713 %% Last Modified On : Sun May 21 23:36:42 2017 14 %% Update Count : 1822 15 15 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 16 16 … … 4838 4838 In \CFA, there are ambiguous cases with dereference and operator identifiers, \eg ©int *?*?()©, where the string ©*?*?© can be interpreted as: 4839 4839 \begin{cfa} 4840 *?§\color{red}\textvisiblespace§*? 4841 *§\color{red}\textvisiblespace§?*? 4842 \end{cfa} 4843 By default, the first interpretation is selected, which does not yield a meaningful string in the language.4840 *?§\color{red}\textvisiblespace§*? §\C{// dereference operator, dereference operator}§ 4841 *§\color{red}\textvisiblespace§?*? §\C{// dereference, multiplication operator}§ 4842 \end{cfa} 4843 By default, the first interpretation is selected, which does not yield a meaningful parse. 4844 4844 Therefore, \CFA does a lexical look-ahead for the second case, and backtracks to return the leading unary operator and reparses the trailing operator identifier. 4845 4845 Otherwise a space is needed between the unary operator and operator identifier to disambiguate this common case. … … 4851 4851 *?()§\color{red}\textvisiblespace...§(...) ; 4852 4852 \end{cfa} 4853 requiring arbitrary whitespace look-ahead for the routine-call parameter 4853 requiring arbitrary whitespace look-ahead for the routine-call parameter-list to disambiguate. 4854 4854 However, the dereference operator \emph{must} have a parameter/argument to dereference ©*?(...)©. 4855 4855 Hence, always interpreting the string ©*?()© as \lstinline[showspaces=true]@* ?()@ does not preclude any meaningful program. … … 4860 4860 i?++§\color{red}\textvisiblespace...§(...); 4861 4861 \end{cfa} 4862 requiring arbitrary whitespace look-ahead for the routine-call parameterlist, even though that interpretation is an incorrect expression (juxtaposed identifiers).4862 requiring arbitrary whitespace look-ahead for the operator parameter-list, even though that interpretation is an incorrect expression (juxtaposed identifiers). 4863 4863 Therefore, it is necessary to disambiguate these cases with a space: 4864 4864 \begin{cfa}
Note: See TracChangeset
for help on using the changeset viewer.