![]() |
|
Your skill will accomplish what the force of many cannot |
|
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
{from an alt.perl post I just made, reposted here to solicit feedback from fellow monks...}
Perl is extremely difficult to parse. In fact, some would say impossible. One thing that makes it difficult is the dual nature of a half dozen characters like "/". If that / is being used in a place that's expecting an operator, it's divide. If it's being used in a place that's expecting an operand, it's the beginning of a regular expression. So you have to keep track at all times of whether you're looking for an operator or an operand. "No problem", you say? Quick... for the following, play the game of "regex or divide?" Got those right? How about these? OK, and now some of your own: Got those too? How about these (same problem, different file): A little harder, eh? So now you have to parse OUTSIDE the file to get your answer. And as if that wasn't enough, let's get weird: Quick, was that last one a divide or a regex start? Why does it matter? Look at this: The first one is computing the sin of the true/false value gotten by matching " 25 ; # " against $_. Then it dies. The second one is computing the time of day divided by 25, then ignoring the comment. Starting to see the trouble? This leads people to say "the only thing which can parse Perl (the language) is perl (the binary)". Maybe not for Perl6. But for the Perl we know and can use today, certainly so. -- Randal L. Schwartz, Perl hacker In reply to On Parsing Perl by merlyn
|
|
打鼾挂什么科 | 烁字五行属什么 | 尿维生素c弱阳性是什么意思 | 多愁善感什么意思 | 假借是什么意思 |
身不由己是什么生肖 | 汗多是什么原因 | 快递客服主要做什么 | 结节性硬化症是什么病 | 漏斗胸为什么长不胖 |
抗宫炎软胶囊主要治什么 | 50分贝相当于什么声音 | 父亲节送什么好 | 经常低血糖是什么原因 | 长春有什么好吃的 |
下午18点是什么时辰 | gopro是什么 | 血管硬化吃什么能软化 | 狼入虎口是什么意思 | 公卿是什么意思 |
死鬼什么意思hcv8jop0ns2r.cn | 西兰花和什么菜搭配hcv7jop6ns1r.cn | 吃三七有什么功效hcv8jop4ns3r.cn | 鸭屎香为什么叫鸭屎香imcecn.com | 宫腔占位什么意思baiqunet.com |
淋巴细胞百分比偏高是什么意思hcv8jop5ns5r.cn | 蓓字五行属什么shenchushe.com | 头发是什么组织hcv8jop6ns8r.cn | 疱疹是一种什么病hcv9jop6ns8r.cn | 女生下体长什么样子hcv9jop0ns0r.cn |
炁是什么意思hcv8jop5ns3r.cn | 早上八点到九点属于什么时辰hcv8jop7ns1r.cn | 总胆固醇低是什么原因hcv9jop6ns6r.cn | 现在是什么季节hcv9jop6ns7r.cn | 肺部感染有什么症状xinmaowt.com |
尿蛋白阴性是什么意思cl108k.com | 什么路最窄打一生肖hcv7jop5ns2r.cn | 牛属相和什么属相配hcv9jop0ns8r.cn | 降尿酸吃什么药hcv7jop4ns5r.cn | 缺钾吃什么水果hcv8jop4ns8r.cn |