[Bug c++/53611] class with hidden visibility cause function returns pointer to class also be hidden

kirbyzhou@sogou-inc.com gcc-bugzilla@gcc.gnu.org
Sat Jun 9 09:43:00 GMT 2012


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53611

--- Comment #3 from Kirby Zhou <kirbyzhou@sogou-inc.com> 2012-06-09 09:43:09 UTC ---
If "myopen" returns "__cook", I will agree with you. But "myopen" returns
"__cook *", just a pointer.
I do not think it is reasonable to hide "myopen".
It is a usual method to hide the implementation detail of cook_t, but exports 
some free function to operate with cook_t*, such as "FILE *".


(In reply to comment #2)
> I think this is expected behavior as if someone defines a "__cook" in the
> executable which links to the shared library, it will be considered a different
> type.



More information about the Gcc-bugs mailing list