new feature: if tatement for conditions in functions
This commit is contained in:
1 parent
bf6b4764db
commit
ee1ebd8ca9
7 files changed
+189
-78
No files matched your search
+10
-3
@@ -221,9 +221,9 @@ class ScriptExecutionFailed: public ScriptFailed {
|
||||
|
||||
class WrongNumberOfArguments: public TestFailed {
|
||||
public:
|
||||
WrongNumberOfArguments(QString name, QStringList vars, QStringList args):
|
||||
TestFailed(QString("%1 has %2 arguments, but %3 were given")
|
||||
.arg(name).arg(vars.size()).arg(args.size())) {
|
||||
WrongNumberOfArguments(QStringList vars, QStringList args):
|
||||
TestFailed(QString("function has %1 arguments, but %2 were given")
|
||||
.arg(vars.size()).arg(args.size())) {
|
||||
}
|
||||
};
|
||||
|
||||
@@ -246,4 +246,11 @@ class FunctionNotFound: public TestFailed {
|
||||
}
|
||||
};
|
||||
|
||||
class VariableNotFound: public TestFailed {
|
||||
public:
|
||||
VariableNotFound(QString name):
|
||||
TestFailed("variable not found: "+name) {
|
||||
}
|
||||
};
|
||||
|
||||
#endif
|
||||
Reference in new issue
Block a user