<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	>
<channel>
	<title>Comments on: CouchDB 的作者 Damien Katz 炮轰 Erlang 的语法</title>
	<atom:link href="http://erlang-china.org/misc/what_erlang_sucks.html/feed" rel="self" type="application/rss+xml" />
	<link>http://erlang-china.org/misc/what_erlang_sucks.html</link>
	<description>erlang 中文社区</description>
	<pubDate>Wed, 08 Oct 2008 11:21:29 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.6.2</generator>
		<item>
		<title>By: jackyz</title>
		<link>http://erlang-china.org/misc/what_erlang_sucks.html#comment-3552</link>
		<dc:creator>jackyz</dc:creator>
		<pubDate>Wed, 19 Mar 2008 13:13:07 +0000</pubDate>
		<guid isPermaLink="false">http://erlang-china.org/misc/what_erlang_sucks.html#comment-3552</guid>
		<description>变量首字母大写恐怕还是必须的吧，要不然，如何区分 atom 和变量呢？

[ t * t &#124;&#124; t ＜－ lists:seq(1, 10)]

这一句，是合法的语句，执行结果是 [] 。其含义你可以用下面这一句来理解

[ t * t &#124;&#124; t ＜－ [t, u, v]]

执行时会告诉你 t * t 不是合法的操作符。这是因为 t ＜－ ［t, u, v］的结果为 [ t ] 对 atom 的 t 执行 t * t 是非法的操作。这一点可以这样印证。

[ t &#124;&#124; t ＜－ [t, u, v]]

其执行结果就是 [t] 。


目前的 erlang-china.org 是以  blog 形式存在的“资料收集/消息发布”处。 bbs/maillist 的感觉可以在 erlang-china@googlegroups.com 论坛找到。</description>
		<content:encoded><![CDATA[<p>变量首字母大写恐怕还是必须的吧，要不然，如何区分 atom 和变量呢？</p>
<p>[ t * t || t ＜－ lists:seq(1, 10)]</p>
<p>这一句，是合法的语句，执行结果是 [] 。其含义你可以用下面这一句来理解</p>
<p>[ t * t || t ＜－ [t, u, v]]</p>
<p>执行时会告诉你 t * t 不是合法的操作符。这是因为 t ＜－ ［t, u, v］的结果为 [ t ] 对 atom 的 t 执行 t * t 是非法的操作。这一点可以这样印证。</p>
<p>[ t || t ＜－ [t, u, v]]</p>
<p>其执行结果就是 [t] 。</p>
<p>目前的 erlang-china.org 是以  blog 形式存在的“资料收集/消息发布”处。 bbs/maillist 的感觉可以在 <a href="mailto:erlang-china@googlegroups.com">erlang-china@googlegroups.com</a> 论坛找到。</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: xrfang</title>
		<link>http://erlang-china.org/misc/what_erlang_sucks.html#comment-3549</link>
		<dc:creator>xrfang</dc:creator>
		<pubDate>Wed, 19 Mar 2008 11:05:14 +0000</pubDate>
		<guid isPermaLink="false">http://erlang-china.org/misc/what_erlang_sucks.html#comment-3549</guid>
		<description>晕菜，楼上我写的代码是：

[ t * t &#124;&#124; t ＜－ lists:seq(1, 10)]</description>
		<content:encoded><![CDATA[<p>晕菜，楼上我写的代码是：</p>
<p>[ t * t || t ＜－ lists:seq(1, 10)]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: xrfang</title>
		<link>http://erlang-china.org/misc/what_erlang_sucks.html#comment-3548</link>
		<dc:creator>xrfang</dc:creator>
		<pubDate>Wed, 19 Mar 2008 11:03:15 +0000</pubDate>
		<guid isPermaLink="false">http://erlang-china.org/misc/what_erlang_sucks.html#comment-3548</guid>
		<description>这位大师的评论我只同意一点，就是erlang的record实在可以用笨拙形容。其他我觉得都很好。比如，；.作为语句结尾符的用法，我觉得意思很明确。

我自己发现了erlang的一些奇怪的地方，奇怪这个用词不妥，应该说是对初学者的陷阱。最明显的一个就是变量首字母必须大写。这个倒也罢了，问题是，不大写，不报错！！！大家看看下面这段代码：

[t * t &#124;&#124; t </description>
		<content:encoded><![CDATA[<p>这位大师的评论我只同意一点，就是erlang的record实在可以用笨拙形容。其他我觉得都很好。比如，；.作为语句结尾符的用法，我觉得意思很明确。</p>
<p>我自己发现了erlang的一些奇怪的地方，奇怪这个用词不妥，应该说是对初学者的陷阱。最明显的一个就是变量首字母必须大写。这个倒也罢了，问题是，不大写，不报错！！！大家看看下面这段代码：</p>
<p>[t * t || t</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: trustno1</title>
		<link>http://erlang-china.org/misc/what_erlang_sucks.html#comment-3488</link>
		<dc:creator>trustno1</dc:creator>
		<pubDate>Thu, 13 Mar 2008 22:38:49 +0000</pubDate>
		<guid isPermaLink="false">http://erlang-china.org/misc/what_erlang_sucks.html#comment-3488</guid>
		<description>更正一下也不能说是没类型,说的准确一些应该是Erlang的类型是by layout而不是by name的,by layout的好处就是pattern match方便，当然也要付出代价就是相同的layout不同的类型要区分出来就要靠人肉标注了.</description>
		<content:encoded><![CDATA[<p>更正一下也不能说是没类型,说的准确一些应该是Erlang的类型是by layout而不是by name的,by layout的好处就是pattern match方便，当然也要付出代价就是相同的layout不同的类型要区分出来就要靠人肉标注了.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: trustno1</title>
		<link>http://erlang-china.org/misc/what_erlang_sucks.html#comment-3487</link>
		<dc:creator>trustno1</dc:creator>
		<pubDate>Thu, 13 Mar 2008 22:36:29 +0000</pubDate>
		<guid isPermaLink="false">http://erlang-china.org/misc/what_erlang_sucks.html#comment-3487</guid>
		<description>Record 语法刚开始确实觉得巨烦巨冗长，它的 get 用起来怒啰嗦(感觉编译器应该给我自动判断某个变量是不是某record就好了嘛，免得多敲键盘)很不爽

那是因为Erlang完全没类型的阿,Haskell就抹油这样的问题.#person实际上就是人肉标注类型.</description>
		<content:encoded><![CDATA[<p>Record 语法刚开始确实觉得巨烦巨冗长，它的 get 用起来怒啰嗦(感觉编译器应该给我自动判断某个变量是不是某record就好了嘛，免得多敲键盘)很不爽</p>
<p>那是因为Erlang完全没类型的阿,Haskell就抹油这样的问题.#person实际上就是人肉标注类型.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: jackyz</title>
		<link>http://erlang-china.org/misc/what_erlang_sucks.html#comment-3458</link>
		<dc:creator>jackyz</dc:creator>
		<pubDate>Wed, 12 Mar 2008 12:41:50 +0000</pubDate>
		<guid isPermaLink="false">http://erlang-china.org/misc/what_erlang_sucks.html#comment-3458</guid>
		<description>半角的“&lt;code&gt; &lt; &lt;/code&gt;”是html标签的一部分嘛。用个[code][/code](把[]变成尖括号)框起来好了。

Record 语法刚开始确实觉得巨烦巨冗长，它的 get 用起来怒啰嗦(感觉编译器应该给我自动判断某个变量是不是某record就好了嘛，免得多敲键盘)很不爽。但用来做 set 就确实很爽(没变化的字段就不用啰里啰嗦的再写了，用getter和setter的恐怕就必须要搞个通用方法来做这件事)，再加上匹配语法啥的，用着用着，也感觉没那么恶心了。

&lt;coolcode lang="erlang" linenum="false"&gt;
...
-record(person, {name=undefined, age=0, address=undefined}).
...
R1 = #person{age=28},
Age1 = R1#person.age,
R2 = R1#record{age=29, address="some address"},
#record{age=29, address=Address} = R2，
...
&lt;/coolcode&gt;

俺在开始的几个月也抱怨了一阵子，后来也就慢慢适应了。</description>
		<content:encoded><![CDATA[<p>半角的“<code> < </code>”是html标签的一部分嘛。用个[code][/code](把[]变成尖括号)框起来好了。</p>
<p>Record 语法刚开始确实觉得巨烦巨冗长，它的 get 用起来怒啰嗦(感觉编译器应该给我自动判断某个变量是不是某record就好了嘛，免得多敲键盘)很不爽。但用来做 set 就确实很爽(没变化的字段就不用啰里啰嗦的再写了，用getter和setter的恐怕就必须要搞个通用方法来做这件事)，再加上匹配语法啥的，用着用着，也感觉没那么恶心了。</p>
<div class="hl-surround"><div class="hl-main"><span style="color: Gray;">...<br />-</span><span style="color: Blue;">record</span><span style="color: Olive;">(</span><span style="color: Blue;">person</span><span style="color: Gray;">, {</span><span style="color: Blue;">name</span><span style="color: Gray;">=</span><span style="color: Blue;">undefined</span><span style="color: Gray;">, </span><span style="color: Blue;">age</span><span style="color: Gray;">=</span><span style="color: Maroon;">0</span><span style="color: Gray;">, </span><span style="color: Blue;">address</span><span style="color: Gray;">=</span><span style="color: Blue;">undefined</span><span style="color: Gray;">}</span><span style="color: Olive;">)</span><span style="color: Gray;">.<br />...<br /></span><span style="color: Blue;">R1</span><span style="color: Gray;"> = #</span><span style="color: Blue;">person</span><span style="color: Gray;">{</span><span style="color: Blue;">age</span><span style="color: Gray;">=</span><span style="color: Maroon;">28</span><span style="color: Gray;">},<br /></span><span style="color: Blue;">Age1</span><span style="color: Gray;"> = </span><span style="color: Blue;">R1</span><span style="color: Gray;">#</span><span style="color: Blue;">person</span><span style="color: Gray;">.</span><span style="color: Blue;">age</span><span style="color: Gray;">,<br /></span><span style="color: Blue;">R2</span><span style="color: Gray;"> = </span><span style="color: Blue;">R1</span><span style="color: Gray;">#</span><span style="color: Blue;">record</span><span style="color: Gray;">{</span><span style="color: Blue;">age</span><span style="color: Gray;">=</span><span style="color: Maroon;">29</span><span style="color: Gray;">, </span><span style="color: Blue;">address</span><span style="color: Gray;">=</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">some address</span><span style="color: #8b0000;">&quot;</span><span style="color: Gray;">},<br />#</span><span style="color: Blue;">record</span><span style="color: Gray;">{</span><span style="color: Blue;">age</span><span style="color: Gray;">=</span><span style="color: Maroon;">29</span><span style="color: Gray;">, </span><span style="color: Blue;">address</span><span style="color: Gray;">=</span><span style="color: Blue;">Address</span><span style="color: Gray;">} = </span><span style="color: Blue;">R2</span><span style="color: Gray;">，<br />...</span></div></div>
<p>俺在开始的几个月也抱怨了一阵子，后来也就慢慢适应了。</code></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Trustno1</title>
		<link>http://erlang-china.org/misc/what_erlang_sucks.html#comment-3456</link>
		<dc:creator>Trustno1</dc:creator>
		<pubDate>Wed, 12 Mar 2008 06:08:41 +0000</pubDate>
		<guid isPermaLink="false">http://erlang-china.org/misc/what_erlang_sucks.html#comment-3456</guid>
		<description>靠这个回复有问题啊.半角的＜－显示不出来.</description>
		<content:encoded><![CDATA[<p>靠这个回复有问题啊.半角的＜－显示不出来.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Trustno1</title>
		<link>http://erlang-china.org/misc/what_erlang_sucks.html#comment-3455</link>
		<dc:creator>Trustno1</dc:creator>
		<pubDate>Wed, 12 Mar 2008 06:07:53 +0000</pubDate>
		<guid isPermaLink="false">http://erlang-china.org/misc/what_erlang_sucks.html#comment-3455</guid>
		<description>我曾经想过一个setter的语法.NewRecord=Record.field</description>
		<content:encoded><![CDATA[<p>我曾经想过一个setter的语法.NewRecord=Record.field</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Trustno1</title>
		<link>http://erlang-china.org/misc/what_erlang_sucks.html#comment-3454</link>
		<dc:creator>Trustno1</dc:creator>
		<pubDate>Wed, 12 Mar 2008 05:58:43 +0000</pubDate>
		<guid isPermaLink="false">http://erlang-china.org/misc/what_erlang_sucks.html#comment-3454</guid>
		<description>另外,record语法实则和immutable问题是捆在一块的.比如dcaoyuan 的record bird.
你最多拿.语法来做getter,遇到setter照样没辙.我曾经想过一个setter的语法.
NewRecord=Record.field</description>
		<content:encoded><![CDATA[<p>另外,record语法实则和immutable问题是捆在一块的.比如dcaoyuan 的record bird.<br />
你最多拿.语法来做getter,遇到setter照样没辙.我曾经想过一个setter的语法.<br />
NewRecord=Record.field</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Trustno1</title>
		<link>http://erlang-china.org/misc/what_erlang_sucks.html#comment-3453</link>
		<dc:creator>Trustno1</dc:creator>
		<pubDate>Wed, 12 Mar 2008 05:53:26 +0000</pubDate>
		<guid isPermaLink="false">http://erlang-china.org/misc/what_erlang_sucks.html#comment-3453</guid>
		<description>对于被C语法族语言惯坏的程序员来说,遇上Erlang已经是非常幸福的事情了.如果高并发高可靠的名头被戴在Haskell,OCaml上面,我看他们除了跳楼之外恐怕没啥其他出路了.</description>
		<content:encoded><![CDATA[<p>对于被C语法族语言惯坏的程序员来说,遇上Erlang已经是非常幸福的事情了.如果高并发高可靠的名头被戴在Haskell,OCaml上面,我看他们除了跳楼之外恐怕没啥其他出路了.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
