Many programmers code by instinct, relying on convenient habits or a "style" they picked up early on. They aren't conscious of all the choices they make, like how they format their source, the names they use for variables, or the kinds of loops they use. They're focused entirely on problems they're solving, solutions they're creating, and algorithms they're implementing. So they write code in the way that seems natural, that happens intuitively, and that feels good. But if you're serious about your profession, intuition isn't enough. Perl Best Practices author Damian Conway explains that rules, conventions, standards, and practices not only help programmers communicate and coordinate with one another, they also provide a reliable framework for thinking about problems, and a common language for expressing solutions. This is especially critical in Perl, because the language is designed to offer many ways to accomplish the same task, and consequently it supports many incompatible dialects. With a good dose of Aussie humor, Dr. Conway (familiar to many in the Perl community) offers 256 guidelines on the art of coding to help you write better Perl code--in fact, the best Perl code you possibly can. The guidelines cover code layout, naming conventions, choice of data and control structures, program decomposition, interface design and implementation, modularity, object orientation, error handling, testing, and debugging. They're designed to work together to produce code that is clear, robust, efficient, maintainable, and concise, but Dr. Conway doesn't pretend that this is the one true universal and unequivocal set of best practices. Instead, Perl Best Practices offers coherent and widely applicable suggestions based on real-world experience of how code is actually written, rather than on someone's ivory-tower theories on how software ought to be created. Most of all, Perl Best Practices offers guidelines that actually work, and that many developers around the world are already using. Much like Perl itself, these guidelines are about helping you to get your job done, without getting in the way. Praise for Perl Best Practices from Perl community members: "As a manager of a large Perl project, I'd ensure that every member of my team has a copy of Perl Best Practices on their desk, and use it as the basis for an in-house style guide." -- Randal Schwartz "There are no more excuses for writing bad Perl programs. All levels of Perl programmer will be more productive after reading this book." -- Peter Scott "Perl Best Practices will be the next big important book in the evolution of Perl. The ideas and practices Damian lays down will help bring Perl out from under the embarrassing heading of "scripting languages". Many of us have known Perl is a real programming language, worthy of all the tasks normally delegated to Java and C++. With Perl Best Practices, Damian shows specifically how and why, so everyone else can see, too." -- Andy Lester "Damian's done what many thought impossible: show how to build large, maintainable Perl applications, while still letting Perl be the powerful, expressive language that programmers have loved for years." -- Bill Odom "Finally, a means to bring lasting order to the process and product of real Perl development teams." -- Andrew Sundstrom"Perl Best Practices provides a valuable education in how to write robust, maintainable Perl, and is a definitive citation source when coaching other programmers." -- Bennett Todd "I've been teaching Perl for years, and find the same question keeps being asked: Where can I find a reference for writing reusable, maintainable Perl code? Finally I have a decent answer." -- Paul Fenwick "At last a well researched, well thought-out, comprehensive guide to Perl style. Instead of each of us developing our own, we can learn good practices from one of Perl's most prolific and experienced authors. I recommend this book to anyone who prefers getting on with the job rather than going back and fixing errors caused by syntax and poor style issues." -- Jacinta Richardson "If you care about programming in any language read this book. Even if you don't intend to follow all of the practices, thinking through your style will improve it." -- Steven Lembark "The Perl community's best author is back with another outstanding book. There has never been a comprehensive reference on high quality Perl coding and style until Perl Best Practices. This book fills a large gap in every Perl bookshelf." -- Uri Guttman
2023-05-03 22:46:17 7.68MB Perl最佳实践
1
Perl最佳实践中文版,并带有各章节目录。
2022-08-30 20:10:22 41.34MB Perl 最佳实践 目录
1
许多程序员凭直觉来编程,这些直觉来自于他们早期养成的习惯和风格。这样写出的程序似乎自然、直观,而且看起来也很不错。但是,如果你想严肃地对待程序员这份职业,那么直觉就远远不够了。《Perl最佳实践》讲述了许多关于Perl语言的编程规则、使用惯例、开发标准和最佳实践,这些内容不仅有助于程序员之间的交流和协同工作,同时也提供了一套思考问题的可靠框架和一种表述解决方案的通用语言。   通过生动幽默的表达,作者Damian Conway为Perl编程人员提供了关于编程艺术的256条规则,这些规则能帮助你编写出更好的Perl代码。这些规则涵盖了代码布局和命名规则,数据和控制结构的选择,程序解构和模块化,接口的设计和实现,面向对象设计,错误处理、程序测试和调试。   本书中所有的规则都是为了写出清晰、健壮、高效、可维护和简洁的程序而设计。Conway博士并不自诩这些规则是最广泛和最清晰的实践集,但实际上,本书确实提供了在实践中被广泛认可和应用的建议,而不是象牙塔似的编程理论。   最特别的是,《Perl最佳实践》提供的规则是实在有效的,世界各地的开发人员已经普遍使用。像Perl语言的初衷一样,这些规则将使你的开发更加出色 前言 第一章 最佳实战  三个目标  改变习惯 第二章 代码部署  括号方式  关键字  子程序和变量  内置函数  键和索引  运算符  分号  逗号  代码行的长度  缩排  制表符  块  组块  Else  垂直对齐  断开长行  非末端表达式  按优先级断开  赋值运算  三元运算符  列表  自动化部署 第三章 命名惯例 标识符 布尔值 引用变量 数组和散列 下划线 大小写 缩写 模糊的缩写 模糊的名称 实用子程序 第四章 值和表达式 字符串定界符 空字符串 单字符字符串 转义字符  …… 第五章 变量 第六章 控制结构 第七章 说明文档 第八章 内置函数 第九章 子程序 第十章 I/O 第十一章 引用 第十二章 正则表达式 第十三章 错误处理 第十四章 命令行处理 第十五章 对象 第十六章 类层次 第十七章 模块 第十八章 测试和调试 第十九章 其他主题 附录一 Perl基本的最佳实践 附录二 Perl最佳实践 附录三 编辑器配置 附录四 推荐的模块和实用程序 附录五 参考文献
2021-07-19 16:25:26 23.01MB Perl最佳实践(高清PDF中文版)
1