Google
 

Trailing-Edge - PDP-10 Archives - bb-r775e-bm_tops20_ks_upd_5 - sources/edt/fput.bli
There are 10 other files named fput.bli in the archive. Click here to see a list.
 %TITLE 'FPUT - write out the format buffer'
MODULE FPUT (				! Write out the format buffer
		IDENT = '3-002'			! File: FPUT.BLI Edit: CJG3002
		) =
BEGIN
!
!			  COPYRIGHT (c) 1981, 1985 BY
!	      DIGITAL EQUIPMENT CORPORATION, MAYNARD, MASS.
!		ALL RIGHTS RESERVED.
!
! THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY BE USED AND  COPIED
! ONLY  IN  ACCORDANCE  WITH  THE  TERMS  OF  SUCH  LICENSE AND WITH THE
! INCLUSION OF THE ABOVE COPYRIGHT NOTICE.  THIS SOFTWARE OR  ANY  OTHER
! COPIES  THEREOF MAY NOT BE PROVIDED OR OTHERWISE MADE AVAILABLE TO ANY
! OTHER PERSON.  NO TITLE TO AND OWNERSHIP OF  THE  SOFTWARE  IS  HEREBY
! TRANSFERRED.
!
! THE INFORMATION IN THIS SOFTWARE IS SUBJECT TO CHANGE  WITHOUT  NOTICE
! AND  SHOULD  NOT  BE  CONSTRUED  AS  A COMMITMENT BY DIGITAL EQUIPMENT
! CORPORATION.
!
! DIGITAL ASSUMES NO RESPONSIBILITY FOR THE USE OR  RELIABILITY  OF  ITS
! SOFTWARE ON EQUIPMENT WHICH IS NOT SUPPLIED BY DIGITAL.
!

!++
! FACILITY:	EDT -- The DEC Standard Editor
!
! ABSTRACT:
!
!	Write out the format buffer.
!
! ENVIRONMENT:	Runs at any access mode - AST reentrant
!
! AUTHOR: Bob Kushlis, CREATION DATE: March 18, 1979
!
! MODIFIED BY:
!
! 1-001	- Original.  DJS 19-FEB-1981.  This module was created by
!	extracting routine EDT$$OUT_FMTBUF  from module FORMAT.
! 1-002	- Regularize headers.  JBS 05-Mar-1981
! 1-003	- Use EDT$$K_FMT_BUFLEN.  JBS 29-Sep-1982
! 3-001 - Make arguments to CH$DIFF be string ptrs.  GB 3-Feb-1983
! 3-002 - Add FMT_FREE to improve speed of format routines. CJG 11-Jan-1984
!--

%SBTTL 'Declarations'
!
! TABLE OF CONTENTS:
!

REQUIRE 'EDTSRC:TRAROUNAM';

FORWARD ROUTINE
    EDT$$OUT_FMTBUF;

!
! INCLUDE FILES:
!

REQUIRE 'EDTSRC:EDTREQ';

!
! MACROS:
!
!	NONE
!
! EQUATED SYMBOLS:
!
!	NONE
!
! OWN STORAGE:
!
!	NONE
!
! EXTERNAL REFERENCES:
!
!	In the routine
%SBTTL 'EDT$$OUT_FMTBUF  - write out the format buffer'

GLOBAL ROUTINE EDT$$OUT_FMTBUF 			! Write out the format buffer
    =

!++
! FUNCTIONAL DESCRIPTION:
!
!	Write out the contents of the format buffer by calling the format
!	write routine.  Reset the buffer pointer and column number.
!
! FORMAL PARAMETERS:
!
!	NONE
!
! IMPLICIT INPUTS:
!
!	FMT_BUF
!	FMT_CUR
!	FMT_WRRUT
!
! IMPLICIT OUTPUTS:
!
!	FMT_CUR
!	FMT_LNPOS
!
! ROUTINE VALUE:
!
!	Same as the formatting routine
!
! SIDE EFFECTS:
!
!	Calls the formatting routine, whose address is in FMT_WRRUT .
!
!--

    BEGIN

    EXTERNAL
	FMT_BUF : BLOCK [CH$ALLOCATION (FMT_BUFLEN, BYTE_SIZE)],
					! The formatted output buffer
	FMT_CUR,			! Pointer to next character in above
	FMT_FREE,			! Space left in format buffer
	FMT_LNPOS,			! The current column number
	FMT_WRRUT;			! Routine to call to write the buffer

    LOCAL
	RETVAL;

    RETVAL = (.FMT_WRRUT) (FMT_BUF, FMT_BUFLEN - .FMT_FREE);
    FMT_CUR = CH$PTR (FMT_BUF,, BYTE_SIZE);
    FMT_FREE = FMT_BUFLEN;
    FMT_LNPOS = 0;
    RETURN (.RETVAL);
    END;


END
ELUDOM