https://github.com/root-project/root
Raw File
Tip revision: dc23f9fcef6b528a41995f8ce10463d5330581e6 authored by Fons Rademakers on 27 October 2012, 21:18:24 UTC
tag patch release v5-34-03.
Tip revision: dc23f9f
t980.cxx
/* -*- C++ -*- */
/*************************************************************************
 * Copyright(c) 1995~2005  Masaharu Goto (root-cint@cern.ch)
 *
 * For the licensing terms see the file COPYING
 *
 ************************************************************************/

#if defined(interp) && defined(makecint)
#pragma include "test.dll"
#else
#include "t980.h"
#endif

#include <cstdio>
#include <cstring>

using namespace std;

int main(int, char**)
{
   A b;
   b = A("A part") + " of a whole";
   A a = A("A part") + " of a whole";
   printf("%s. %s.\n", a.val(), b.val());

   f(a, "A part of a whole");
   f("A part of a whole", a);

   if (!strcmp(a, "A part of a whole")) {
      printf("true\n");
   }
   else {
      printf("false\n");
   }
   if (!strcmp(a, "a part of a whole")) {
      printf("true\n");
   }
   else {
      printf("false\n");
   }

   if (!strcmp(a.val(), "A part of a whole")) {
      printf("true\n");
   }
   else {
      printf("false\n");
   }
   if (!strcmp(a.val(), "a part of a whole")) {
      printf("true\n");
   }
   else {
      printf("false\n");
   }
   return 0;
}

back to top