bug-gawk
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug-gawk] Possible bug in gawk 4.1.3 running in cygwin OS Windows 7 Ult


From: Christopher Durant
Subject: [bug-gawk] Possible bug in gawk 4.1.3 running in cygwin OS Windows 7 Ultimate SP 1
Date: Wed, 8 Feb 2017 13:38:41 +0000

This function causes the interpreter to go into what I can only describe as a spasm. 

function datetime()
{tag = (strftime ("%Y-%m-%d") " " (strftime("%r"));
return tag;
}


It fails to pass Go reporting:

gawk: test2ver5.awk:36:                 {tag = (strftime ("%Y-%m-%d") " " (strftime("%r"))
gawk: test2ver5.awk:36:                                                                    ^ unexpected newline or end of string

It then snags every subsequent line in the program with "unexpected newline" and "syntax error".

Whereas this version of the function, it's happy with:

function datetime()
{tag1 = strftime ("%Y-%m-%d");
tag2 = strftime("%r");
return (tag1 " " tag2);
}

Hope this useful; not a stupid error on my part.

Kind regards

Christopher Durant




reply via email to

[Prev in Thread] Current Thread [Next in Thread]