Otherwise, end of file acts like fullstop. If only end of file is read, the event 190 is raised and the default handler unifies Term with the atom end_of_file.
The default action for syntax errors is to print a warning and fail.
Success: [eclipse]: read(0,Term). > atom. Term = atom yes. [eclipse]: open(file1,write,s),write(s, 'f(1,2,3).\ng(1,2'), > write(s, ',3). h(1,2,3).\ni.\nj(1, 2\n,3).'). yes. [eclipse]: system('cat file1'). f(1,2,3). g(1,2,3). h(1,2,3). i. j(1, 2 ,3). yes. [eclipse]: open(file1,read,s), read(s,A), read(s,B), > read(s,C), read(s,D), read(s,E), read(s,F). A = f(1, 2, 3) B = g(1, 2, 3) C = h(1, 2, 3) D = i E = j(1, 2, 3) F = end_of_file yes. Fail: [eclipse]: read(0,a). > b. no. [eclipse]: read(0,X). > f(1,2)m. ^ (here?) syntax error: postfix/infix operator expected no (more) solution. Error: read(a(b,c),S). (Error 4). read("string", a(b,c)). (Error 5). read(9, X=2). (Error 192). % stream not open read(atom, X=2). (Error 193).