writeProcComments is now member of Function, at it has an ostream based overload, also added gmock framework to dependencies

This commit is contained in:
Artur K
2012-03-13 00:16:09 +01:00
parent bc395da6ab
commit d39449124a
40 changed files with 3660 additions and 72 deletions

51
tests/prev_base/FIBOL.b Normal file
View File

@@ -0,0 +1,51 @@
/*
* Input file : ./tests/inputs/FIBOL.EXE
* File type : EXE
*/
#include "dcc.h"
int proc_1 (int arg0)
/* Takes 2 bytes of parameters.
* High-level language prologue code.
* C calling convention.
*/
{
int loc1; /* si */
int loc2; /* ax */
loc1 = arg0;
if (loc1 > 2) {
loc2 = (proc_1 ((loc1 - 1)) + proc_1 ((loc1 + 0xfffe)));
}
else {
loc2 = 1;
}
return (loc2);
}
void main ()
/* Takes no parameters.
* High-level language prologue code.
* Contains instructions not normally used by compilers.
*/
{
int loc1;
int loc2;
int loc3;
int loc4;
printf ("Input number of iterations: ");
scanf ("%d", &loc1, );
loc3 = 1;
while ((loc3 <= loc1)) {
printf ("Input number: ");
scanf ("%d", &loc2, );
printf ("fibonacci(%d) = %u\n", loc2, proc_1 (loc2));
loc3 = (loc3 + 1);
} /* end of while */
exit (0);
}