Skip to content

Commit

Permalink
Bug 1035884 - Follow-up: Use typedef for ns(C){CharSeparated,Whitespa…
Browse files Browse the repository at this point in the history
…ce}Tokenizer. r=froydnj
  • Loading branch information
poiru committed Jul 27, 2014
1 parent 77bec57 commit c95547c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 40 deletions.
24 changes: 2 additions & 22 deletions xpcom/ds/nsCharSeparatedTokenizer.h
Original file line number Diff line number Diff line change
Expand Up @@ -177,17 +177,7 @@ class nsCharSeparatedTokenizerTemplate
}
};

class nsCharSeparatedTokenizer
: public nsCharSeparatedTokenizerTemplate<>
{
public:
nsCharSeparatedTokenizer(const nsSubstring& aSource,
char16_t aSeparatorChar,
uint32_t aFlags = 0)
: nsCharSeparatedTokenizerTemplate<>(aSource, aSeparatorChar, aFlags)
{
}
};
typedef nsCharSeparatedTokenizerTemplate<> nsCharSeparatedTokenizer;

template<bool IsWhitespace(char16_t) = NS_IsAsciiWhitespace>
class nsCCharSeparatedTokenizerTemplate
Expand All @@ -203,16 +193,6 @@ class nsCCharSeparatedTokenizerTemplate
}
};

class nsCCharSeparatedTokenizer
: public nsCCharSeparatedTokenizerTemplate<>
{
public:
nsCCharSeparatedTokenizer(const nsCSubstring& aSource,
char aSeparatorChar,
uint32_t aFlags = 0)
: nsCCharSeparatedTokenizerTemplate<>(aSource, aSeparatorChar, aFlags)
{
}
};
typedef nsCCharSeparatedTokenizerTemplate<> nsCCharSeparatedTokenizer;

#endif /* __nsCharSeparatedTokenizer_h */
20 changes: 2 additions & 18 deletions xpcom/ds/nsWhitespaceTokenizer.h
Original file line number Diff line number Diff line change
Expand Up @@ -91,15 +91,7 @@ class nsWhitespaceTokenizerTemplate
}
};

class nsWhitespaceTokenizer
: public nsWhitespaceTokenizerTemplate<>
{
public:
nsWhitespaceTokenizer(const nsSubstring& aSource)
: nsWhitespaceTokenizerTemplate<>(aSource)
{
}
};
typedef nsWhitespaceTokenizerTemplate<> nsWhitespaceTokenizer;

template<bool IsWhitespace(char16_t) = NS_IsAsciiWhitespace>
class nsCWhitespaceTokenizerTemplate
Expand All @@ -112,14 +104,6 @@ class nsCWhitespaceTokenizerTemplate
}
};

class nsCWhitespaceTokenizer
: public nsCWhitespaceTokenizerTemplate<>
{
public:
nsCWhitespaceTokenizer(const nsCSubstring& aSource)
: nsCWhitespaceTokenizerTemplate<>(aSource)
{
}
};
typedef nsCWhitespaceTokenizerTemplate<> nsCWhitespaceTokenizer;

#endif /* __nsWhitespaceTokenizer_h */

0 comments on commit c95547c

Please sign in to comment.