summaryrefslogtreecommitdiff
path: root/support/tab4tex/source/newline.inc
blob: bb47722f64528db795b405d6e9a3667a32da07e0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
* NEWLINE
* Checks OS and compiler type to set newline
* Part of this function uses a function posted by
* Gregory White <glwhite@netconnect.com.au>
* on the Snobol list in March 2003
* Guido Milanese <guido.milanese@unicatt.it>

	define('newline()compiler_type')	
-include "compiler.inc"
-include "systype.inc"
					:(newline_end)

newline					
* Compiler being used. If it is Snobol4+, that does not have
* the HOST() function, assumes that the newline is Dos type

snobol4	(compiler_type = compiler()) ? "SNOBOL4+"   	:f(other)	
	newline	= char(13) char(10)			:(return)

* otherwise finds through HOST the OS type and sets newline
* accordingly
other	newline = systype()  				:(return)
newline_end