Ignore:
Timestamp:
Apr 15, 2016, 12:03:11 PM (9 years ago)
Author:
Thierry Delisle <tdelisle@…>
Branches:
ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, ctor, deferred_resn, demangler, enum, forall-pointer-decay, gc_noraii, jacob/cs343-translation, jenkins-sandbox, master, memory, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, with_gc
Children:
29ad0ac
Parents:
c5833e8 (diff), 37f0da8 (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.
Message:

Merge branch 'master' into gc_noraii

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/examples/prolog.c

    rc5833e8 r0f9e4403  
    1010// Created On       : Wed May 27 17:56:53 2015
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Wed May 27 18:25:52 2015
    13 // Update Count     : 1
     12// Last Modified On : Tue Mar  8 22:09:39 2016
     13// Update Count     : 5
    1414//
    1515
    16 extern "C" { extern int printf( const char *fmt, ... ); }
     16#include <fstream>
    1717
    18 void printResult( int x ) { printf( "int\n" ); }
    19 void printResult( double x ) { printf( "double\n" ); }
    20 void printResult( char * x ) { printf( "char*\n" ); }
     18void printResult( int x ) { sout | "int" | endl; }
     19void printResult( double x ) { sout | "double" | endl; }
     20void printResult( char * x ) { sout | "char*" | endl; }
    2121
    2222void is_arithmetic( int x ) {}
     
    2525void is_integer( int x ) {}
    2626
    27 context ArithmeticType( type T ) {
     27trait ArithmeticType( otype T ) {
    2828        void is_arithmetic( T );
    2929};
    3030
    31 context IntegralType( type T | ArithmeticType( T ) ) {
     31trait IntegralType( otype T | ArithmeticType( T ) ) {
    3232        void is_integer( T );
    3333};
    3434
    35 forall( type T | IntegralType( T ) | { void printResult( T ); } )
     35forall( otype T | IntegralType( T ) | { void printResult( T ); } )
    3636void hornclause( T param ) {
    3737        printResult( param );
Note: See TracChangeset for help on using the changeset viewer.