What was the scary code comment about dragons?

2019-03-14 16:09发布

问题:

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 code maintainers :)



回答2:

// Here be dragons


An example is in the source code of HipHop for PHP, at line 649 of /src/runtime/ext/ext_imagesprite.cpp as of July 13, 2012:

// Here be dragons. Thou art forewarned

If for some reason the programmer(s) doesn't quite understand what the code is doing, a comment saying "here be dragons" means that the code is "uncharted territory".

(Note my username :P)



回答3:

Here be dragons



回答4:

"Here be dragons" is displayed when you go to about:config in the address bar in Firefox.

Edit: Please note I'm in the UK so this may be locale specific.



标签: comments