Return-Path: Delivered-To: apmail-lucene-java-dev-archive@www.apache.org Received: (qmail 81996 invoked from network); 18 Nov 2008 09:27:44 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 18 Nov 2008 09:27:44 -0000 Received: (qmail 22162 invoked by uid 500); 18 Nov 2008 09:27:49 -0000 Delivered-To: apmail-lucene-java-dev-archive@lucene.apache.org Received: (qmail 22111 invoked by uid 500); 18 Nov 2008 09:27:48 -0000 Mailing-List: contact java-dev-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: java-dev@lucene.apache.org Delivered-To: mailing list java-dev@lucene.apache.org Received: (qmail 22102 invoked by uid 99); 18 Nov 2008 09:27:48 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 18 Nov 2008 01:27:48 -0800 X-ASF-Spam-Status: No, hits=2.2 required=10.0 tests=HTML_MESSAGE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of adrianocrestani@gmail.com designates 209.85.198.238 as permitted sender) Received: from [209.85.198.238] (HELO rv-out-0506.google.com) (209.85.198.238) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 18 Nov 2008 09:26:27 +0000 Received: by rv-out-0506.google.com with SMTP id f6so2844641rvb.5 for ; Tue, 18 Nov 2008 01:27:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:sender :to:subject:in-reply-to:mime-version:content-type:references :x-google-sender-auth; bh=Q67tpWRO9zaDJ4yoM/5NWdAwdeNM0NxuLAEsMVVXPAs=; b=f2rsaZEeGqjwzFGa/r8p06OlihraZCPd+ZM2UevKJ1YIG9QSQ7d2COt8/DY+rrVfKz OQtQw21pQSMmjzKJu//84SnMqDXFj6nDvnpVeVw64/7jfsO+dX8Gs/8j7qaGasRXuku8 ZNGAjRiqfOfFTLZ2wzacRZNgPL6AlImajqbI4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:sender:to:subject:in-reply-to:mime-version :content-type:references:x-google-sender-auth; b=rLiR8buc51Qg2h4Iw+DQt6qiO8knyyZW8May3+PQIWPMw0zeSCHoiwz020fxEwjBcb 1A09BzriT3LKV1wIDwUBtq6qMc7e/557Xyo6beybgC5sqBF5YWb0EMt+zxyNhpayzV0p XU1Xoemk6bFK+8/3sNDKyWuY3V0H249fRbFRA= Received: by 10.140.127.13 with SMTP id z13mr2816414rvc.30.1227000422154; Tue, 18 Nov 2008 01:27:02 -0800 (PST) Received: by 10.141.41.15 with HTTP; Tue, 18 Nov 2008 01:27:02 -0800 (PST) Message-ID: <55e2bf7e0811180127j64f9d9edk33db871dc8a9ffd9@mail.gmail.com> Date: Tue, 18 Nov 2008 01:27:02 -0800 From: "Adriano Crestani" Sender: adrianocrestani@gmail.com To: java-dev@lucene.apache.org Subject: Re: Bug in FieldInfo (omitTF)? In-Reply-To: <786fde50811180109x4ba83630q799c2dbb19b7af9a@mail.gmail.com> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_51985_20082129.1227000422153" References: <786fde50811180109x4ba83630q799c2dbb19b7af9a@mail.gmail.com> X-Google-Sender-Auth: ef2b261b113dbab4 X-Virus-Checked: Checked by ClamAV on apache.org ------=_Part_51985_20082129.1227000422153 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline I'm almost sure this was not the expected logic. Otherwise the "this.omitTf = true" statement will never be executed. Based on code logic, it should probably be what you are saying: "this.omitTf != other.omitTf" instead of "this.omitTf omitTf" : ) Regards, Adriano Crestani Campos On Tue, Nov 18, 2008 at 1:09 AM, Shai Erera wrote: > Hi > > I looked at FieldInfo and found this line (95): > > if (this.omitTf != omitTf) { > this.omitTf = true; // if one require omitTf at least > once, it remains off for life > } > > Shouldn't it be: > if (this.omitTf != other.omitTf) { > this.omitTf = true; // if one require omitTf at least > once, it remains off for life > } > > The first version compares the field to itself ... > > Shai > ------=_Part_51985_20082129.1227000422153 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline I'm almost sure this was not the expected logic.

Otherwise the "this.omitTf = true" statement will never be executed.

Based on code logic, it should probably be what you are saying: "this.omitTf != other.omitTf" instead of "this.omitTf omitTf" : )

Regards,
Adriano Crestani Campos

On Tue, Nov 18, 2008 at 1:09 AM, Shai Erera <serera@gmail.com> wrote:
Hi

I looked at FieldInfo and found this line (95):

    if (this.omitTf != omitTf) {
      this.omitTf = true;                // if one require omitTf at least once, it remains off for life
    }

Shouldn't it be:
    if (this.omitTf != other.omitTf) {
      this.omitTf = true;                // if one require omitTf at least once, it remains off for life
    }

The first version compares the field to itself ...

Shai

------=_Part_51985_20082129.1227000422153--