Changeset 3e5610 in git
- Timestamp:
- Jul 12, 2018, 1:39:04 PM (5 years ago)
- Branches:
- (u'spielwiese', '8e0ad00ce244dfd0756200662572aef8402f13d5')
- Children:
- 6c8f2bd7d8f3d28a5621da4bfc39a75f6d4ce055
- Parents:
- ce5acd0310801fae5f6a56e78258c3ac612fe6ce
- git-author:
- Hans Schoenemann <hannes@mathematik.uni-kl.de>2018-07-12 13:39:04+02:00
- git-committer:
- Hans Schoenemann <hannes@mathematik.uni-kl.de>2018-07-12 13:47:55+02:00
- Location:
- kernel/GBEngine
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/GBEngine/gr_kstd2.cc
rce5acd0 r3e5610 102 102 if ((*h).p == NULL) 103 103 { 104 if (h->lcm!=NULL) p_LmFree((*h).lcm, currRing);104 kDeleteLcm(h); 105 105 return 0; 106 106 } … … 286 286 if ((*h).p == NULL) 287 287 { 288 if (h->lcm!=NULL) p_LmFree((*h).lcm, currRing);288 kDeleteLcm(h); 289 289 return 0; 290 290 } … … 399 399 { 400 400 if (TEST_OPT_DEBUG) PrintS(" to 0\n"); 401 if (h->lcm!=NULL) pLmFree((*h).lcm); 402 (*h).lcm=NULL; 401 kDeleteLcm(h); 403 402 return 0; 404 403 } … … 466 465 { 467 466 if (TEST_OPT_DEBUG) PrintS(" to 0\n"); 468 if (h->lcm!=NULL) pLmFree((*h).lcm); 469 (*h).lcm=NULL; 467 kDeleteLcm(h); 470 468 return 0; 471 469 } … … 548 546 { 549 547 if (TEST_OPT_DEBUG) PrintS(" to 0\n"); 550 if (h->lcm!=NULL) pLmFree((*h).lcm); 551 (*h).lcm=NULL; 548 kDeleteLcm(h); 552 549 return 0; 553 550 } … … 725 722 if ((*h).p == NULL) 726 723 { 727 if (h->lcm!=NULL) pLmFree((*h).lcm); 728 (*h).lcm=NULL; 724 kDeleteLcm(h); 729 725 return 0; 730 726 } … … 870 866 pLmFree(p); 871 867 pDelete(&((*h).p)); 872 if (h->lcm!=NULL) 873 { 874 pLmFree((*h).lcm); 875 (*h).lcm=NULL; 876 } 868 kDeleteLcm(h); 877 869 return 0; 878 870 } … … 895 887 else 896 888 { 897 if (h->lcm!=NULL) 898 { 899 pLmFree((*h).lcm); 900 (*h).lcm=NULL; 901 } 902 (*h).p = NULL; 889 kDeleteLcm(h); 903 890 return 0; 904 891 } … … 1245 1232 // if (hilb!=NULL) khCheck(Q,w,hilb,hilbeledeg,hilbcount,strat); 1246 1233 } 1247 if (strat->P.lcm!=NULL) pLmFree(strat->P.lcm); 1248 } 1249 #ifdef KDEBUG 1250 strat->P.lcm=NULL; 1251 #endif 1234 kDeleteLcm(&strat->P); 1235 } 1252 1236 //kTest(strat); 1253 1237 } -
kernel/GBEngine/kstd1.cc
rce5acd0 r3e5610 258 258 { 259 259 assume(!rField_is_Ring(currRing)); 260 if (h->lcm!=NULL) pLmFree(h->lcm);260 kDeleteLcm(h); 261 261 h->Clear(); 262 262 return 0; … … 361 361 if(h->p == NULL) 362 362 { 363 if (h->lcm!=NULL) pLmDelete(h->lcm);363 kDeleteLcm(h); 364 364 h->Clear(); 365 365 return 0; … … 372 372 if (h->GetLmTailRing() == NULL) 373 373 { 374 if (h->lcm!=NULL) pLmDelete(h->lcm);374 kDeleteLcm(h); 375 375 h->Clear(); 376 376 return 0; … … 454 454 if (h->IsNull()) 455 455 { 456 if (h->lcm!=NULL) pLmDelete(h->lcm);456 kDeleteLcm(h); 457 457 h->Clear(); 458 458 return 0; … … 575 575 { 576 576 assume(!rField_is_Ring(currRing)); 577 if (h->lcm!=NULL) pLmFree(h->lcm);577 kDeleteLcm(h); 578 578 h->Clear(); 579 579 return 0; … … 1703 1703 1704 1704 // clear strat->P 1705 if (strat->P.lcm!=NULL) 1706 { 1707 if (rField_is_Ring(currRing)) 1708 pLmDelete(strat->P.lcm); 1709 else 1710 pLmFree(strat->P.lcm); 1711 strat->P.lcm=NULL; 1712 } 1705 kDeleteLcm(&strat->P); 1713 1706 1714 1707 #ifdef KDEBUG … … 3321 3314 // clean P 3322 3315 } 3323 if (strat->P.lcm!=NULL) 3324 #ifdef HAVE_RINGS 3325 pLmDelete(strat->P.lcm); 3326 #else 3327 pLmFree(strat->P.lcm); 3328 #endif 3316 kDeleteLcm(&strat->P); 3329 3317 } 3330 3318 -
kernel/GBEngine/kstd2.cc
rce5acd0 r3e5610 462 462 if(h->p == NULL) 463 463 { 464 if (h->lcm!=NULL) pLmDelete(h->lcm);464 kDeleteLcm(h); 465 465 h->Clear(); 466 466 return 0; … … 476 476 if (h->GetLmTailRing() == NULL) 477 477 { 478 if (h->lcm!=NULL) pLmDelete(h->lcm);478 kDeleteLcm(h); 479 479 h->Clear(); 480 480 return 0; … … 489 489 if (h->GetLmTailRing() == NULL) 490 490 { 491 if (h->lcm!=NULL) pLmDelete(h->lcm); 492 #ifdef KDEBUG 493 h->lcm=NULL; 494 #endif 491 kDeleteLcm(h); 495 492 h->Clear(); 496 493 return 0; … … 635 632 if (h_p == NULL) 636 633 { 637 if (h->lcm!=NULL) pLmFree(h->lcm); 638 #ifdef KDEBUG 639 h->lcm=NULL; 640 #endif 634 kDeleteLcm(h); 641 635 return 0; 642 636 } … … 839 833 if (h_p == NULL) 840 834 { 841 if (h->lcm!=NULL) pLmFree(h->lcm); 842 #ifdef KDEBUG 843 h->lcm=NULL; 844 #endif 835 kDeleteLcm(h); 845 836 return 0; 846 837 } … … 947 938 if (h->GetLmTailRing() == NULL) 948 939 { 949 if (h->lcm!=NULL) pLmDelete(h->lcm);940 kDeleteLcm(h); 950 941 h->Clear(); 951 942 return 0; … … 1091 1082 if (h_p == NULL) 1092 1083 { 1093 if (h->lcm!=NULL) pLmFree(h->lcm); 1094 #ifdef KDEBUG 1095 h->lcm=NULL; 1096 #endif 1084 kDeleteLcm(h); 1097 1085 return 0; 1098 1086 } … … 1341 1329 if (h_p == NULL) 1342 1330 { 1343 if (h->lcm!=NULL) pLmFree(h->lcm); 1344 #ifdef KDEBUG 1345 h->lcm=NULL; 1346 #endif 1331 kDeleteLcm(h); 1347 1332 return 0; 1348 1333 } … … 1514 1499 if(h->IsNull()) 1515 1500 { 1501 kDeleteLcm(h); 1516 1502 h->Clear(); 1517 if (h->lcm!=NULL) pLmFree(h->lcm);1518 #ifdef KDEBUG1519 h->lcm=NULL;1520 #endif1521 1503 return 0; 1522 1504 } … … 2144 2126 if (hilb!=NULL) khCheck(Q,w,hilb,hilbeledeg,hilbcount,strat); 2145 2127 // Print("[%d]",hilbeledeg); 2146 if (strat->P.lcm!=NULL) 2147 { 2148 if (rField_is_Ring(currRing)) pLmDelete(strat->P.lcm); 2149 else pLmFree(strat->P.lcm); 2150 strat->P.lcm=NULL; 2151 } 2128 kDeleteLcm(&strat->P); 2152 2129 if (strat->s_poly!=NULL) 2153 2130 { … … 2589 2566 int pos = posInSyz(strat, strat->P.sig); 2590 2567 enterSyz(strat->P, strat, pos); 2591 if (strat->P.lcm!=NULL) 2592 pLmFree(strat->P.lcm); 2568 kDeleteLcm(&strat->P); 2593 2569 red_result = 2; 2594 2570 } … … 2987 2963 if (hilb!=NULL) khCheck(Q,w,hilb,hilbeledeg,hilbcount,strat); 2988 2964 // Print("[%d]",hilbeledeg); 2989 if (strat->P.lcm!=NULL) 2990 #ifdef HAVE_RINGS 2991 pLmDelete(strat->P.lcm); 2992 #else 2993 pLmFree(strat->P.lcm); 2994 #endif 2965 kDeleteLcm(&strat->P); 2995 2966 if (strat->sl>srmax) srmax = strat->sl; 2996 2967 } … … 3764 3735 } 3765 3736 // Print("[%d]",hilbeledeg); 3766 if (strat->P.lcm!=NULL) 3767 #ifdef HAVE_RINGS 3768 pLmDelete(strat->P.lcm); 3769 #else 3770 pLmFree(strat->P.lcm); 3771 #endif 3737 kDeleteLcm(&strat->P); 3772 3738 if (strat->sl>srmax) srmax = strat->sl; 3773 3739 } … … 4136 4102 if (hilb!=NULL) khCheck(Q,w,hilb,hilbeledeg,hilbcount,strat); 4137 4103 // Print("[%d]",hilbeledeg); 4138 if (strat->P.lcm!=NULL) pLmFree(strat->P.lcm);4104 kDeleteLcm(&strat->P); 4139 4105 } 4140 4106 else … … 4318 4284 if (h->IsNull()) 4319 4285 { 4320 if (h->lcm!=NULL) pLmFree(h->lcm);4286 kDeleteLcm(h); 4321 4287 h->Clear(); 4322 4288 return 0; -
kernel/GBEngine/kstdfac.cc
rce5acd0 r3e5610 575 575 } 576 576 } 577 if (strat->P.lcm!=NULL) pLmFree(strat->P.lcm);577 kDeleteLcm(&strat->P); 578 578 int i; 579 579 -
kernel/GBEngine/kutil.cc
rce5acd0 r3e5610 1154 1154 if (set[j].lcm!=NULL) 1155 1155 { 1156 #ifdef HAVE_RINGS 1157 if (rField_is_Ring(currRing) 1158 && (pGetCoeff(set[j].lcm) != NULL)) 1159 pLmDelete(set[j].lcm); 1160 else 1161 #endif 1162 pLmFree(set[j].lcm); 1156 kDeleteLcm(&set[j]); 1163 1157 } 1164 1158 if (set[j].sig!=NULL) -
kernel/GBEngine/kutil.h
rce5acd0 r3e5610 841 841 extern int (*test_PosInL)(const LSet set, const int length, 842 842 LObject* L,const kStrategy strat); 843 #endif 843 844 static inline void kDeleteLcm(LObject *P) 845 { 846 if (P->lcm!=NULL) 847 { 848 #ifdef HAVE_RINGS 849 if (rField_is_Ring(currRing)) 850 pLmDelete(P->lcm); 851 else 852 #endif 853 pLmFree(P->lcm); 854 P->lcm=NULL; 855 } 856 } 857 #endif -
kernel/GBEngine/sca.cc
rce5acd0 r3e5610 86 86 // enterT(h, strat); // ?! 87 87 88 if (h.lcm!=NULL) pLmFree(h.lcm);88 kDeleteLcm(&h); 89 89 } 90 90 … … 681 681 682 682 // Print("[%d]",hilbeledeg); 683 if (strat->P.lcm!=NULL) pLmFree(strat->P.lcm);683 kDeleteLcm(&strat->P); 684 684 685 685 // ////////////////////////////////////////////////////////// … … 1109 1109 1110 1110 // clear strat->P 1111 if (strat->P.lcm!=NULL) pLmFree(strat->P.lcm); 1112 strat->P.lcm=NULL; 1111 kDeleteLcm(&strat->P); 1113 1112 1114 1113 // //////////////////////////////////////////////////////////
Note: See TracChangeset
for help on using the changeset viewer.