Index: libcfa/src/iostream.cfa
===================================================================
--- libcfa/src/iostream.cfa	(revision 88001dd7b8549584dfbc667a75b53dcc6164ae6c)
+++ libcfa/src/iostream.cfa	(revision aa25216bacaf2695b708cdc8fdef1f1397903d56)
@@ -10,6 +10,6 @@
 // Created On       : Wed May 27 17:56:53 2015
 // Last Modified By : Peter A. Buhr
-// Last Modified On : Thu Aug 24 10:25:20 2023
-// Update Count     : 1516
+// Last Modified On : Fri Aug 25 12:04:27 2023
+// Update Count     : 1526
 //
 
@@ -21,5 +21,6 @@
 #include <float.h>										// DBL_DIG, LDBL_DIG
 #include <complex.h>									// creal, cimag
-//#include <string.h>									// strlen, strcmp, memcpy
+//#include <stdio.h>
+
 extern "C" {
 extern size_t strlen (const char *__s) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1)));
@@ -971,22 +972,24 @@
 
 		int check = f.wd - 1;
+		const char * scanset = f.scanset;;
+		if ( f.flags.delimit ) scanset = f.delimit;		// getline ?
 
 		// getline
-		if ( f.flags.delimit ) {
-			enum { size = 32 };
-			char fmtstr[size];
-			snprintf( fmtstr, size, "%%%d[^%c]s", f.wd, f.delimit );
-			if ( ! f.flags.rwd ) f.s[check] = '\0';		// insert sentinel
-			int len = fmt( is, fmtstr, f.s );			// read upto delimiter
-			if ( ! f.flags.rwd && f.s[check] != '\0' )	// sentinel overwritten ?
-				throw (cstring_length){ &cstring_length_vt };
-			if ( len == 0 ) f.s[0] = '\0';				// empty read => argument unchanged => set empty
-//			fprintf( stderr, "getline %s %s %d %d %d '%c'\n", fmtstr, f.s, len, f.wd, check, f.s[check] );
-			if ( ! eof( is ) ) fmt( is, "%*c" );		// ignore delimiter
-			return is;
-		} // if
+		// if ( f.flags.delimit ) {
+		// 	enum { size = 32 };
+		// 	char fmtstr[size];
+		// 	snprintf( fmtstr, size, "%%%d[^%c]s", f.wd, f.delimit );
+		// 	if ( ! f.flags.rwd ) f.s[check] = '\0';		// insert sentinel
+		// 	int len = fmt( is, fmtstr, f.s );			// read upto delimiter
+		// 	if ( ! f.flags.rwd && f.s[check] != '\0' )	// sentinel overwritten ?
+		// 		throw (cstring_length){ &cstring_length_vt };
+		// 	if ( len == 0 ) f.s[0] = '\0';				// empty read => argument unchanged => set empty
+		// 	// fprintf( stderr, "getline %s %s %d %d %d '%c'\n", fmtstr, f.s, len, f.wd, check, f.s[check] );
+		// 	if ( ! eof( is ) ) fmt( is, "%*c" );		// ignore delimiter
+		// 	return is;
+		// } // if
 
 		size_t len = 0;
-		if ( f.scanset ) len = strlen( f.scanset );
+		if ( scanset ) len = strlen( scanset );
 		char fmtstr[len + 16];
 		int start = 1;
@@ -995,5 +998,5 @@
 		if ( f.wd != -1 ) { start += sprintf( &fmtstr[start], "%d", f.wd ); }
 
-		if ( ! f.scanset ) {
+		if ( ! scanset ) {
 			// %s, %*s, %ws, %*ws
 			fmtstr[start] = 's'; fmtstr[start + 1] = '\0';
@@ -1004,5 +1007,5 @@
 			fmtstr[start] = '['; start += 1;
 			if ( f.flags.inex ) { fmtstr[start] = '^'; start += 1; }
-			strcpy( &fmtstr[start], f.scanset );		// copy includes '\0'
+			strcpy( &fmtstr[start], scanset );			// copy includes '\0'
 			len += start;
 			fmtstr[len] = ']'; fmtstr[len + 1] = '\0';
@@ -1011,8 +1014,13 @@
 
 		if ( ! f.flags.rwd ) f.s[check] = '\0';			// insert sentinel
-		fmt( is, fmtstr, f.s );
-//		fprintf( stderr, "KK %s %d %c\n", fmtstr, check, f.s[check] );
+		len = fmt( is, fmtstr, f.s );
+		//fprintf( stderr, "KK %s %zd %d %c\n", fmtstr, len, check, f.s[check] );
 		if ( ! f.flags.rwd && f.s[check] != '\0' )		// sentinel overwritten ?
 			throw (cstring_length){ &cstring_length_vt };
+
+		if ( f.flags.delimit ) {						// getline ?
+		 	if ( len == 0 ) f.s[0] = '\0';				// empty read => argument unchanged => set empty
+		 	if ( ! eof( is ) ) fmt( is, "%*c" );		// ignore delimiter
+		} //if
 		return is;
 	} // ?|?
Index: libcfa/src/iostream.hfa
===================================================================
--- libcfa/src/iostream.hfa	(revision 88001dd7b8549584dfbc667a75b53dcc6164ae6c)
+++ libcfa/src/iostream.hfa	(revision aa25216bacaf2695b708cdc8fdef1f1397903d56)
@@ -10,6 +10,6 @@
 // Created On       : Wed May 27 17:56:53 2015
 // Last Modified By : Peter A. Buhr
-// Last Modified On : Thu Aug 24 11:35:02 2023
-// Update Count     : 530
+// Last Modified On : Fri Aug 25 11:55:46 2023
+// Update Count     : 533
 //
 
@@ -20,5 +20,4 @@
 
 // *********************************** ostream ***********************************
-
 
 forall( ostype & )
@@ -305,7 +304,5 @@
 } // ?|?
 
-
 // *********************************** istream ***********************************
-
 
 #define ISTYPE_VOID( T ) void ?|?( istype &, T )
@@ -403,10 +400,7 @@
 } // distribution
 
-
 // *********************************** exceptions ***********************************
 
-
 ExceptionDecl( cstring_length );
-
 
 // *********************************** manipulators ***********************************
@@ -416,5 +410,5 @@
 	union {
 		const char * scanset;
-		char delimit;
+		char delimit[2];
 	};
 	int wd;												// width
@@ -440,5 +434,6 @@
 	_Istream_Cstr skip( const char scanset[] ) { return (_Istream_Cstr){ 0p, {scanset}, -1, {.all : 0} }; }
 	_Istream_Cstr skip( unsigned int wd ) { return (_Istream_Cstr){ 0p, {0p}, wd, {.all : 0} }; }
-	_Istream_Cstr & getline( _Istream_Cstr & fmt, const char delimit = '\n' ) { fmt.delimit = delimit; fmt.flags.delimit = true; return fmt; }
+	_Istream_Cstr & getline( _Istream_Cstr & fmt, const char delimit = '\n' ) {
+		fmt.delimit[0] = delimit; fmt.delimit[1] = '\0'; fmt.flags.delimit = true; fmt.flags.inex = true; return fmt; }
 	_Istream_Cstr & incl( const char scanset[], _Istream_Cstr & fmt ) { fmt.scanset = scanset; fmt.flags.inex = false; return fmt; }
 	_Istream_Cstr & excl( const char scanset[], _Istream_Cstr & fmt ) { fmt.scanset = scanset; fmt.flags.inex = true; return fmt; }
@@ -502,7 +497,5 @@
 INPUT_FMT_DECL( long double _Complex )
 
-
 // *********************************** time ***********************************
-
 
 #include <time_t.hfa>									// Duration (constructors) / Time (constructors)
