mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-10 12:32:20 +02:00
Support for non-static ++ and -- operator overloads
This commit is contained in:
parent
5924d4819b
commit
66d5f67528
3 changed files with 58 additions and 19 deletions
|
@ -521,10 +521,13 @@ BfMethodDef* BfDefBuilder::CreateMethodDef(BfMethodDeclaration* methodDeclaratio
|
|||
{
|
||||
if (!methodDef->mIsStatic)
|
||||
{
|
||||
if (!declError.empty())
|
||||
declError += " and ";
|
||||
declError += "'static'";
|
||||
methodDef->mIsStatic = true; // Fix it
|
||||
if ((operatorDecl->mUnaryOp != BfUnaryOp_Increment) && (operatorDecl->mUnaryOp != BfUnaryOp_Decrement))
|
||||
{
|
||||
if (!declError.empty())
|
||||
declError += " and ";
|
||||
declError += "'static'";
|
||||
methodDef->mIsStatic = true; // Fix it
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!declError.empty())
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue