Skip to content

Commit a90cde2

Browse files
committed
Merge remote-tracking branch 'origin/master'
2 parents c9abe06 + da7647e commit a90cde2

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Context managers for SWI Prolog
44
Synopsis
55
--------
66

7-
```
7+
```prolog
88
?- use_module(library(with)).
99
1010
% IO streams automatically closed
@@ -78,7 +78,7 @@ goals must succeed. If they fail, the error
7878
For example, the provided manage_context/3 clause
7979
for opening files could be defined:
8080

81-
```
81+
```prolog
8282
with:manage_context(open(File, Mode, Stream),
8383
open(File, Mode, Stream),
8484
close(Stream)).
@@ -87,7 +87,7 @@ with:manage_context(open(File, Mode, Stream),
8787

8888
The result is that the following are equivalent:
8989

90-
```
90+
```prolog
9191
?- setup_call_cleanup(open(File, read, Stream),
9292
is_stream(Stream),
9393
close(Stream)).
@@ -100,7 +100,7 @@ The result is that the following are equivalent:
100100
To show defined context managers, using ```listing/1```. E.g, the
101101
context managers packaged with this module are:
102102

103-
```
103+
```prolog
104104
?- use_module(library(with)), listing(with:manage_context/3).
105105
106106
manage_context(open(A, C, D), (absolute_file_name(A, B), open(B, C, D)), close(D)).
@@ -114,7 +114,7 @@ Installation
114114

115115
Using SWI-Prolog 6.3 or later:
116116

117-
```
117+
```prolog
118118
?- pack_install(with).
119119
120120
```

0 commit comments

Comments
 (0)