From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Qiantan Hong Newsgroups: gmane.emacs.devel Subject: Prototype of object capability in Emacs Date: Thu, 16 Sep 2021 23:09:22 +0000 Message-ID: <9069C6C8-B901-4F7C-B950-168AFDD119C6@mit.edu> Mime-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="5286"; mail-complaints-to="usenet@ciao.gmane.io" Cc: =?utf-8?B?TWF0dGlhcyBFbmdkZWfDpXJk?= , Stefan Monnier To: "emacs-devel@gnu.org" Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Sep 17 01:19:24 2021 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mR0f5-0001BE-5t for ged-emacs-devel@m.gmane-mx.org; Fri, 17 Sep 2021 01:19:23 +0200 Original-Received: from localhost ([::1]:38186 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mR0f3-00030G-4D for ged-emacs-devel@m.gmane-mx.org; Thu, 16 Sep 2021 19:19:21 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:46982) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mR0Vv-0006LK-Mx for emacs-devel@gnu.org; Thu, 16 Sep 2021 19:09:55 -0400 Original-Received: from outgoing-exchange-1.mit.edu ([18.9.28.15]:60625) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mR0Vt-0006vH-7i for emacs-devel@gnu.org; Thu, 16 Sep 2021 19:09:55 -0400 Original-Received: from w92exedge3.exchange.mit.edu (W92EXEDGE3.EXCHANGE.MIT.EDU [18.7.73.15]) by outgoing-exchange-1.mit.edu (8.14.7/8.12.4) with ESMTP id 18GN9jE5014552; Thu, 16 Sep 2021 19:09:46 -0400 Original-Received: from oc11expo16.exchange.mit.edu (18.9.4.47) by w92exedge3.exchange.mit.edu (18.7.73.15) with Microsoft SMTP Server (TLS) id 15.0.1497.23; Thu, 16 Sep 2021 19:09:38 -0400 Original-Received: from oc11expo16.exchange.mit.edu (18.9.4.47) by oc11expo16.exchange.mit.edu (18.9.4.47) with Microsoft SMTP Server (TLS) id 15.0.1497.23; Thu, 16 Sep 2021 19:09:22 -0400 Original-Received: from oc11expo16.exchange.mit.edu ([18.9.4.47]) by oc11expo16.exchange.mit.edu ([18.9.4.47]) with mapi id 15.00.1497.023; Thu, 16 Sep 2021 19:09:22 -0400 Thread-Topic: Prototype of object capability in Emacs Thread-Index: AQHXq0/iUnF45PI4rkeo9ext9kBpHA== Accept-Language: en-US Content-Language: en-US x-ms-exchange-messagesentrepresentingtype: 1 x-ms-exchange-transport-fromentityheader: Hosted x-originating-ip: [128.12.11.144] Content-ID: <043177F67C93DA4BBCDE92833BA20673@exchange.mit.edu> Received-SPF: pass client-ip=18.9.28.15; envelope-from=qhong@mit.edu; helo=outgoing-exchange-1.mit.edu X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: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