7 Commits
6.0.0 ... 6.0.1

Author SHA1 Message Date
Andrew Johnson
e0367a2dd7 Update release notes and release date. 2016-09-14 17:01:51 -05:00
Andrew Johnson
1e0f1119e2 testTypeCast: mangle values to be printable
print  (u)int8 as integer instead of character

(cherry picked from commit da8ba56dd1)
2016-09-14 16:43:53 -05:00
Andrew Johnson
6d6314a924 #include <algorithm> required for MSVS 2015
(cherry picked from commit 4555f69733)
2016-09-14 16:33:37 -05:00
Dave Hickin
e0b881d036 Correction to documentation for 6.0.1 2016-09-14 11:25:30 +01:00
Dave Hickin
d24ff6c3d2 Update documentation for 6.0.1 2016-09-13 22:44:11 +01:00
Dave Hickin
ef17aac046 Update release notes for 6.0.1 2016-09-13 22:33:28 +01:00
Dave Hickin
83b63a9138 Fix for MinGW
Fixes #42
2016-09-07 15:14:17 +01:00
6 changed files with 65 additions and 19 deletions

View File

@@ -1,3 +1,29 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!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/html;" />
<meta name="keywords" content="EPICS, EPICSv4" />
<title>EPICS V4 pvData C++ Release Notes</title>
<link rel="stylesheet" type="text/css" href="../../base.css" />
<link rel="stylesheet" type="text/css" href="../../epicsv4.css" />
</head>
<body>
<h1>Release 6.0.1</h1>
<p>The changes since release 6.0.0 are:</p>
<ul>
<li>Fix "Problem building pvDataCPP for win32-x86-mingw" (issue #42)</li>
<li>In src/misc/bitSet.cpp #include <algorithm> required for MSVS 2015</li>
<li>In testApp/misc/testTypeCast.cpp print (u)int8 values as integers</li>
<li>Minor documentation updates</li>
</ul>
<h1>Release 6.0.0</h1> <h1>Release 6.0.0</h1>
<p>The main changes since release 5.0.4 are:</p> <p>The main changes since release 5.0.4 are:</p>
@@ -211,8 +237,8 @@ it was necessary to have code like:</p>
<p>A new template getField method has been added to Structure</p> <p>A new template getField method has been added to Structure</p>
<p>template<typename FT > <p>template&lt;typename FT-&gt;
std::tr1::shared_ptr&lt; const FT > getField(std::string const &amp;fieldName) const </p> std::tr1::shared_ptr&lt; const FT-&gt; getField(std::string const &amp;fieldName) const </p>
<p>Can be used, for example, as follows:</p> <p>Can be used, for example, as follows:</p>
@@ -313,3 +339,7 @@ This is prototype and is subject to debate.</p>
<h1>Release 3.0.2</h1> <h1>Release 3.0.2</h1>
<p>This was the starting point for RELEASE_NOTES</p> <p>This was the starting point for RELEASE_NOTES</p>
</body>
</html>

View File

@@ -1,3 +1,13 @@
Release 6.0.1
=============
The changes since release 6.0.0 are:
* Fix "Problem building pvDataCPP for win32-x86-mingw" (issue #42)
* In src/misc/bitSet.cpp #include <algorithm> required for MSVS 2015
* In testApp/misc/testTypeCast.cpp print (u)int8 values as integers
* Minor documentation updates
Release 6.0.0 Release 6.0.0
============= =============

View File

@@ -36,7 +36,7 @@
<div class="head"> <div class="head">
<h1>EPICS pvDataCPP</h1> <h1>EPICS pvDataCPP</h1>
<h2 class="nocount">Release 6.0.0 - 2016.08.01</h2> <h2 class="nocount">Release 6.0.1 - 2016-09-14</h2>
<dl> <dl>
<dt>Editors:</dt> <dt>Editors:</dt>
@@ -45,10 +45,6 @@
<dd>Matej Sekoranja, CosyLab</dd> <dd>Matej Sekoranja, CosyLab</dd>
<dd>David Hickin, Diamond Light Source</dd> <dd>David Hickin, Diamond Light Source</dd>
</dl> </dl>
<p class="copyright">This product is made available subject to acceptance of the <a
href="http://epics-pvdata.sourceforge.net/LICENSE.html">EPICS open source
license.</a></p>
<hr /> <hr />
</div> </div>
@@ -66,7 +62,7 @@ V4 control system programming environment:<br />
<h2 class="nocount">Status of this Document</h2> <h2 class="nocount">Status of this Document</h2>
<p>This is the 01-August-2016 version for the 6.0.0 release of the <p>This is the 14-September-2016 version for the 6.0.1 release of the
C++ implementation of pvData. C++ implementation of pvData.
</p> </p>

View File

@@ -10,6 +10,7 @@
#include <stdio.h> #include <stdio.h>
#include <iostream> #include <iostream>
#include <stdexcept> #include <stdexcept>
#include <algorithm>
#include <epicsMutex.h> #include <epicsMutex.h>

View File

@@ -10,7 +10,9 @@
// gently nudge the compiler to inline our wrappers // gently nudge the compiler to inline our wrappers
// Warning: Only use this when the template body is *small*. // Warning: Only use this when the template body is *small*.
// You have been warned! // You have been warned!
#if defined(__GNUC__) && __GNUC__>=3 #if defined(__MINGW32__)
# define FORCE_INLINE inline
#elif defined(__GNUC__) && __GNUC__>=3
# define FORCE_INLINE __attribute__((always_inline)) inline # define FORCE_INLINE __attribute__((always_inline)) inline
#elif defined(_MSC_VER) #elif defined(_MSC_VER)
# define FORCE_INLINE __forceinline # define FORCE_INLINE __forceinline

View File

@@ -29,6 +29,13 @@
using std::string; using std::string;
namespace { namespace {
// Mangle value to be printable as per print_convolute<>
template<typename T>
inline
typename epics::pvData::detail::print_convolute<T>::return_t
print(T v) {
return epics::pvData::detail::print_convolute<T>::op(v);
}
template<typename T> template<typename T>
struct testequal { struct testequal {
@@ -54,24 +61,24 @@ namespace {
//actual = ::epics::pvData::detail::cast_helper<TO,FROM>::op(inp); //actual = ::epics::pvData::detail::cast_helper<TO,FROM>::op(inp);
} catch(std::runtime_error& e) { } catch(std::runtime_error& e) {
msg<<"Failed to cast " msg<<"Failed to cast "
<<inp<<" ("<<typeid(FROM).name()<<") -> " <<print(inp)<<" ("<<typeid(FROM).name()<<") -> "
<<expect<<" ("<<typeid(TO).name()<<")\n Error: " <<print(expect)<<" ("<<typeid(TO).name()<<")\n Error: "
<<typeid(e).name()<<"("<<e.what()<<")"; <<typeid(e).name()<<"("<<e.what()<<")";
testFail("%s", msg.str().c_str()); testFail("%s", msg.str().c_str());
return; return;
} }
if(!testequal<TO>::op(actual, expect)) { if(!testequal<TO>::op(actual, expect)) {
msg<<"Failed cast gives unexpected value " msg<<"Failed cast gives unexpected value "
<<inp<<" ("<<typeid(FROM).name()<<") -> " <<print(inp)<<" ("<<typeid(FROM).name()<<") -> "
<<expect<<" ("<<typeid(TO).name()<<") yields: " <<print(expect)<<" ("<<typeid(TO).name()<<") yields: "
<<actual; <<print(actual);
testFail("%s", msg.str().c_str()); testFail("%s", msg.str().c_str());
return; return;
} }
msg<<"cast " msg<<"cast "
<<inp<<" ("<<typeid(FROM).name()<<") -> " <<print(inp)<<" ("<<typeid(FROM).name()<<") -> "
<<expect<<" ("<<typeid(TO).name()<<") yields: " <<print(expect)<<" ("<<typeid(TO).name()<<") yields: "
<<actual; <<print(actual);
testPass("%s", msg.str().c_str()); testPass("%s", msg.str().c_str());
return; return;
} }
@@ -86,14 +93,14 @@ namespace {
try { try {
actual = ::epics::pvData::castUnsafe<TO,FROM>(inp); actual = ::epics::pvData::castUnsafe<TO,FROM>(inp);
msg<<"Failed to generate expected error " msg<<"Failed to generate expected error "
<<inp<<" ("<<typeid(FROM).name()<<") -> (" <<print(inp)<<" ("<<typeid(FROM).name()<<") -> ("
<<typeid(TO).name()<<") yields: " <<typeid(TO).name()<<") yields: "
<<actual; <<actual;
testFail("%s", msg.str().c_str()); testFail("%s", msg.str().c_str());
return; return;
} catch(std::runtime_error& e) { } catch(std::runtime_error& e) {
msg<<"Got expected error " msg<<"Got expected error "
<<inp<<" ("<<typeid(FROM).name()<<") -> (" <<print(inp)<<" ("<<typeid(FROM).name()<<") -> ("
<<typeid(TO).name()<<") fails with: " <<typeid(TO).name()<<") fails with: "
<<e.what(); <<e.what();
testPass("%s", msg.str().c_str()); testPass("%s", msg.str().c_str());