diff options
author | ZeroC Staff <git@zeroc.com> | 2001-08-24 15:18:10 +0000 |
---|---|---|
committer | ZeroC Staff <git@zeroc.com> | 2001-08-24 15:18:10 +0000 |
commit | 7d942fd5acf7921e77a244542a0db5fe636678a2 (patch) | |
tree | 8da2d4683d87af41a1036004f4828b06b28fc253 /cpp | |
parent | fix (diff) | |
download | ice-7d942fd5acf7921e77a244542a0db5fe636678a2.tar.bz2 ice-7d942fd5acf7921e77a244542a0db5fe636678a2.tar.xz ice-7d942fd5acf7921e77a244542a0db5fe636678a2.zip |
no output for empty block start/end
Diffstat (limited to 'cpp')
-rw-r--r-- | cpp/src/Slice/OutputUtil.cpp | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/cpp/src/Slice/OutputUtil.cpp b/cpp/src/Slice/OutputUtil.cpp index a6ec2bb683c..d8087a6f2c4 100644 --- a/cpp/src/Slice/OutputUtil.cpp +++ b/cpp/src/Slice/OutputUtil.cpp @@ -172,9 +172,12 @@ Slice::Output::nl() void Slice::Output::sb() -{ - nl(); - _out << _blockStart; +{
+ if (_blockStart.length())
+ { + nl(); + _out << _blockStart;
+ } ++_pos; inc(); _separator = false; @@ -184,8 +187,11 @@ void Slice::Output::eb() { dec(); - nl(); - _out << _blockEnd; + if (_blockEnd.length())
+ {
+ nl(); + _out << _blockEnd;
+ } --_pos; } |