From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Skip Montanaro Newsgroups: gmane.emacs.help Subject: Re: Requiring elisp that comes with Emacs Date: Mon, 30 Jan 2017 12:50:58 -0600 Message-ID: References: <874m0gv6ba.fsf@gmail.com> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Trace: blaine.gmane.org 1485802562 23780 195.159.176.226 (30 Jan 2017 18:56:02 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 30 Jan 2017 18:56:02 +0000 (UTC) Cc: help-gnu-emacs@gnu.org To: Narendra Joshi Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Jan 30 19:55:58 2017 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cYH7N-0005oK-B4 for geh-help-gnu-emacs@m.gmane.org; Mon, 30 Jan 2017 19:55:57 +0100 Original-Received: from localhost ([::1]:34541 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cYH7N-0001mr-Fo for geh-help-gnu-emacs@m.gmane.org; Mon, 30 Jan 2017 13:55:57 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:58784) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cYH2a-0006mD-SZ for help-gnu-emacs@gnu.org; Mon, 30 Jan 2017 13:51:01 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cYH2a-00040t-3c for help-gnu-emacs@gnu.org; Mon, 30 Jan 2017 13:51:00 -0500 Original-Received: from mail-wm0-x231.google.com ([2a00:1450:400c:c09::231]:36377) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1cYH2Z-00040d-Sr for help-gnu-emacs@gnu.org; Mon, 30 Jan 2017 13:51:00 -0500 Original-Received: by mail-wm0-x231.google.com with SMTP id c85so227221418wmi.1 for ; Mon, 30 Jan 2017 10:50:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=2tL18EhXdudMh/mUJGgdAfpoutvKZgarKRV9EBRVRYQ=; b=GkAGgnFPArynQbZB/fbZxvdCnQRNx9UygyrfrAMOBmUgRO5Ya2ZZd9qKrgjLqtsCwB 0alWSsuqbZeqtTmimQArJ9rcVMSgi5V/8+oxY8cu+UuBTDWhKQQUIU1M9lfresHkmStv 4Dp3T73DAbQvyFxfk61EVXB19Gj/2Kd8BcxnBQNfqoHUE+P5k+hrugEMsZTUkhhaPwqP B9LsWz1hH8MgTMJn8+qIFWH8+MxNYmfFdcxfLB6Er8qU8Dn4wpRqaVlEACnhO5K2PZnc lAIzUBYjld3as8l1JgtCNWzxdvQ4mbL8SDG13mlj+MZsKsIhn1qtnsaBoEQvDuniwPMY Mlqg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=2tL18EhXdudMh/mUJGgdAfpoutvKZgarKRV9EBRVRYQ=; b=f5vWyOZ6gF3F0QU/lvxAgB5utBPo+y8zZ8PKt2TcTX/lKmflhGYDFCXblJnmY+Lo55 5Ia9k2Mj4gXlQM7Nt+NiX2Zs4zkSVu2FpnomFzONnN0/3LKqI8jU5BpBOA6su9cU6NPU EE58E9RtyOaCklyjBYvAiT2be6Kb6fSMX758mOLiadAfZZSawuP6PLR9j61Yd2g5uNVT fbgFuGQoa4r36fa7dg7uz1RjrnVHwfu5xkTilsV+jFbULxQiyFtzbKjGxtO8AUYo5YkX 7+B+In6ujdBoE+zNe7D/4Q2z0se+1ECdH9znVjagz7Fses50Lsq+3WECxj9D4QoE05U7 uInQ== X-Gm-Message-State: AIkVDXJ8in+3HSm82KidpzGWy+d3l7u5dP6nytMihPTb4i9qlo9xANrJjhDvtPrYK/ebiPw+/nyE51SF1a1heQ== X-Received: by 10.223.133.164 with SMTP id 33mr20362196wrt.39.1485802258412; Mon, 30 Jan 2017 10:50:58 -0800 (PST) Original-Received: by 10.28.224.86 with HTTP; Mon, 30 Jan 2017 10:50:58 -0800 (PST) In-Reply-To: <874m0gv6ba.fsf@gmail.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2a00:1450:400c:c09::231 X-Content-Filtered-By: Mailman/MimeDel 2.1.21 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.org gmane.emacs.help:112205 Archived-At: On Mon, Jan 30, 2017 at 10:52 AM, Narendra Joshi wrote: > What happens when we do `require'? It guarantees the relevant feature is available, generally as a side effect of loading the named package. I believe the package much "provide" its name. If not found, an error is raised. Full details can be found here: https://www.gnu.org/software/emacs/manual/html_node/elisp/Named-Features.html While under the covers I imagine the implementation is much different, I my mental model is similar to Python's import statement or C++'s namespace statement. All three make a series of names available to you, though require is a global operation, not local to a particular module or translation unit. Skip Montanaro