mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-04 14:01:25 +12:00
Renamed the stream member functions get() and eat().
This commit is contained in:
parent
852e5b63e5
commit
c1966ba3fc
8 changed files with 143 additions and 73 deletions
16
stream.cpp
16
stream.cpp
|
@ -2,9 +2,9 @@
|
|||
|
||||
namespace YAML
|
||||
{
|
||||
// GetChar
|
||||
// get
|
||||
// . Extracts a character from the stream and updates our position
|
||||
char Stream::GetChar()
|
||||
char Stream::get()
|
||||
{
|
||||
char ch = input.get();
|
||||
column++;
|
||||
|
@ -15,21 +15,21 @@ namespace YAML
|
|||
return ch;
|
||||
}
|
||||
|
||||
// GetChar
|
||||
// get
|
||||
// . Extracts 'n' characters from the stream and updates our position
|
||||
std::string Stream::GetChar(int n)
|
||||
std::string Stream::get(int n)
|
||||
{
|
||||
std::string ret;
|
||||
for(int i=0;i<n;i++)
|
||||
ret += GetChar();
|
||||
ret += get();
|
||||
return ret;
|
||||
}
|
||||
|
||||
// Eat
|
||||
// eat
|
||||
// . Eats 'n' characters and updates our position.
|
||||
void Stream::Eat(int n)
|
||||
void Stream::eat(int n)
|
||||
{
|
||||
for(int i=0;i<n;i++)
|
||||
GetChar();
|
||||
get();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue