summaryrefslogtreecommitdiff
path: root/cpp/src/Slice/Parser.cpp
diff options
context:
space:
mode:
authorBenoit Foucher <benoit@zeroc.com>2008-04-17 18:18:21 +0200
committerBenoit Foucher <benoit@zeroc.com>2008-04-17 18:18:21 +0200
commit79eeac56ac66dd3c9e621b66183fdcf68eb5b1d4 (patch)
treed866f25790d5871a8bafefbd58e3ed36e0649300 /cpp/src/Slice/Parser.cpp
parentFixed bug 2947 (diff)
downloadice-79eeac56ac66dd3c9e621b66183fdcf68eb5b1d4.tar.bz2
ice-79eeac56ac66dd3c9e621b66183fdcf68eb5b1d4.tar.xz
ice-79eeac56ac66dd3c9e621b66183fdcf68eb5b1d4.zip
Fixed Parser.cpp assert
Diffstat (limited to 'cpp/src/Slice/Parser.cpp')
-rw-r--r--cpp/src/Slice/Parser.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/cpp/src/Slice/Parser.cpp b/cpp/src/Slice/Parser.cpp
index c6816a19669..b08f2515bd2 100644
--- a/cpp/src/Slice/Parser.cpp
+++ b/cpp/src/Slice/Parser.cpp
@@ -5095,12 +5095,16 @@ Slice::Unit::scanPosition(const char* s)
if(_currentLine == 0)
{
- if(currentFile != _topLevelFile)
+ if(!_topLevelFileStart)
{
type = Push;
line.erase(idx);
eraseWhiteSpace(line);
}
+ else
+ {
+ _topLevelFileStart = false;
+ }
}
else
{
@@ -5487,7 +5491,7 @@ Slice::Unit::parse(const string& filename, FILE* file, bool debug, Slice::Featur
_currentLine = 1;
_currentIncludeLevel = 0;
_featureProfile = profile;
- _topLevelFile = normalizePath(filename);
+ _topLevelFileStart = true;
pushContainer(this);
pushDefinitionContext();