LineAndColumn: fix operator[+-]=
This commit is contained in:
parent
8a4a3e447b
commit
2f093d78b5
|
@ -22,7 +22,7 @@ struct LineAndColumn
|
||||||
{
|
{
|
||||||
line += other.line;
|
line += other.line;
|
||||||
column += other.column;
|
column += other.column;
|
||||||
return *this;
|
return *static_cast<EffectiveType*>(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
EffectiveType operator-(const EffectiveType& other) const
|
EffectiveType operator-(const EffectiveType& other) const
|
||||||
|
@ -34,7 +34,7 @@ struct LineAndColumn
|
||||||
{
|
{
|
||||||
line += other.line;
|
line += other.line;
|
||||||
column += other.column;
|
column += other.column;
|
||||||
return *this;
|
return *static_cast<EffectiveType*>(this);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user