mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-04-25 20:42:50 -06:00
Removing obsolete code in py-bindings.
This commit is contained in:
@@ -41,42 +41,12 @@ static PyObject*
|
|||||||
pgf_repr(PGF *self) {
|
pgf_repr(PGF *self) {
|
||||||
Lang* lang = gf_abstractName(self);
|
Lang* lang = gf_abstractName(self);
|
||||||
char* abs = gf_showLanguage(lang);
|
char* abs = gf_showLanguage(lang);
|
||||||
// gf_freeLanguage(&lang);
|
|
||||||
Py_DECREF(lang);
|
Py_DECREF(lang);
|
||||||
PyObject* str = PyString_FromFormat("<gf.pgf with abstract %s>", abs);
|
PyObject* str = PyString_FromFormat("<gf.pgf with abstract %s>", abs);
|
||||||
free(abs);
|
free(abs);
|
||||||
return str;
|
return str;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* static gfType*
|
|
||||||
startCategory(PGF *self, PyObject *noarg)
|
|
||||||
{
|
|
||||||
gfType *cat;
|
|
||||||
if (!checkType(self, &PGFType)) return NULL;
|
|
||||||
cat = (gfType*)gfTypeType.tp_new(&gfTypeType,NULL,NULL);
|
|
||||||
gf_startCat(self, cat);
|
|
||||||
return cat;
|
|
||||||
}
|
|
||||||
|
|
||||||
inline static PyObject*
|
|
||||||
categories(PGF* self)
|
|
||||||
{
|
|
||||||
return gf_categories(self);
|
|
||||||
}
|
|
||||||
|
|
||||||
inline static PyObject*
|
|
||||||
functions(PGF* self)
|
|
||||||
{
|
|
||||||
return gf_functions(self);
|
|
||||||
}
|
|
||||||
|
|
||||||
inline static PyObject*
|
|
||||||
languages(PGF* self)
|
|
||||||
{
|
|
||||||
return gf_languages(self);
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
|
|
||||||
static PyObject*
|
static PyObject*
|
||||||
languageCode(PGF *self, PyObject *args)
|
languageCode(PGF *self, PyObject *args)
|
||||||
{
|
{
|
||||||
@@ -263,7 +233,6 @@ infer_expr(Expr *self, PyObject* args) {
|
|||||||
PyErr_Format(PyExc_ValueError, "Must be a pgf module.");
|
PyErr_Format(PyExc_ValueError, "Must be a pgf module.");
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
// gfType* gftp = (gfType*)gfTypeType.tp_new(&gfTypeType,NULL,NULL);
|
|
||||||
return gf_inferexpr(pgf, self);
|
return gf_inferexpr(pgf, self);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user