28 #define PATCH_CHAR '_' 37 for(
int i = pos; i < 80; i++)
45 while((beg <= end) && (buf[end] ==
BLANK))
48 while((beg <= end) && (buf[beg] ==
BLANK))
51 for(
int i = beg; i <= end; i++)
78 <<
" " <<
m_buf << std::endl; )
86 len = int(strlen(
m_buf));
87 for(
int i = 0; i < len; i++ )
97 len = int(strlen(
m_buf));
101 assert(strlen(
m_buf) >= 80);
111 m_f1 = strtok(0,
" ");
122 else if ((
m_buf[39] ==
'$') && (
m_buf[38] ==
' '))
133 if (space ==
BLANK || len < 13)
139 bool number = isdigit(
m_buf[24]) || isdigit(
m_buf[25])
149 if (number || len < 13)
182 if (0 == (
m_f1 = strtok(s,
" ")))
185 if ((0 == (
m_f2 = strtok(0,
" "))) || (*
m_f2 ==
'$'))
190 if (!strcmp(
m_f2,
"'MARKER'"))
193 if ((0 == (
m_f3 = strtok(0,
" "))) || (*
m_f3 ==
'$'))
200 if (!strcmp(
m_f3,
"'INTORG'"))
202 else if (!strcmp(
m_f3,
"'INTEND'"))
208 if (!strcmp(
m_f3,
"'MARKER'"))
211 if ((0 == (
m_f4 = strtok(0,
" "))) || (*
m_f4 ==
'$'))
218 if (!strcmp(
m_f4,
"'INTORG'"))
220 else if (!strcmp(
m_f4,
"'INTEND'"))
226 if ((0 == (
m_f5 = strtok(0,
" "))) || (*
m_f5 ==
'$'))
234 <<
"DMPSIN02 -----------------------------------------------" 236 <<
"DMPSIN03 f0=" << ((
m_f0 == 0) ?
"nil" :
m_f0) << std::endl
237 <<
"DMPSIN04 f1=" << ((
m_f1 == 0) ?
"nil" :
m_f1) << std::endl
238 <<
"DMPSIN05 f2=" << ((
m_f2 == 0) ?
"nil" :
m_f2) << std::endl
239 <<
"DMPSIN06 f3=" << ((
m_f3 == 0) ?
"nil" :
m_f3) << std::endl
240 <<
"DMPSIN07 f4=" << ((
m_f4 == 0) ?
"nil" :
m_f4) << std::endl
241 <<
"DMPSIN08 f5=" << ((
m_f5 == 0) ?
"nil" :
m_f5) << std::endl
242 <<
"DMPSIN09 -----------------------------------------------"
Wrapper for different output streams and verbosity levels.
Debugging, floating point type and parameter definitions.
Everything should be within this namespace.
static void patch_field(char *buf, int beg, int end)
change all blanks inside a field to PATCH_CHAR.
static void clear_from(char *buf, int pos)
fill the line from pos up to column 80 with blanks.