- 1
Путин, уходи, нахуй!..
Нашли или выдавили из себя код, который нельзя назвать нормальным, на который без улыбки не взглянешь? Не торопитесь его удалять или рефакторить, — запостите его на говнокод.ру, посмеёмся вместе!
−24
Путин, уходи, нахуй!..
Заебал
+1
$np = new NP();
//Проверяю пользователя на модератора
$arResult["showModerInfo"] = ($np->checkUserAccess([6]));
$fil = $arResult['FILTER']; // Ради сокращения длины строк
$req = $np->getRequest()->toArray()['filter'];
?>
<div class="col-xs-12">
<div class="b-shadow-wrapper b-filter" <?=($arResult['FILTER'])?'style="display:block"':''?>>
сокращение строк
−25
Никто не заметил связи между уходами долбоёба-стертора, и внезапным появлением kegdan?
Кого наебать решил, паскуда?
+1
program bio;
uses crt, graphABC;
const y1=200; r1=20;
var
x2,x3,r:real;
procedure del (x1,x11:integer);
begin
circle (x1,y1,r1);
sleep(1000);
ClearWindow();
r:=r1/2;
x2:=x1-(r);
circle (Trunc(x2),y1,Trunc(r));
x3:=x11+(r);
circle (Trunc(x3),y1,Trunc(r));
sleep(1000);
r:=r*2;
x2:=x1-(r);
circle (Trunc(x2),y1,Trunc(r));
x3:=x11+(r);
circle (Trunc(x3),y1,Trunc(r));
del(Trunc(x2),Trunc(x3));
end;
begin
SetWindowSize(600,400);
setBrushColor(clGreen);
del(300,300);
end.
Симулятор деления клеток на паскале, который не работает.
0
@requests = Request.where(instrument_id: 1).where("state_id not in (12,3,5,8,13,15,4)").where(id: current_user.arr_request_services).order(priority_id: :desc, updated_at: :desc, id: :desc) #.page(params[:page]).per_page(20)
@requests1 = Request.where(instrument_id: 1).where(locked_by: current_user).where("state_id not in (12,3,5,8,13,15,4)").order(priority_id: :desc, updated_at: :desc, id: :desc)
@requests2 = Request.where(instrument_id: 1).where(author_id: current_user.id).where("state_id not in (12,3,5,8,13,15,4)").order(priority_id: :desc, updated_at: :desc, id: :desc)
@requests3 = Request.where(instrument_id: 1).where(owner_id: current_user.id).where("state_id not in (12,3,5,8,13,15,4)").order(priority_id: :desc, updated_at: :desc, id: :desc)
@requests = (@requests + @requests1 + @requests2 + @requests3).uniq
Что это ?
−27
Политота.
Ребята, девчонки и петухи. Завтра будем голосовать, выбирать себе хозяина еще на 4 года. У кого какие соображение на этот счет?
−4
if ($memberInfo['member_profile_image'] != ''):
$memberInfo['photoCount'] = $memberInfo['photoCount'] ;
else:
$memberInfo['photoCount'] = $memberInfo['photoCount'];
endif;
6 строчек кода, а этот код не делает ничего. От слова совсем
−1
public function syncStock() {
$locked = file_exists(__DIR__ . '/lock/gk_sync_stock');
if ($locked) {
$this->logger->log("Attempt to sync locked stock");
return;
}
file_put_contents(__DIR__ . '/lock/gk_sync_stock', current_time('mysql'));
$changed = $this->_syncStock();
unlink(__DIR__ . '/lock/gk_sync_stock');
$this->logger->log("Sync stock complete, $changed changed");
}
Тут может произойти дедлок, или ни один из синхронных запросов не выполнится?
−2
assert exec("from my_runtime_analyze_lib import do_amazing_magic") or True
if __name__ == '__main__':
do_smth()
assert do_amazing_magic()
do_smth_else()
Как вхерачить в код любую ересь для dev окружения, а потом отключить на продакшене. Только не забыть бы на проде при запуске флаг оптимизации.
−1
Antony Polukhin
in
pro.cxx
Кстати, в EWG одобрили constexpr контейнеры http://open-std.org/JTC1/SC22/WG21/docs/papers/2018/p0784r1.html
так что есть все шансы к С++20 писать:
constexpr std::string result = foo();
t.me/ProCxx
/184343
Mar 16 at 10:47
Library pragmatism
Current implementations of standard libraries sometimes perform various raw storage operations through interfaces other than the standard allocator and allocator traits. That may make it difficult to make the associated components usable in constexpr components. Based on a cursory examination of current practices, we therefore propose to start only with the requirement that the container templates in the [containers] clause be usable in constexpr evaluation, when instantiated over literal types and the default allocator. In particular, this excludes std::string, std::variant, and various other allocating components. Again, it is our hope we will be able to extend support to more components in the future.
With regards to the default allocator and allocator traits implementation, the majority of the work is envisioned in the constexpr evaluator: It will recognize those specific components and implement their members directly (without necessarily regarding the library definition).
We might, however, consider decorating the class members with the constexpr keyword. Also, some implementations provide extra members in these class templates (such as libc++'s allocator_traits<A>::__construct_forward ) that perform non-constexpr-friendly operations (memcpy, in particular). Lifting such members to standard status would help interoperability between library and compiler implementations.