Я обнаружил этот драгоценный камень при просмотре источника HTML более раннее повторение веб-сайта TVNZ (от строки 571, если Вы манипулируете дома):
<!-- Hopfully we can do this otherwise the nav is going to be pretty plain and Hong will go postal. -->
Я просто натыкался на этого в действительно простом тесте программа C++ для класса в колледже.
я комментировал класс.
В деструкторе...
// Choose! Choose the form of the Destructor!
// The choice is made! The Traveler has come!
catch (Domain.ConcurrencyException)
{
// somebody changed it between the time we loaded it and now.
// weird, huh?
}
В крупном инвестиционном банке, который потребовал, все простои приложений зарегистрированы и прокомментировали, что я видел
Without a crash
Or mighty bang
The sync disk
Did it's process hang
Это - мой любимый комментарий когда-либо.
/// I intend to do this as shittily as possible because there are many better products that will totally blow this out of the water
/// and we don't have them so whatever
Позже в файле мы развлекаемся еще больше как
/// sidestep a bug in WCF (that we can't send types across)
/// or, depending on how you look at, this issue is a Feature
И снова позже
if( where == null)//be nice
// THE LOOP THAT DO EVERYTHING!!!!!!!
'Do not optimize these next two lines. Compiler bugs lurk.
И они сделали. Уплотнение переменной в выражение на второй строке привело к вскакиванию в середину "кучи" и попытки выполнить данные.
// Bad Christian, No cookie
Cookie в этом контексте делает не , относятся к браузеру cookie
Это один от моего собственного кода, но это все еще действительно забавно, и я полагаю, что мог бы также поднять его, потому что это - на публике SVN.
// These were orginally up and down. When it was clear the names were
// inapplicable, they were renamed to retain the joke.
// Sorry if you were hoping for useful variable names.
quantum strange, charm;
Не комментарий, а атрибут
[ThereBeDragons]
И один я видел в реализации IHttpHandler
//What is this?
public bool IsReusable
{
get{return false;}
}
/* My lawyer told me not to reveal */
# absolutely foul heuristic code.
# ..it's dirty, but you want it.
и:
# VERY USEFUL DEBUGGING AID, for when the above all goes pearshaped:
// TODO: Implement this function!
THIS PROGRAM HAS CODE THAT DOES NOT MEET STANDARDS
, Что комментарий находится почти в каждой программе, которую мы имеем здесь....
Я должен был добавить этого к нашему старому управляемому таблицей данных механизму правил, прежде чем я решил заменить его языком сценариев.
/************************************************************
* *
* .=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-. *
* | ______ | *
* | .-" "-. | *
* | / \ | *
* | _ | | _ | *
* | ( \ |, .-. .-. ,| / ) | *
* | > "=._ | )(__/ \__)( | _.=" < | *
* | (_/"=._"=._ |/ /\ \| _.="_.="\_) | *
* | "=._"(_ ^^ _)"_.=" | *
* | "=\__|IIIIII|__/=" | *
* | _.="| \IIIIII/ |"=._ | *
* | _ _.="_.="\ /"=._"=._ _ | *
* | ( \_.="_.=" `--------` "=._"=._/ ) | *
* | > _.=" "=._ < | *
* | (_/ \_) | *
* | | *
* '-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=' *
* *
* LASCIATE OGNI SPERANZA, VOI CH'ENTRATE *
*************************************************************/
Этот комментарий из старого проекта, который я должен был отладить:
//Haleluya i can go home!
Просто добавленный этот сегодня:
// Hardcoded this for time sake ... will make andrew fix later :)
// Some wanker in ISO got rid of ifstream(int), ofstream(int), and
// fstream(int). Twit.
// TODO: Drive an ashen stake through the foul heart of this function.
И это была грязная функция. У меня есть кошмары об этом по сей день.
Ну, они являются моими, таким образом, WTF - я, как заявил CodingHorror:
//#region Code for weird cases - do you really want to know?
Я когда-то оставил комментарий как так в некотором ASP:
' Commented out following code, don't delete for when [CustomerName] changes his mind
Как это происходит, [CustomerName] не передумал, но он, DID имеет доступ к веб-серверу и ему, DID находит ту строку...
public int hashCode() {
//sucks, but what're you gonna do
/*
int hash = 7;
for (int i = 0; i < array.length; i++)
hash = hash * 31 * (null == array[i] ? 0 : array[i].hashCode());
return hash;
*/
return 0;
}
// This part is more difficult
At the top of a method.
That was about 5 lines long.
And not very difficult.
It was the only comment.
In the entire application.
// TODO: not this
Написано коллегой над запросом, отчаянно нуждающимся в оптимизации. В его защиту мы все работали по 70 часов в течение нескольких месяцев в этот момент ...
Из исходного кода UNIX версии 6, около 1975 г .:
/* You are not expected to understand this. */
/**
* Not even your mum thinks you're special if you call this method
*/
onlyYourMumThinksYoureSpecialIfYouCallThisMethod() {...}
Я нашел это в Google Code Search
// Constructs a tuple with 2 elements (fucking idiot, use std::pair instead!)
template <typename T0,typename T1>
inline tuple <T0,T1> make_tuple (const T0& t0,
const T1& t1) {
tuple <T0,T1> t;
t.get<0>() = t0;
t.get<1>() = t1;
return t;
}
// Fuck.
Это и ...
// This code worked before, but my cat decided to take a trip across my keyboard...
/*
____________________
/ \
| Jean-Michel Bechet |
| 2002-2009 |
\___ _______________/
|/
(o_
//\
V_/_
*/
/**
* This run through all the guipublisherbuyRecord , the records those have
* diff. is buytotal and prior to buy isRecommendedBillingClickedWarning flag
* is set if priously RB ran and this time not.
*
* --What?
*
* @return
* @throws AppException
*/
При отладке чужого JavaScript я видел следующий комментарий:
// Notice: I feel so dirty doing this, but it's the only way to make it cross browser.
Но, читая один пост Скотта Хансельмена Я наткнулся на следующую цитату, которая очень хорошо сочетается с комментариями, которые я нашел внутри кода:
Every line of code you write that you feel gross about will ultimately come back to haunt you. Therefore, avoid writing code that makes you feel dirty.
Это забавно:)