Skip to content

Instantly share code, notes, and snippets.

View eklitzke's full-sized avatar

Evan Klitzke eklitzke

View GitHub Profile
def docme(f):
f.__doc__ = "lol"
return f
@docme
def foo():
pass
# now it's like as if i had put "lol" as the docstring of f
_muldi3.o:
0000000000000000 T __multi3
_negdi2.o:
0000000000000000 T __negti2
_lshrdi3.o:
0000000000000000 T __lshrti3
_ashldi3.o:
%%{
machine Lexer;
main := |*
'(' => {
CAPTURE_TOKEN_TYPE(Open);
fbreak;
};
#include <gtest/gtest.h>
#include "lisp/lexer.h"
// Assert that the next token has the given type (with no value).
#define TOKTYPE(t) \
ASSERT_EQ(lexer.NextToken(), lisp::Token(lisp::TokenType::t));
// Assert that the next token has the given type and value.
#define TOKVAL(t, val) \
size_t dirlen = strlen (dir);
char *name = malloc (dirlen + sizeof id_name);
if (unlikely (name == NULL))
break;
memcpy (mempcpy (name, dir, dirlen), id_name, sizeof id_name);
#pragma once
#include "solution.h"
using namespace advent;
namespace advent2019 {
class Solution3 : public Solution {
public:
using Point = std::pair<int, int>;
---------------------
deltarpm suite V3.4
---------------------
A) Programs
makedeltarpm [-V version] [-s seqfile] oldrpm newrpm deltarpm
Extracts the usable files (i.e. no config files) from oldrpm and
// A sample standard C++20 program that prints
// the first N Pythagorean triples.
#include <iostream>
#include <optional>
#include <ranges> // New header!
using namespace std;
// maybe_view defines a view over zero or one
// objects.
#!/bin/bash
#
# Simple script implementing a temperature dependent fan speed control
# Supported Linux kernel versions: 2.6.5 and later
#
# Version 0.71
#
# Usage: fancontrol [CONFIGFILE]
#
# Dependencies:
irc/accounts.go:366:10: Error return value of `tx.Set` is not checked (errcheck)
tx.Set(accountKey, "1", setOptions)
^
irc/accounts.go:367:10: Error return value of `tx.Set` is not checked (errcheck)
tx.Set(accountNameKey, account, setOptions)
^
irc/accounts.go:368:10: Error return value of `tx.Set` is not checked (errcheck)
tx.Set(registeredTimeKey, registeredTimeStr, setOptions)
^
irc/accounts.go:384:16: Error return value of `am.Unregister` is not checked (errcheck)