Changeset fd54fef for tests/bugs


Ignore:
Timestamp:
Jan 19, 2021, 8:44:29 PM (9 months ago)
Author:
Michael Brooks <mlbrooks@…>
Branches:
arm-eh, jacob/cs343-translation, master, new-ast-unique-expr
Children:
dafbde8
Parents:
2f47ea4
Message:

Converting the project to use the new syntax for otype, dtype and ttytpe.

Changed prelude (gen), libcfa and test suite to use it. Added a simple deprecation rule of the old syntax to the parser; we might wish to support both syntaxes "officially," like with an extra CLI switch, but this measure should serve as a simple reminder for our team to try the new syntax.

Location:
tests/bugs
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • tests/bugs/10.cfa

    r2f47ea4 rfd54fef  
    22// https://cforall.uwaterloo.ca/trac/ticket/10
    33
    4 forall(otype T)
     4forall(T)
    55struct result {
    66      union {
  • tests/bugs/104.cfa

    r2f47ea4 rfd54fef  
    44[ float, float ] modf_( float x );
    55
    6 forall(otype T | { [T, T] modf_(T); })
     6forall(T | { [T, T] modf_(T); })
    77void modf(T);
    88
  • tests/bugs/194.cfa

    r2f47ea4 rfd54fef  
    22// https://cforall.uwaterloo.ca/trac/ticket/194
    33
    4 forall( dtype T | sized(T) ) T * foo( void ) {
     4forall( T & | sized(T) ) T * foo( void ) {
    55      printf( "foo1\n" );
    66        return (T *)0;
    77}
    8 forall( dtype T | sized(T) ) T & foo( void ) {
     8forall( T & | sized(T) ) T & foo( void ) {
    99        printf( "foo2\n" );
    1010        return (T &)*(T *)0;
  • tests/bugs/196.cfa

    r2f47ea4 rfd54fef  
    22// https://cforall.uwaterloo.ca/trac/ticket/196
    33
    4 forall(dtype T)
     4forall(T &)
    55struct link;
    66
    7 forall(dtype T)
     7forall(T &)
    88struct link {
    99        link(T) * next;
     
    1212// -----
    1313
    14 forall(dtype T)
     14forall(T &)
    1515struct foo;
    1616
    17 forall(dtype U)
     17forall(U &)
    1818struct bar {
    1919        foo(U) * data;
    2020};
    2121
    22 forall(dtype T)
     22forall(T &)
    2323struct foo {};
    2424
  • tests/bugs/203-2.cfa

    r2f47ea4 rfd54fef  
    11// Trac ticket: https://cforall.uwaterloo.ca/trac/ticket/203
    22
    3 forall(dtype A)
     3forall(A &)
    44struct empty {
    55        // Nothing.
    66};
    77
    8 forall(dtype C)
     8forall(C &)
    99struct wrap_e {
    1010        empty(C) field;
  • tests/bugs/203-7.cfa

    r2f47ea4 rfd54fef  
    11// Trac ticket: https://cforall.uwaterloo.ca/trac/ticket/203
    22
    3 forall(dtype A)
     3forall(A &)
    44struct empty {
    55        // Nothing.
    66};
    77
    8 forall(dtype C)
     8forall(C &)
    99struct wrap_e {
    1010        empty(C) field;
  • tests/bugs/203-9.cfa

    r2f47ea4 rfd54fef  
    11// Trac ticket: https://cforall.uwaterloo.ca/trac/ticket/203
    22
    3 forall(dtype A)
     3forall(A &)
    44struct empty {
    55        // Nothing.
    66};
    77
    8 forall(dtype C)
     8forall(C &)
    99struct wrap_e {
    1010        empty(C) field;
  • tests/bugs/7.cfa

    r2f47ea4 rfd54fef  
    88
    99// (Bug 1 unresolved as of this test.)
    10 forall(otype T)
     10forall(T)
    1111struct stack_node;
    1212
    13 forall(otype T)
     13forall(T)
    1414struct stack_node {
    1515    stack_node(T) * next;
     
    1717};
    1818
    19 forall(otype T)
     19forall(T)
    2020struct stack {
    2121    stack_node(T) * head;
    2222};
    2323
    24 trait stack_errors(otype T) {
     24trait stack_errors(T) {
    2525    T emptyStackHandler (stack(T) * this);
    2626};
    2727
    28 forall(otype T | stack_errors(T))
     28forall(T | stack_errors(T))
    2929T pop (stack(T) * this) {
    3030    return (T){};
Note: See TracChangeset for help on using the changeset viewer.