You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficserver.apache.org by zw...@apache.org on 2013/04/27 17:59:59 UTC

git commit: Remove unused typedef to make Lua compile

Updated Branches:
  refs/heads/master f7917f8e8 -> a58b8ec57


Remove unused typedef to make Lua compile


Project: http://git-wip-us.apache.org/repos/asf/trafficserver/repo
Commit: http://git-wip-us.apache.org/repos/asf/trafficserver/commit/a58b8ec5
Tree: http://git-wip-us.apache.org/repos/asf/trafficserver/tree/a58b8ec5
Diff: http://git-wip-us.apache.org/repos/asf/trafficserver/diff/a58b8ec5

Branch: refs/heads/master
Commit: a58b8ec57898cff3839b76990e7eca92e75074cf
Parents: f7917f8
Author: Leif Hedstrom <zw...@apache.org>
Authored: Sat Apr 27 09:59:34 2013 -0600
Committer: Leif Hedstrom <zw...@apache.org>
Committed: Sat Apr 27 09:59:37 2013 -0600

----------------------------------------------------------------------
 plugins/experimental/lua/hook.cc |    2 --
 1 files changed, 0 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/trafficserver/blob/a58b8ec5/plugins/experimental/lua/hook.cc
----------------------------------------------------------------------
diff --git a/plugins/experimental/lua/hook.cc b/plugins/experimental/lua/hook.cc
index e4a4e4e..4572910 100644
--- a/plugins/experimental/lua/hook.cc
+++ b/plugins/experimental/lua/hook.cc
@@ -125,8 +125,6 @@ struct inline_tuple
 
   static void * allocate(const first_type first, const second_type second) {
 #if defined(INLINE_LUA_HOOK_REFERENCE)
-    typedef char __size_check[sizeof(this_type) == sizeof(void *) ? 0 : -1];
-
     this_type obj;
     obj.first() = first;
     obj.second() = second;


Re: git commit: Remove unused typedef to make Lua compile

Posted by James Peach <ja...@me.com>.
On Apr 27, 2013, at 8:59 AM, zwoop@apache.org wrote:

> Updated Branches:
>  refs/heads/master f7917f8e8 -> a58b8ec57
> 
> 
> Remove unused typedef to make Lua compile
> 
> 
> Project: http://git-wip-us.apache.org/repos/asf/trafficserver/repo
> Commit: http://git-wip-us.apache.org/repos/asf/trafficserver/commit/a58b8ec5
> Tree: http://git-wip-us.apache.org/repos/asf/trafficserver/tree/a58b8ec5
> Diff: http://git-wip-us.apache.org/repos/asf/trafficserver/diff/a58b8ec5
> 
> Branch: refs/heads/master
> Commit: a58b8ec57898cff3839b76990e7eca92e75074cf
> Parents: f7917f8
> Author: Leif Hedstrom <zw...@apache.org>
> Authored: Sat Apr 27 09:59:34 2013 -0600
> Committer: Leif Hedstrom <zw...@apache.org>
> Committed: Sat Apr 27 09:59:37 2013 -0600
> 
> ----------------------------------------------------------------------
> plugins/experimental/lua/hook.cc |    2 --
> 1 files changed, 0 insertions(+), 2 deletions(-)
> ----------------------------------------------------------------------
> 
> 
> http://git-wip-us.apache.org/repos/asf/trafficserver/blob/a58b8ec5/plugins/experimental/lua/hook.cc
> ----------------------------------------------------------------------
> diff --git a/plugins/experimental/lua/hook.cc b/plugins/experimental/lua/hook.cc
> index e4a4e4e..4572910 100644
> --- a/plugins/experimental/lua/hook.cc
> +++ b/plugins/experimental/lua/hook.cc
> @@ -125,8 +125,6 @@ struct inline_tuple
> 
>   static void * allocate(const first_type first, const second_type second) {
> #if defined(INLINE_LUA_HOOK_REFERENCE)
> -    typedef char __size_check[sizeof(this_type) == sizeof(void *) ? 0 : -1];
> -

This is a static assert to make sure that the pointer hackery we do later is going to work. This check should not be removed; if it fails it means the plugin is broken.

>     this_type obj;
>     obj.first() = first;
>     obj.second() = second;
>