Ignore:
Timestamp:
Apr 7, 2016, 5:35:36 PM (6 years ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
aaron-thesis, arm-eh, cleanup-dtors, ctor, deferred_resn, demangler, gc_noraii, jacob/cs343-translation, jenkins-sandbox, master, memory, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, resolv-new, string, with_gc
Children:
224e52f, 630a82a
Parents:
53ba273
Message:

fix library includes from < to ", and generalize rational IO to use iostream from fstream

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/libcfa/rational.c

    r53ba273 r3d9b5da  
    1111// Created On       : Wed Apr  6 17:54:28 2016
    1212// Last Modified By : Peter A. Buhr
    13 // Last Modified On : Wed Apr  6 21:52:16 2016
    14 // Update Count     : 7
     13// Last Modified On : Thu Apr  7 17:28:03 2016
     14// Update Count     : 12
    1515//
    1616
    1717#include "rational"
    18 #include <fstream>
    19 #include <stdlib>
     18#include "fstream"
     19#include "stdlib"
    2020
    2121extern "C" {
     
    188188} // narrow
    189189
    190 ifstream * ?|?( ifstream *is, Rational *r ) {
     190forall( dtype istype | istream( istype ) )
     191istype * ?|?( istype *is, Rational *r ) {
    191192        long int t;
    192193    is | &(r->numerator) | &(r->denominator);
     
    197198} // ?|?
    198199
    199 ofstream * ?|?( ofstream *os, Rational r ) {
     200forall( dtype ostype | ostream( ostype ) )
     201ostype * ?|?( ostype *os, Rational r ) {
    200202    return os | r.numerator | '/' | r.denominator;
    201203} // ?|?
Note: See TracChangeset for help on using the changeset viewer.