[m-rev.] for review: fix samples/c_interface/cplusplus_calls_mercury

Ian MacLarty maclarty at cs.mu.OZ.AU
Tue Apr 19 14:03:32 AEST 2005


I'm not sure at all if this is the right fix, but the compiler passes a
bootcheck and all the tests with the following two lines in
runtime/mercury_types.h removed.

For review by anyone.

Estimated hours taken: 0.5
Branches: main and 0.12

Remove conflicting declarations of MR_Dictionary_Struct which were causing 
samples/c_interface/cplusplus_calls_mercury not to compile with the following 
error:

mgnuc --grade asm_fast.gc     -g   --      -DMR_MACHDEPS_ALPHA_REGS_H -DMR_MACHDEPS_MIPS_REGS_H -DMR_MACHDEPS_SPARC_REGS_H -DMR_MACHDEPS_I386_REGS_H -DMR_MACHDEPS_PA_REGS_H -DMR_MACHDEPS_RS6000_REGS_H -g -c cpp_main.cc
In file included from /home/jupiter/public/mercury-latest/i686-pc-linux-gnu/lib/mercury/inc/mercury_imp.h:76,
                 from cpp_main.cc:1:
/home/jupiter/public/mercury-latest/i686-pc-linux-gnu/lib/mercury/inc/mercury_typeclass_info.h:314: conflicting
   types for `typedef struct MR_Dictionary_Struct MR_Dictionary_Struct'
/home/jupiter/public/mercury-latest/i686-pc-linux-gnu/lib/mercury/inc/mercury_types.h:197: previous
   declaration as `struct MR_Dictionary_Struct'
gmake: *** [cpp_main.o] Error 1

runtime/mercury_types.h:
	Remove the two typedefs which were conflicting with the one
	in mercury_typeclass_info.h.

Index: runtime/mercury_types.h
===================================================================
RCS file: /home/mercury1/repository/mercury/runtime/mercury_types.h,v
retrieving revision 1.40
diff -u -r1.40 mercury_types.h
--- runtime/mercury_types.h	14 Dec 2004 01:07:25 -0000	1.40
+++ runtime/mercury_types.h	18 Apr 2005 07:24:29 -0000
@@ -194,8 +194,6 @@
 typedef const struct MR_Instance_Struct                 *MR_Instance;
 typedef       struct MR_DictId_Struct                   MR_DictIdStruct;
 typedef const struct MR_DictId_Struct                   *MR_DictId;
-typedef       struct MR_Dictionary_Struct               MR_DictionaryStruct;
-typedef const struct MR_Dictionary_Struct               *MR_Dictionary;
 
 typedef struct MR_TrailEntry_Struct             MR_TrailEntry;
 typedef struct MR_TrailEntry_Struct             *MR_TrailEntryPtr;
--------------------------------------------------------------------------
mercury-reviews mailing list
post:  mercury-reviews at cs.mu.oz.au
administrative address: owner-mercury-reviews at cs.mu.oz.au
unsubscribe: Address: mercury-reviews-request at cs.mu.oz.au Message: unsubscribe
subscribe:   Address: mercury-reviews-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------



More information about the reviews mailing list