<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/"><channel><title>草木瓜 - C++/C/C#</title><link>http://blog.csdn.net/liwei_cmg/category/207528.aspx</link><description /><dc:language>zh-CN</dc:language><lastUpdateTime>Mon, 15 Sep 2008 08:38:00 GMT</lastUpdateTime><ttl>60</ttl><item><dc:creator>草木瓜</dc:creator><title>网络编程概念全面接触(四).C++与Java的实现</title><link>http://blog.csdn.net/liwei_cmg/archive/2008/02/16/2099719.aspx</link><pubDate>Sat, 16 Feb 2008 18:02:00 GMT</pubDate><guid>http://blog.csdn.net/liwei_cmg/archive/2008/02/16/2099719.aspx</guid><wfw:comment>http://blog.csdn.net/liwei_cmg/comments/2099719.aspx</wfw:comment><comments>http://blog.csdn.net/liwei_cmg/archive/2008/02/16/2099719.aspx#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://blog.csdn.net/liwei_cmg/comments/commentRss/2099719.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=2099719</trackback:ping><description>前一阵子遇到网络通信方面的东西，感觉总结还是十分必要的。这里给出一些新的补充。
本示例采用C++方式。

一、Socket.h 头文件

#ifndef SOCKET_H
#define SOCKET_H

#include 
#include 
&lt;img src ="http://blog.csdn.net/liwei_cmg/aggbug/2099719.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>草木瓜</dc:creator><title>Lex和Yacc使用教程(九).Windows下使用Lex和Yacc</title><link>http://blog.csdn.net/liwei_cmg/archive/2007/09/06/1774665.aspx</link><pubDate>Thu, 06 Sep 2007 14:21:00 GMT</pubDate><guid>http://blog.csdn.net/liwei_cmg/archive/2007/09/06/1774665.aspx</guid><wfw:comment>http://blog.csdn.net/liwei_cmg/comments/1774665.aspx</wfw:comment><comments>http://blog.csdn.net/liwei_cmg/archive/2007/09/06/1774665.aspx#Feedback</comments><slash:comments>1</slash:comments><wfw:commentRss>http://blog.csdn.net/liwei_cmg/comments/commentRss/1774665.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=1774665</trackback:ping><description>    不想Lex和Yacc系列的最后一篇文章竟如此“难产”，已时隔三个月之久。不由慨叹自由可支
配时间是如此之少，如此岂不谓新时代的“奴隶”~
    罢罢罢，闲话少叙，回归正题，本文主要介绍在Windows下如何去使用Lex和Yacc，以作为
本系列文章的终结。&lt;img src ="http://blog.csdn.net/liwei_cmg/aggbug/1774665.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>草木瓜</dc:creator><title>Lex和Yacc入门教程(八).使用堆栈编译语法</title><link>http://blog.csdn.net/liwei_cmg/archive/2007/06/05/1638779.aspx</link><pubDate>Tue, 05 Jun 2007 11:08:00 GMT</pubDate><guid>http://blog.csdn.net/liwei_cmg/archive/2007/06/05/1638779.aspx</guid><wfw:comment>http://blog.csdn.net/liwei_cmg/comments/1638779.aspx</wfw:comment><comments>http://blog.csdn.net/liwei_cmg/archive/2007/06/05/1638779.aspx#Feedback</comments><slash:comments>23</slash:comments><wfw:commentRss>http://blog.csdn.net/liwei_cmg/comments/commentRss/1638779.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=1638779</trackback:ping><description>一、序

    前面一些系列文章着重介绍了递归语法树在编译理论方面的应用。本文则会介绍另一种
实现方式----堆栈。  
    堆栈在底层系统有十分广泛的应用，同样也十分擅长处理语法结构，这里通过实际示例
探讨如何构造堆栈完成语法分析。

    重要补充：下面是本系列文章全示例代码统一的调试测试环境，另对于lex,yacc文件需
要存储为Unix格式，这一点和Linux，Unix下shell很类似，DOS格式的Shell是不能够被执行
的，同样bison,lex编译DOS格式文件会出错误提示：
    
    Red Hat Linux release 9 (Shrike)
    Linux 2.4.20-8 
    gcc version 3.2.2 20030222
    bison (GNU Bison) 1.35
    lex version 2.5.4
    flex version 2.5.4
&lt;img src ="http://blog.csdn.net/liwei_cmg/aggbug/1638779.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>草木瓜</dc:creator><title>Lex和Yacc使用方法(七).企业方面的实际应用</title><link>http://blog.csdn.net/liwei_cmg/archive/2007/05/28/1628419.aspx</link><pubDate>Mon, 28 May 2007 16:46:00 GMT</pubDate><guid>http://blog.csdn.net/liwei_cmg/archive/2007/05/28/1628419.aspx</guid><wfw:comment>http://blog.csdn.net/liwei_cmg/comments/1628419.aspx</wfw:comment><comments>http://blog.csdn.net/liwei_cmg/archive/2007/05/28/1628419.aspx#Feedback</comments><slash:comments>2</slash:comments><wfw:commentRss>http://blog.csdn.net/liwei_cmg/comments/commentRss/1628419.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=1628419</trackback:ping><description>    说到这里，也许有人觉得要把这些东西实际应用起来，还没谱，或许很多人觉得工作中很
少能使用到。
    本文的主要目的就是为了详细说明下实际的企业应用示例。示例基于《Lex和Yacc应用方
法(五).再识语法树》&lt;img src ="http://blog.csdn.net/liwei_cmg/aggbug/1628419.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>草木瓜</dc:creator><title>Lex和Yacc使用教程(六).语法树打印</title><link>http://blog.csdn.net/liwei_cmg/archive/2007/05/25/1626133.aspx</link><pubDate>Fri, 25 May 2007 21:29:00 GMT</pubDate><guid>http://blog.csdn.net/liwei_cmg/archive/2007/05/25/1626133.aspx</guid><wfw:comment>http://blog.csdn.net/liwei_cmg/comments/1626133.aspx</wfw:comment><comments>http://blog.csdn.net/liwei_cmg/archive/2007/05/25/1626133.aspx#Feedback</comments><slash:comments>2</slash:comments><wfw:commentRss>http://blog.csdn.net/liwei_cmg/comments/commentRss/1626133.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=1626133</trackback:ping><description>  没有直观的语法树显示界面，理解前面两篇文章会比较难一些。(语法树的示例见
《Lex和Yacc应用教程(四).语法树的应用》) 其实语法树显示程序在Tom Niemann的
《A Compact Guide to Lex &amp; Yacc》文中已有完整的示例，不过我很不喜欢，也许
是无法适应别人的代码习惯吧，这里针对《Lex和Yacc应用方法(五).再识语法树》，
完全重写了打印语法树的程序代码。我不敢说算法有多高明，起码十分便于理解和掌握。&lt;img src ="http://blog.csdn.net/liwei_cmg/aggbug/1626133.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>草木瓜</dc:creator><title>Lex和Yacc使用教程(五).再识语法树</title><link>http://blog.csdn.net/liwei_cmg/archive/2007/05/25/1626129.aspx</link><pubDate>Fri, 25 May 2007 21:26:00 GMT</pubDate><guid>http://blog.csdn.net/liwei_cmg/archive/2007/05/25/1626129.aspx</guid><wfw:comment>http://blog.csdn.net/liwei_cmg/comments/1626129.aspx</wfw:comment><comments>http://blog.csdn.net/liwei_cmg/archive/2007/05/25/1626129.aspx#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://blog.csdn.net/liwei_cmg/comments/commentRss/1626129.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=1626129</trackback:ping><description>  在《Lex和Yacc应用教程(四).语法树》一文已对语法树有了初步的概念，本文主要目的
是巩固语法树的概念，并做进一步的扩展分析。闲说少说，首先给出完整示例，本例在Redhat Linux 9
下调试通过，可放心使用。
    另外系列文章的标题，有的叫“lex和yacc应用方法”，有的叫“lex和yacc应用教程”,
还有的叫“lex和yacc使用教程”等等，概念都是一样的。之所以起这么多名字是便于大家通
过搜索引擎能迅速查到。&lt;img src ="http://blog.csdn.net/liwei_cmg/aggbug/1626129.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>草木瓜</dc:creator><title>Lex和Yacc应用教程(四).语法树的应用</title><link>http://blog.csdn.net/liwei_cmg/archive/2007/05/21/1618822.aspx</link><pubDate>Mon, 21 May 2007 10:17:00 GMT</pubDate><guid>http://blog.csdn.net/liwei_cmg/archive/2007/05/21/1618822.aspx</guid><wfw:comment>http://blog.csdn.net/liwei_cmg/comments/1618822.aspx</wfw:comment><comments>http://blog.csdn.net/liwei_cmg/archive/2007/05/21/1618822.aspx#Feedback</comments><slash:comments>1</slash:comments><wfw:commentRss>http://blog.csdn.net/liwei_cmg/comments/commentRss/1618822.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=1618822</trackback:ping><description>    不论什么语言，语法结构总是那几种，可以想象任何程序体都可以解释成一棵语法
树，语法树的本质是递归，很显然Yacc文法的核心思想也是递归。本文就通过具体实例，
使用Yacc构建递归的语法树来解决实际问题。
    比较遗憾的是，在总结的过程中想表达清楚并不容易，估且三分言传，七分会意吧。
关键在于个人去思考。&lt;img src ="http://blog.csdn.net/liwei_cmg/aggbug/1618822.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>草木瓜</dc:creator><title>Lex和Yacc应用教程(三).使用变量</title><link>http://blog.csdn.net/liwei_cmg/archive/2007/05/14/1609064.aspx</link><pubDate>Mon, 14 May 2007 22:25:00 GMT</pubDate><guid>http://blog.csdn.net/liwei_cmg/archive/2007/05/14/1609064.aspx</guid><wfw:comment>http://blog.csdn.net/liwei_cmg/comments/1609064.aspx</wfw:comment><comments>http://blog.csdn.net/liwei_cmg/archive/2007/05/14/1609064.aspx#Feedback</comments><slash:comments>15</slash:comments><wfw:commentRss>http://blog.csdn.net/liwei_cmg/comments/commentRss/1609064.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=1609064</trackback:ping><description>早在两个月前就想对Lex和Yacc作系列的阐述，然而工作的事情实在太多，很难抽出空
静下心去总结学习。不觉感慨国内工作环境恶劣，加班是家常便饭，整天基本都是在做
一些简单大量的重复，甚至徒劳无用。

在《初识Lex》一文中主要从入门角度总结了Lex，《再识Lex和Yacc》一文在可以简单
使用Lex情况基础，介绍了Lex和Yacc的算法理论，并说明如何将Lex和Yacc结合起来使
用。

这里我们需要对Lex和Yacc使用方法做进一步研究，以备能理解后面会引入的语法树。
&lt;img src ="http://blog.csdn.net/liwei_cmg/aggbug/1609064.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>草木瓜</dc:creator><title>Lex和Yacc应用方法(二).再识Lex与Yacc</title><link>http://blog.csdn.net/liwei_cmg/archive/2007/03/16/1530999.aspx</link><pubDate>Fri, 16 Mar 2007 10:19:00 GMT</pubDate><guid>http://blog.csdn.net/liwei_cmg/archive/2007/03/16/1530999.aspx</guid><wfw:comment>http://blog.csdn.net/liwei_cmg/comments/1530999.aspx</wfw:comment><comments>http://blog.csdn.net/liwei_cmg/archive/2007/03/16/1530999.aspx#Feedback</comments><slash:comments>5</slash:comments><wfw:commentRss>http://blog.csdn.net/liwei_cmg/comments/commentRss/1530999.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=1530999</trackback:ping><description>早在二十世记七十年代之前，编写编译器一直是一个非常费时的工作。但到了1975这
一年这一切却发生了重大转变，首先Stephen C. Johnson Lesk在贝尔实验室完成了
Yacc开发，为了配合yacc更好的协作, Mike Lesk和Eric Schmidt又完成了lex。从
而Lex和yacc成为计算机编译领域的重要理论，而这些工具也极大地简化了编写编译
器的工作。&lt;img src ="http://blog.csdn.net/liwei_cmg/aggbug/1530999.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>草木瓜</dc:creator><title>Lex和Yacc应用方法(一).初识Lex</title><link>http://blog.csdn.net/liwei_cmg/archive/2007/03/15/1530492.aspx</link><pubDate>Thu, 15 Mar 2007 17:23:00 GMT</pubDate><guid>http://blog.csdn.net/liwei_cmg/archive/2007/03/15/1530492.aspx</guid><wfw:comment>http://blog.csdn.net/liwei_cmg/comments/1530492.aspx</wfw:comment><comments>http://blog.csdn.net/liwei_cmg/archive/2007/03/15/1530492.aspx#Feedback</comments><slash:comments>10</slash:comments><wfw:commentRss>http://blog.csdn.net/liwei_cmg/comments/commentRss/1530492.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=1530492</trackback:ping><description>Lex(Lexical Analyzar 词法分析生成器)，Yacc(Yet Another Compiler Compiler
编译器代码生成器)是Unix下十分重要的词法分析，语法分析的工具。经常用于语言分
析，公式编译等广泛领域。遗憾的是网上中文资料介绍不是过于简单，就是跳跃太大，
入门参考意义并不大。本文通过循序渐进的例子，从0开始了解掌握Lex和Yacc的用法。&lt;img src ="http://blog.csdn.net/liwei_cmg/aggbug/1530492.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>草木瓜</dc:creator><title>网络编程概念全面接触(三)</title><link>http://blog.csdn.net/liwei_cmg/archive/2006/08/06/1027925.aspx</link><pubDate>Sun, 06 Aug 2006 13:47:00 GMT</pubDate><guid>http://blog.csdn.net/liwei_cmg/archive/2006/08/06/1027925.aspx</guid><wfw:comment>http://blog.csdn.net/liwei_cmg/comments/1027925.aspx</wfw:comment><comments>http://blog.csdn.net/liwei_cmg/archive/2006/08/06/1027925.aspx#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://blog.csdn.net/liwei_cmg/comments/commentRss/1027925.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=1027925</trackback:ping><description>写文章真累，写好文章更是很累，怪不得大家都喜欢贴来贴去，或者稍加修改罢了。网络编程这块是老生常谈，个人觉得《Beej网络socket编程指南》算是经典了。网上一搜一大堆，这里也顺应大流，不写了，贴一下。下面给出一个网络交互的完整示例，在HP UNIX编译调试通过！对照以前的网络概念，还有经典的文章就应该很清楚了。&lt;img src ="http://blog.csdn.net/liwei_cmg/aggbug/1027925.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>草木瓜</dc:creator><title>（转贴）网络编程指南  Beej</title><link>http://blog.csdn.net/liwei_cmg/archive/2006/08/03/1014170.aspx</link><pubDate>Thu, 03 Aug 2006 11:15:00 GMT</pubDate><guid>http://blog.csdn.net/liwei_cmg/archive/2006/08/03/1014170.aspx</guid><wfw:comment>http://blog.csdn.net/liwei_cmg/comments/1014170.aspx</wfw:comment><comments>http://blog.csdn.net/liwei_cmg/archive/2006/08/03/1014170.aspx#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://blog.csdn.net/liwei_cmg/comments/commentRss/1014170.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=1014170</trackback:ping><description>写文章真累，写好文章更是很累，怪不得大家都喜欢贴来贴去，或者稍加修改罢了。网络编程这块是老生常谈，个人觉得《Beej网络socket编程指南》算很经典了。网上一搜一大堆，这里也顺应大流，不写了，贴一下。&lt;img src ="http://blog.csdn.net/liwei_cmg/aggbug/1014170.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>草木瓜</dc:creator><title>字节顺序的详细解释</title><link>http://blog.csdn.net/liwei_cmg/archive/2006/07/26/980278.aspx</link><pubDate>Wed, 26 Jul 2006 13:53:00 GMT</pubDate><guid>http://blog.csdn.net/liwei_cmg/archive/2006/07/26/980278.aspx</guid><wfw:comment>http://blog.csdn.net/liwei_cmg/comments/980278.aspx</wfw:comment><comments>http://blog.csdn.net/liwei_cmg/archive/2006/07/26/980278.aspx#Feedback</comments><slash:comments>3</slash:comments><wfw:commentRss>http://blog.csdn.net/liwei_cmg/comments/commentRss/980278.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=980278</trackback:ping><description>字节顺序的详细解释

草木瓜 2006.7.26

一、基本概念

位的概念：在计算机中，一个0或1称为一位(bit)。

字节：连续的八位称为一个字节(Byte)，字节是计算机中可单独处理的最小单位。即以字节
为基本单位来解释信息，规定1个字节是8个二进制位。

通常1个ASCII码用1个字节存放，1个汉字用2个字节存放，双精度浮点实数用8个字节存放。
下面列表C语言中定义类型所占字节以及数据范围。
&lt;img src ="http://blog.csdn.net/liwei_cmg/aggbug/980278.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>草木瓜</dc:creator><title>转贴GDB的详细用法</title><link>http://blog.csdn.net/liwei_cmg/archive/2006/07/24/967657.aspx</link><pubDate>Mon, 24 Jul 2006 09:32:00 GMT</pubDate><guid>http://blog.csdn.net/liwei_cmg/archive/2006/07/24/967657.aspx</guid><wfw:comment>http://blog.csdn.net/liwei_cmg/comments/967657.aspx</wfw:comment><comments>http://blog.csdn.net/liwei_cmg/archive/2006/07/24/967657.aspx#Feedback</comments><slash:comments>2</slash:comments><wfw:commentRss>http://blog.csdn.net/liwei_cmg/comments/commentRss/967657.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=967657</trackback:ping><description>这篇文章是GDB入门提高的很有价值的参考文章，很难得是比较系统！只是在文章组织上，细节的处理上还稍有些不足。&lt;img src ="http://blog.csdn.net/liwei_cmg/aggbug/967657.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>草木瓜</dc:creator><title>C.C++很不错的系列文章</title><link>http://blog.csdn.net/liwei_cmg/archive/2006/07/11/904010.aspx</link><pubDate>Tue, 11 Jul 2006 09:39:00 GMT</pubDate><guid>http://blog.csdn.net/liwei_cmg/archive/2006/07/11/904010.aspx</guid><wfw:comment>http://blog.csdn.net/liwei_cmg/comments/904010.aspx</wfw:comment><comments>http://blog.csdn.net/liwei_cmg/archive/2006/07/11/904010.aspx#Feedback</comments><slash:comments>1</slash:comments><wfw:commentRss>http://blog.csdn.net/liwei_cmg/comments/commentRss/904010.aspx</wfw:commentRss><trackback:ping>http://tb.blog.csdn.net/TrackBack.aspx?PostId=904010</trackback:ping><description>C.C++很不错的系列文章，含Windows编程&lt;img src ="http://blog.csdn.net/liwei_cmg/aggbug/904010.aspx" width = "1" height = "1" /&gt;</description></item></channel></rss>