summaryrefslogtreecommitdiffstats
path: root/parse.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'parse.cxx')
-rw-r--r--parse.cxx16
1 files changed, 3 insertions, 13 deletions
diff --git a/parse.cxx b/parse.cxx
index 5b3506f8..cfefa12d 100644
--- a/parse.cxx
+++ b/parse.cxx
@@ -2352,8 +2352,6 @@ parser::parse_symbol ()
// now scrutinize this identifier for the various magic forms of identifier
// (printf, @stat_op, and $var...)
- bool pf_stream, pf_format, pf_delim, pf_newline, pf_char;
-
if (name == "@cast")
{
// type-punning time
@@ -2410,19 +2408,11 @@ parser::parse_symbol ()
return sop;
}
- else if (print_format::parse_print(name,
- pf_stream, pf_format, pf_delim, pf_newline, pf_char))
+ else if (print_format *fmt = print_format::create(t))
{
- print_format *fmt = new print_format;
- fmt->tok = t;
- fmt->print_to_stream = pf_stream;
- fmt->print_with_format = pf_format;
- fmt->print_with_delim = pf_delim;
- fmt->print_with_newline = pf_newline;
- fmt->print_char = pf_char;
-
expect_op("(");
- if ((name == "print" || name == "println") &&
+ if ((name == "print" || name == "println" ||
+ name == "sprint" || name == "sprintln") &&
(peek_kw("@hist_linear") || peek_kw("@hist_log")))
{
// We have a special case where we recognize