Rheolef  7.1
an efficient C++ finite element environment
space_constitution_old_get.cc
Go to the documentation of this file.
1 // old format input space_constitution files:
22 // space_constitution_old_get (idiststream& ids, space_constitution<T,M>& constit)
23 //
24 // author: Pierre.Saramito@imag.fr
25 //
26 // date: 19 dec 2011
27 //
29 
30 // ================================================================================
31 // part 1 : read from idiststeam and build as tree_type* result_ptr
32 // ================================================================================
33 /* AIX requires this to be the first thing in the file. */
34 #ifndef __GNUC__
35 # if _RHEOLEF_HAVE_ALLOCA_H
36 # include <alloca.h>
37 # else
38 # ifdef _AIX
39 #pragma alloca
40 # else
41 # ifndef alloca /* predefined by HP cc +Olibcalls */
42 char *alloca ();
43 # endif
44 # endif
45 # endif
46 #endif
47 
48 namespace rheolef {
49 
50 using namespace std;
51 
52 typedef size_t size_type;
53 
56 
57 extern int space_constitution_old_lex();
58 void space_constitution_old_error (const char* msg) {
59  std::string near;
60  error_macro("space constitution_old input:" << space_constitution_old_line_no << ": " << msg);
62 }
63 int space_constitution_old_wrap () { return 1; }
64 
65 #pragma GCC diagnostic push
66 #pragma GCC diagnostic ignored "-Weffc++"
67 #define YYMALLOC ::malloc
68 #define YYFREE ::free
69 #include "space_constitution_old_yacc.cc"
70 // avoid re-definition of YY_NULL within flex
71 #ifdef YY_NULL
72 #undef YY_NULL
73 #endif
74 #include "space_constitution_old_lex.cc"
75 #pragma GCC diagnostic pop
76 
77 static yyFlexLexer input_space_constitution_old;
78 
80 
81 // ================================================================================
82 // part 2 : main call
83 // ================================================================================
84 template<class T, class M>
85 void
87 {
88  space_constitution_get_pass_1_2 (ids, space_constitution_old_parse,
90  // convert tree_type result_ptr to space_constitution
91  const tree_type* ptr = result_ptr;
92  constit = build_from_tree<T,M> (*ptr);
93  delete_macro (result_ptr); result_ptr = 0;
94 }
95 // ----------------------------------------------------------------------------
96 // instanciation in library
97 // ----------------------------------------------------------------------------
99 
100 #ifdef _RHEOLEF_HAVE_MPI
102 #endif // _RHEOLEF_HAVE_MPI
103 
104 } // namespace rheolef
static tree_type * result_ptr
static yyFlexLexer input_space_constitution_old
static size_type space_constitution_old_line_no
static size_type space_constitution_old_n_error
#define error_macro(message)
Definition: dis_macros.h:49
This file is part of Rheolef.
void space_constitution_old_get(idiststream &ids, space_constitution< T, M > &constit)
void space_constitution_old_error(const char *msg)