comments

How to comment out chunk of code in multi-line macro?

泄露秘密 提交于 2021-01-29 05:37:39
问题 I have a complex multi line macro code in C++ (that process some geometry and computes its physical properties in RT) which is used many times and can not be converted to function (without huge space and performance hits). The problem is I sometimes need to configure the code inside disabling parts of code (in compile time for specific tasks/machines) something like this: #define some_macro \ bla; \ bla; \ if (0) \ { \ bla; \ bla; \ bla; \ } \ bla; As you can see this leads to multiples of

Open CV Code - Can someone help me understand what the code is doing

梦想的初衷 提交于 2021-01-28 08:31:11
问题 I am working on the OpenCV color blob and I am reviewing the code. I need some help understand what the code is doing so that I can work further on it and help integrate this further. Is it possible for someone to help me with understanding/commenting the code so it is easier to interpate. public boolean onTouch(View v, MotionEvent event) { int cols = mRgba.cols(); //get resolution of display int rows = mRgba.rows(); // get resolution of display int xOffset = (mOpenCvCameraView.getWidth() -

How can I add a comment with ruamel.yaml

Deadly 提交于 2021-01-27 20:01:56
问题 I'm trying to create a data structure with ruamel.yaml and want to add comments before dumping and/or loading it again. Unfortunately all examples load some string with the round trip dumper first or use no longer existing APIs. This is what I am trying to dump: test: asdf # Test Comment! I tried the following: insert = ruamel.yaml.comments.CommentedMap() start_mark = ruamel.yaml.error.CommentMark(0) insert['test'] = 'asdf' insert.ca.items['test'] = [ None, [ruamel.yaml.CommentToken(value='#

The mystic getClobVal()

怎甘沉沦 提交于 2021-01-27 11:56:24
问题 I have a table (AKADMIN) with an XMLTYPE column which name is XML. I would like to use the getClobVal() with this column. select t.xml.getClobVal() /**/ , t.xml.getClobVal() -- , t.xml.getClobVal() as clobval , t.xml.getClobVal() from akadmin t where ROWID = 'AAAQc6AAIAAAADDAAA' ; In the resultset the first 4 column give CLOB type, but the fifth column XMLTYPE. I have to type any comment or alias after getClobVal() to correct (CLOB) type of the result. Why? Another issue, when I leave the

The mystic getClobVal()

僤鯓⒐⒋嵵緔 提交于 2021-01-27 11:54:21
问题 I have a table (AKADMIN) with an XMLTYPE column which name is XML. I would like to use the getClobVal() with this column. select t.xml.getClobVal() /**/ , t.xml.getClobVal() -- , t.xml.getClobVal() as clobval , t.xml.getClobVal() from akadmin t where ROWID = 'AAAQc6AAIAAAADDAAA' ; In the resultset the first 4 column give CLOB type, but the fifth column XMLTYPE. I have to type any comment or alias after getClobVal() to correct (CLOB) type of the result. Why? Another issue, when I leave the

single line comment in HTML

蹲街弑〆低调 提交于 2021-01-20 14:40:23
问题 Is there a way to comment out a single line in HTML using just an escape sequence at the start of the line? Similar to using # or // in other languages? Or is <!-- ... --> the only option for commenting in html? 回答1: from http://htmlhelp.com/reference/wilbur/misc/comment.html Since HTML is officially an SGML application, the comment syntax used in HTML documents is actually the SGML comment syntax. Unfortunately this syntax is a bit unclear at first. The definition of an SGML comment is

What is the correct way to comment out a PHP variable being echoed using shorthand notation?

♀尐吖头ヾ 提交于 2020-12-26 07:53:38
问题 I have recently started using the PHP shorthand <?= ?> tags to echo variables etc in my PHP scripts. However I find if I want to then comment out the variable, e.g. <?= //$myVariable; ?> i get a syntax error. Is it safe to just do this: <?//= $myVariable; ?> Many Thanks! 回答1: The short tag <?= ... ?> is translated into <?php echo ...; ?> So to comment it out, you have to put something into ... that always shows up as empty. Here's the shortest I can come up with: <?= false && ... ?> This

“rem” comment in .bat file causes error “25 was unexpected at this time”

无人久伴 提交于 2020-12-25 16:00:15
问题 Isn't this weird? Do .bat rem commands have some kind of escape code? file.bat: rem https://sourceforge.net/p/jedit/bugs/4084/?limit=25 Running it: C:\Users\admin>file.bat 25 was unexpected at this time. C:\Users\admin>https://sourceforge.net/p/jedit/bugs/4084/?limit=25 I don't see any errorlevel. 回答1: The rem command supports one argument, namely /? , and it is greedy for it. Your URL contains that string. The = is a standard token separator (just like SPACE , TAB , , , ; ), and so the

“rem” comment in .bat file causes error “25 was unexpected at this time”

自闭症网瘾萝莉.ら 提交于 2020-12-25 15:59:48
问题 Isn't this weird? Do .bat rem commands have some kind of escape code? file.bat: rem https://sourceforge.net/p/jedit/bugs/4084/?limit=25 Running it: C:\Users\admin>file.bat 25 was unexpected at this time. C:\Users\admin>https://sourceforge.net/p/jedit/bugs/4084/?limit=25 I don't see any errorlevel. 回答1: The rem command supports one argument, namely /? , and it is greedy for it. Your URL contains that string. The = is a standard token separator (just like SPACE , TAB , , , ; ), and so the

“rem” comment in .bat file causes error “25 was unexpected at this time”

谁都会走 提交于 2020-12-25 15:58:49
问题 Isn't this weird? Do .bat rem commands have some kind of escape code? file.bat: rem https://sourceforge.net/p/jedit/bugs/4084/?limit=25 Running it: C:\Users\admin>file.bat 25 was unexpected at this time. C:\Users\admin>https://sourceforge.net/p/jedit/bugs/4084/?limit=25 I don't see any errorlevel. 回答1: The rem command supports one argument, namely /? , and it is greedy for it. Your URL contains that string. The = is a standard token separator (just like SPACE , TAB , , , ; ), and so the