From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Eric M. Ludlam" Newsgroups: gmane.emacs.cedet,gmane.emacs.devel Subject: Re: CEDET completion-at-point-function Date: Sat, 21 Jun 2014 20:23:42 -0400 Message-ID: <53A6220E.8010309@siege-engine.com> References: <53717C7E.60208@siege-engine.com> <539DEC30.4050403@siege-engine.com> <53A23AD7.3050007@siege-engine.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1403396642 2206 80.91.229.3 (22 Jun 2014 00:24:02 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 22 Jun 2014 00:24:02 +0000 (UTC) Cc: dgutov@gnu.org, cedet-devel@lists.sourceforge.net, emacs-devel@gnu.org To: Stefan Monnier Original-X-From: cedet-devel-bounces@lists.sourceforge.net Sun Jun 22 02:23:56 2014 Return-path: Envelope-to: sf-cedet-devel@m.gmane.org Original-Received: from lists.sourceforge.net ([216.34.181.88]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1WyVZc-0006t4-IO for sf-cedet-devel@m.gmane.org; Sun, 22 Jun 2014 02:23:56 +0200 Original-Received: from localhost ([127.0.0.1] helo=sfs-ml-4.v29.ch3.sourceforge.com) by sfs-ml-4.v29.ch3.sourceforge.com with esmtp (Exim 4.76) (envelope-from ) id 1WyVZZ-00068j-6g; Sun, 22 Jun 2014 00:23:53 +0000 Original-Received: from sog-mx-2.v43.ch3.sourceforge.com ([172.29.43.192] helo=mx.sourceforge.net) by sfs-ml-4.v29.ch3.sourceforge.com with esmtp (Exim 4.76) (envelope-from ) id 1WyVZX-00068X-J3 for cedet-devel@lists.sourceforge.net; Sun, 22 Jun 2014 00:23:51 +0000 Received-SPF: pass (sog-mx-2.v43.ch3.sourceforge.com: domain of gmail.com designates 209.85.216.47 as permitted sender) client-ip=209.85.216.47; envelope-from=ericludlam@gmail.com; helo=mail-qa0-f47.google.com; Original-Received: from mail-qa0-f47.google.com ([209.85.216.47]) by sog-mx-2.v43.ch3.sourceforge.com with esmtps (TLSv1:RC4-SHA:128) (Exim 4.76) id 1WyVZV-0003dY-Oo for cedet-devel@lists.sourceforge.net; Sun, 22 Jun 2014 00:23:51 +0000 Original-Received: by mail-qa0-f47.google.com with SMTP id hw13so4362973qab.20 for ; Sat, 21 Jun 2014 17:23:44 -0700 (PDT) X-Received: by 10.224.111.196 with SMTP id t4mr19159867qap.63.1403396624179; Sat, 21 Jun 2014 17:23:44 -0700 (PDT) Original-Received: from [192.168.1.201] (pool-71-184-209-46.bstnma.fios.verizon.net. [71.184.209.46]) by mx.google.com with ESMTPSA id a43sm8320554qge.8.2014.06.21.17.23.42 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sat, 21 Jun 2014 17:23:43 -0700 (PDT) User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.3a1pre) Gecko/20091222 Shredder/3.1a1pre In-Reply-To: X-Spam-Score: -1.5 (-) X-Spam-Report: Spam Filtering performed by mx.sourceforge.net. See http://spamassassin.org/tag/ for more details. -1.5 SPF_CHECK_PASS SPF reports sender host as permitted sender for sender-domain 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (ericludlam[at]gmail.com) -0.0 SPF_PASS SPF: sender matches SPF record 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature X-Headers-End: 1WyVZV-0003dY-Oo X-BeenThere: cedet-devel@lists.sourceforge.net X-Mailman-Version: 2.1.9 Precedence: list List-Id: Development discussions for CEDET projects List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: cedet-devel-bounces@lists.sourceforge.net Xref: news.gmane.org gmane.emacs.cedet:6873 gmane.emacs.devel:172624 Archived-At: On 06/18/2014 09:47 PM, Stefan Monnier wrote: >> reference. "d" is generally derived the same as f and a, but we apply one >> > last filter of the return type, so if you had: >> > q = p->f->a->d; >> > Then d's type should be similar to q. > That's odd. Does that mean that the user might have been unable to use > completion on the "p->f->a" part (before typing "->d") because the "a" > field was not of a similar type as q? > Or do you first use this "type similar to context" filter an if the > filter doesn't let anything through, then you drop the filter (kind of > like we filter out files that match completion-ignored-extensions, > except when that results in "no match")? Good call. The list of all possible completions from withing a struct/class contains any terminal type that matches (ie - int, char, etc) and any type that is a compound type (structs, classes) so it is both. Basically, if you are completing to an int, it will toss chars, floats, etc but keep user types which have fields. You can see it in semantic/analyze/complete around line 230. Eric ------------------------------------------------------------------------------ HPCC Systems Open Source Big Data Platform from LexisNexis Risk Solutions Find What Matters Most in Your Big Data with HPCC Systems Open Source. Fast. Scalable. Simple. Ideal for Dirty Data. Leverages Graph Analysis for Fast Processing & Easy Data Exploration http://p.sf.net/sfu/hpccsystems