Ignore:
Timestamp:
Feb 1, 2021, 4:23:55 PM (4 years ago)
Author:
Andrew Beach <ajbeach@…>
Branches:
ADT, arm-eh, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, master, new-ast-unique-expr, pthread-emulation, qualifiedEnum
Children:
85871478
Parents:
f99f5ba
Message:

That should fix the memory module. Simply removed all the special features.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • tests/smart-pointers.cfa

    rf99f5ba r8be729f  
    22
    33#include <memory.hfa>
    4 #include <stdlib.hfa>
     4#include <assert.h>
    55
    66void counter_test(void) {
     
    5353}
    5454
     55void declare_test(void) {
     56        counter_ptr(int) ptr_i0 = 3;
     57        counter_ptr(char) ptr_c0 = 'a';
     58        counter_ptr(float) ptr_f0 = 3.5f;
     59        counter_ptr(double) ptr_d0 = 3.5;
     60
     61        unique_ptr(int) ptr_i1 = 3;
     62        unique_ptr(char) ptr_c1 = 'a';
     63        unique_ptr(float) ptr_f1 = 3.5f;
     64        unique_ptr(double) ptr_d1 = 3.5;
     65}
     66
    5567int main(int argc, char * argv[]) {
    5668        counter_test();
    5769        unique_test();
    5870        pointer_equality();
     71
     72        printf("done\n");
    5973}
Note: See TracChangeset for help on using the changeset viewer.