fix several warnings spotted by GCC-4.9.2

as usual, the compiler was right in most cases
Several typedefs are really just leftovers from copy-n-paste
This commit is contained in:
Fischlurch 2015-08-15 18:24:35 +02:00
parent 32f1773288
commit 03e87d4d33
9 changed files with 12 additions and 15 deletions

View file

@ -804,8 +804,6 @@ namespace func{
typename _Clo<SIG,ARG>::Type
closure (SIG& f, Tuple<ARG>& args)
{
typedef typename _Fun<SIG>::Ret Ret;
typedef typename _Sig<Ret,ARG>::Type Signature;
typedef typename _Clo<SIG,ARG>::Type Closure;
return Closure (f,args);
}

View file

@ -248,7 +248,6 @@ namespace session {
ScopePath
commonPrefix (ScopePath const& path1, ScopePath const& path2)
{
typedef std::vector<Scope>::iterator VIter;
ScopePath prefix (ScopePath::INVALID);
uint len = std::min (path1.length(), path2.length());
for (uint pos = 0; pos<len; ++pos)

View file

@ -252,7 +252,7 @@ namespace test {
{
PseudoRandom gen(distinction_);
for (uint i=0; i<BUFFSIZ; ++i)
if (data_[i] != (gen() % CHAR_MAX))
if (data_[i] != char(gen() % CHAR_MAX))
return false;
return true;
}
@ -262,7 +262,7 @@ namespace test {
{
PseudoRandom gen(distinction_);
for (uint i=0; i<BUFFSIZ; ++i)
data_[i] = (gen() % CHAR_MAX);
data_[i] = char(gen() % CHAR_MAX);
}

View file

@ -244,8 +244,10 @@ namespace test {
CHECK (!isSameObject (path2,path3));
CHECK (!isSameObject (path1,path3));
Scope parent = path3.moveUp();
CHECK (path1 == path2);
Scope parent = path3.moveUp(); // mutation
CHECK (parent == path2.getLeaf().getParent());
CHECK (path1 == path2); // the others are not affected
CHECK (path2 != path3);
CHECK (path1 != path3);

View file

@ -114,7 +114,7 @@ namespace test {
CHECK (fork3 == focus.getObject());
RFork fork31 = sess->attach(
asset::Struct::retrieve (Query<asset::????> ("id(fork31)"))); ////TODO broken: we don't use a dedicated Fork asset anymore. It's just an EntryID<Fork>
asset::Struct::retrieve (Query<asset::???? > ("id(fork31)"))); ////TODO broken: we don't use a dedicated Fork asset anymore. It's just an EntryID<Fork>
CHECK (fork31 == focus.getObject());

View file

@ -60,11 +60,11 @@ namespace test {
ID i2 = index->insert (p2, i1 );
ID i3 = index->insert (p3, i2 );
ID i4 = index->insert (p4, i3 );
ID i5 = index->insert (p5, i4 );
index->insert (p5, i4 );
ID is1 = index->insert (ps1,root);
ID is2 = index->insert (ps2,root);
ID is3 = index->insert (ps3, is2);
index->insert (ps1,root);
ID is2 =index->insert (ps2,root);
index->insert (ps3, is2);
return index;
}

View file

@ -75,7 +75,6 @@ namespace test {
ostream& operator<< (ostream& s, const B& b) { return s << "B{} adr="<<&b<<" type: "<<tyAbbr(b); }
ostream& operator<< (ostream& s, const D& d) { return s << "D{} adr="<<&d<<" type: "<<tyAbbr(d); }
ostream& operator<< (ostream& s, const E& e) { return s << "E{} adr="<<&e<<" type: "<<tyAbbr(e); }
ostream& operator<< (ostream& s, const F& f) { return s << "F{} adr="<<&f<<" type: "<<tyAbbr(f); }
}//(End)Test fixture

View file

@ -119,7 +119,7 @@ namespace test{
{
void
run (Arg arg)
run (Arg)
{
Depend<TestSingletonO> sing;

View file

@ -102,7 +102,6 @@ namespace test{
void
checkExtension ()
{
typedef SubId<Colour> CID;
typedef SubId<uint> UID;
typedef ExtendedSubId<Colour, UID> CUID;