From patchwork Fri Jun 19 21:42:51 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?q?Matthias_M=C3=A4nnich?= X-Patchwork-Id: 39696 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 61B453938C0E; Fri, 19 Jun 2020 21:43:18 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 61B453938C0E DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1592602998; bh=MYRweQXk8CqMUKfg24zNmwv8M4of+omF6QZM/LgjajI=; h=Date:In-Reply-To:References:Subject:To:List-Id:List-Unsubscribe: List-Archive:List-Help:List-Subscribe:From:Reply-To:Cc:From; b=AAZwNe7E1iH0GDTr6rnSbTJA/OXTX26aFTP7vu/q0c4hUlMcaXQMuLkaLjiU8w/M0 6zqwDXmvzEsuazs+ZBRN/pGVrIDj/tYt8+mopalNCSagb4/XTfkogQQ78WZ1rLwhW5 96La/juwZqVzjoxf4ComdSOLlJ1rS56I+WN5s1bU= X-Original-To: libabigail@sourceware.org Delivered-To: libabigail@sourceware.org Received: from mail-qv1-xf4a.google.com (mail-qv1-xf4a.google.com [IPv6:2607:f8b0:4864:20::f4a]) by sourceware.org (Postfix) with ESMTPS id 405F23898536 for ; Fri, 19 Jun 2020 21:43:16 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 405F23898536 Received: by mail-qv1-xf4a.google.com with SMTP id q5so7808194qvp.23 for ; Fri, 19 Jun 2020 14:43:16 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:in-reply-to:message-id:mime-version :references:subject:from:to:cc; bh=MYRweQXk8CqMUKfg24zNmwv8M4of+omF6QZM/LgjajI=; b=L0ykvtfjxIpnv1vrJX3cmbHkZMrjJcGrNjs8gnP75zgcery78Cq/iTg7/0g8M6Pzky JENrG42FMUC9i5q2yqpsar9UYKNk068g8Y9LJsDHCF6wK3DJ6qGZE517SA2+no8xk6Wp +yZtzW1GQOuCUuvC/PMqPwmgTw+OqwmIg0ZQ/IJRnzweido0ZCDrWLtqlFZGuwyYNIbx 95TvGjdM0EduwPmUor1OwDiy3pm5dT60xXLFPgNxs2X+g/f68rN9DZ8vKIH9cAj5k2o+ Zaa7N2M16Lru7fSJQo/87tkQK8kfsOc2p8KLYbzY37itnHXfAWifVNNzTFjVX0WSt14J 1A0Q== X-Gm-Message-State: AOAM531w+uv5j4ThjvwqedwUIjqcROKBrLcGD1FFlcGx59RP4ZE03JIh FUeDXx8M966ADmrFJuckXhzTu76kYnqodgGaCHWastD2rZtUOKCMOHAyPGG+iB6NfIZkqTqYron xoswvyUxolskmu2/FfWl9KQ4XmoLZJprhoJ7sEirYCXPQS7BZpqi0QPoCod/cN7hIR6LN+d0= X-Google-Smtp-Source: ABdhPJwYAWJLcgQzz0J3bYPsehdqeA20Mqu6qymIPCj+AgHw7otXtHdtfx5o3QuJ4c/q7SqkiEhRRcqmDegrQQ== X-Received: by 2002:a0c:806e:: with SMTP id 101mr10422685qva.173.1592602995791; Fri, 19 Jun 2020 14:43:15 -0700 (PDT) Date: Fri, 19 Jun 2020 23:42:51 +0200 In-Reply-To: <20200619214305.562-1-maennich@google.com> Message-Id: <20200619214305.562-3-maennich@google.com> Mime-Version: 1.0 References: <20200619214305.562-1-maennich@google.com> X-Mailer: git-send-email 2.27.0.111.gc72c7da667-goog Subject: [PATCH v1 02/16] abg-cxx-compat: more support: std::bind and friends To: libabigail@sourceware.org X-Spam-Status: No, score=-23.1 required=5.0 tests=BAYES_00, DKIMWL_WL_MED, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, USER_IN_DEF_DKIM_WL autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: libabigail@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Mailing list of the Libabigail project List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-Patchwork-Original-From: Matthias Maennich via Libabigail From: =?utf-8?q?Matthias_M=C3=A4nnich?= Reply-To: Matthias Maennich Cc: maennich@google.com, gprocida@google.com, kernel-team@android.com Errors-To: libabigail-bounces@sourceware.org Sender: "Libabigail" Add abg_compat::{bind,function,placeholders} to the compatibility layer. That is made use of in a later patch. As usual, for C++ standards that natively support this functionality (C++11 and later), the native implementation is aliased into the abg_compat namespace. * include/abg-cxx-compat.h: add support for abg_compat::{bind,function,placeholders} Reviewed-by: Giuliano Procida Signed-off-by: Matthias Maennich --- include/abg-cxx-compat.h | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/include/abg-cxx-compat.h b/include/abg-cxx-compat.h index 1283e9191d46..cab2883b231e 100644 --- a/include/abg-cxx-compat.h +++ b/include/abg-cxx-compat.h @@ -58,8 +58,15 @@ namespace abg_compat { #if __cplusplus >= 201103L // +using std::bind; +using std::function; using std::hash; +namespace placeholders +{ +using namespace std::placeholders; +} + // using std::shared_ptr; using std::weak_ptr; @@ -75,8 +82,15 @@ using std::unordered_set; #else // +using std::tr1::bind; +using std::tr1::function; using std::tr1::hash; +namespace placeholders +{ +using namespace std::tr1::placeholders; +} + // using std::tr1::shared_ptr; using std::tr1::weak_ptr;