Outcommented Facelets code still invokes EL expressions like #{bean.action()} and causes javax.el.PropertyNotFoundException on #{bean.action}

Look closer at the stack trace. Here’s the relevant part: … org.apache.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:189) com.sun.faces.facelets.el.ELText$ELTextVariable.toString(ELText.java:217) com.sun.faces.facelets.el.ELText$ELTextComposite.toString(ELText.java:157) com.sun.faces.facelets.compiler.CommentInstruction.write(CommentInstruction.java:77) … It’s thus evaluating EL in a comment block (recognizable by CommentInstruction). A comment block is considered as template text. Facelets evaluates by default also EL #{} in template text. It’s like as if you’re writing <p>#{screenShotBean.takeScreenshot}</p> without any JSF … Read more

Remove comments from C/C++ code

Run the following command on your source file: gcc -fpreprocessed -dD -E test.c Thanks to KennyTM for finding the right flags. Here’s the result for completeness: test.c: #define foo bar foo foo foo #ifdef foo #undef foo #define foo baz #endif foo foo /* comments? comments. */ // c++ style comments gcc -fpreprocessed -dD -E … Read more

Comments in Markdown

I believe that all the previously proposed solutions (apart from those that require specific implementations) result in the comments being included in the output HTML, even if they are not displayed. If you want a comment that is strictly for yourself (readers of the converted document should not be able to see it, even with … Read more