
c++ c plus plus
tmjdone
这个作者很懒,什么都没留下…
展开
-
c++ boost regex 表达式书写问题
regex r("^s");string x="start";smatch m;regex_match(x,m,r) 就是匹配不成功,郁闷了半天(真的半天...),发现表达式要这么写:regex r=("^s.*");以前perl的用惯了..../^s/ 郁闷,估计是没仔细看文档说明的效果吧,呵呵,改天好好看下说明。原创 2010-04-15 01:29:00 · 366 阅读 · 0 评论 -
hash_map[转]
hash_map (C++)From Wikipedia, the free encyclopediaJump to: navigation, searchIn C++ computer programming, hash_map is the name of a hashed associative container in the Standar转载 2010-04-21 11:15:00 · 518 阅读 · 0 评论 -
使用GProf来优化你的 C/C++程序
源地址:http://dev.youkuaiyun.com/article/81/81317.shtmProfiling in a nutshell程序概要分析的概念非常简单:通过记录各个函数的调用和结束时间,我们可以计算出程序的最大运行时的程序段。这种方法听起来似乎要花费很多气力——幸运的是,我们其实离真理并不远!我们只需要在用 gcc编译时加上一个额外的参数(-pg转载 2010-04-21 10:52:00 · 401 阅读 · 0 评论 -
linux sound recording
cpp source file: #include #include #include #define ALSA_PCM_NEW_HW_PARAMS_API#define debug 0void printBuffer(unsigned char* buf,int size){ printf("print buffer(%d):/n",size); in原创 2011-06-22 22:19:00 · 762 阅读 · 0 评论 -
target: alignment with features
to be filled原创 2011-06-28 21:56:00 · 311 阅读 · 0 评论 -
c++里调用 perl 子过程(函数)
<br />test.cpp:<br />#include <perl++/perl++.h> #include <perl++/lambda.h> #include <tap++/tap++.h> //#include <algorithm> //#include <limits> #include <cstdlib> #include <cstring> #include <ctime> #include <cstdio> #include <iostream> /* #incl原创 2011-05-11 12:50:00 · 1801 阅读 · 0 评论 -
linux gcc static dynamic linked compiling
src:http://www.yolinux.com/TUTORIALS/LibraryArchives-StaticAndDynamic.html gcc object1.o object2.o -Wl,-Bstatic -lapplejuice -Wl,-Bdynamic转载 2011-08-16 13:44:29 · 1923 阅读 · 0 评论 -
c++ read gzip
aoeu #include #include #include #include #include #include #include using namespace std; using namespace boost::iostreams; int main(int argc,char* argv[]){ for(int i=1;i<argc;i++){ pri转载 2012-01-13 15:52:10 · 2665 阅读 · 0 评论