diff --git a/kitty/cocoa_window.m b/kitty/cocoa_window.m index e0286df069..a660c555b8 100644 --- a/kitty/cocoa_window.m +++ b/kitty/cocoa_window.m @@ -939,7 +939,7 @@ - (BOOL)openFileURLs:(NSPasteboard*)pasteboard } static PyObject* -cocoa_get_lang(PyObject UNUSED *self) { +cocoa_get_lang(PyObject UNUSED *self, PyObject *args UNUSED) { @autoreleasepool { NSString* lang_code = [[NSLocale currentLocale] languageCode]; NSString* country_code = [[NSLocale currentLocale] objectForKey:NSLocaleCountryCode]; diff --git a/kitty/core_text.m b/kitty/core_text.m index 59d700c3df..af6301586d 100644 --- a/kitty/core_text.m +++ b/kitty/core_text.m @@ -1035,7 +1035,7 @@ static CTFontRef nerd_font(CGFloat sz) { } static PyObject* -get_variation(CTFace *self) { +get_variation(CTFace *self, PyObject *args UNUSED) { RAII_CoreFoundation(CFDictionaryRef, src, CTFontCopyVariation(self->ct_font)); return variation_to_python(src); } @@ -1062,7 +1062,7 @@ static CTFontRef nerd_font(CGFloat sz) { static PyObject* -get_variable_data(CTFace *self) { +get_variable_data(CTFace *self, PyObject *args UNUSED) { if (!ensure_name_table(self)) return NULL; RAII_PyObject(output, PyDict_New()); if (!output) return NULL; @@ -1078,7 +1078,7 @@ static CTFontRef nerd_font(CGFloat sz) { } static PyObject* -identify_for_debug(CTFace *self) { +identify_for_debug(CTFace *self, PyObject *args UNUSED) { RAII_PyObject(features, PyTuple_New(self->font_features.count)); if (!features) return NULL; char buf[128]; for (unsigned i = 0; i < self->font_features.count; i++) { @@ -1095,13 +1095,13 @@ static CTFontRef nerd_font(CGFloat sz) { // Boilerplate {{{ static PyObject* -display_name(CTFace *self) { +display_name(CTFace *self, PyObject *args UNUSED) { CFStringRef dn = CTFontCopyDisplayName(self->ct_font); return convert_cfstring(dn, true); } static PyObject* -postscript_name(CTFace *self) { +postscript_name(CTFace *self, PyObject *args UNUSED) { return self->postscript_name ? Py_BuildValue("O", self->postscript_name) : PyUnicode_FromString(""); } diff --git a/kitty/data-types.c b/kitty/data-types.c index d0ebae69c5..301b561b8c 100644 --- a/kitty/data-types.c +++ b/kitty/data-types.c @@ -42,14 +42,14 @@ #include static PyObject* -user_cache_dir(void) { +user_cache_dir(PyObject *self UNUSED, PyObject *args UNUSED) { static char buf[1024]; if (!confstr(_CS_DARWIN_USER_CACHE_DIR, buf, sizeof(buf) - 1)) return PyErr_SetFromErrno(PyExc_OSError); return PyUnicode_FromString(buf); } static PyObject* -process_group_map(void) { +process_group_map(PyObject *self UNUSED, PyObject *args UNUSED) { int num_of_processes = proc_listallpids(NULL, 0); size_t bufsize = sizeof(pid_t) * (num_of_processes + 1024); RAII_ALLOC(pid_t, buf, malloc(bufsize));