Skip to contentSkip to conversation

+ x86-move-vsyscall-page-out-of-fixmap-above-stack-tidy.patch added to -mm tree

DISCUSSION Chris Wedgwood 2 participants 3 messages May 21, 2006 1 message not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw

Review

Quoted 3 lines · On Sun, May 21, 2006 at 02:51:54AM -0700, [email protected] wrote:
(quoted diff) +2 -1
-	if ((ret = insert_vm_struct(mm, vma))) {
+	ret = insert_vm_struct(mm, vma);
+	if (ret) {

Urgh.

It's not really any cleaner/clearer so why do that?

#2 lore raw
Quoted 11 lines · Chris Wedgwood

Review

Quoted 3 lines · On Sun, May 21, 2006 at 02:51:54AM -0700, [email protected] wrote:
(quoted diff) +2 -1
-	if ((ret = insert_vm_struct(mm, vma))) {
+	ret = insert_vm_struct(mm, vma);
+	if (ret) {

Urgh.

It's not really any cleaner/clearer so why do that?

Because it's cleaner and clearer and because Linus said.

One is an assignment and the other is a test. These have nothing to do with each other.

Keep it simple.

#3 lore raw
Quoted 1 line · Andrew Morton

Because it's cleaner and clearer

some would disagree

Quoted 1 line

and because Linus said.

ok, sure, that works (i don't personally agree, but if there is contention it's best that someone just stands up and says "because i said so")

Quoted 2 lines

One is an assignment and the other is a test. These have nothing to do with each other.

should there be a comment in codingstyle about this then perhaps?