This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
_muldi3.o: | |
0000000000000000 T __multi3 | |
_negdi2.o: | |
0000000000000000 T __negti2 | |
_lshrdi3.o: | |
0000000000000000 T __lshrti3 | |
_ashldi3.o: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
%%{ | |
machine Lexer; | |
main := |* | |
'(' => { | |
CAPTURE_TOKEN_TYPE(Open); | |
fbreak; | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#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) \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#pragma once | |
#include "solution.h" | |
using namespace advent; | |
namespace advent2019 { | |
class Solution3 : public Solution { | |
public: | |
using Point = std::pair<int, int>; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--------------------- | |
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 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// 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. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/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: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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) |