Warning, file /kdevelop/kdev-python/duchain/types/nonetype.h was not indexed or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).

0001 /*
0002     SPDX-FileCopyrightText: 2017 Francis Herne <mail@flherne.uk>
0003 
0004     SPDX-License-Identifier: GPL-2.0-or-later
0005 */
0006 
0007 #ifndef PYTHON_NONETYPE_H
0008 #define PYTHON_NONETYPE_H
0009 
0010 #include <language/duchain/types/integraltype.h>
0011 #include "pythonduchainexport.h"
0012 
0013 using namespace KDevelop;
0014 
0015 namespace Python {
0016 
0017 typedef IntegralTypeData NoneTypeData;
0018 
0019 /**
0020  * The only purpose of this class is to override IntegralType::toString().
0021  * TODO: improve kdevplatform API to allow custom strings sanely.
0022  */
0023 class KDEVPYTHONDUCHAIN_EXPORT NoneType: public IntegralType
0024 {
0025 public:
0026     /// Default constructor
0027     explicit NoneType();
0028     /// Copy constructor. \param rhs type to copy
0029     NoneType(const NoneType& rhs);
0030     /// Constructor using raw data. \param data internal data.
0031     explicit NoneType(IntegralTypeData& data);
0032 
0033     AbstractType* clone() const override;
0034 
0035     enum { Identity = 64 };
0036 
0037     QString toString() const override;
0038 };
0039 
0040 }
0041 
0042 #endif // PYTHON_NONETYPE_H