Permalink
Browse files

Make counter in TagInfo an unsigned int

  • Loading branch information...
lauft committed Jul 31, 2018
1 parent 5f66dff commit 1420ca27c82f57a649a4dfda3d5aef0d063771ae
Showing with 12 additions and 8 deletions.
  1. +7 −4 src/TagInfo.cpp
  2. +5 −4 src/TagInfo.h
@@ -24,19 +24,22 @@
//
////////////////////////////////////////////////////////////////////////////////

#include "TagInfo.h"
#include <TagInfo.h>

TagInfo::TagInfo (int count)
////////////////////////////////////////////////////////////////////////////////
TagInfo::TagInfo (unsigned int count)
{
_count = count;
}

int TagInfo::increment ()
////////////////////////////////////////////////////////////////////////////////
unsigned int TagInfo::increment ()
{
return _count++;
}

int TagInfo::decrement ()
////////////////////////////////////////////////////////////////////////////////
unsigned int TagInfo::decrement ()
{
return --_count;
}
@@ -30,13 +30,14 @@
class TagInfo
{
public:
explicit TagInfo (int);
explicit TagInfo (unsigned int);

unsigned int increment ();
unsigned int decrement ();

int increment ();
int decrement ();

private:
int _count = 0;
unsigned int _count = 0;
};

#endif

0 comments on commit 1420ca2

Please sign in to comment.