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 | |
# Configurations | |
player=mplayer | |
playlisturl='http://comic.sjtu.edu.cn/vlc/pl_xspf.asp' | |
TMPDIR=$(mktemp -d) | |
cd $TMPDIR | |
cat > comic-vlc.xslt <<EOF |
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 {Writable} from "stream"; | |
// scanner returns remaining string if succeeded, null/undefined otherwise | |
class ScanningState { | |
constructor(buf, scanner) { | |
this.buf = buf; | |
this.scanner = scanner; | |
} | |
scan() { | |
throw new Error("Another scan in progress"); |
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
44022 silly gunzTarPerm modified mode [ 'lib/dependencies/RequireResolveDependency.js', 438, 420 ] | |
44023 silly gunzTarPerm extractEntry library/es7/array.js | |
44024 silly gunzTarPerm modified mode [ 'library/es7/array.js', 438, 420 ] | |
44025 silly gunzTarPerm extractEntry library/es7/index.js | |
44026 silly gunzTarPerm modified mode [ 'library/es7/index.js', 438, 420 ] | |
44027 silly gunzTarPerm extractEntry node_modules/npmlog/node_modules/gauge/node_modules/lodash.padleft/node_modules/lodash._createpadding/index.js | |
44028 silly gunzTarPerm extractEntry node_modules/npmlog/node_modules/gauge/node_modules/lodash.padleft/node_modules/lodash._createpadding/node_modules/lodash.repeat/package.json | |
44029 silly gunzTarPerm extractEntry node_modules/node-pre-gyp/node_modules/request/node_modules/mime/types/mime.types | |
44030 silly gunzTarPerm extractEntry node_modules/node-pre-gyp/node_modules/request/node_modules/mime/types/node.types | |
44031 silly gunzTarPerm extractEntry features-json/midi.json |
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
macro DO { | |
rule { ($name:ident <- $expr:expr, ret($any...)) } => { ($expr).map($name => ($any...)) } | |
rule { ($name:ident <- $expr:expr, $any...) } => { ($expr).chain($name => DO($any...))} | |
rule { ($expr:expr, ret($any...)) } => { ($expr).map(() => ($any...)) } | |
rule { ($expr:expr, $any...) } => { ($expr).chain(() => DO($any...)) } | |
rule { ($expr:expr) } => { ($expr) } | |
} | |
export DO; |
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
namespace tuple_util_impl { | |
template <size_t... i, class Function, class Tuple> | |
auto spread_call(std::index_sequence<i...>, Function f, Tuple&& t) | |
-> decltype(f(std::get<i>(t)...)) | |
{ | |
return f(std::get<i>(t)...); | |
} |
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 <string> | |
#include <algorithm> | |
#include <chrono> | |
#include <iostream> | |
#include "crc-32.hh" | |
std::chrono::duration<unsigned long long, std::micro> | |
constexpr operator""_us(unsigned long long x) | |
{ |
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
auto x = ([](Dependency a) { | |
Foo f(a); | |
Bar b(a); | |
return f+b; | |
})({}); | |
long_computation(x); |
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 <iostream> | |
#include "output-iterator-adaptor.hh" | |
#include "map.hh" | |
int main() | |
{ | |
auto f = [](auto x) { return x+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
#include <cstddef> | |
#include <string> | |
#include <memory> | |
#include <type_traits> | |
#include <vector> | |
#include <iostream> | |
#include <cassert> | |
template <class Char, class Traits=std::char_traits<Char>, |
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 <type_traits> | |
#include <iostream> | |
int f(const int&) | |
{ | |
return 1; | |
} | |
int f(int&&) | |
{ |
OlderNewer