Skip to content

Commit

Permalink
Fix slow file reading (#1949)
Browse files Browse the repository at this point in the history
  • Loading branch information
kustosz authored Aug 13, 2021
1 parent a9c8aa4 commit bd04f8c
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
5 changes: 5 additions & 0 deletions RELEASES.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Enso Next

## Libraries

- Fixed a bug where reading binary and text files would be 100 times slower than
expected ([#1949](https://github.com/enso-org/enso/pull/1949)).

# Enso 0.2.24 (2021-08-13)

## Interpreter/Runtime
Expand Down
4 changes: 2 additions & 2 deletions distribution/lib/Standard/Base/0.1.0/src/System/File.enso
Original file line number Diff line number Diff line change
Expand Up @@ -570,7 +570,7 @@ type Input_Stream
read_all_bytes : Vector.Vector ! File_Error
read_all_bytes = Managed_Resource.with this.stream_resource java_stream->
here.handle_java_exceptions this.file <|
Vector.from_array java_stream.readAllBytes
Vector.Vector java_stream.readAllBytes

## ADVANCED

Expand Down Expand Up @@ -601,7 +601,7 @@ type Input_Stream
read_n_bytes n = Managed_Resource.with this.stream_resource java_stream->
here.handle_java_exceptions this.file <|
bytes = java_stream.readNBytes n
Vector.from_array bytes
Vector.Vector bytes

## ADVANCED

Expand Down

0 comments on commit bd04f8c

Please sign in to comment.