| Summary: | Formatting issue with #define | ||
|---|---|---|---|
| Product: | [Tools] CDT | Reporter: | BB <bjoern.kiefer> |
| Component: | cdt-editor | Assignee: | Project Inbox <cdt-editor-inbox> |
| Status: | RESOLVED WORKSFORME | QA Contact: | Anton Leherbauer <aleherb+eclipse> |
| Severity: | major | ||
| Priority: | P3 | CC: | ghislain.viguier, marco.stornelli, zeratul976 |
| Version: | 7.0 | ||
| Target Milestone: | --- | ||
| Hardware: | PC | ||
| OS: | Linux | ||
| Whiteboard: | |||
This bug report should be closed because we can't reproduce with CDT 9.7. |
I found a formatting issue. Copy the following code into the C++ Editor and press (ctrl+shift+f). #include <iostream> #include <string> //#define OUTPUT_STREAM std::cout #define OUTPUT_STREAM true && std::cout int main(int argc, char **argv) { OUTPUT_STREAM << "test" << std::endl; // This line moves // This line moves } // This line moves The result after the formatting is not well and looks like this: #include <iostream> #include <string> //#define OUTPUT_STREAM std::cout #define OUTPUT_STREAM true && std::cout int main(int argc, char **argv) { OUTPUT_STREAM << "test" << std::endl; // This line moves // This line moves } // This line moves If I comment out the second define and uncomment the first define, the formatting looks good: #include <iostream> #include <string> #define OUTPUT_STREAM std::cout //#define OUTPUT_STREAM true && std::cout int main(int argc, char **argv) { OUTPUT_STREAM << "test" << std::endl; // This line moves // This line moves } // This line moves