473,386 Members | 1,752 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

C3767 error

JW
I received this error while compiling OSE 6.0 with MSVC7.1
(it compiles with MSVC7.0).

otcbitset.cc
.../include\OTC\collctn\strgactn.hh(45) : error
C3767: 'otclib_hash' matching function is not accessible
could be the friend function
at '../include\OTC\misc\hash.hh(54)' : 'otclib_hash' [may
be found via argument-dependent lookup]
or the friend function
at '../include\OTC\misc\hash.hh
(64)' : 'otclib_hash' [may be found via argument-
dependent lookup]
.../include\OTC\collctn\strgactn.hh(55) : error
C3767: 'otclib_hash' matching function is not accessible
could be the friend function
at '../include\OTC\misc\hash.hh(54)' : 'otclib_hash' [may
be found via argument-dependent lookup]
or the friend function
at '../include\OTC\misc\hash.hh
(64)' : 'otclib_hash' [may be found via argument-
dependent lookup]
The info in the MSDN help wasn't clear to me.

Here are the two files causing the problem.

strgactn.hh

template<>
class OSE_EXPORT OTC_HashActions<char*>
{
public:
static int hash(char* const& s)
{ return otclib_hash(s); }
};

template<>
class OSE_EXPORT OTC_HashActions<const char*>
{
public:
static int hash(const char* const& s)
{ return otclib_hash(s); }
};
hash.hh

class OSE_EXPORT OTC_Hash
{
public:

static int hash(char const* theString);

friend inline int otclib_hash(char const* theString)
{ return OTC_Hash::hash
(theString); }

static int hash(char const* theString, u_int
theLength);

friend inline int otclib_hash(char const* theString,
u_int theLength)
{ return OTC_Hash::hash
(theString,theLength); }

Anyone know how to fix it?

Thanks.
Nov 16 '05 #1
1 1602
JW
I got it.

Had to declare the friend function header inside the class
and implement it outside the class. I'm not sure if
that's the correct way to do it, but it works.
Nov 16 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: AIM | last post by:
Error in msvc in building inheritance.obj to build hello.pyd Hello, I am trying to build the boost 1.31.0 sample extension hello.cpp. I can not compile the file inheritance.cpp because the two...
13
by: deko | last post by:
I use this convention frequently: Exit_Here: Exit Sub HandleErr: Select Case Err.Number Case 3163 Resume Next Case 3376 Resume Next
4
by: Adriano Coser | last post by:
I'm getting the following error: error C3767: PictureSource - candidate function(s) not accessible when accessing a public member function of a managed class, either from managed or unmanaged...
3
by: Steve Jaworski | last post by:
Using VS2005Beta 2 I have VC++/CLI class defined in a Class Library DLL as: #foo.h namespace foo { public ref class Convert { public: static Obj^ ToObj(UnmanagedObj* uObj);
1
by: Antonio Carvalho | last post by:
I am getting this compler error in similar situations as described in previous posts to this site, however in my case the solution that is proposed is of no use. In my case, the managed C++...
7
by: p | last post by:
WE had a Crystal 8 WebApp using vs 2002 which we upgraded to VS2003. I also have Crystal 9 pro on my development machine. The web app runs fine on my dev machine but am having problems deploying....
2
by: Iwanow | last post by:
Hello! I have a single class without any inheritance over there, and I get that error on its constructor which is an empty function: LabelProcessor::LabelProcessor() { } The full error...
2
hyperpau
by: hyperpau | last post by:
Before anything else, I am not a very technical expert when it comes to VBA coding. I learned most of what I know by the excellent Access/VBA forum from bytes.com (formerly thescripts.com). Ergo, I...
0
hyperpau
by: hyperpau | last post by:
Before anything else, I am not a very technical expert when it comes to VBA coding. I learned most of what I know by the excellent Access/VBA forum from bytes.com (formerly thescripts.com). Ergo, I...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.