File: printf.cc

package info (click to toggle)
icmake 13.05.01-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 7,132 kB
  • sloc: cpp: 11,595; fortran: 883; makefile: 853; sh: 546; pascal: 342
file content (16 lines) | stat: -rw-r--r-- 367 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
//#define XERR
#include "builtin.ih"

// prints the arguments of a printf call.
// 
// The arguments are: the number of arguments [2], and then the 
// remaining argument in the order in which they must be printed
//  ([3], [4], etc)

void Builtin::printf()
{
    d_reg = d_stack[2];

    insert(cout, 3, 3 + d_reg.value());
    xerr("returns: " << d_reg.value());
}