+ if (longprompt) {
+ so_enter();
+ putstr(current_name);
+ putstr(":");
+ if (!ispipe) {
+ (void)sprintf(pbuf, " file %d/%d", curr_ac + 1, ac);
+ putstr(pbuf);
+ }
+ if (linenums) {
+ (void)sprintf(pbuf, " line %d", currline(BOTTOM));
+ putstr(pbuf);
+ }
+ if ((pos = position(BOTTOM)) != NULL_POSITION) {
+ (void)sprintf(pbuf, " byte %ld", pos);
+ putstr(pbuf);
+ if (!ispipe && (len = ch_length())) {
+ (void)sprintf(pbuf, "/%ld pct %ld%%",
+ len, ((100 * pos) / len));
+ putstr(pbuf);
+ }
+ }
+ so_exit();
+ longprompt = 0;
+ }
+ else if (terseprompt)