PIPS
constraint_to_text.c File Reference
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include "linear.h"
#include "genC.h"
#include "text.h"
#include "text-util.h"
#include "properties.h"
#include "misc.h"
#include "ri.h"
#include "ri-util.h"
+ Include dependency graph for constraint_to_text.c:

Go to the source code of this file.

Functions

void sc_syst_debug (Psysteme s)
 constraint_to_text.c More...
 
void inegalite_debug (Pcontrainte c)
 
void egalite_debug (Pcontrainte c)
 
static string the_operator (bool is_inegalite, bool a_la_fortran)
 
static void add_Value_to_current_line (string buffer, Value v, string continuation, text t)
 
static void constante_to_textline (string buffer, Value constante, bool is_inegalite, bool a_la_fortran, string continuation, text t)
 
static void unsigned_operation_to_textline (string buffer, Value coeff, Variable var, char *(*variable_name)(Variable), string continuation, text t)
 
static void signed_operation_to_textline (string buffer, string signe, Value coeff, Variable var, char *(*variable_name)(Variable), string continuation, text t)
 
static char * contrainte_to_text_1 (string buffer, string continuation, text txt, Pvecteur v, bool is_inegalite, char *(*variable_name)(Variable), bool a_la_fortran, bool __attribute__((unused)) first_line)
 
static string contrainte_to_text_2 (string buffer, string continuation, text txt, Pvecteur v, bool is_inegalite, string(*variable_name)(Variable), bool a_la_fortran, bool __attribute__((unused)) first_line)
 FI: does not take into account constant floating point terms. More...
 
string contrainte_text_format (string aux_line, string continuation, text txt, Pcontrainte c, bool is_inegalite, string(*variable_name)(Variable), bool a_la_fortran, bool first_line)
 
string egalite_text_format (string aux_line, string continuation, text txt, Pcontrainte eg, string(*variable_name)(Variable), bool a_la_fortran, bool first_line)
 
string inegalite_text_format (string aux_line, string continuation, text txt, Pcontrainte ineg, string(*variable_name)(), bool a_la_fortran, bool first_line)
 
static void add_separation (string line, string prefix, text txt, bool a_la_fortran)
 
static bool contraintes_text_format (string line, string prefix, text txt, Pcontrainte cs, string(*variable_name)(Variable), bool invert_put_first, bool(*put_first)(Pvecteur), bool some_previous, bool is_inegalites, bool a_la_fortran)
 
void system_sorted_text_format (string line, string prefix, text txt, Psysteme ps, string(*variable_name)(Variable), bool(*put_first)(Pvecteur), bool a_la_fortran)
 lower level hook for regions. More...
 
void system_text_format (string line, string prefix, text txt, Psysteme ps, string(*variable_name)(Variable), bool a_la_fortran)
 appends ps to line/txt with prefix continuations. More...
 
void entity_list_text_format (string line, string continuation, text t, list le, const char *(*var_name)(entity))
 appends the list of entity... More...
 

Function Documentation

◆ add_separation()

static void add_separation ( string  line,
string  prefix,
text  txt,
bool  a_la_fortran 
)
static

Definition at line 350 of file constraint_to_text.c.

351 {
352  add_to_current_line(line, a_la_fortran? ".AND.": ", ", prefix, txt);
353 }
static const char * prefix
static int line
FLEX_SCANNER.
Definition: scanner.c:852
void add_to_current_line(string, const char *, string, text)
Definition: util.c:140

References add_to_current_line(), line, and prefix.

Referenced by contraintes_text_format().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ add_Value_to_current_line()

static void add_Value_to_current_line ( string  buffer,
Value  v,
string  continuation,
text  t 
)
static

Definition at line 70 of file constraint_to_text.c.

75 {
77 }
char * Value_to_string(Value)
Definition: io.c:76
#define continuation
Definition: prettyprint.c:102
static string buffer
Definition: string.c:113

References add_to_current_line(), buffer, continuation, and Value_to_string().

Referenced by constante_to_textline(), contrainte_to_text_2(), and unsigned_operation_to_textline().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ constante_to_textline()

static void constante_to_textline ( string  buffer,
Value  constante,
bool  is_inegalite,
bool  a_la_fortran,
string  continuation,
text  t 
)
static

Definition at line 80 of file constraint_to_text.c.

87 {
88  add_to_current_line(buffer, the_operator(is_inegalite, a_la_fortran),
89  continuation, t);
91 }
static string the_operator(bool is_inegalite, bool a_la_fortran)
static void add_Value_to_current_line(string buffer, Value v, string continuation, text t)

References add_to_current_line(), add_Value_to_current_line(), buffer, continuation, and the_operator().

Referenced by contrainte_to_text_1().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ contrainte_text_format()

string contrainte_text_format ( string  aux_line,
string  continuation,
text  txt,
Pcontrainte  c,
bool  is_inegalite,
string(*)(Variable variable_name,
bool  a_la_fortran,
bool  first_line 
)
Parameters
aux_lineux_line
continuationontinuation
txtxt
is_inegalites_inegalite
a_la_fortran_la_fortran
first_lineirst_line

Definition at line 285 of file constraint_to_text.c.

294 {
295  Pvecteur v;
296  int heuristique = 2;
297 
298  if (!CONTRAINTE_UNDEFINED_P(c))
299  v = contrainte_vecteur(c);
300  else
301  v = VECTEUR_NUL;
302 
303  pips_assert("vector v is okay", vect_check(v));
304 
305  switch(heuristique) {
306  case 1: aux_line = contrainte_to_text_1(aux_line,continuation,txt,
307  v,is_inegalite, variable_name,
308  a_la_fortran, first_line);
309  break;
310  case 2:aux_line = contrainte_to_text_2(aux_line,continuation,txt,v,
311  is_inegalite, variable_name,
312  a_la_fortran, first_line);
313  break;
314  default: contrainte_error("contrainte_sprint", "unknown heuristics\n");
315  }
316 
317  return aux_line;
318 }
static string contrainte_to_text_2(string buffer, string continuation, text txt, Pvecteur v, bool is_inegalite, string(*variable_name)(Variable), bool a_la_fortran, bool __attribute__((unused)) first_line)
FI: does not take into account constant floating point terms.
static char * contrainte_to_text_1(string buffer, string continuation, text txt, Pvecteur v, bool is_inegalite, char *(*variable_name)(Variable), bool a_la_fortran, bool __attribute__((unused)) first_line)
#define CONTRAINTE_UNDEFINED_P(c)
#define contrainte_vecteur(c)
passage au champ vecteur d'une contrainte "a la Newgen"
void contrainte_error(char *, char *,...)
error.c
Definition: error.c:49
bool vect_check(Pvecteur cv)
bool vect_check(Pvecteur v): renvoie true si le vecteur v est coherent avec les specifications du pac...
Definition: reductions.c:529
#define pips_assert(what, predicate)
common macros, two flavors depending on NDEBUG
Definition: misc-local.h:172
char * variable_name(Variable v)
polynome_ri.c
Definition: polynome_ri.c:73
le type des coefficients dans les vecteurs: Value est defini dans le package arithmetique
Definition: vecteur-local.h:89
#define VECTEUR_NUL
DEFINITION DU VECTEUR NUL.

References continuation, contrainte_error(), contrainte_to_text_1(), contrainte_to_text_2(), CONTRAINTE_UNDEFINED_P, contrainte_vecteur, pips_assert, variable_name(), vect_check(), and VECTEUR_NUL.

Referenced by contraintes_text_format(), egalite_text_format(), and inegalite_text_format().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ contrainte_to_text_1()

static char* contrainte_to_text_1 ( string  buffer,
string  continuation,
text  txt,
Pvecteur  v,
bool  is_inegalite,
char *(*)(Variable variable_name,
bool  a_la_fortran,
bool __attribute__((unused))  first_line 
)
static

on admet plusieurs occurences du terme constant!?!

Definition at line 123 of file constraint_to_text.c.

132 {
133  short int debut = 1;
134  Value constante = VALUE_ZERO;
135 
136  while (!VECTEUR_NUL_P(v))
137  {
138  Variable var = var_of(v);
139  Value coeff = val_of(v);
140 
141  if (var!=TCST) {
142  string signe;
143 
144  if (value_notzero_p(coeff)) {
145  if (value_pos_p(coeff))
146  signe = "+";
147  else {
148  signe = "-";
149  coeff = value_uminus(coeff);
150  };
151  if (value_pos_p(coeff) && debut)
154  continuation, txt);
155  else
156  signed_operation_to_textline(buffer, signe, coeff,
157  var, variable_name,
158  continuation, txt);
159  debut = 0;
160  }
161  }
162  else
163  /* on admet plusieurs occurences du terme constant!?! */
164  value_addto(constante, coeff);
165 
166  v = v->succ;
167  }
168  constante_to_textline(buffer,value_uminus(constante),is_inegalite,
169  a_la_fortran, continuation, txt);
170  return buffer;
171 }
#define value_pos_p(val)
#define VALUE_ZERO
#define value_notzero_p(val)
#define value_uminus(val)
unary operators on values
int Value
#define value_addto(ref, val)
static void signed_operation_to_textline(string buffer, string signe, Value coeff, Variable var, char *(*variable_name)(Variable), string continuation, text t)
static void constante_to_textline(string buffer, Value constante, bool is_inegalite, bool a_la_fortran, string continuation, text t)
static void unsigned_operation_to_textline(string buffer, Value coeff, Variable var, char *(*variable_name)(Variable), string continuation, text t)
struct Svecteur * succ
Definition: vecteur-local.h:92
#define TCST
VARIABLE REPRESENTANT LE TERME CONSTANT.
#define val_of(varval)
#define VECTEUR_NUL_P(v)
void * Variable
arithmetique is a requirement for vecteur, but I do not want to inforce it in all pips files....
Definition: vecteur-local.h:60
#define var_of(varval)

References buffer, constante_to_textline(), continuation, signed_operation_to_textline(), Svecteur::succ, TCST, unsigned_operation_to_textline(), val_of, value_addto, value_notzero_p, value_pos_p, value_uminus, VALUE_ZERO, var_of, variable_name(), and VECTEUR_NUL_P.

Referenced by contrainte_text_format().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ contrainte_to_text_2()

static string contrainte_to_text_2 ( string  buffer,
string  continuation,
text  txt,
Pvecteur  v,
bool  is_inegalite,
string(*)(Variable variable_name,
bool  a_la_fortran,
bool __attribute__((unused))  first_line 
)
static

FI: does not take into account constant floating point terms.

No easy modification. I give up for the time being. 25 July 2011.

Save the constant term for future use

And now, a lie... In fact, rhs_terms++

Definition at line 178 of file constraint_to_text.c.

187 {
188  Pvecteur coord;
189  short int debut = true;
190  int positive_terms = 0;
191  int negative_terms = 0;
192  Value const_coeff = 0;
193  bool const_coeff_p = false;
194  string signe;
195 
196  if(!is_inegalite) {
197  for(coord = v; !VECTEUR_NUL_P(coord); coord = coord->succ) {
198  if(vecteur_var(coord)!= TCST
199  && !entity_constant_p((entity)vecteur_var(coord)))
200  (value_pos_p(vecteur_val(coord))) ?
201  positive_terms++ : negative_terms++;
202  }
203 
204  if(negative_terms > positive_terms)
205  vect_chg_sgn(v);
206  }
207 
208  positive_terms = 0;
209  negative_terms = 0;
210 
211  for(coord = v; !VECTEUR_NUL_P(coord); coord = coord->succ) {
212  Value coeff = vecteur_val(coord);
213  Variable var = vecteur_var(coord);
214 
215  if (value_pos_p(coeff)) {
216  positive_terms++;
217  if(!term_cst(coord)|| is_inegalite)
218  {
219  signe = "+";
220  if (debut)
222  continuation, txt);
223  else
225  continuation, txt);
226  debut=false;
227  }
228  else positive_terms--;
229  }
230  }
231 
232  if(positive_terms == 0)
234 
235  add_to_current_line(buffer, the_operator(is_inegalite, a_la_fortran),
236  continuation, txt);
237 
238  debut = true;
239  for(coord = v; !VECTEUR_NUL_P(coord); coord = coord->succ)
240  {
241  Value coeff = vecteur_val(coord);
242  Variable var = var_of(coord);
243 
244  if(term_cst(coord) && !is_inegalite) {
245  /* Save the constant term for future use */
246  const_coeff_p = true;
247  const_coeff = coeff;
248  /* And now, a lie... In fact, rhs_terms++ */
249  negative_terms++;
250  }
251  else if (value_neg_p(coeff))
252  {
253  negative_terms++;
254  signe = "+";
255  if (debut) {
257  (buffer, value_uminus(coeff), var, variable_name,
258  continuation, txt);
259  debut=false;
260  }
261  else
263  (buffer, signe, value_uminus(coeff),var, variable_name,
264  continuation, txt);
265  }
266  }
267 
268  if(negative_terms == 0)
270 
271  else if(const_coeff_p)
272  {
273  pips_assert("const coeff not zero", value_notzero_p(const_coeff));
274  if (!debut && value_neg_p(const_coeff))
277  continuation, txt);
278  }
279 
280  return buffer;
281 }
#define value_neg_p(val)
#define entity_constant_p(e)
void vect_chg_sgn(Pvecteur v)
void vect_chg_sgn(Pvecteur v): multiplie v par -1
Definition: scalaires.c:151
#define vecteur_val(v)
#define vecteur_var(v)
#define term_cst(varval)

References add_to_current_line(), add_Value_to_current_line(), buffer, continuation, entity_constant_p, pips_assert, signed_operation_to_textline(), Svecteur::succ, TCST, term_cst, the_operator(), unsigned_operation_to_textline(), value_neg_p, value_notzero_p, value_pos_p, value_uminus, var_of, variable_name(), vect_chg_sgn(), VECTEUR_NUL_P, vecteur_val, and vecteur_var.

Referenced by contrainte_text_format().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ contraintes_text_format()

static bool contraintes_text_format ( string  line,
string  prefix,
text  txt,
Pcontrainte  cs,
string(*)(Variable variable_name,
bool  invert_put_first,
bool(*)(Pvecteur put_first,
bool  some_previous,
bool  is_inegalites,
bool  a_la_fortran 
)
static
Parameters
prefixcurrent buffer
txtfor continuations
csformed text
variable_namecontraintes to be printed
invert_put_firsthook for naming a variable
put_firstwhether to invert put_first
some_previouswhether to put first some constraints
is_inegaliteswhether a separator is needed
a_la_fortranegalites or inegalites fortran look?

Definition at line 356 of file constraint_to_text.c.

367 {
368  for (; cs; cs=cs->succ)
369  {
370  if (put_first? (invert_put_first ^ put_first(cs->vecteur)): true)
371  {
372  if (some_previous) add_separation(line, prefix, txt, a_la_fortran);
373  else some_previous = true;
374 
375  if (a_la_fortran)
376  add_to_current_line(line, "(", prefix, txt);
377 
378  contrainte_text_format(line, prefix, txt, cs, is_inegalites,
379  variable_name, false, a_la_fortran);
380 
381  if (a_la_fortran)
382  add_to_current_line(line, ")", prefix, txt);
383  }
384  }
385  return some_previous;
386 }
string contrainte_text_format(string aux_line, string continuation, text txt, Pcontrainte c, bool is_inegalite, string(*variable_name)(Variable), bool a_la_fortran, bool first_line)
static void add_separation(string line, string prefix, text txt, bool a_la_fortran)
Pvecteur vecteur
struct Scontrainte * succ

References add_separation(), add_to_current_line(), contrainte_text_format(), line, prefix, Scontrainte::succ, variable_name(), and Scontrainte::vecteur.

Referenced by system_sorted_text_format().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ egalite_debug()

void egalite_debug ( Pcontrainte  c)

Definition at line 58 of file constraint_to_text.c.

59 {
61 }
void egalite_fprint(FILE *, Pcontrainte, char *(*)(Variable))
const char * entity_local_name(entity e)
entity_local_name modified so that it does not core when used in vect_fprint, since someone thought t...
Definition: entity.c:453
char *(* get_variable_name_t)(Variable)
Definition: vecteur-local.h:62

References egalite_fprint(), and entity_local_name().

Referenced by sc_projection_optim_along_vecteur_ofl().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ egalite_text_format()

string egalite_text_format ( string  aux_line,
string  continuation,
text  txt,
Pcontrainte  eg,
string(*)(Variable variable_name,
bool  a_la_fortran,
bool  first_line 
)
Parameters
aux_lineux_line
continuationontinuation
txtxt
egg
a_la_fortran_la_fortran
first_lineirst_line

Definition at line 321 of file constraint_to_text.c.

329 {
330  return contrainte_text_format(aux_line,continuation,txt,eg, false,
331  variable_name,a_la_fortran,first_line);
332 }

References continuation, contrainte_text_format(), and variable_name().

+ Here is the call graph for this function:

◆ entity_list_text_format()

void entity_list_text_format ( string  line,
string  continuation,
text  t,
list  le,
const char *(*)(entity var_name 
)

appends the list of entity...

Parameters
leof entity

Definition at line 468 of file constraint_to_text.c.

474 {
475  if (le)
476  {
477  int j=0, len = gen_length(le);
478  const char ** provi = (const char **) malloc(sizeof(char *) * len);
479  bool some_previous = false;
480 
481  FOREACH(entity, e, le)
482  provi[j++] = entity_undefined_p(e)? "undefined...": var_name(e);
483 
484  qsort(provi, len, sizeof(char**), gen_qsort_string_cmp);
485 
486  for(j=0; j<len; j++)
487  {
488  if (some_previous) add_to_current_line(line, ",", continuation, t);
489  else some_previous = true;
490  add_to_current_line(line, provi[j], continuation, t);
491  }
492 
493  free(provi);
494  }
495 }
void * malloc(YYSIZE_T)
void free(void *)
size_t gen_length(const list l)
Definition: list.c:150
#define FOREACH(_fe_CASTER, _fe_item, _fe_list)
Apply/map an instruction block on all the elements of a list.
Definition: newgen_list.h:179
int gen_qsort_string_cmp(const void *, const void *)
Callback for sorting string with qsort.
Definition: string.c:332
#define entity_undefined_p(x)
Definition: ri.h:2762

References add_to_current_line(), continuation, entity_undefined_p, FOREACH, free(), gen_length(), gen_qsort_string_cmp(), line, and malloc().

Referenced by text_transformer().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ inegalite_debug()

void inegalite_debug ( Pcontrainte  c)

Definition at line 53 of file constraint_to_text.c.

54 {
56 }
void inegalite_fprint(FILE *, Pcontrainte, char *(*)(Variable))

References entity_local_name(), and inegalite_fprint().

+ Here is the call graph for this function:

◆ inegalite_text_format()

string inegalite_text_format ( string  aux_line,
string  continuation,
text  txt,
Pcontrainte  ineg,
string(*)()  variable_name,
bool  a_la_fortran,
bool  first_line 
)

Definition at line 335 of file constraint_to_text.c.

343 {
344  return contrainte_text_format(aux_line,continuation,txt,ineg, true,
345  variable_name,a_la_fortran,first_line);
346 }

References continuation, contrainte_text_format(), and variable_name().

+ Here is the call graph for this function:

◆ sc_syst_debug()

void sc_syst_debug ( Psysteme  s)

constraint_to_text.c

Definition at line 46 of file constraint_to_text.c.

47 {
49 }
void sc_fprint(FILE *fp, Psysteme ps, get_variable_name_t nom_var)
void sc_fprint(FILE * f, Psysteme ps, char * (*nom_var)()): cette fonction imprime dans le fichier po...
Definition: sc_io.c:220

References entity_local_name(), and sc_fprint().

Referenced by build_and_test_dependence_context(), dependence_cone_positive(), loop_regions_normalize(), region_exact_projection_along_variable(), region_sc_minimal(), regions_may_convex_hull(), regions_must_convex_hull(), sc_projection_optim_along_vecteur_ofl(), TestDependence(), text_transformer(), and unimodular().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ signed_operation_to_textline()

static void signed_operation_to_textline ( string  buffer,
string  signe,
Value  coeff,
Variable  var,
char *(*)(Variable variable_name,
string  continuation,
text  t 
)
static

Definition at line 108 of file constraint_to_text.c.

116 {
119  continuation, t);
120 }

References add_to_current_line(), buffer, continuation, unsigned_operation_to_textline(), and variable_name().

Referenced by contrainte_to_text_1(), and contrainte_to_text_2().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ system_sorted_text_format()

void system_sorted_text_format ( string  line,
string  prefix,
text  txt,
Psysteme  ps,
string(*)(Variable variable_name,
bool(*)(Pvecteur put_first,
bool  a_la_fortran 
)

lower level hook for regions.

{

repeat twice: once for first, once for not first.

== / .EQ.

<= / .LE.

}

Parameters
lineine
prefixrefix
txtxt
pss
a_la_fortranwhether to put a constraints ahead

Definition at line 391 of file constraint_to_text.c.

399 {
400  bool invert, stop, some_previous = false;
401 
402  if (ps==NULL)
403  {
404  add_to_current_line(line, get_string_property("SYSTEM_NULL"), prefix, txt);
405  return;
406  }
407  else if (SC_UNDEFINED_P(ps))
408  {
409  add_to_current_line(line, get_string_property("SYSTEM_UNDEFINED"),
410  prefix, txt);
411  return;
412  }
413  else if (sc_empty_p(ps))
414  {
415  add_to_current_line(line, get_string_property("SYSTEM_NOT_FEASIBLE"),
416  prefix, txt);
417  return;
418  }
419 
420  /* {
421  */
422  if (!a_la_fortran) add_to_current_line(line, "{", prefix, txt);
423 
424  /* repeat twice: once for first, once for not first.
425  */
426  for(invert = false, stop = false; !stop; )
427  {
428  /* == / .EQ.
429  */
430  some_previous =
431  contraintes_text_format(line, prefix, txt, sc_egalites(ps),
432  variable_name, invert, put_first,
433  some_previous, false, a_la_fortran);
434 
435  /* <= / .LE.
436  */
437  some_previous =
438  contraintes_text_format(line, prefix, txt, sc_inegalites(ps),
439  variable_name, invert, put_first,
440  some_previous, true, a_la_fortran);
441 
442  if (invert || !put_first) stop = true;
443  invert = true;
444  }
445 
446  /* }
447  */
448  if (!a_la_fortran) add_to_current_line(line, "}", prefix, txt);
449 }
static bool contraintes_text_format(string line, string prefix, text txt, Pcontrainte cs, string(*variable_name)(Variable), bool invert_put_first, bool(*put_first)(Pvecteur), bool some_previous, bool is_inegalites, bool a_la_fortran)
char * get_string_property(const char *)
bool sc_empty_p(Psysteme sc)
bool sc_empty_p(Psysteme sc): check if the set associated to sc is the constant sc_empty or not.
Definition: sc_alloc.c:350

References add_to_current_line(), contraintes_text_format(), get_string_property(), line, prefix, sc_empty_p(), and variable_name().

Referenced by system_text_format(), text_pointer_value(), text_points_to_relation(), and text_region_no_action().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ system_text_format()

void system_text_format ( string  line,
string  prefix,
text  txt,
Psysteme  ps,
string(*)(Variable variable_name,
bool  a_la_fortran 
)

appends ps to line/txt with prefix continuations.

Parameters
lineine
prefixrefix
txtxt
pss
a_la_fortran_la_fortran

Definition at line 453 of file constraint_to_text.c.

460 {
462  (line, prefix, txt, ps, variable_name, NULL, a_la_fortran);
463 }
void system_sorted_text_format(string line, string prefix, text txt, Psysteme ps, string(*variable_name)(Variable), bool(*put_first)(Pvecteur), bool a_la_fortran)
lower level hook for regions.

References line, prefix, system_sorted_text_format(), and variable_name().

Referenced by text_continuation(), and text_transformer().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ the_operator()

static string the_operator ( bool  is_inegalite,
bool  a_la_fortran 
)
static

Definition at line 63 of file constraint_to_text.c.

64 {
65  return is_inegalite? (a_la_fortran? ".LE.": "<="):
66  (a_la_fortran? ".EQ.": "==");
67 }

Referenced by constante_to_textline(), and contrainte_to_text_2().

+ Here is the caller graph for this function:

◆ unsigned_operation_to_textline()

static void unsigned_operation_to_textline ( string  buffer,
Value  coeff,
Variable  var,
char *(*)(Variable variable_name,
string  continuation,
text  t 
)
static

Definition at line 94 of file constraint_to_text.c.

101 {
102  if (value_notone_p(ABS(coeff)) || var==TCST)
105 }
#define value_notone_p(val)
#define ABS(x)
was: #define value_mult(v,w) value_direct_multiply(v,w) #define value_product(v,w) value_direct_produ...

References ABS, add_to_current_line(), add_Value_to_current_line(), buffer, continuation, TCST, value_notone_p, and variable_name().

Referenced by contrainte_to_text_1(), contrainte_to_text_2(), and signed_operation_to_textline().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: