diff options
| author | Inari Listenmaa <inari.listenmaa@gmail.com> | 2022-03-05 06:28:17 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-03-05 06:28:17 +0100 |
| commit | 25dd1354c71ab9267d6fdb8ad7cf8cc7ce30812f (patch) | |
| tree | c4887072e30758e7a26b524ee537239d5afb08f9 /src/compiler | |
| parent | 1b41e94f83feb5bba7a12780128f305573477b84 (diff) | |
| parent | b53a102c98ec9693a5cbecb9ade08bc1a1d07742 (diff) | |
Merge pull request #135 from mengwong/base-4-15
prepare for GHC 9, base 4.15, by using Buffer constructor interface
Diffstat (limited to 'src/compiler')
| -rw-r--r-- | src/compiler/GF/Text/Coding.hs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/compiler/GF/Text/Coding.hs b/src/compiler/GF/Text/Coding.hs index bac7938c0..2a89427fe 100644 --- a/src/compiler/GF/Text/Coding.hs +++ b/src/compiler/GF/Text/Coding.hs @@ -38,7 +38,7 @@ decodeUnicode :: TextEncoding -> ByteString -> String decodeUnicode enc bs = unsafePerformIO $ decodeUnicodeIO enc bs decodeUnicodeIO enc (PS fptr l len) = do - let bbuf = Buffer{bufRaw=fptr, bufState=ReadBuffer, bufSize=len, bufL=l, bufR=l+len} + let bbuf = (emptyBuffer fptr len ReadBuffer) { bufL=l, bufR=l+len } cbuf <- newCharBuffer 128 WriteBuffer case enc of TextEncoding {mkTextDecoder=mk} -> do decoder <- mk |
