comments

What was the scary code comment about dragons?

岁酱吖の 提交于 2019-12-03 11:07:13
问题 The phrase was used as a warning that the code was pulling some serious stunts. My google search for this is pulling up nada; but I remember someone doing a search of google source for the phrase quite a while back. in lies dragons? dragons sleep here... Bah... 回答1: Here be Dragons. originally sourced from old maps, not that any old maps actually used the term! PS. Not recommended to use the original latin "hic sunt dracones" unless you want to be really nerdy and appear superior to future

Why is '//' style multiline comment bad (in Java)?

本秂侑毒 提交于 2019-12-03 11:04:17
问题 http://java.sun.com/docs/codeconv/html/CodeConventions.doc4.html#286 I was reading the above section of Java coding convention and started to wonder why it says "// comment.....shouldn't be used on consecutive multiple lines for text comments" Copy pasted the relevant section here for convenience: The // comment delimiter can comment out a complete line or only a partial line. It shouldn't be used on consecutive multiple lines for text comments ; however, it can be used in consecutive

How to comment multiple lines in PhpStorm IDE?

这一生的挚爱 提交于 2019-12-03 10:41:25
I use PhpStorm to edit PHP files and configuration files for Apache. How to comment on the selected block and set the symbol comment? I want,for example, <Directory /> Options FollowSymLinks AllowOverride None Order deny,allow Deny from all </Directory> to #<Directory /> # Options FollowSymLinks # AllowOverride None # Order deny,allow # Deny from all #</Directory> CrazyCoder Select multiple lines and use the Comment with Line Comment ( Ctrl + / in the default keymap on Windows, can be changed in Settings | Keymap ). There is also Comment with Block Comment that works for file types that have

What's the difference between % and %% for comments?

↘锁芯ラ 提交于 2019-12-03 10:40:28
The MATLAB editor automatically highlights all content after %% comments, and text after %% in the same line are turned bold. But what's the essential difference here? Why do people sometimes use %% instead of % ? From a syntax point of view, they are both comments. In the Matlab editor, Matlab parses %% delimited blocks as "sections" which you can run as a unit independent of running the whole script. One percent sign ( % ) is used for commenting lines. Two percent signs ( %% ) have a different purpose: they are used for dividing your code into sections , which can be run independently. This

Adding comment to column when I create table in PostgreSQL?

我的梦境 提交于 2019-12-03 10:24:42
问题 How can I add comment to column in PostgreSQL? create table session_log ( UserId int index not null, PhoneNumber int index); 回答1: Comments are attached to a column using the comment statement: create table session_log ( userid int not null, phonenumber int ); comment on column session_log.userid is 'The user ID'; comment on column session_log.phonenumber is 'The phone number including the area code'; You can also add a comment to the table: comment on table session_log is 'Our session logs';

How to avoid Eclipse importing a class when putting the class name in the comments, so that checkstyle does not complain later?

有些话、适合烂在心里 提交于 2019-12-03 10:09:39
Sometimes I put the class name in the comments of methods or class just for referencing. But eclipse does the import automatically and leaves an import statement in the file which causes "unused import" checkstyle errors later. Is there some configuration I can change to avoid eclipse automatically importing when I type the class name in the comments? People don't agree whether this is a bug or not. Javadoc needs the imports to create appropriate links. I'd say checkstyle should provide an option (and Eclipse maybe too) to change the warning. There are two relevant bug reports: eclipse

Vim plugin to generate Javascript Documentation comments

做~自己de王妃 提交于 2019-12-03 08:24:50
Is there a plugin for vim, somewhat like Jsbeautify, which automatically generates JavaDoc like comments in the script files. For example it will take this function(a , b , c){ } and return /** * Description. * * @param a Description. * @param b Description. * @param c Description. */ function(a , b , c){ } claus Here's a little something to get you started - tweak as required!-) " generate doc comment template map <LocalLeader>/ :call GenerateDOCComment()<cr> function! GenerateDOCComment() let l = line('.') let i = indent(l) let pre = repeat(' ',i) let text = getline(l) let params = matchstr

How to add comments to an Exuberant Ctags config file?

折月煮酒 提交于 2019-12-03 08:16:45
问题 What character can I use to put comments in an Exuberant Ctags .ctags file? I would like to add comments with explanations, and perhaps to disable some regexps. But I can't find any comment character which ctags-exuberant accepts! I keep getting the warning: ctags: Warning: Ignoring non-option in /home/joey/.ctags which is better than an error, but still a little annoying. I have tried # // /* ... */ and ; as comments, but ctags tries to parse them all! Here is an example file with some

Finding Shortcuts in Aptana Studio 3.0 to Comment Code [closed]

久未见 提交于 2019-12-03 08:12:25
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 7 years ago . I can't find any shortcuts for comment my code in Aptana Studio 3.0. I need shortcuts both to comment individual lines and for commenting selected blocks of code. Some have told me to try to comment with shortcut WIN + / on my Windows OS but that does not appear workable. 回答1: It depends on which language you're

wordpress - having comments inline ajax like in stackoverflow

假装没事ソ 提交于 2019-12-03 07:50:44
问题 i have a wordpress blog and want to give people the same user experience for adding comments that is in stackoverflow. There are a number of comments ajax plugins out there but i can't find a working one that allows you to inline on the main page, go in and add comments without first drilling down into a seperate single post page. Can anyone help here with either a wordpress plugin or php code to do this. 回答1: I was never able to get AJAXed Wordpress to do what me (and apparently the