Repository: lucy
Updated Branches:
  refs/heads/master 3accfc8f6 -> 81a065053


Remove Clownfish-specific code from example-lang


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

Branch: refs/heads/master
Commit: 0496571069a217a4a4c3a7f87d45cfbaeb0862e2
Parents: 3accfc8
Author: Nick Wellnhofer <[email protected]>
Authored: Fri Jul 25 14:25:46 2014 +0200
Committer: Nick Wellnhofer <[email protected]>
Committed: Fri Jul 25 14:25:46 2014 +0200

----------------------------------------------------------------------
 example-lang/README                             | 31 ------------
 example-lang/src/CFBind.c                       | 19 -------
 example-lang/src/CFBind.h                       | 51 -------------------
 example-lang/src/Lucy/Object/Err.c              | 46 -----------------
 example-lang/src/Lucy/Object/Host.c             | 53 --------------------
 example-lang/src/Lucy/Object/LockFreeRegistry.c | 28 -----------
 example-lang/src/Lucy/Object/Obj.c              | 45 -----------------
 example-lang/src/Lucy/Object/VTable.c           | 50 ------------------
 8 files changed, 323 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucy/blob/04965710/example-lang/README
----------------------------------------------------------------------
diff --git a/example-lang/README b/example-lang/README
index add0171..ce23a90 100644
--- a/example-lang/README
+++ b/example-lang/README
@@ -19,34 +19,3 @@ routines whose interfaces are defined within "trunk/core".
 Once all the stubs have been implemented correctly, Lucy will theoretically
 build and pass its tests.
 
-There is one pair of files with an interface *not* defined in core.
-
-    example-lang/src/CFBind.h
-    example-lang/src/CFBind.c
-
-The CFBind files are there to hold conversion routines which are specific to a
-language binding.  Since it is impractical to impose a generic interface, they
-are not defined in core.
-
-You may wish to start by referencing a finished language binding to get a feel
-for what should go in the CFBind files.
-
-Some of Lucy's classes really ought to be grouped with Clownfish, as they form
-something similar to a free floating "standard library" and are not
-search-related.  At some point everything under Lucy::Object will probably
-migrate to a new namespace:
-
-    Clownfish::Obj       => Clownfish::Obj
-    Lucy::Object::String    => Clownfish::String
-    Lucy::Object::VArray    => Clownfish::VArray
-    Lucy::Object::Hash      => Clownfish::Hash
-    Lucy::Object::BitVector => Clownfish::BitVector
-    ...
-
-Other, search-related classes belong with Lucy itself, but are represented
-here because they lack one or more implementing functions:
-
-    Lucy::Document::Doc
-    Lucy::Analysis::RegexTokenizer
-    Lucy::Index::Inverter
-    ...

http://git-wip-us.apache.org/repos/asf/lucy/blob/04965710/example-lang/src/CFBind.c
----------------------------------------------------------------------
diff --git a/example-lang/src/CFBind.c b/example-lang/src/CFBind.c
deleted file mode 100644
index 772b065..0000000
--- a/example-lang/src/CFBind.c
+++ /dev/null
@@ -1,19 +0,0 @@
-/* Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include "CFBind.h"
-
-

http://git-wip-us.apache.org/repos/asf/lucy/blob/04965710/example-lang/src/CFBind.h
----------------------------------------------------------------------
diff --git a/example-lang/src/CFBind.h b/example-lang/src/CFBind.h
deleted file mode 100644
index b4c142b..0000000
--- a/example-lang/src/CFBind.h
+++ /dev/null
@@ -1,51 +0,0 @@
-/* Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/* CFBind.h -- Functions to help bind Clownfish to [LANGUAGE_X].
- */
-
-#ifndef H_CFISH_CFBIND
-#define H_CFISH_CFBIND 1
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#include "charmony.h"
-#include "Clownfish/Obj.h"
-#include "Clownfish/ByteBuf.h"
-#include "Clownfish/String.h"
-#include "Clownfish/Err.h"
-#include "Clownfish/Hash.h"
-#include "Clownfish/Num.h"
-#include "Clownfish/VArray.h"
-#include "Clownfish/VTable.h"
-
-/* Strip the prefix from some common symbols where we know there's no
- * conflict.  It's a little inconsistent to do this rather than leave all
- * symbols at full size, but the succinctness is worth it.
- */
-#define THROW                CFISH_THROW
-#define WARN                 CFISH_WARN
-#define UNREACHABLE_RETURN   CHY_UNREACHABLE_RETURN
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif // H_CFISH_CFBIND
-
-

http://git-wip-us.apache.org/repos/asf/lucy/blob/04965710/example-lang/src/Lucy/Object/Err.c
----------------------------------------------------------------------
diff --git a/example-lang/src/Lucy/Object/Err.c 
b/example-lang/src/Lucy/Object/Err.c
deleted file mode 100644
index 389e8f4..0000000
--- a/example-lang/src/Lucy/Object/Err.c
+++ /dev/null
@@ -1,46 +0,0 @@
-/* Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include "CFBind.h"
-
-lucy_Err*
-lucy_Err_get_error() {
-    THROW(LUCY_ERR, "TODO");
-    UNREACHABLE_RETURN(lucy_Err*);
-}
-
-void
-lucy_Err_set_error(lucy_Err *error) {
-    THROW(LUCY_ERR, "TODO");
-}
-
-void*
-lucy_Err_to_host(lucy_Err *self) {
-    THROW(LUCY_ERR, "TODO");
-    UNREACHABLE_RETURN(void*);
-}
-
-void
-lucy_Err_throw_mess(lucy_VTable *vtable, lucy_CharBuf *message) {
-    THROW(LUCY_ERR, "TODO");
-}
-
-void
-lucy_Err_warn_mess(lucy_CharBuf *message) {
-    THROW(LUCY_ERR, "TODO");
-}
-
-

http://git-wip-us.apache.org/repos/asf/lucy/blob/04965710/example-lang/src/Lucy/Object/Host.c
----------------------------------------------------------------------
diff --git a/example-lang/src/Lucy/Object/Host.c 
b/example-lang/src/Lucy/Object/Host.c
deleted file mode 100644
index dad09bd..0000000
--- a/example-lang/src/Lucy/Object/Host.c
+++ /dev/null
@@ -1,53 +0,0 @@
-/* Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include "CFBind.h"
-
-void
-lucy_Host_callback(void *vobj, char *method, uint32_t num_args, ...) {
-    THROW(LUCY_ERR, "TODO");
-}
-
-int64_t
-lucy_Host_callback_i64(void *vobj, char *method, uint32_t num_args, ...) {
-    THROW(LUCY_ERR, "TODO");
-    UNREACHABLE_RETURN(int64_t);
-}
-
-double
-lucy_Host_callback_f64(void *vobj, char *method, uint32_t num_args, ...) {
-    THROW(LUCY_ERR, "TODO");
-    UNREACHABLE_RETURN(double);
-}
-
-lucy_Obj*
-lucy_Host_callback_obj(void *vobj, char *method, uint32_t num_args, ...) {
-    THROW(LUCY_ERR, "TODO");
-    UNREACHABLE_RETURN(lucy_Obj*);
-}
-
-lucy_CharBuf*
-lucy_Host_callback_str(void *vobj, char *method, uint32_t num_args, ...) {
-    THROW(LUCY_ERR, "TODO");
-    UNREACHABLE_RETURN(lucy_CharBuf*);
-}
-
-void*
-lucy_Host_callback_host(void *vobj, char *method, uint32_t num_args, ...) {
-    THROW(LUCY_ERR, "TODO");
-    UNREACHABLE_RETURN(void*);
-}
-

http://git-wip-us.apache.org/repos/asf/lucy/blob/04965710/example-lang/src/Lucy/Object/LockFreeRegistry.c
----------------------------------------------------------------------
diff --git a/example-lang/src/Lucy/Object/LockFreeRegistry.c 
b/example-lang/src/Lucy/Object/LockFreeRegistry.c
deleted file mode 100644
index 5991ad3..0000000
--- a/example-lang/src/Lucy/Object/LockFreeRegistry.c
+++ /dev/null
@@ -1,28 +0,0 @@
-/* Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#define C_CFISH_LOCKFREEREGISTRY
-
-#include "CFBind.h"
-#include "Clownfish/LockFreeRegistry.h"
-
-void*
-lucy_LFReg_to_host(lucy_LockFreeRegistry *self) {
-    THROW(LUCY_ERR, "TODO");
-    UNREACHABLE_RETURN(void*);
-}
-
-

http://git-wip-us.apache.org/repos/asf/lucy/blob/04965710/example-lang/src/Lucy/Object/Obj.c
----------------------------------------------------------------------
diff --git a/example-lang/src/Lucy/Object/Obj.c 
b/example-lang/src/Lucy/Object/Obj.c
deleted file mode 100644
index 2e0551d..0000000
--- a/example-lang/src/Lucy/Object/Obj.c
+++ /dev/null
@@ -1,45 +0,0 @@
-/* Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#define C_CFISH_OBJ
-
-#include "CFBind.h"
-
-uint32_t
-lucy_Obj_get_refcount(lucy_Obj *self) {
-    THROW(LUCY_ERR, "TODO");
-    UNREACHABLE_RETURN(uint32_t);
-}
-
-lucy_Obj*
-lucy_Obj_inc_refcount(lucy_Obj *self) {
-    THROW(LUCY_ERR, "TODO");
-    UNREACHABLE_RETURN(lucy_Obj*);
-}
-
-uint32_t
-lucy_Obj_dec_refcount(lucy_Obj *self) {
-    THROW(LUCY_ERR, "TODO");
-    UNREACHABLE_RETURN(uint32_t);
-}
-
-void*
-lucy_Obj_to_host(lucy_Obj *self) {
-    THROW(LUCY_ERR, "TODO");
-    UNREACHABLE_RETURN(void*);
-}
-
-

http://git-wip-us.apache.org/repos/asf/lucy/blob/04965710/example-lang/src/Lucy/Object/VTable.c
----------------------------------------------------------------------
diff --git a/example-lang/src/Lucy/Object/VTable.c 
b/example-lang/src/Lucy/Object/VTable.c
deleted file mode 100644
index 3055f8d..0000000
--- a/example-lang/src/Lucy/Object/VTable.c
+++ /dev/null
@@ -1,50 +0,0 @@
-/* Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#define C_CFISH_OBJ
-#define C_CFISH_VTABLE
-
-#include "CFBind.h"
-
-lucy_Obj*
-lucy_VTable_foster_obj(lucy_VTable *self, void *host_obj) {
-    THROW(LUCY_ERR, "TODO");
-    UNREACHABLE_RETURN(lucy_Obj*);
-}
-
-void
-lucy_VTable_register_with_host(lucy_VTable *singleton, lucy_VTable *parent) {
-    THROW(LUCY_ERR, "TODO");
-}
-
-lucy_VArray*
-lucy_VTable_fresh_host_methods(const lucy_CharBuf *class_name) {
-    THROW(LUCY_ERR, "TODO");
-    UNREACHABLE_RETURN(lucy_VArray*);
-}
-
-lucy_CharBuf*
-lucy_VTable_find_parent_class(const lucy_CharBuf *class_name) {
-    THROW(LUCY_ERR, "TODO");
-    UNREACHABLE_RETURN(lucy_CharBuf*);
-}
-
-void*
-lucy_VTable_to_host(lucy_VTable *self) {
-    THROW(LUCY_ERR, "TODO");
-    UNREACHABLE_RETURN(void*);
-}
-

Reply via email to