source: src/examples/abstype.c@ 2bae7307

ADT aaron-thesis arm-eh ast-experimental cleanup-dtors ctor deferred_resn demangler enum forall-pointer-decay gc_noraii jacob/cs343-translation jenkins-sandbox memory new-ast new-ast-unique-expr new-env no_list persistent-indexer pthread-emulation qualifiedEnum resolv-new string with_gc
Last change on this file since 2bae7307 was 843054c2, checked in by Peter A. Buhr <pabuhr@…>, 10 years ago

licencing: seventh groups of files

  • Property mode set to 100644
File size: 348 bytes
Line 
1// "cfa-cpp -nx Abstype.c"
2
3type T | { T x( T ); };
4
5T y( T t ) {
6 T t_instance;
7 return x( t );
8}
9
10forall(type T) lvalue T *?( T* );
11int ?++( int *);
12int ?=?( int*, int );
13forall(dtype DT) DT* ?=?( DT **, DT* );
14
15type U = int*;
16
17U x( U u ) {
18 U u_instance = u;
19 (*u)++;
20 return u;
21}
22
23int *break_abstraction( U u ) {
24 return u;
25}
Note: See TracBrowser for help on using the repository browser.