tags 365121 +patch
thanks

In standard C++, friend functions that are only declared inside a class
can only be found by argument-dependent lookup (and can only be defined
inline, though it's not a syntax error to fail to do so!)

The following patch fixes the compilation errors:

--- src/include/projdesc.h~     2004-05-10 01:40:55.000000000 +0100
+++ src/include/projdesc.h      2006-03-10 02:41:13.729466784 +0000
@@ -130,6 +130,10 @@
 
 class AttrDesc { public: const char* name; AttrType type; };
 
+class PrcsAttrs;
+bool attrs_equal(const PrcsAttrs*const& x, const PrcsAttrs*const& y);
+int attrs_hash(const PrcsAttrs*const& s, int M);
+
 class PrcsAttrs {
     friend class ProjectDescriptor;
     friend class FileEntry;
@@ -181,6 +185,12 @@
                                              bool is_working,
                                              FILE* pipe,
                                              ProjectReadData flags);
+PrBoolError setkeys_internal(const char* input_buffer0,
+                            int input_buffer_len0,
+                            ostream* os,
+                            MemorySegment* seg,
+                            FileEntry *fe,
+                            SetkeysAction action);
 
 class ProjectDescriptor {
 
--- src/include/vc.h~   2004-05-10 01:40:55.000000000 +0100
+++ src/include/vc.h    2006-03-10 02:41:53.920167517 +0000
@@ -135,6 +135,10 @@
  *     and checked in, the version's parent will be B.4, and the first
  *     MergeParent will be A.3.
  */
+
+class ProjectVersionData;
+ostream& operator<<(ostream& o, const ProjectVersionData* pvd);
+
 class ProjectVersionData : public RcsVersionData {
 public:
     ProjectVersionData(int index);
-- END --

As a temporary alternative, the g++ option "-ffriend-injection" may be
used instead of changing the code, but this option will probably be
removed in some later version.

Ben. 

-- 
Ben Hutchings
Q.  Which is the greater problem in the world today, ignorance or apathy?
A.  I don't know and I couldn't care less.

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to