Changeset 85e36d in git for Singular/mpsr_GetPoly.cc
- Timestamp:
- Dec 7, 2000, 5:25:19 PM (23 years ago)
- Branches:
- (u'spielwiese', '17f1d200f27c5bd38f5dfc6e8a0879242279d1d8')
- Children:
- 4d688465cef2d21563e211d3a815944e412b94db
- Parents:
- a4f307a99ef35df8d18781c23cf3f7ad97cb4d4b
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Singular/mpsr_GetPoly.cc
ra4f307a r85e36d 3 3 ****************************************/ 4 4 5 /* $Id: mpsr_GetPoly.cc,v 1.3 0 2000-10-19 15:00:18 obachmanExp $ */5 /* $Id: mpsr_GetPoly.cc,v 1.31 2000-12-07 16:25:19 Singular Exp $ */ 6 6 7 7 /*************************************************************** … … 252 252 *x = (number) omAlloc0Bin(rnumber_bin); 253 253 y = (number) *x; 254 #if defined(LDEBUG) 254 #if defined(LDEBUG) 255 255 y->debug = 123456; 256 256 #endif … … 277 277 *x = (number) omAlloc0Bin(rnumber_bin); 278 278 y = (number) *x; 279 #if defined(LDEBUG) 279 #if defined(LDEBUG) 280 280 y->debug = 123456; 281 281 #endif … … 301 301 * 302 302 ***************************************************************/ 303 static inline mpsr_Status_t GetAlgPoly(MP_Link_pt link, alg*p)303 static inline mpsr_Status_t GetAlgPoly(MP_Link_pt link, napoly *p) 304 304 { 305 305 MP_Uint32_t j, nm; 306 306 int i; 307 alg a; 308 #if SIZEOF_INT == SIZEOF_PARAMETER 309 Exponent_t *exp; 310 #else 307 napoly a; 311 308 int *exp; 312 #endif313 309 314 310 IMP_GetUint32(link, &nm); … … 322 318 *p = a; 323 319 324 failr(GetAlgNumberNumber(link, &(a->ko))); 325 #if SIZEOF_INT == SIZEOF_PARAMETER 326 exp = &(a->e[0]); 327 mp_failr(IMP_GetSint32Vector(link, (MP_Sint32_t **) &exp, naNumbOfPar)); 328 #else 320 failr(GetAlgNumberNumber(link, &(napGetCoeff(a)))); 329 321 mp_failr(IMP_GetSint32Vector(link, (MP_Sint32_t **) &gTa, naNumbOfPar)); 330 322 for (i=0; i<naNumbOfPar; i++) 331 a->e[i] = (PARAMETER_TYPE) gTa[i]; 332 #endif 323 napSetExp(a,i+1,gTa[i]); 333 324 334 325 for (j=1; j<nm; j++) 335 326 { 336 a->ne = napNew(); 337 a = a->ne; 338 failr(GetAlgNumberNumber(link, &(a->ko))); 339 #if SIZEOF_INT == SIZEOF_PARAMETER 340 exp = &(a->e[0]); 341 mp_failr(IMP_GetSint32Vector(link, (MP_Sint32_t **) &exp, naNumbOfPar)); 342 #else 343 mp_failr(IMP_GetSint32Vector(link, (MP_Sint32_t **) &gTa, naNumbOfPar)); 344 for (i=0; i<naNumbOfPar; i++) 345 a->e[i] = (PARAMETER_TYPE) gTa[i]; 346 #endif 347 } 348 a->ne = NULL; 327 napNext(a) = napNew(); 328 napIter(a); 329 failr(GetAlgNumberNumber(link, &(napGetCoeff(a)))); 330 mp_failr(IMP_GetSint32Vector(link, (MP_Sint32_t **) &gTa, naNumbOfPar)); 331 for (i=0; i<naNumbOfPar; i++) 332 napSetExp(a,i+1,gTa[i]); 333 } 334 napNext(a) = NULL; 349 335 350 336 return mpsr_Success; … … 1024 1010 return mpsr_Success; 1025 1011 } 1026 1027 1012 #endif
Note: See TracChangeset
for help on using the changeset viewer.