C4275 compile warning

A

Angus

I am getting this error:

asn-buf.h(133) : warning C4275: non dll-interface class
'std::basic_streambuf<char,struct std::char_traits<char> >'
used as base for dll-interface class 'SNACC::AsnRvsBuf'
asn-buf.h(132) : see declaration of 'AsnRvsBuf'

The line causing the problem is:
class __declspec(dllexport) AsnRvsBuf : public std::streambuf

What is the problem and how do I resolve?
 
M

mlimber

Angus said:
I am getting this error:

asn-buf.h(133) : warning C4275: non dll-interface class
'std::basic_streambuf<char,struct std::char_traits<char> >'
used as base for dll-interface class 'SNACC::AsnRvsBuf'
asn-buf.h(132) : see declaration of 'AsnRvsBuf'

The line causing the problem is:
class __declspec(dllexport) AsnRvsBuf : public std::streambuf

What is the problem and how do I resolve?

Ask on a newsgroup dedicated to your platform. DLLs are
platform-specific and off-topic here (see
http://www.parashift.com/c++-faq-lite/how-to-post.html#faq-5.9).

Cheers! --M
 
N

Noah Roberts

Angus said:
I am getting this error:

asn-buf.h(133) : warning C4275: non dll-interface class
'std::basic_streambuf<char,struct std::char_traits<char> >'
used as base for dll-interface class 'SNACC::AsnRvsBuf'
asn-buf.h(132) : see declaration of 'AsnRvsBuf'

The line causing the problem is:
class __declspec(dllexport) AsnRvsBuf : public std::streambuf

What is the problem and how do I resolve?

There is no problem to resolve. Disable the warning. Visual Studio
often goes ape shit over template instantiations in DLL projects and
spews a bunch of bogus warnings like the above.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,432
Messages
2,571,680
Members
48,796
Latest member
Greg L.

Latest Threads

Top