Sophie

Sophie

distrib > Mageia > 4 > x86_64 > by-pkgid > ba6e5e1a033bd8535c43a771ce407926 > files > 46

lib64cxx-gtk-utils2.2-devel-2.2.3-2.mga4.x86_64.rpm

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.4"/>
<title>c++-gtk-utils: Compiling with clang++</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">c++-gtk-utils
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.4 -->
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li class="current"><a href="pages.html"><span>Related&#160;Pages</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li><a href="namespaces.html"><span>Namespaces</span></a></li>
      <li><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div class="header">
  <div class="headertitle">
<div class="title">Compiling with clang++ </div>  </div>
</div><!--header-->
<div class="contents">
<div class="textblock"><p>This library will compile successfully with clang &gt;= 3.2. Clang however has by default a significantly wider set of warnings enabled than does gcc. In particular, it will complain if a template class declared with the struct keyword is specialized using the class keyword, or vice versa.</p>
<p>This is a nuisance because a number of template structs/classes mandated by the C++11 standard are intended to be specialized where necessary, most notably <a class="el" href="classstd_1_1hash.html" title="A specialization of std::hash for Cgu::Callback::FunctorArg, Cgu::Callback::SafeFunctorArg, Cgu::GobjHandle, Cgu::GvarHandle, Cgu::IntrusivePtr, Cgu::SharedHandle, Cgu::SharedLockHandle, Cgu::SharedPtr and Cgu::SharedLockPtr so that such objects may be keys of unordered associative containers. ">std::hash</a>, and (unless the library is compiled with the --without-smart-ptr-comp option) this library does indeed specialize <a class="el" href="classstd_1_1hash.html" title="A specialization of std::hash for Cgu::Callback::FunctorArg, Cgu::Callback::SafeFunctorArg, Cgu::GobjHandle, Cgu::GvarHandle, Cgu::IntrusivePtr, Cgu::SharedHandle, Cgu::SharedLockHandle, Cgu::SharedPtr and Cgu::SharedLockPtr so that such objects may be keys of unordered associative containers. ">std::hash</a> for <a class="el" href="classCgu_1_1Callback_1_1FunctorArg.html" title="Functor class holding a Callback::CallbackArg object. ">Cgu::Callback::FunctorArg</a>, <a class="el" href="classCgu_1_1Callback_1_1SafeFunctorArg.html" title="Functor class holding a Callback::CallbackArg object, with thread-safe reference count. ">Cgu::Callback::SafeFunctorArg</a>, <a class="el" href="classCgu_1_1GobjHandle.html" title="This is a handle for managing the reference count of GObjects. ">Cgu::GobjHandle</a>, <a class="el" href="classCgu_1_1GvarHandle.html" title="This is a handle for managing the reference count of GVariant objects. ">Cgu::GvarHandle</a>, <a class="el" href="classCgu_1_1IntrusivePtr.html" title="This is a smart pointer for managing objects allocated on freestore which maintain their own referenc...">Cgu::IntrusivePtr</a>, <a class="el" href="classCgu_1_1SharedHandle.html" title="This is a generic class for managing the lifetime of objects allocated on freestore. ">Cgu::SharedHandle</a>, <a class="el" href="classCgu_1_1SharedLockHandle.html" title="This is a generic class for managing the lifetime of objects allocated on freestore, with a thread safe reference count.. ">Cgu::SharedLockHandle</a>, <a class="el" href="classCgu_1_1SharedPtr.html" title="This is a smart pointer for managing the lifetime of objects allocated on freestore. ">Cgu::SharedPtr</a> and <a class="el" href="classCgu_1_1SharedLockPtr.html" title="This is a smart pointer for managing the lifetime of objects allocated on freestore, with a thread safe reference count. ">Cgu::SharedLockPtr</a> so that objects of such classes may be keys of unordered associative containers. The standard does not specify whether the <a class="el" href="classstd_1_1hash.html" title="A specialization of std::hash for Cgu::Callback::FunctorArg, Cgu::Callback::SafeFunctorArg, Cgu::GobjHandle, Cgu::GvarHandle, Cgu::IntrusivePtr, Cgu::SharedHandle, Cgu::SharedLockHandle, Cgu::SharedPtr and Cgu::SharedLockPtr so that such objects may be keys of unordered associative containers. ">std::hash</a> template is to be declared as a struct or a class: it only requires that the specialization is to have certain public functions and typedefs. Either declaration is standard conforming and legitimate.</p>
<p>This library declares <a class="el" href="classstd_1_1hash.html" title="A specialization of std::hash for Cgu::Callback::FunctorArg, Cgu::Callback::SafeFunctorArg, Cgu::GobjHandle, Cgu::GvarHandle, Cgu::IntrusivePtr, Cgu::SharedHandle, Cgu::SharedLockHandle, Cgu::SharedPtr and Cgu::SharedLockPtr so that such objects may be keys of unordered associative containers. ">std::hash</a> specializations as structs, because that is the (non-mandatory) format provided for in ยง20.8.12 of the C++11 standard for the specializations required by the standard. The versions of libstdc++ which come with gcc &lt;= 4.7 do likewise. However the version of libstdc++ which comes with gcc-4.8 declares the <a class="el" href="classstd_1_1hash.html" title="A specialization of std::hash for Cgu::Callback::FunctorArg, Cgu::Callback::SafeFunctorArg, Cgu::GobjHandle, Cgu::GvarHandle, Cgu::IntrusivePtr, Cgu::SharedHandle, Cgu::SharedLockHandle, Cgu::SharedPtr and Cgu::SharedLockPtr so that such objects may be keys of unordered associative containers. ">std::hash</a> template as a class. This means that if clang is used with the version of libstdc++ which comes with gcc-4.8, by default warnings will be issued when the header files for the classes mentioned above are included in user code.</p>
<p>This can be avoided by compiling user code with clang with the -Wno-mismatched-tags compiler flag. </p>
</div></div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated on Mon Sep 16 2013 20:45:31 for c++-gtk-utils by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.4
</small></address>
</body>
</html>