diff --git a/src/App/ApplicationPy.cpp b/src/App/ApplicationPy.cpp index 96793ee80e..773d25add3 100644 --- a/src/App/ApplicationPy.cpp +++ b/src/App/ApplicationPy.cpp @@ -100,9 +100,9 @@ PyMethodDef Application::Methods[] = { "* If no module is given it will be determined by the file extension.\n" "* If more than one module can load a file the first one will be taken.\n" "* If no module exists to load the file an exception will be raised."}, - {"open", reinterpret_cast(reinterpret_cast( Application::sOpenDocument )), METH_VARARGS|METH_KEYWORDS, + {"open", reinterpret_cast(reinterpret_cast( Application::sOpenDocument )), METH_VARARGS|METH_KEYWORDS, "See openDocument(string)"}, - {"openDocument", reinterpret_cast(reinterpret_cast( Application::sOpenDocument )), METH_VARARGS|METH_KEYWORDS, + {"openDocument", reinterpret_cast(reinterpret_cast( Application::sOpenDocument )), METH_VARARGS|METH_KEYWORDS, "openDocument(filepath,hidden=False) -> object\n" "Create a document and load the project file into the document.\n\n" "filepath: file path to an existing file. If the file doesn't exist\n" @@ -112,7 +112,7 @@ PyMethodDef Application::Methods[] = { // {"saveDocument", (PyCFunction) Application::sSaveDocument, METH_VARARGS, // "saveDocument(string) -- Save the document to a file."}, // {"saveDocumentAs", (PyCFunction) Application::sSaveDocumentAs, METH_VARARGS}, - {"newDocument", reinterpret_cast(reinterpret_cast( Application::sNewDocument )), METH_VARARGS|METH_KEYWORDS, + {"newDocument", reinterpret_cast(reinterpret_cast( Application::sNewDocument )), METH_VARARGS|METH_KEYWORDS, "newDocument(name, label=None, hidden=False, temp=False) -> object\n" "Create a new document with a given name.\n\n" "name: unique document name which is checked automatically.\n" diff --git a/src/App/DocumentObject.h b/src/App/DocumentObject.h index f7f0772566..2ff1a3fd23 100644 --- a/src/App/DocumentObject.h +++ b/src/App/DocumentObject.h @@ -112,7 +112,7 @@ public: boost::signals2::signal signalChanged; /// returns the type name of the ViewProvider - virtual const char* getViewProviderName(void) const { + virtual const char* getViewProviderName() const { return ""; } /** @@ -129,11 +129,11 @@ public: } /// Constructor - DocumentObject(void); + DocumentObject(); virtual ~DocumentObject(); /// returns the name which is set in the document for this object (not the name property!) - const char *getNameInDocument(void) const; + const char *getNameInDocument() const; /// Return the object ID that is unique within its owner document long getID() const {return _Id;} /// returns the name that is safe to be exported to other document @@ -143,7 +143,7 @@ public: virtual bool isAttachedToDocument() const override; virtual const char* detachFromDocument() override; /// gets the document in which this Object is handled - App::Document *getDocument(void) const; + App::Document *getDocument() const; /** Set the property touched -> changed, cause recomputation in Update() */ @@ -151,22 +151,22 @@ public: /// set this document object touched (cause recomputation on dependent features) void touch(bool noRecompute=false); /// test if this document object is touched - bool isTouched(void) const; + bool isTouched() const; /// Enforce this document object to be recomputed void enforceRecompute(); /// Test if this document object must be recomputed - bool mustRecompute(void) const; + bool mustRecompute() const; /// reset this document object touched - void purgeTouched(void) { + void purgeTouched() { StatusBits.reset(ObjectStatus::Touch); StatusBits.reset(ObjectStatus::Enforce); setPropertyStatus(0,false); } /// set this feature to error - bool isError(void) const {return StatusBits.test(ObjectStatus::Error);} - bool isValid(void) const {return !StatusBits.test(ObjectStatus::Error);} + bool isError() const {return StatusBits.test(ObjectStatus::Error);} + bool isValid() const {return !StatusBits.test(ObjectStatus::Error);} /// remove the error from the object - void purgeError(void){StatusBits.reset(ObjectStatus::Error);} + void purgeError(){StatusBits.reset(ObjectStatus::Error);} /// returns true if this objects is currently recomputing bool isRecomputing() const {return StatusBits.test(ObjectStatus::Recompute);} /// returns true if this objects is currently restoring from file @@ -228,7 +228,7 @@ public: /// returns a list of objects linked by the property std::vector getOutListOfProperty(App::Property*) const; /// returns a list of objects this object is pointing to by Links and all further descended - std::vector getOutListRecursive(void) const; + std::vector getOutListRecursive() const; /// clear internal out list cache void clearOutListCache() const; /// get all possible paths from this to another object following the OutList @@ -237,10 +237,10 @@ public: /// get all objects link to this object std::vector getInList(void) const #else - const std::vector &getInList(void) const; + const std::vector &getInList() const; #endif /// get all objects link directly or indirectly to this object - std::vector getInListRecursive(void) const; + std::vector getInListRecursive() const; /** Get a set of all objects linking to this object, including possible external parent objects * * @param inSet [out]: a set containing all objects linking to this object. @@ -299,7 +299,7 @@ public: * necessarily mean that it will be recomputed. It only means that all * objects that link it (i.e. its InList) will be recomputed. */ - virtual short mustExecute(void) const; + virtual short mustExecute() const; /** Recompute only this feature * @@ -308,7 +308,7 @@ public: bool recomputeFeature(bool recursive=false); /// get the status Message - const char *getStatusString(void) const; + const char *getStatusString() const; /** Called in case of losing a link * Get called by the document when a object got deleted a link property of this @@ -317,7 +317,7 @@ public: * additional or different behavior. */ virtual void onLostLinkToObject(DocumentObject*); - virtual PyObject *getPyObject(void) override; + virtual PyObject *getPyObject() override; /** Get the sub element/object by name * @@ -561,7 +561,7 @@ public: protected: /// recompute only this object - virtual App::DocumentObjectExecReturn *recompute(void); + virtual App::DocumentObjectExecReturn *recompute(); /** get called by the document to recompute this feature * Normally this method get called in the processing of * Document::recompute(). @@ -569,7 +569,7 @@ protected: * with the data from linked objects and objects own * properties. */ - virtual App::DocumentObjectExecReturn *execute(void); + virtual App::DocumentObjectExecReturn *execute(); /** * Executes the extensions of a document object. @@ -592,8 +592,8 @@ protected: */ std::bitset<32> StatusBits; - void setError(void){StatusBits.set(ObjectStatus::Error);} - void resetError(void){StatusBits.reset(ObjectStatus::Error);} + void setError(){StatusBits.set(ObjectStatus::Error);} + void resetError(){StatusBits.reset(ObjectStatus::Error);} void setDocument(App::Document* doc); /// get called before the value is changed diff --git a/src/App/Expression.cpp b/src/App/Expression.cpp index e4c5f48598..844db1c6b0 100644 --- a/src/App/Expression.cpp +++ b/src/App/Expression.cpp @@ -3191,7 +3191,7 @@ static int column; // show the parser the lexer method #define yylex ExpressionParserlex -int ExpressionParserlex(void); +int ExpressionParserlex(); // Parser, defined in ExpressionParser.y # define YYTOKENTYPE diff --git a/src/App/Link.cpp b/src/App/Link.cpp index 270cc30b73..e8ba3f06d3 100644 --- a/src/App/Link.cpp +++ b/src/App/Link.cpp @@ -148,7 +148,7 @@ void LinkParams::removeCopyOnChangeApplyToAll() { EXTENSION_PROPERTY_SOURCE(App::LinkBaseExtension, App::DocumentObjectExtension) -LinkBaseExtension::LinkBaseExtension(void) +LinkBaseExtension::LinkBaseExtension() :enableLabelCache(false),hasOldSubElement(false),hasCopyOnChange(true) { initExtensionType(LinkBaseExtension::getExtensionClassTypeId()); @@ -166,7 +166,7 @@ LinkBaseExtension::~LinkBaseExtension() { } -PyObject* LinkBaseExtension::getExtensionPyObject(void) { +PyObject* LinkBaseExtension::getExtensionPyObject() { if (ExtensionPythonObject.is(Py::_None())){ // ref counter is set to 1 ExtensionPythonObject = Py::Object(new LinkBaseExtensionPy(this),true); @@ -293,7 +293,7 @@ void LinkBaseExtension::setProperty(int idx, Property *prop) { static const char _GroupPrefix[] = "Configuration ("; -App::DocumentObjectExecReturn *LinkBaseExtension::extensionExecute(void) { +App::DocumentObjectExecReturn *LinkBaseExtension::extensionExecute() { // The actual value of LinkTouched is not important, just to notify view // provider that the link (in fact, its dependents, i.e. linked ones) have // recomputed. @@ -398,7 +398,7 @@ App::DocumentObjectExecReturn *LinkBaseExtension::extensionExecute(void) { return inherited::extensionExecute(); } -short LinkBaseExtension::extensionMustExecute(void) { +short LinkBaseExtension::extensionMustExecute() { auto link = getLink(); if(!link) return 0; @@ -2225,7 +2225,7 @@ template class AppExport ExtensionPythonT; EXTENSION_PROPERTY_SOURCE(App::LinkExtension, App::LinkBaseExtension) -LinkExtension::LinkExtension(void) +LinkExtension::LinkExtension() { initExtensionType(LinkExtension::getExtensionClassTypeId()); @@ -2265,7 +2265,7 @@ bool Link::canLinkProperties() const { namespace App { PROPERTY_SOURCE_TEMPLATE(App::LinkPython, App::Link) -template<> const char* App::LinkPython::getViewProviderName(void) const { +template<> const char* App::LinkPython::getViewProviderName() const { return "Gui::ViewProviderLinkPython"; } template class AppExport FeaturePythonT; @@ -2292,7 +2292,7 @@ bool LinkElement::canDelete() const { namespace App { PROPERTY_SOURCE_TEMPLATE(App::LinkElementPython, App::LinkElement) -template<> const char* App::LinkElementPython::getViewProviderName(void) const { +template<> const char* App::LinkElementPython::getViewProviderName() const { return "Gui::ViewProviderLinkPython"; } template class AppExport FeaturePythonT; @@ -2311,7 +2311,7 @@ LinkGroup::LinkGroup() { namespace App { PROPERTY_SOURCE_TEMPLATE(App::LinkGroupPython, App::LinkGroup) -template<> const char* App::LinkGroupPython::getViewProviderName(void) const { +template<> const char* App::LinkGroupPython::getViewProviderName() const { return "Gui::ViewProviderLinkPython"; } template class AppExport FeaturePythonT; diff --git a/src/App/Link.h b/src/App/Link.h index 60757cc725..1d3001fbad 100644 --- a/src/App/Link.h +++ b/src/App/Link.h @@ -286,8 +286,8 @@ public: bool extensionGetLinkedObject(DocumentObject *&ret, bool recurse, Base::Matrix4D *mat, bool transform, int depth) const override; - virtual App::DocumentObjectExecReturn *extensionExecute(void) override; - virtual short extensionMustExecute(void) override; + virtual App::DocumentObjectExecReturn *extensionExecute() override; + virtual short extensionMustExecute() override; virtual void extensionOnChanged(const Property* p) override; virtual void onExtendedUnsetupObject () override; virtual void onExtendedDocumentRestored() override; @@ -296,7 +296,7 @@ public: virtual int extensionIsElementVisible(const char *) override; virtual bool extensionHasChildElement() const override; - virtual PyObject* getExtensionPyObject(void) override; + virtual PyObject* getExtensionPyObject() override; virtual Property *extensionGetPropertyByName(const char* name) const override; @@ -536,9 +536,9 @@ public: LINK_PROPS_DEFINE(LINK_PARAMS_LINK) - Link(void); + Link(); - const char* getViewProviderName(void) const override{ + const char* getViewProviderName() const override{ return "Gui::ViewProviderLink"; } @@ -581,7 +581,7 @@ public: LINK_PROPS_DEFINE(LINK_PARAMS_ELEMENT) LinkElement(); - const char* getViewProviderName(void) const override{ + const char* getViewProviderName() const override{ return "Gui::ViewProviderLink"; } @@ -620,7 +620,7 @@ public: LinkGroup(); - const char* getViewProviderName(void) const override{ + const char* getViewProviderName() const override{ return "Gui::ViewProviderLink"; }