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
/usr/lib/gcc/x86_64-linux-gnu/7/collect2 | |
-plugin | |
/usr/lib/gcc/x86_64-linux-gnu/7/liblto_plugin.so | |
-plugin-opt=/usr/lib/gcc/x86_64-linux-gnu/7/lto-wrapper | |
-plugin-opt=-fresolution=/tmp/cc1vmx7H.res | |
-plugin-opt=-pass-through=-lgcc_s | |
-plugin-opt=-pass-through=-lgcc | |
-plugin-opt=-pass-through=-lc | |
-plugin-opt=-pass-through=-lgcc_s | |
-plugin-opt=-pass-through=-lgcc |
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
diff --git a/gdb/cli/cli-cmds.c b/gdb/cli/cli-cmds.c | |
index 2a5b128d56..618640cffe 100644 | |
--- a/gdb/cli/cli-cmds.c | |
+++ b/gdb/cli/cli-cmds.c | |
@@ -1710,6 +1710,11 @@ void | |
_initialize_cli_cmds (void) | |
{ | |
struct cmd_list_element *c; | |
+ /* Called more than once due to ordering dependencies. */ | |
+ static bool initialized = false; |
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
/int-str |
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 give_me_a_switch(args): | |
sense = False | |
for a in args: | |
switch a: | |
case '+': | |
sense = True | |
case '-': | |
sense = False | |
case 'a': | |
a.x = sense |
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
class via_data: | |
def __init__(self, name=None): | |
# name can be None for python 3.6 | |
self.name = name | |
def __get__(self, instance, owner): | |
if instance is not None: | |
assert self.name is not None, 'name not specified' | |
return instance.data[self.name] | |
return self | |
def __set_name__(self, owner, 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
#!/bin/sh | |
# For repositories cloned using `git-remote-bzr` (the official one), | |
# convert a git commit hash to the bzr hash *and* revno. | |
set -e | |
die() | |
{ | |
printf '%s\n' "$1" >&2 | |
exit 1 | |
} |
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
# This script is sourced from all over the place to fix broken shells. | |
# It does assume you have at *least* /usr/bin:/bin though. | |
# Significant care is taken to be sh-compatible; if bash or zsh could be | |
# required, it could be made simpler or more generic. | |
has_PATH () { | |
local tmp=":$PATH:" | |
[ "${tmp}" != "${tmp#*:$1:}" ] | |
} |
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
import os | |
import pycurl | |
from tqdm import tqdm | |
downloader = pycurl.Curl() | |
def sanitize(c): | |
c.setopt(pycurl.UNRESTRICTED_AUTH, False) |
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
import functools | |
def self_aware(f): | |
@functools.wraps(f) | |
def aware_f(*args, aware=False, **kwargs): | |
rv = f(*args, **kwargs) | |
if not aware: | |
# If the function ever might *legitimately* return a callable, | |
# use a dedicated wrapper type. |