This file contains hidden or 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
find . -type f -regextype posix-egrep -regex '.*\.pm|.*\.c|.*\.h|.*\.xs' ! -regex '\./\.git/|.*ppport\.h' | while read fname; do perl -ne 'print unless /^=h/ .. /^=cut/' < $fname; done | sed '/^$/d;/^#/d' | wc -l |
This file contains hidden or 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
use LWP::UserAgent; | |
use Time::HiRes; | |
use strict; | |
my $ua = LWP::UserAgent->new(); | |
my $start = Time::HiRes::time(); | |
my $maxbytes = 1024*1024; | |
my $curspeed = 0; | |
my $received_bytes = 0; |
This file contains hidden or 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 <QDebug> | |
#include <QSqlDatabase> | |
#include <QSqlQuery> | |
#include <QString> | |
#include <QSqlError> | |
#include <QVariant> | |
int main() | |
{ | |
QSqlDatabase db = QSqlDatabase::addDatabase("QIBASE"); |
This file contains hidden or 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
use autodie; | |
use Fcntl qw(SEEK_SET); | |
use strict; | |
use warnings; | |
my ($in1, $in2, $ot) = @ARGV; | |
die "usage: $0 input1 input2 output" | |
unless defined $in1 && defined $in2 && defined $ot; | |
open IN1, '<:urf8', $in1; |
This file contains hidden or 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
<?php | |
class Ax { | |
public $super; | |
function __construct() { | |
$this->super = "super"; | |
$GLOBALS['super'] = &$this->super; | |
} | |
This file contains hidden or 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 <xlslib.h> | |
#include <vector> | |
#include <string> | |
#include <iostream> | |
#include <fstream> | |
#include <ctime> | |
using namespace xlslib_core; | |
using namespace std; |
This file contains hidden or 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
BEGIN { | |
$ENV{PERL_ANYEVENT_MAX_OUTSTANDING_DNS} = 30; | |
} | |
use strict; | |
use Coro::LWP; | |
use Coro; | |
use LWP; | |
my @coros; | |
for (1..30) { |
This file contains hidden or 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
BEGIN { | |
$ENV{SOCKS_DEBUG} = 1; | |
} | |
use IO::Socket::Socks::Wrapper ( | |
Net::FTP => { | |
ProxyAddr => 'localhost', | |
ProxyPort => 1080, | |
SocksVersion => 5 | |
}, | |
Net::FTP::dataconn => { |
This file contains hidden or 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
use strict; | |
use URI; | |
use HTTP::Request; | |
use IO::Lambda qw(:all); | |
use IO::Lambda::HTTP qw(http_request); | |
sub request($) { | |
my $url = URI->new($_[0]); | |
my $req = HTTP::Request->new(GET => $url, [Host => $url->host]); | |
$req->protocol('HTTP/1.1'); |
This file contains hidden or 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
use strict; | |
use warnings; | |
use AnyEvent::Google::PageRank 'rank_get'; | |
my $cv = AE::cv; | |
rank_get 'http://www.google.ru', sub { | |
print shift, "\n"; | |
$cv->send; | |
}; | |
$cv->recv; |
OlderNewer