- Timestamp:
- May 21, 2020, 5:06:35 PM (4 years ago)
- Branches:
- ADT, arm-eh, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, master, new-ast, new-ast-unique-expr, pthread-emulation, qualifiedEnum
- Children:
- 0e4df2e, 7119daa
- Parents:
- 6f121b8 (diff), 66ba544 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - Location:
- tests
- Files:
-
- 2 added
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
tests/errors/.expect/completeType.txt
r6f121b8 r99fea48 132 132 ?=?: pointer to function 133 133 ... with parameters 134 reference to instance of type _10 4_0_T (not function type)135 instance of type _10 4_0_T (not function type)134 reference to instance of type _108_0_T (not function type) 135 instance of type _108_0_T (not function type) 136 136 ... returning 137 _retval__operator_assign: instance of type _10 4_0_T (not function type)137 _retval__operator_assign: instance of type _108_0_T (not function type) 138 138 ... with attributes: 139 139 Attribute with name: unused -
tests/exceptions/conditional.cfa
r6f121b8 r99fea48 56 56 57 57 try { 58 throw &exc;58 throw exc; 59 59 } catch (num_error * error ; 3 == error->virtual_table->code( error )) { 60 60 caught_num_error(3, error); … … 64 64 65 65 try { 66 throwResume &exc;66 throwResume exc; 67 67 } catchResume (num_error * error ; 3 == error->virtual_table->code( error )) { 68 68 caught_num_error(3, error); -
tests/exceptions/data-except.cfa
r6f121b8 r99fea48 28 28 29 29 try { 30 throw &except;30 throw except; 31 31 } catch (paired * exc) { 32 32 printf("%s(%d, %d)\n", paired_msg(exc), exc->first, exc->second); … … 37 37 38 38 try { 39 throwResume &except;39 throwResume except; 40 40 } catchResume (paired * exc) { 41 41 printf("%s(%d, %d)\n", paired_msg(exc), exc->first, exc->second); -
tests/exceptions/finally.cfa
r6f121b8 r99fea48 12 12 try { 13 13 printf("termination throw\n"); 14 throw &exc;14 throw exc; 15 15 } finally { 16 16 loud_exit a = "termination inner finally"; … … 28 28 try { 29 29 printf("resumption throw\n"); 30 throwResume &exc;30 throwResume exc; 31 31 } finally { 32 32 loud_exit a = "resumption inner finally"; -
tests/exceptions/interact.cfa
r6f121b8 r99fea48 10 10 // Resume falls back to terminate. 11 11 try { 12 throwResume &(star){};12 throwResume (star){}; 13 13 } catch (star *) { 14 14 printf("caught as termination\n"); … … 17 17 try { 18 18 loud_region a = "try block with resume throw"; 19 throwResume &(star){};19 throwResume (star){}; 20 20 } catch (star *) { 21 21 printf("caught as termination\n"); … … 29 29 try { 30 30 try { 31 throw &(star){};31 throw (star){}; 32 32 } catchResume (star *) { 33 33 printf("resume catch on terminate\n"); … … 43 43 try { 44 44 try { 45 throwResume &(star){};45 throwResume (star){}; 46 46 } catch (star *) { 47 47 printf("terminate catch on resume\n"); … … 58 58 try { 59 59 try { 60 throw &(star){};60 throw (star){}; 61 61 } catchResume (star *) { 62 62 printf("inner resume catch (error)\n"); … … 64 64 } catch (star * error) { 65 65 printf("termination catch, will resume\n"); 66 throwResume error;66 throwResume *error; 67 67 } 68 68 } catchResume (star *) { … … 75 75 try { 76 76 try { 77 throwResume &(star){};77 throwResume (star){}; 78 78 } catch (star *) { 79 79 printf("inner termination catch\n"); … … 81 81 } catchResume (star * error) { 82 82 printf("resumption catch, will terminate\n"); 83 throw error;83 throw *error; 84 84 } 85 85 } catch (star *) { … … 94 94 try { 95 95 printf("throwing resume moon\n"); 96 throwResume &(moon){};96 throwResume (moon){}; 97 97 } catch (star *) { 98 98 printf("termination catch\n"); 99 99 } 100 100 printf("throwing resume star\n"); 101 throwResume &(star){};101 throwResume (star){}; 102 102 } catchResume (star *) { 103 103 printf("resumption star catch\n"); … … 105 105 } catchResume (moon *) { 106 106 printf("resumption moon catch, will terminate\n"); 107 throw &(star){};107 throw (star){}; 108 108 } 109 109 } catchResume (star *) { -
tests/exceptions/resume.cfa
r6f121b8 r99fea48 14 14 loud_exit a = "simple try clause"; 15 15 printf("simple throw\n"); 16 throwResume &(zen){};16 throwResume (zen){}; 17 17 printf("end of try clause\n"); 18 18 } catchResume (zen * error) { … … 24 24 // Throw catch-all test. 25 25 try { 26 throwResume &(zen){};26 throwResume (zen){}; 27 27 } catchResume (exception_t * error) { 28 28 printf("catch-all\n"); … … 33 33 try { 34 34 printf("throwing child exception\n"); 35 throwResume &(moment_of){};35 throwResume (moment_of){}; 36 36 } catchResume (zen *) { 37 37 printf("inner parent match\n"); … … 44 44 try { 45 45 try { 46 throwResume &(yin){};46 throwResume (yin){}; 47 47 } catchResume (zen *) { 48 48 printf("caught yin as zen\n"); … … 60 60 loud_exit a = "rethrow inner try"; 61 61 printf("rethrow inner try\n"); 62 throwResume &(zen){};62 throwResume (zen){}; 63 63 } catchResume (zen *) { 64 64 loud_exit a = "rethrowing catch clause"; … … 75 75 try { 76 76 try { 77 throwResume &(yin){};77 throwResume (yin){}; 78 78 } catchResume (yin *) { 79 79 printf("caught yin, will throw yang\n"); 80 throwResume &(yang){};80 throwResume (yang){}; 81 81 } catchResume (yang *) { 82 82 printf("caught exception from same try\n"); … … 91 91 try { 92 92 printf("throwing first exception\n"); 93 throwResume &(yin){};93 throwResume (yin){}; 94 94 } catchResume (yin *) { 95 95 printf("caught first exception\n"); 96 96 try { 97 97 printf("throwing second exception\n"); 98 throwResume &(yang){};98 throwResume (yang){}; 99 99 } catchResume (yang *) { 100 100 printf("caught second exception\n"); … … 112 112 try { 113 113 try { 114 throwResume &(zen){};115 throwResume &(zen){};114 throwResume (zen){}; 115 throwResume (zen){}; 116 116 } catchResume (zen *) { 117 117 printf("inner catch\n"); 118 118 } 119 throwResume &(zen){};119 throwResume (zen){}; 120 120 } catchResume (zen *) { 121 121 printf("outer catch\n"); -
tests/exceptions/terminate.cfa
r6f121b8 r99fea48 14 14 loud_exit a = "simple try clause"; 15 15 printf("simple throw\n"); 16 throw &(zen){};16 throw (zen){}; 17 17 printf("end of try clause\n"); 18 18 } catch (zen * error) { … … 24 24 // Throw catch-all test. 25 25 try { 26 throw &(zen){};26 throw (zen){}; 27 27 } catch (exception_t * error) { 28 28 printf("catch-all\n"); … … 33 33 try { 34 34 printf("throwing child exception\n"); 35 throw &(moment_of){};35 throw (moment_of){}; 36 36 } catch (zen *) { 37 37 printf("inner parent match\n"); … … 44 44 try { 45 45 try { 46 throw &(yin){};46 throw (yin){}; 47 47 } catch (zen *) { 48 48 printf("caught yin as zen\n"); … … 60 60 loud_exit a = "rethrow inner try"; 61 61 printf("rethrow inner try\n"); 62 throw &(zen){};62 throw (zen){}; 63 63 } catch (zen *) { 64 64 loud_exit a = "rethrowing catch clause"; … … 75 75 try { 76 76 try { 77 throw &(yin){};77 throw (yin){}; 78 78 } catch (yin *) { 79 79 printf("caught yin, will throw yang\n"); 80 throw &(yang){};80 throw (yang){}; 81 81 } catch (yang *) { 82 82 printf("caught exception from same try\n"); … … 91 91 try { 92 92 printf("throwing first exception\n"); 93 throw &(yin){};93 throw (yin){}; 94 94 } catch (yin *) { 95 95 printf("caught first exception\n"); 96 96 try { 97 97 printf("throwing second exception\n"); 98 throw &(yang){};98 throw (yang){}; 99 99 } catch (yang *) { 100 100 printf("caught second exception\n"); … … 112 112 try { 113 113 try { 114 throw &(zen){};115 throw &(zen){};114 throw (zen){}; 115 throw (zen){}; 116 116 } catch (zen *) { 117 117 printf("inner catch\n"); 118 118 } 119 throw &(zen){};119 throw (zen){}; 120 120 } catch (zen *) { 121 121 printf("outer catch\n");
Note: See TracChangeset
for help on using the changeset viewer.