sagemath / sage

Main repository of SageMath. Now open for Issues and Pull Requests.
https://www.sagemath.org
Other
1.19k stars 411 forks source link

Cython vtable warnings in padics #24609

Open jdemeyer opened 6 years ago

jdemeyer commented 6 years ago
warning: sage/rings/padics/CR_template.pxi:779:10: Compatible but non-identical C method '_floordiv_' not redeclared in definition part of extension type 'CRElement'.  This may cause incorrect vtables to be generated.
warning: sage/rings/padics/CR_template.pxi:1396:10: Compatible but non-identical C method 'val_unit' not redeclared in definition part of extension type 'CRElement'.  This may cause incorrect vtables to be generated.
warning: sage/rings/padics/FP_template.pxi:1096:10: Compatible but non-identical C method 'val_unit' not redeclared in definition part of extension type 'FPElement'.  This may cause incorrect vtables to be generated.
warning: sage/rings/padics/CR_template.pxi:779:10: Compatible but non-identical C method '_floordiv_' not redeclared in definition part of extension type 'CRElement'.  This may cause incorrect vtables to be generated.
warning: sage/rings/padics/CR_template.pxi:1396:10: Compatible but non-identical C method 'val_unit' not redeclared in definition part of extension type 'CRElement'.  This may cause incorrect vtables to be generated.
warning: sage/rings/padics/FP_template.pxi:1096:10: Compatible but non-identical C method 'val_unit' not redeclared in definition part of extension type 'FPElement'.  This may cause incorrect vtables to be generated.
warning: sage/rings/padics/padic_generic_element.pyx:279:10: Compatible but non-identical C method '_floordiv_' not redeclared in definition part of extension type 'pAdicGenericElement'.  This may cause incorrect vtables to be generated.
warning: sage/rings/padics/padic_generic_element.pyx:390:10: Compatible but non-identical C method '_mod_' not redeclared in definition part of extension type 'pAdicGenericElement'.  This may cause incorrect vtables to be generated.

This is part of #23600.

CC: @roed314

Component: padics

Keywords: padicIMA

Work Issues: rename right to other; add p parameter to val_unit everywhere

Author: Julian Rüth

Branch/Commit: u/saraedum/24609 @ a0bac48

Issue created by migration from https://trac.sagemath.org/ticket/24609

jdemeyer commented 6 years ago

Description changed:

--- 
+++ 
@@ -6,6 +6,8 @@
 warning: sage/rings/padics/CR_template.pxi:779:10: Compatible but non-identical C method '_floordiv_' not redeclared in definition part of extension type 'CRElement'.  This may cause incorrect vtables to be generated.
 warning: sage/rings/padics/CR_template.pxi:1396:10: Compatible but non-identical C method 'val_unit' not redeclared in definition part of extension type 'CRElement'.  This may cause incorrect vtables to be generated.
 warning: sage/rings/padics/FP_template.pxi:1096:10: Compatible but non-identical C method 'val_unit' not redeclared in definition part of extension type 'FPElement'.  This may cause incorrect vtables to be generated.
+warning: sage/rings/padics/padic_generic_element.pyx:279:10: Compatible but non-identical C method '_floordiv_' not redeclared in definition part of extension type 'pAdicGenericElement'.  This may cause incorrect vtables to be generated.
+warning: sage/rings/padics/padic_generic_element.pyx:390:10: Compatible but non-identical C method '_mod_' not redeclared in definition part of extension type 'pAdicGenericElement'.  This may cause incorrect vtables to be generated.

This is part of #23600.

roed314 commented 5 years ago

Changed keywords from none to padicIMA

saraedum commented 5 years ago

Author: Julian Rüth

saraedum commented 5 years ago

Branch: u/saraedum/24609

saraedum commented 5 years ago

Work Issues: is the patchbot happy?

saraedum commented 5 years ago

Commit: a0bac48

saraedum commented 5 years ago

New commits:

a0bac48Fixes Cython warnings
saraedum commented 5 years ago
comment:6

I have not tested this, but the warnings are gone.

jdemeyer commented 5 years ago
comment:7

Minor nitpick, but could you use self, other instead of self, right?

saraedum commented 5 years ago
comment:8

The implementation uses right. So I should change all the implementations as well I guess?

jdemeyer commented 5 years ago
comment:9

I don't care so much. Whatever you feel like.

saraedum commented 5 years ago

Changed work issues from is the patchbot happy? to rename right to other; add p parameter to val_unit everywhere