diff options
author | Marc Laukien <marc@zeroc.com> | 2001-08-10 20:59:22 +0000 |
---|---|---|
committer | Marc Laukien <marc@zeroc.com> | 2001-08-10 20:59:22 +0000 |
commit | 7377a861663e60c6e0155edbdf6b544d1dba0502 (patch) | |
tree | 80a44155233c491841c0036d48346f4850e875d9 /cpp/src/Slice/Parser.cpp | |
parent | fixes (diff) | |
download | ice-7377a861663e60c6e0155edbdf6b544d1dba0502.tar.bz2 ice-7377a861663e60c6e0155edbdf6b544d1dba0502.tar.xz ice-7377a861663e60c6e0155edbdf6b544d1dba0502.zip |
nonmutating
Diffstat (limited to 'cpp/src/Slice/Parser.cpp')
-rw-r--r-- | cpp/src/Slice/Parser.cpp | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/cpp/src/Slice/Parser.cpp b/cpp/src/Slice/Parser.cpp index 73754ae3147..97ce13547b2 100644 --- a/cpp/src/Slice/Parser.cpp +++ b/cpp/src/Slice/Parser.cpp @@ -1050,7 +1050,8 @@ Slice::ClassDef::createOperation(const string& name, const TypePtr& returnType, const TypeStringList& inParams, const TypeStringList& outParams, - const TypeList& throws) + const TypeList& throws, + bool nonmutating) { ContainedList matches = _unit->findContents(thisScope() + name); if (!matches.empty()) @@ -1119,7 +1120,7 @@ Slice::ClassDef::createOperation(const string& name, return 0; } - OperationPtr p = new Operation(this, name, returnType, inParams, outParams, throws); + OperationPtr p = new Operation(this, name, returnType, inParams, outParams, throws, nonmutating); _contents.push_back(p); return p; } @@ -1363,6 +1364,12 @@ Slice::Operation::throws() return _throws; } +bool +Slice::Operation::nonmutating() +{ + return _nonmutating; +} + Slice::Contained::ContainedType Slice::Operation::containedType() { @@ -1376,13 +1383,15 @@ Slice::Operation::visit(ParserVisitor* visitor) } Slice::Operation::Operation(const ContainerPtr& container, const string& name, const TypePtr& returnType, - const TypeStringList& inParams, const TypeStringList& outParams, const TypeList& throws) : + const TypeStringList& inParams, const TypeStringList& outParams, const TypeList& throws, + bool nonmutating) : Contained(container, name), SyntaxTreeBase(container->unit()), _returnType(returnType), _inParams(inParams), _outParams(outParams), - _throws(throws) + _throws(throws), + _nonmutating(nonmutating) { } |