git.iko.soy/typeable/attoparsec
on da754bb help sign in
.gitignore−1
since splitsnapshots
unifiedsplit
@@ -3,4 +3,3 @@
3/dist/
3/dist/
4.cabal-sandbox
4.cabal-sandbox
5cabal.sandbox.config
5cabal.sandbox.config
6−*.sw[op]
.hgignore+1−5
@@ -1,15 +1,11 @@
1+^(?:\.cabal-sandbox|benchmarks/\.cabal-sandbox|cabal-dev|dist)$
1\.(?:aux|eventlog|h[ip]|hs.html|log|[mt]ix|[oa]|orig|prof|ps|rej|swp)$
2\.(?:aux|eventlog|h[ip]|hs.html|log|[mt]ix|[oa]|orig|prof|ps|rej|swp)$
2~$
3~$
3−^(?:.+/|)\.cabal-sandbox/
4−^(?:.+/|)dist/
5benchmarks/Arse
4benchmarks/Arse
6benchmarks/dist
5benchmarks/dist
7benchmarks/med.txt
6benchmarks/med.txt
8benchmarks/tiny
7benchmarks/tiny
9−benchmarks/warp-[0-9]*
10cabal.sandbox.config
8cabal.sandbox.config
11−examples/c-http
12−examples/http_parser.[ch]
13hpc.*\.html$
9hpc.*\.html$
14
10
15syntax: glob
11syntax: glob
.hgtags−17
@@ -44,20 +44,3 @@ e8bc38ea66812bf5f24599d3f33480411084affb 0.10.1.1
44f0bc0f79b70b97a856042386aa8856ac1cad88f1 0.10.2.0
44f0bc0f79b70b97a856042386aa8856ac1cad88f1 0.10.2.0
45030191aa39c97afcad17d365ed114a2eedc04ad4 0.10.3.0
45030191aa39c97afcad17d365ed114a2eedc04ad4 0.10.3.0
46ec23283e88c00af34c3144a8775ca4358daea3f7 0.10.4.0
46ec23283e88c00af34c3144a8775ca4358daea3f7 0.10.4.0
47−6f4b317a12acdd05d67fd9ec55d3defaf37a01eb 0.11.1.0
48−48809d7716468fe2bbc47b191b1d64358daaf6d1 0.11.2.1
49−856a772f83a6e382bbcfe53e221a5a92623b107c 0.11.3.0
50−a3c7a521fd58595d6a470ab890cc54a80dd45bd7 0.11.3.1
51−38326ce07aca6c8c3a014b0d454d2a5bfdbd6a52 0.11.3.2
52−694039f4fc157a8ca5dce37959391615b6c3f535 0.11.3.3
53−1fe92d1838fb1b1afcee1ca18d4970cf7e01956e 0.11.3.4
54−68203a4cb847da905fa44b5aa1942b99d5867ab4 0.12.0.0
55−c9c2b05707b2fffcd749d5817e3e0d04e6ad6d0d 0.12.1.0
56−9157c2b4c35aa5f683b4ac51e6ff52c696bc22e2 0.12.1.1
57−682ba515f7ba62500ad79371b37b90932e0c0e3d 0.12.1.2
58−2066a72b79b478f59a9c7f1839c522fc59ba9af7 0.12.1.3
59−ef875ad3bebef2b6fb1bd7063de6a46a06d0d4b4 0.12.1.4
60−dc1fcff28d13a508f677c7b06af6420877842493 0.12.1.5
61−013e04e4526bfd5e9e4a611b42e6f03c413bea91 0.12.1.6
62−0ddbce995b77b8db391b4d6519f13feddf4b5bf3 0.13.0.0
63−46c16463ec20ad46c9cd0bfb1050c4268f34b749 0.13.0.1
.travis.ymldeleted−161
@@ -1,161 +0,0 @@
1−# This Travis job script has been generated by a script via
2−#
3−# haskell-ci '--tests-jobs=>=7.4' '--no-benchmarks' 'attoparsec.cabal'
4−#
5−# For more information, see https://github.com/haskell-CI/haskell-ci
6−#
7−# version: 0.3.20190815
8−#
9−language: c
10−dist: xenial
11−git:
12− # whether to recursively clone submodules
13− submodules: false
14−cache:
15− directories:
16− - $HOME/.cabal/packages
17− - $HOME/.cabal/store
18−before_cache:
19− - rm -fv $CABALHOME/packages/hackage.haskell.org/build-reports.log
20− # remove files that are regenerated by 'cabal update'
21− - rm -fv $CABALHOME/packages/hackage.haskell.org/00-index.*
22− - rm -fv $CABALHOME/packages/hackage.haskell.org/*.json
23− - rm -fv $CABALHOME/packages/hackage.haskell.org/01-index.cache
24− - rm -fv $CABALHOME/packages/hackage.haskell.org/01-index.tar
25− - rm -fv $CABALHOME/packages/hackage.haskell.org/01-index.tar.idx
26− - rm -rfv $CABALHOME/packages/head.hackage
27−matrix:
28− include:
29− - compiler: ghc-8.8.1
30− addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.8.1","cabal-install-3.0"]}}
31− - compiler: ghc-8.6.5
32− addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.6.5","cabal-install-2.4"]}}
33− - compiler: ghc-8.4.4
34− addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.4.4","cabal-install-2.4"]}}
35− - compiler: ghc-8.2.2
36− addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.2.2","cabal-install-2.4"]}}
37− - compiler: ghc-8.0.2
38− addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.0.2","cabal-install-2.4"]}}
39− - compiler: ghc-7.10.3
40− addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-7.10.3","cabal-install-2.4"]}}
41− - compiler: ghc-7.8.4
42− addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-7.8.4","cabal-install-2.4"]}}
43− - compiler: ghc-7.6.3
44− addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-7.6.3","cabal-install-2.4"]}}
45− - compiler: ghc-7.4.2
46− addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-7.4.2","cabal-install-2.4"]}}
47− - compiler: ghc-7.2.2
48− addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-7.2.2","cabal-install-2.4"]}}
49− - compiler: ghc-7.0.4
50− addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-7.0.4","cabal-install-2.4"]}}
51−before_install:
52− - HC=$(echo "/opt/$CC/bin/ghc" | sed 's/-/\//')
53− - WITHCOMPILER="-w $HC"
54− - HCPKG="$HC-pkg"
55− - unset CC
56− - CABAL=/opt/ghc/bin/cabal
57− - CABALHOME=$HOME/.cabal
58− - export PATH="$CABALHOME/bin:$PATH"
59− - TOP=$(pwd)
60− - "HCNUMVER=$(${HC} --numeric-version|perl -ne '/^(\\d+)\\.(\\d+)\\.(\\d+)(\\.(\\d+))?$/; print(10000 * $1 + 100 * $2 + ($3 == 0 ? $5 != 1 : $3))')"
61− - echo $HCNUMVER
62− - CABAL="$CABAL -vnormal+nowrap+markoutput"
63− - set -o pipefail
64− - |
65− echo 'function blue(s) { printf "\033[0;34m" s "\033[0m " }' >> .colorful.awk
66− echo 'BEGIN { state = "output"; }' >> .colorful.awk
67− echo '/^-----BEGIN CABAL OUTPUT-----$/ { state = "cabal" }' >> .colorful.awk
68− echo '/^-----END CABAL OUTPUT-----$/ { state = "output" }' >> .colorful.awk
69− echo '!/^(-----BEGIN CABAL OUTPUT-----|-----END CABAL OUTPUT-----)/ {' >> .colorful.awk
70− echo ' if (state == "cabal") {' >> .colorful.awk
71− echo ' print blue($0)' >> .colorful.awk
72− echo ' } else {' >> .colorful.awk
73− echo ' print $0' >> .colorful.awk
74− echo ' }' >> .colorful.awk
75− echo '}' >> .colorful.awk
76− - cat .colorful.awk
77− - |
78− color_cabal_output () {
79− awk -f $TOP/.colorful.awk
80− }
81− - echo text | color_cabal_output
82−install:
83− - ${CABAL} --version
84− - echo "$(${HC} --version) [$(${HC} --print-project-git-commit-id 2> /dev/null || echo '?')]"
85− - TEST=--enable-tests
86− - if [ $HCNUMVER -lt 70400 ] ; then TEST=--disable-tests ; fi
87− - BENCH=--enable-benchmarks
88− - BENCH=--disable-benchmarks
89− - HEADHACKAGE=false
90− - rm -f $CABALHOME/config
91− - |
92− echo "verbose: normal +nowrap +markoutput" >> $CABALHOME/config
93− echo "remote-build-reporting: anonymous" >> $CABALHOME/config
94− echo "write-ghc-environment-files: always" >> $CABALHOME/config
95− echo "remote-repo-cache: $CABALHOME/packages" >> $CABALHOME/config
96− echo "logs-dir: $CABALHOME/logs" >> $CABALHOME/config
97− echo "world-file: $CABALHOME/world" >> $CABALHOME/config
98− echo "extra-prog-path: $CABALHOME/bin" >> $CABALHOME/config
99− echo "symlink-bindir: $CABALHOME/bin" >> $CABALHOME/config
100− echo "installdir: $CABALHOME/bin" >> $CABALHOME/config
101− echo "build-summary: $CABALHOME/logs/build.log" >> $CABALHOME/config
102− echo "store-dir: $CABALHOME/store" >> $CABALHOME/config
103− echo "install-dirs user" >> $CABALHOME/config
104− echo " prefix: $CABALHOME" >> $CABALHOME/config
105− echo "repository hackage.haskell.org" >> $CABALHOME/config
106− echo " url: http://hackage.haskell.org/" >> $CABALHOME/config
107− - cat $CABALHOME/config
108− - rm -fv cabal.project cabal.project.local cabal.project.freeze
109− - travis_retry ${CABAL} v2-update -v
110− # Generate cabal.project
111− - rm -rf cabal.project cabal.project.local cabal.project.freeze
112− - touch cabal.project
113− - |
114− echo "packages: ." >> cabal.project
115− - |
116− - "for pkg in $($HCPKG list --simple-output); do echo $pkg | sed 's/-[^-]*$//' | (grep -vE -- '^(attoparsec)$' || true) | sed 's/^/constraints: /' | sed 's/$/ installed/' >> cabal.project.local; done"
117− - cat cabal.project || true
118− - cat cabal.project.local || true
119− - if [ -f "./configure.ac" ]; then (cd "." && autoreconf -i); fi
120− - ${CABAL} v2-freeze $WITHCOMPILER ${TEST} ${BENCH} | color_cabal_output
121− - "cat cabal.project.freeze | sed -E 's/^(constraints: *| *)//' | sed 's/any.//'"
122− - rm cabal.project.freeze
123− - ${CABAL} v2-build $WITHCOMPILER ${TEST} ${BENCH} --dep -j2 all | color_cabal_output
124− - ${CABAL} v2-build $WITHCOMPILER --disable-tests --disable-benchmarks --dep -j2 all | color_cabal_output
125−script:
126− - DISTDIR=$(mktemp -d /tmp/dist-test.XXXX)
127− # Packaging...
128− - ${CABAL} v2-sdist all | color_cabal_output
129− # Unpacking...
130− - mv dist-newstyle/sdist/*.tar.gz ${DISTDIR}/
131− - cd ${DISTDIR} || false
132− - find . -maxdepth 1 -type f -name '*.tar.gz' -exec tar -xvf '{}' \;
133− - find . -maxdepth 1 -type f -name '*.tar.gz' -exec rm '{}' \;
134− - PKGDIR_attoparsec="$(find . -maxdepth 1 -type d -regex '.*/attoparsec-[0-9.]*')"
135− # Generate cabal.project
136− - rm -rf cabal.project cabal.project.local cabal.project.freeze
137− - touch cabal.project
138− - |
139− echo "packages: ${PKGDIR_attoparsec}" >> cabal.project
140− - |
141− - "for pkg in $($HCPKG list --simple-output); do echo $pkg | sed 's/-[^-]*$//' | (grep -vE -- '^(attoparsec)$' || true) | sed 's/^/constraints: /' | sed 's/$/ installed/' >> cabal.project.local; done"
142− - cat cabal.project || true
143− - cat cabal.project.local || true
144− # Building...
145− # this builds all libraries and executables (without tests/benchmarks)
146− - ${CABAL} v2-build $WITHCOMPILER --disable-tests --disable-benchmarks all | color_cabal_output
147− # Building with tests and benchmarks...
148− # build & run tests, build benchmarks
149− - ${CABAL} v2-build $WITHCOMPILER ${TEST} ${BENCH} all | color_cabal_output
150− # Testing...
151− - if [ $HCNUMVER -ge 70400 ] ; then ${CABAL} v2-test $WITHCOMPILER ${TEST} ${BENCH} all | color_cabal_output ; fi
152− # cabal check...
153− - (cd ${PKGDIR_attoparsec} && ${CABAL} -vnormal check)
154− # haddock...
155− - ${CABAL} v2-haddock $WITHCOMPILER ${TEST} ${BENCH} all | color_cabal_output
156− # Building without installed constraints for packages in global-db...
157− - rm -f cabal.project.local
158− - ${CABAL} v2-build $WITHCOMPILER --disable-tests --disable-benchmarks all | color_cabal_output
159−
160−# REGENDATA ["--tests-jobs=>=7.4","--no-benchmarks","attoparsec.cabal"]
161−# EOF
Data/Attoparsec.hs+3−8
@@ -1,21 +1,16 @@
1-- |
1-- |
2-- Module : Data.Attoparsec
2-- Module : Data.Attoparsec
3−-- Copyright : Bryan O'Sullivan 2007-2015
3+-- Copyright : Bryan O'Sullivan 2007-2011
4-- License : BSD3
4-- License : BSD3
5--
5--
6-- Maintainer : bos@serpentine.com
6-- Maintainer : bos@serpentine.com
7-- Stability : experimental
7-- Stability : experimental
8-- Portability : unknown
8-- Portability : unknown
9--
9--
10−-- Simple, efficient combinator parsing for
10+-- Simple, efficient combinator parsing for 'ByteString' strings,
11−-- 'Data.ByteString.ByteString' strings, loosely based on the Parsec
11+-- loosely based on the Parsec library.
12−-- library.
13−--
14−-- This module is deprecated. Use "Data.Attoparsec.ByteString"
15−-- instead.
16
12
17module Data.Attoparsec
13module Data.Attoparsec
18− {-# DEPRECATED "This module will be removed in the next major release." #-}
19 (
14 (
20 module Data.Attoparsec.ByteString
15 module Data.Attoparsec.ByteString
21 ) where
16 ) where
Data/Attoparsec/ByteString.hs+34−56
@@ -1,10 +1,6 @@
1−{-# LANGUAGE CPP #-}
2−#if __GLASGOW_HASKELL__ >= 702
3−{-# LANGUAGE Trustworthy #-}
4−#endif
5-- |
1-- |
6-- Module : Data.Attoparsec.ByteString
2-- Module : Data.Attoparsec.ByteString
7−-- Copyright : Bryan O'Sullivan 2007-2015
3+-- Copyright : Bryan O'Sullivan 2007-2011
8-- License : BSD3
4-- License : BSD3
9--
5--
10-- Maintainer : bos@serpentine.com
6-- Maintainer : bos@serpentine.com
@@ -42,6 +38,11 @@ module Data.Attoparsec.ByteString
42 , maybeResult
38 , maybeResult
43 , eitherResult
39 , eitherResult
44
40
41+ -- * Combinators
42+ , (I.<?>)
43+ , I.try
44+ , module Data.Attoparsec.Combinator
45+
45 -- * Parsing individual bytes
46 -- * Parsing individual bytes
46 , I.word8
47 , I.word8
47 , I.anyWord8
48 , I.anyWord8
@@ -63,7 +64,6 @@ module Data.Attoparsec.ByteString
63 , I.skipWhile
64 , I.skipWhile
64 , I.take
65 , I.take
65 , I.scan
66 , I.scan
66− , I.runScanner
67 , I.takeWhile
67 , I.takeWhile
68 , I.takeWhile1
68 , I.takeWhile1
69 , I.takeTill
69 , I.takeTill
@@ -72,32 +72,12 @@ module Data.Attoparsec.ByteString
72 , I.takeByteString
72 , I.takeByteString
73 , I.takeLazyByteString
73 , I.takeLazyByteString
74
74
75− -- * Combinators
76− , try
77− , (<?>)
78− , choice
79− , count
80− , option
81− , many'
82− , many1
83− , many1'
84− , manyTill
85− , manyTill'
86− , sepBy
87− , sepBy'
88− , sepBy1
89− , sepBy1'
90− , skipMany
91− , skipMany1
92− , eitherP
93− , I.match
94 -- * State observation and manipulation functions
75 -- * State observation and manipulation functions
95 , I.endOfInput
76 , I.endOfInput
96 , I.atEnd
77 , I.atEnd
97 ) where
78 ) where
98
79
99import Data.Attoparsec.Combinator
80import Data.Attoparsec.Combinator
100−import Data.List (intercalate)
101import qualified Data.Attoparsec.ByteString.Internal as I
81import qualified Data.Attoparsec.ByteString.Internal as I
102import qualified Data.Attoparsec.Internal as I
82import qualified Data.Attoparsec.Internal as I
103import qualified Data.ByteString as B
83import qualified Data.ByteString as B
@@ -106,51 +86,49 @@ import qualified Data.Attoparsec.Internal.Types as T
106
86
107-- $parsec
87-- $parsec
108--
88--
109−-- Compared to Parsec 3, attoparsec makes several tradeoffs. It is
89+-- Compared to Parsec 3, Attoparsec makes several tradeoffs. It is
110-- not intended for, or ideal for, all possible uses.
90-- not intended for, or ideal for, all possible uses.
111--
91--
112−-- * While attoparsec can consume input incrementally, Parsec cannot.
92+-- * While Attoparsec can consume input incrementally, Parsec cannot.
113-- Incremental input is a huge deal for efficient and secure network
93-- Incremental input is a huge deal for efficient and secure network
114-- and system programming, since it gives much more control to users
94-- and system programming, since it gives much more control to users
115-- of the library over matters such as resource usage and the I/O
95-- of the library over matters such as resource usage and the I/O
116-- model to use.
96-- model to use.
117--
97--
118−-- * Much of the performance advantage of attoparsec is gained via
98+-- * Much of the performance advantage of Attoparsec is gained via
119-- high-performance parsers such as 'I.takeWhile' and 'I.string'.
99-- high-performance parsers such as 'I.takeWhile' and 'I.string'.
120-- If you use complicated combinators that return lists of bytes or
100-- If you use complicated combinators that return lists of bytes or
121-- characters, there is less performance difference between the two
101-- characters, there is less performance difference between the two
122-- libraries.
102-- libraries.
123--
103--
124−-- * Unlike Parsec 3, attoparsec does not support being used as a
104+-- * Unlike Parsec 3, Attoparsec does not support being used as a
125-- monad transformer.
105-- monad transformer.
126--
106--
127−-- * attoparsec is specialised to deal only with strict 'B.ByteString'
107+-- * Attoparsec is specialised to deal only with strict 'B.ByteString'
128-- input. Efficiency concerns rule out both lists and lazy
108-- input. Efficiency concerns rule out both lists and lazy
129-- bytestrings. The usual use for lazy bytestrings would be to
109-- bytestrings. The usual use for lazy bytestrings would be to
130-- allow consumption of very large input without a large footprint.
110-- allow consumption of very large input without a large footprint.
131−-- For this need, attoparsec's incremental input provides an
111+-- For this need, Attoparsec's incremental input provides an
132-- excellent substitute, with much more control over when input
112-- excellent substitute, with much more control over when input
133−-- takes place. If you must use lazy bytestrings, see the
113+-- takes place. If you must use lazy bytestrings, see the 'Lazy'
134−-- "Data.Attoparsec.ByteString.Lazy" module, which feeds lazy chunks
135−-- to a regular parser.
114+-- module, which feeds lazy chunks to a regular parser.
136--
115--
137-- * Parsec parsers can produce more helpful error messages than
116-- * Parsec parsers can produce more helpful error messages than
138−-- attoparsec parsers. This is a matter of focus: attoparsec avoids
117+-- Attoparsec parsers. This is a matter of focus: Attoparsec avoids
139-- the extra book-keeping in favour of higher performance.
118-- the extra book-keeping in favour of higher performance.
140
119
141-- $incremental
120-- $incremental
142--
121--
143−-- attoparsec supports incremental input, meaning that you can feed it
122+-- Attoparsec supports incremental input, meaning that you can feed it
144-- a bytestring that represents only part of the expected total amount
123-- a bytestring that represents only part of the expected total amount
145-- of data to parse. If your parser reaches the end of a fragment of
124-- of data to parse. If your parser reaches the end of a fragment of
146-- input and could consume more input, it will suspend parsing and
125-- input and could consume more input, it will suspend parsing and
147-- return a 'T.Partial' continuation.
126-- return a 'T.Partial' continuation.
148--
127--
149−-- Supplying the 'T.Partial' continuation with a bytestring will
128+-- Supplying the 'T.Partial' continuation with another bytestring will
150−-- resume parsing at the point where it was suspended, with the
129+-- resume parsing at the point where it was suspended. You must be
151−-- bytestring you supplied used as new input at the end of the
152−-- existing input. You must be prepared for the result of the resumed
130+-- prepared for the result of the resumed parse to be another
153−-- parse to be another 'T.Partial' continuation.
131+-- 'T.Partial' continuation.
154--
132--
155-- To indicate that you have no more input, supply the 'T.Partial'
133-- To indicate that you have no more input, supply the 'T.Partial'
156-- continuation with an empty bytestring.
134-- continuation with an empty bytestring.
@@ -162,19 +140,12 @@ import qualified Data.Attoparsec.Internal.Types as T
162-- If you do not need support for incremental input, consider using
140-- If you do not need support for incremental input, consider using
163-- the 'I.parseOnly' function to run your parser. It will never
141-- the 'I.parseOnly' function to run your parser. It will never
164-- prompt for more input.
142-- prompt for more input.
165−--
166−-- /Note/: incremental input does /not/ imply that attoparsec will
167−-- release portions of its internal state for garbage collection as it
168−-- proceeds. Its internal representation is equivalent to a single
169−-- 'ByteString': if you feed incremental input to a parser, it will
170−-- require memory proportional to the amount of input you supply.
171−-- (This is necessary to support arbitrary backtracking.)
172
143
173-- $performance
144-- $performance
174--
145--
175−-- If you write an attoparsec-based parser carefully, it can be
146+-- If you write an Attoparsec-based parser carefully, it can be
176−-- realistic to expect it to perform similarly to a hand-rolled C
147+-- realistic to expect it to perform within a factor of 2 of a
177−-- parser (measuring megabytes parsed per second).
148+-- hand-rolled C parser (measuring megabytes parsed per second).
178--
149--
179-- To actually achieve high performance, there are a few guidelines
150-- To actually achieve high performance, there are a few guidelines
180-- that it is useful to follow.
151-- that it is useful to follow.
@@ -195,6 +166,14 @@ import qualified Data.Attoparsec.Internal.Types as T
195-- Make active use of benchmarking and profiling tools to measure,
166-- Make active use of benchmarking and profiling tools to measure,
196-- find the problems with, and improve the performance of your parser.
167-- find the problems with, and improve the performance of your parser.
197
168
169+-- | If a parser has returned a 'T.Partial' result, supply it with more
170+-- input.
171+feed :: Result r -> B.ByteString -> Result r
172+feed f@(T.Fail _ _ _) _ = f
173+feed (T.Partial k) d = k d
174+feed (T.Done bs r) d = T.Done (B.append bs d) r
175+{-# INLINE feed #-}
176+
198-- | Run a parser and print its result to standard output.
177-- | Run a parser and print its result to standard output.
199parseTest :: (Show a) => I.Parser a -> B.ByteString -> IO ()
178parseTest :: (Show a) => I.Parser a -> B.ByteString -> IO ()
200parseTest p s = print (parse p s)
179parseTest p s = print (parse p s)
@@ -224,7 +203,6 @@ maybeResult _ = Nothing
224-- | Convert a 'Result' value to an 'Either' value. A 'T.Partial'
203-- | Convert a 'Result' value to an 'Either' value. A 'T.Partial'
225-- result is treated as failure.
204-- result is treated as failure.
226eitherResult :: Result r -> Either String r
205eitherResult :: Result r -> Either String r
227−eitherResult (T.Done _ r) = Right r
206+eitherResult (T.Done _ r) = Right r
228−eitherResult (T.Fail _ [] msg) = Left msg
207+eitherResult (T.Fail _ _ msg) = Left msg
229−eitherResult (T.Fail _ ctxs msg) = Left (intercalate " > " ctxs ++ ": " ++ msg)
230−eitherResult _ = Left "Result: incomplete input"
208+eitherResult _ = Left "Result: incomplete input"
Data/Attoparsec/ByteString/Buffer.hsdeleted−156
@@ -1,156 +0,0 @@
1−{-# LANGUAGE BangPatterns #-}
2−-- |
3−-- Module : Data.Attoparsec.ByteString.Buffer
4−-- Copyright : Bryan O'Sullivan 2007-2015
5−-- License : BSD3
6−--
7−-- Maintainer : bos@serpentine.com
8−-- Stability : experimental
9−-- Portability : GHC
10−--
11−-- An "immutable" buffer that supports cheap appends.
12−--
13−-- A Buffer is divided into an immutable read-only zone, followed by a
14−-- mutable area that we've preallocated, but not yet written to.
15−--
16−-- We overallocate at the end of a Buffer so that we can cheaply
17−-- append. Since a user of an existing Buffer cannot see past the end
18−-- of its immutable zone into the data that will change during an
19−-- append, this is safe.
20−--
21−-- Once we run out of space at the end of a Buffer, we do the usual
22−-- doubling of the buffer size.
23−--
24−-- The fact of having a mutable buffer really helps with performance,
25−-- but it does have a consequence: if someone misuses the Partial API
26−-- that attoparsec uses by calling the same continuation repeatedly
27−-- (which never makes sense in practice), they could overwrite data.
28−--
29−-- Since the API *looks* pure, it should *act* pure, too, so we use
30−-- two generation counters (one mutable, one immutable) to track the
31−-- number of appends to a mutable buffer. If the counters ever get out
32−-- of sync, someone is appending twice to a mutable buffer, so we
33−-- duplicate the entire buffer in order to preserve the immutability
34−-- of its older self.
35−--
36−-- While we could go a step further and gain protection against API
37−-- abuse on a multicore system, by use of an atomic increment
38−-- instruction to bump the mutable generation counter, that would be
39−-- very expensive, and feels like it would also be in the realm of the
40−-- ridiculous. Clients should never call a continuation more than
41−-- once; we lack a linear type system that could enforce this; and
42−-- there's only so far we should go to accommodate broken uses.
43−
44−module Data.Attoparsec.ByteString.Buffer
45− (
46− Buffer
47− , buffer
48− , unbuffer
49− , pappend
50− , length
51− , unsafeIndex
52− , substring
53− , unsafeDrop
54− ) where
55−
56−import Control.Exception (assert)
57−import Data.ByteString.Internal (ByteString(..), memcpy, nullForeignPtr)
58−import Data.Attoparsec.Internal.Fhthagn (inlinePerformIO)
59−import Data.List (foldl1')
60−import Data.Monoid as Mon (Monoid(..))
61−import Data.Semigroup (Semigroup(..))
62−import Data.Word (Word8)
63−import Foreign.ForeignPtr (ForeignPtr, withForeignPtr)
64−import Foreign.Ptr (castPtr, plusPtr)
65−import Foreign.Storable (peek, peekByteOff, poke, sizeOf)
66−import GHC.ForeignPtr (mallocPlainForeignPtrBytes)
67−import Prelude hiding (length)
68−
69−-- If _cap is zero, this buffer is empty.
70−data Buffer = Buf {
71− _fp :: {-# UNPACK #-} !(ForeignPtr Word8)
72− , _off :: {-# UNPACK #-} !Int
73− , _len :: {-# UNPACK #-} !Int
74− , _cap :: {-# UNPACK #-} !Int
75− , _gen :: {-# UNPACK #-} !Int
76− }
77−
78−instance Show Buffer where
79− showsPrec p = showsPrec p . unbuffer
80−
81−-- | The initial 'Buffer' has no mutable zone, so we can avoid all
82−-- copies in the (hopefully) common case of no further input being fed
83−-- to us.
84−buffer :: ByteString -> Buffer
85−buffer (PS fp off len) = Buf fp off len len 0
86−
87−unbuffer :: Buffer -> ByteString
88−unbuffer (Buf fp off len _ _) = PS fp off len
89−
90−instance Semigroup Buffer where
91− (Buf _ _ _ 0 _) <> b = b
92− a <> (Buf _ _ _ 0 _) = a
93− buf <> (Buf fp off len _ _) = append buf fp off len
94−
95−instance Monoid Buffer where
96− mempty = Buf nullForeignPtr 0 0 0 0
97−
98− mappend = (<>)
99−
100− mconcat [] = Mon.mempty
101− mconcat xs = foldl1' mappend xs
102−
103−pappend :: Buffer -> ByteString -> Buffer
104−pappend (Buf _ _ _ 0 _) bs = buffer bs
105−pappend buf (PS fp off len) = append buf fp off len
106−
107−append :: Buffer -> ForeignPtr a -> Int -> Int -> Buffer
108−append (Buf fp0 off0 len0 cap0 gen0) !fp1 !off1 !len1 =
109− inlinePerformIO . withForeignPtr fp0 $ \ptr0 ->
110− withForeignPtr fp1 $ \ptr1 -> do
111− let genSize = sizeOf (0::Int)
112− newlen = len0 + len1
113− gen <- if gen0 == 0
114− then return 0
115− else peek (castPtr ptr0)
116− if gen == gen0 && newlen <= cap0
117− then do
118− let newgen = gen + 1
119− poke (castPtr ptr0) newgen
120− memcpy (ptr0 `plusPtr` (off0+len0))
121− (ptr1 `plusPtr` off1)
122− (fromIntegral len1)
123− return (Buf fp0 off0 newlen cap0 newgen)
124− else do
125− let newcap = newlen * 2
126− fp <- mallocPlainForeignPtrBytes (newcap + genSize)
127− withForeignPtr fp $ \ptr_ -> do
128− let ptr = ptr_ `plusPtr` genSize
129− newgen = 1
130− poke (castPtr ptr_) newgen
131− memcpy ptr (ptr0 `plusPtr` off0) (fromIntegral len0)
132− memcpy (ptr `plusPtr` len0) (ptr1 `plusPtr` off1)
133− (fromIntegral len1)
134− return (Buf fp genSize newlen newcap newgen)
135−
136−length :: Buffer -> Int
137−length (Buf _ _ len _ _) = len
138−{-# INLINE length #-}
139−
140−unsafeIndex :: Buffer -> Int -> Word8
141−unsafeIndex (Buf fp off len _ _) i = assert (i >= 0 && i < len) .
142− inlinePerformIO . withForeignPtr fp $ flip peekByteOff (off+i)
143−{-# INLINE unsafeIndex #-}
144−
145−substring :: Int -> Int -> Buffer -> ByteString
146−substring s l (Buf fp off len _ _) =
147− assert (s >= 0 && s <= len) .
148− assert (l >= 0 && l <= len-s) $
149− PS fp (off+s) l
150−{-# INLINE substring #-}
151−
152−unsafeDrop :: Int -> Buffer -> ByteString
153−unsafeDrop s (Buf fp off len _ _) =
154− assert (s >= 0 && s <= len) $
155− PS fp (off+s) (len-s)
156−{-# INLINE unsafeDrop #-}
Data/Attoparsec/ByteString/Char8.hs+89−113
@@ -1,13 +1,10 @@
1−{-# LANGUAGE BangPatterns, CPP, FlexibleInstances, TypeFamilies,
1+{-# LANGUAGE BangPatterns, FlexibleInstances, TypeFamilies,
2 TypeSynonymInstances, GADTs #-}
2 TypeSynonymInstances, GADTs #-}
3−#if __GLASGOW_HASKELL__ >= 702
4−{-# LANGUAGE Trustworthy #-} -- Imports internal modules
5−#endif
6−{-# OPTIONS_GHC -fno-warn-orphans -fno-warn-warnings-deprecations #-}
3+{-# OPTIONS_GHC -fno-warn-orphans #-}
7
4
8-- |
5-- |
9-- Module : Data.Attoparsec.ByteString.Char8
6-- Module : Data.Attoparsec.ByteString.Char8
10−-- Copyright : Bryan O'Sullivan 2007-2015
7+-- Copyright : Bryan O'Sullivan 2007-2011
11-- License : BSD3
8-- License : BSD3
12--
9--
13-- Maintainer : bos@serpentine.com
10-- Maintainer : bos@serpentine.com
@@ -32,13 +29,18 @@ module Data.Attoparsec.ByteString.Char8
32 , A.parse
29 , A.parse
33 , A.feed
30 , A.feed
34 , A.parseOnly
31 , A.parseOnly
35− , A.parseWith
36 , A.parseTest
32 , A.parseTest
33+ , A.parseWith
37
34
38 -- ** Result conversion
35 -- ** Result conversion
39 , A.maybeResult
36 , A.maybeResult
40 , A.eitherResult
37 , A.eitherResult
41
38
39+ -- * Combinators
40+ , (I.<?>)
41+ , I.try
42+ , module Data.Attoparsec.Combinator
43+
42 -- * Parsing individual characters
44 -- * Parsing individual characters
43 , char
45 , char
44 , char8
46 , char8
@@ -70,7 +72,7 @@ module Data.Attoparsec.ByteString.Char8
70
72
71 -- * Efficient string handling
73 -- * Efficient string handling
72 , I.string
74 , I.string
73− , I.stringCI
75+ , stringCI
74 , skipSpace
76 , skipSpace
75 , skipWhile
77 , skipWhile
76 , I.take
78 , I.take
@@ -101,49 +103,23 @@ module Data.Attoparsec.ByteString.Char8
101 , Number(..)
103 , Number(..)
102 , number
104 , number
103 , rational
105 , rational
104− , scientific
105
106
106− -- * Combinators
107− , try
108− , (<?>)
109− , choice
110− , count
111− , option
112− , many'
113− , many1
114− , many1'
115− , manyTill
116− , manyTill'
117− , sepBy
118− , sepBy'
119− , sepBy1
120− , sepBy1'
121− , skipMany
122− , skipMany1
123− , eitherP
124− , I.match
125 -- * State observation and manipulation functions
107 -- * State observation and manipulation functions
126 , I.endOfInput
108 , I.endOfInput
127 , I.atEnd
109 , I.atEnd
128 ) where
110 ) where
129
111
130−#if !MIN_VERSION_base(4,8,0)
131−import Control.Applicative (pure, (*>), (<*), (<$>))
112+import Control.Applicative (pure, (*>), (<*), (<$>), (<|>))
132−import Data.Word (Word)
133−#endif
134−import Control.Applicative ((<|>))
135−import Control.Monad (void, when)
136import Data.Attoparsec.ByteString.FastSet (charClass, memberChar)
113import Data.Attoparsec.ByteString.FastSet (charClass, memberChar)
137−import Data.Attoparsec.ByteString.Internal (Parser)
114+import Data.Attoparsec.ByteString.Internal (Parser, (<?>))
138import Data.Attoparsec.Combinator
115import Data.Attoparsec.Combinator
139import Data.Attoparsec.Number (Number(..))
116import Data.Attoparsec.Number (Number(..))
140import Data.Bits (Bits, (.|.), shiftL)
117import Data.Bits (Bits, (.|.), shiftL)
141import Data.ByteString.Internal (c2w, w2c)
118import Data.ByteString.Internal (c2w, w2c)
142import Data.Int (Int8, Int16, Int32, Int64)
119import Data.Int (Int8, Int16, Int32, Int64)
143import Data.String (IsString(..))
120import Data.String (IsString(..))
144−import Data.Scientific (Scientific)
121+import Data.Scientific (Scientific, scientific, coefficient, base10Exponent)
145−import qualified Data.Scientific as Sci
146−import Data.Word (Word8, Word16, Word32, Word64)
122+import Data.Word (Word8, Word16, Word32, Word64, Word)
147import Prelude hiding (takeWhile)
123import Prelude hiding (takeWhile)
148import qualified Data.Attoparsec.ByteString as A
124import qualified Data.Attoparsec.ByteString as A
149import qualified Data.Attoparsec.ByteString.Internal as I
125import qualified Data.Attoparsec.ByteString.Internal as I
@@ -169,6 +145,16 @@ instance (a ~ B.ByteString) => IsString (Parser a) where
169-- currency sign in ISO-8859-1). Haskell 'Char' values above U+00FF
145-- currency sign in ISO-8859-1). Haskell 'Char' values above U+00FF
170-- are truncated, so e.g. U+1D6B7 is truncated to the byte @0xB7@.
146-- are truncated, so e.g. U+1D6B7 is truncated to the byte @0xB7@.
171
147
148+-- ASCII-specific but fast, oh yes.
149+toLower :: Word8 -> Word8
150+toLower w | w >= 65 && w <= 90 = w + 32
151+ | otherwise = w
152+
153+-- | Satisfy a literal string, ignoring case.
154+stringCI :: B.ByteString -> Parser B.ByteString
155+stringCI = I.stringTransform (B8.map toLower)
156+{-# INLINE stringCI #-}
157+
172-- | Consume input as long as the predicate returns 'True', and return
158-- | Consume input as long as the predicate returns 'True', and return
173-- the consumed input.
159-- the consumed input.
174--
160--
@@ -232,7 +218,7 @@ isDigit c = c >= '0' && c <= '9'
232
218
233-- | A fast digit predicate.
219-- | A fast digit predicate.
234isDigit_w8 :: Word8 -> Bool
220isDigit_w8 :: Word8 -> Bool
235−isDigit_w8 w = w - 48 <= 9
221+isDigit_w8 w = w >= 48 && w <= 57
236{-# INLINE isDigit_w8 #-}
222{-# INLINE isDigit_w8 #-}
237
223
238-- | Match any character.
224-- | Match any character.
@@ -269,7 +255,7 @@ isSpace c = (c == ' ') || ('\t' <= c && c <= '\r')
269
255
270-- | Fast 'Word8' predicate for matching ASCII space characters.
256-- | Fast 'Word8' predicate for matching ASCII space characters.
271isSpace_w8 :: Word8 -> Bool
257isSpace_w8 :: Word8 -> Bool
272−isSpace_w8 w = w == 32 || w - 9 <= 4
258+isSpace_w8 w = (w == 32) || (9 <= w && w <= 13)
273{-# INLINE isSpace_w8 #-}
259{-# INLINE isSpace_w8 #-}
274
260
275
261
@@ -371,39 +357,30 @@ skipSpace = I.skipWhile isSpace_w8
371
357
372-- $specalt
358-- $specalt
373--
359--
374−-- If you enable the @OverloadedStrings@ language extension, you can
360+-- The '.*>' and '<*.' combinators are intended for use with the
375−-- use the '*>' and '<*' combinators to simplify the common task of
361+-- @OverloadedStrings@ language extension. They simplify the common
376−-- matching a statically known string, then immediately parsing
362+-- task of matching a statically known string, then immediately
377−-- something else.
363+-- parsing something else.
378--
364--
379−-- Instead of writing something like this:
365+-- An example makes this easier to understand:
380--
366--
381−-- @
367+-- @{-\# LANGUAGE OverloadedStrings #-}
382−--'I.string' \"foo\" '*>' wibble
383−-- @
384--
368--
385−-- Using @OverloadedStrings@, you can omit the explicit use of
369+-- shoeSize = \"Shoe size: \" '.*>' 'decimal'
386−-- 'I.string', and write a more compact version:
387−--
388−-- @
389−-- \"foo\" '*>' wibble
390-- @
370-- @
391--
371--
392−-- (Note: the '.*>' and '<*.' combinators that were originally
372+-- If we were to try to use '*>' above instead, the type checker would
393−-- provided for this purpose are obsolete and unnecessary, and will be
373+-- not be able to tell which 'IsString' instance to use for the text
394−-- removed in the next major version.)
374+-- in quotes. We would have to be explicit, using either a type
375+-- signature or the 'I.string' parser.
395
376
396−-- | /Obsolete/. A type-specialized version of '*>' for
377+-- | Type-specialized version of '*>' for 'B.ByteString'.
397−-- 'B.ByteString'. Use '*>' instead.
398(.*>) :: B.ByteString -> Parser a -> Parser a
378(.*>) :: B.ByteString -> Parser a -> Parser a
399s .*> f = I.string s *> f
379s .*> f = I.string s *> f
400−{-# DEPRECATED (.*>) "This is no longer necessary, and will be removed. Use '*>' instead." #-}
401
380
402−-- | /Obsolete/. A type-specialized version of '<*' for
381+-- | Type-specialized version of '<*' for 'B.ByteString'.
403−-- 'B.ByteString'. Use '<*' instead.
404(<*.) :: Parser a -> B.ByteString -> Parser a
382(<*.) :: Parser a -> B.ByteString -> Parser a
405f <*. s = f <* I.string s
383f <*. s = f <* I.string s
406−{-# DEPRECATED (<*.) "This is no longer necessary, and will be removed. Use '<*' instead." #-}
407
384
408-- | A predicate that matches either a carriage return @\'\\r\'@ or
385-- | A predicate that matches either a carriage return @\'\\r\'@ or
409-- newline @\'\\n\'@ character.
386-- newline @\'\\n\'@ character.
@@ -444,8 +421,9 @@ hexadecimal = B8.foldl' step 0 `fmap` I.takeWhile1 isHexDigit
444
421
445-- | Parse and decode an unsigned decimal number.
422-- | Parse and decode an unsigned decimal number.
446decimal :: Integral a => Parser a
423decimal :: Integral a => Parser a
447−decimal = B8.foldl' step 0 `fmap` I.takeWhile1 isDigit_w8
424+decimal = B8.foldl' step 0 `fmap` I.takeWhile1 isDig
425+ where isDig w = w >= 48 && w <= 57
448− where step a w = a * 10 + fromIntegral (w - 48)
426+ step a w = a * 10 + fromIntegral (w - 48)
449{-# SPECIALISE decimal :: Parser Int #-}
427{-# SPECIALISE decimal :: Parser Int #-}
450{-# SPECIALISE decimal :: Parser Int8 #-}
428{-# SPECIALISE decimal :: Parser Int8 #-}
451{-# SPECIALISE decimal :: Parser Int16 #-}
429{-# SPECIALISE decimal :: Parser Int16 #-}
@@ -471,24 +449,6 @@ signed p = (negate <$> (char8 '-' *> p))
471 <|> (char8 '+' *> p)
449 <|> (char8 '+' *> p)
472 <|> p
450 <|> p
473
451
474−-- | Parse a rational number.
475−--
476−-- The syntax accepted by this parser is the same as for 'double'.
477−--
478−-- /Note/: this parser is not safe for use with inputs from untrusted
479−-- sources. An input with a suitably large exponent such as
480−-- @"1e1000000000"@ will cause a huge 'Integer' to be allocated,
481−-- resulting in what is effectively a denial-of-service attack.
482−--
483−-- In most cases, it is better to use 'double' or 'scientific'
484−-- instead.
485−rational :: Fractional a => Parser a
486−{-# SPECIALIZE rational :: Parser Double #-}
487−{-# SPECIALIZE rational :: Parser Float #-}
488−{-# SPECIALIZE rational :: Parser Rational #-}
489−{-# SPECIALIZE rational :: Parser Scientific #-}
490−rational = scientifically realToFrac
491−
492-- | Parse a rational number.
452-- | Parse a rational number.
493--
453--
494-- This parser accepts an optional leading sign character, followed by
454-- This parser accepts an optional leading sign character, followed by
@@ -516,57 +476,73 @@ rational = scientifically realToFrac
516--
476--
517-- This function does not accept string representations of \"NaN\" or
477-- This function does not accept string representations of \"NaN\" or
518-- \"Infinity\".
478-- \"Infinity\".
479+rational :: Fractional a => Parser a
480+{-# SPECIALIZE rational :: Parser Double #-}
481+{-# SPECIALIZE rational :: Parser Float #-}
482+{-# SPECIALIZE rational :: Parser Rational #-}
483+{-# SPECIALIZE rational :: Parser Scientific #-}
484+rational = scientifically realToFrac
485+
486+-- | Parse a rational number.
487+--
488+-- The syntax accepted by this parser is the same as for 'rational'.
489+--
490+-- /Note/: This function is almost ten times faster than 'rational',
491+-- but is slightly less accurate.
492+--
493+-- The 'Double' type supports about 16 decimal places of accuracy.
494+-- For 94.2% of numbers, this function and 'rational' give identical
495+-- results, but for the remaining 5.8%, this function loses precision
496+-- around the 15th decimal place. For 0.001% of numbers, this
497+-- function will lose precision at the 13th or 14th decimal place.
498+--
499+-- This function does not accept string representations of \"NaN\" or
500+-- \"Infinity\".
519double :: Parser Double
501double :: Parser Double
520−double = scientifically Sci.toRealFloat
502+double = rational
521
503
522-- | Parse a number, attempting to preserve both speed and precision.
504-- | Parse a number, attempting to preserve both speed and precision.
523--
505--
524−-- The syntax accepted by this parser is the same as for 'double'.
506+-- The syntax accepted by this parser is the same as for 'rational'.
507+--
508+-- /Note/: This function is almost ten times faster than 'rational'.
509+-- On integral inputs, it gives perfectly accurate answers, and on
510+-- floating point inputs, it is slightly less accurate than
511+-- 'rational'.
512+--
513+-- This function does not accept string representations of \"NaN\" or
514+-- \"
525number :: Parser Number
515number :: Parser Number
526number = scientifically $ \s ->
516number = scientifically $ \s ->
527− let e = Sci.base10Exponent s
517+ let e = base10Exponent s
528− c = Sci.coefficient s
518+ c = coefficient s
529 in if e >= 0
519 in if e >= 0
530 then I (c * 10 ^ e)
520 then I (c * 10 ^ e)
531− else D (Sci.toRealFloat s)
521+ else D (fromInteger c / 10 ^ negate e)
532−{-# DEPRECATED number "Use 'scientific' instead." #-}
533−
534−-- | Parse a scientific number.
535−--
536−-- The syntax accepted by this parser is the same as for 'double'.
537−scientific :: Parser Scientific
538−scientific = scientifically id
539−
540−-- A strict pair
541−data SP = SP !Integer {-# UNPACK #-}!Int
542
522
543{-# INLINE scientifically #-}
523{-# INLINE scientifically #-}
544scientifically :: (Scientific -> a) -> Parser a
524scientifically :: (Scientific -> a) -> Parser a
545scientifically h = do
525scientifically h = do
546 let minus = 45
526 let minus = 45
547 plus = 43
527 plus = 43
548− sign <- I.peekWord8'
549− let !positive = sign == plus || sign /= minus
528+ !positive <- ((== plus) <$> I.satisfy (\c -> c == minus || c == plus)) <|>
550− when (sign == plus || sign == minus) $
529+ pure True
551− void $ I.anyWord8
552
530
553 n <- decimal
531 n <- decimal
554
532
555− let f fracDigits = SP (B8.foldl' step n fracDigits)
533+ let f fracDigits = scientific (B8.foldl' step n fracDigits)
556− (negate $ B8.length fracDigits)
534+ (negate $ B8.length fracDigits)
557 step a w = a * 10 + fromIntegral (w - 48)
535 step a w = a * 10 + fromIntegral (w - 48)
558
536
559− dotty <- I.peekWord8
537+ s <- let dot = 46 in
560− -- '.' -> ascii 46
561− SP c e <- case dotty of
562− Just 46 -> I.anyWord8 *> (f <$> I.takeWhile isDigit_w8)
538+ (I.satisfy (==dot) *> (f <$> I.takeWhile isDigit_w8)) <|>
563− _ -> pure (SP n 0)
539+ pure (scientific n 0)
564
540
565− let !signedCoeff | positive = c
541+ let !signedCoeff | positive = coefficient s
566− | otherwise = -c
542+ | otherwise = negate $ coefficient s
567
543
568 let littleE = 101
544 let littleE = 101
569 bigE = 69
545 bigE = 69
570− (I.satisfy (\ex -> ex == littleE || ex == bigE) *>
546+ (I.satisfy (\c -> c == littleE || c == bigE) *>
571− fmap (h . Sci.scientific signedCoeff . (e +)) (signed decimal)) <|>
547+ fmap (h . scientific signedCoeff . (base10Exponent s +)) (signed decimal)) <|>
572− return (h $ Sci.scientific signedCoeff e)
548+ return (h $ scientific signedCoeff (base10Exponent s))
Data/Attoparsec/ByteString/FastSet.hs+1−1
@@ -3,7 +3,7 @@
3-----------------------------------------------------------------------------
3-----------------------------------------------------------------------------
4-- |
4-- |
5-- Module : Data.Attoparsec.ByteString.FastSet
5-- Module : Data.Attoparsec.ByteString.FastSet
6−-- Copyright : Bryan O'Sullivan 2007-2015
6+-- Copyright : Bryan O'Sullivan 2008
7-- License : BSD3
7-- License : BSD3
8--
8--
9-- Maintainer : bos@serpentine.com
9-- Maintainer : bos@serpentine.com
Data/Attoparsec/ByteString/Internal.hs+256−265
@@ -1,15 +1,15 @@
1−{-# LANGUAGE BangPatterns, CPP, GADTs, OverloadedStrings, RankNTypes,
1+{-# LANGUAGE BangPatterns, CPP, Rank2Types, OverloadedStrings,
2− RecordWildCards #-}
2+ RecordWildCards, MagicHash, UnboxedTuples #-}
3-- |
3-- |
4-- Module : Data.Attoparsec.ByteString.Internal
4-- Module : Data.Attoparsec.ByteString.Internal
5−-- Copyright : Bryan O'Sullivan 2007-2015
5+-- Copyright : Bryan O'Sullivan 2007-2011
6-- License : BSD3
6-- License : BSD3
7--
7--
8-- Maintainer : bos@serpentine.com
8-- Maintainer : bos@serpentine.com
9-- Stability : experimental
9-- Stability : experimental
10-- Portability : unknown
10-- Portability : unknown
11--
11--
12−-- Simple, efficient parser combinators for 'ByteString' strings,
12+-- Simple, efficient parser combinators for 'B.ByteString' strings,
13-- loosely based on the Parsec library.
13-- loosely based on the Parsec library.
14
14
15module Data.Attoparsec.ByteString.Internal
15module Data.Attoparsec.ByteString.Internal
@@ -23,6 +23,8 @@ module Data.Attoparsec.ByteString.Internal
23 , parseOnly
23 , parseOnly
24
24
25 -- * Combinators
25 -- * Combinators
26+ , (<?>)
27+ , try
26 , module Data.Attoparsec.Combinator
28 , module Data.Attoparsec.Combinator
27
29
28 -- * Parsing individual bytes
30 -- * Parsing individual bytes
@@ -47,10 +49,9 @@ module Data.Attoparsec.ByteString.Internal
47 -- * Efficient string handling
49 -- * Efficient string handling
48 , skipWhile
50 , skipWhile
49 , string
51 , string
50− , stringCI
52+ , stringTransform
51 , take
53 , take
52 , scan
54 , scan
53− , runScanner
54 , takeWhile
55 , takeWhile
55 , takeWhile1
56 , takeWhile1
56 , takeTill
57 , takeTill
@@ -59,32 +60,26 @@ module Data.Attoparsec.ByteString.Internal
59 , takeByteString
60 , takeByteString
60 , takeLazyByteString
61 , takeLazyByteString
61
62
62− -- * Utilities
63+ -- * State observation and manipulation functions
63− , endOfLine
64 , endOfInput
64 , endOfInput
65− , match
66 , atEnd
65 , atEnd
66+
67+ -- * Utilities
68+ , endOfLine
67 ) where
69 ) where
68
70
69−#if !MIN_VERSION_base(4,8,0)
70−import Control.Applicative ((<$>))
71+import Control.Applicative ((<|>), (<$>))
71−#endif
72−import Control.Applicative ((<|>))
73import Control.Monad (when)
72import Control.Monad (when)
74−import Data.Attoparsec.ByteString.Buffer (Buffer, buffer)
75import Data.Attoparsec.ByteString.FastSet (charClass, memberWord8)
73import Data.Attoparsec.ByteString.FastSet (charClass, memberWord8)
76−import Data.Attoparsec.Combinator ((<?>))
74+import Data.Attoparsec.Combinator
77−import Data.Attoparsec.Internal
78−import Data.Attoparsec.Internal.Fhthagn (inlinePerformIO)
79−import Data.Attoparsec.Internal.Types hiding (Parser, Failure, Success)
75+import Data.Attoparsec.Internal.Types
80−import Data.ByteString (ByteString)
76+ hiding (Parser, Input, Added, Failure, Success)
81−import Data.List (intercalate)
77+import Data.Monoid (Monoid(..))
82import Data.Word (Word8)
78import Data.Word (Word8)
83import Foreign.ForeignPtr (withForeignPtr)
79import Foreign.ForeignPtr (withForeignPtr)
84import Foreign.Ptr (castPtr, minusPtr, plusPtr)
80import Foreign.Ptr (castPtr, minusPtr, plusPtr)
85import Foreign.Storable (Storable(peek, sizeOf))
81import Foreign.Storable (Storable(peek, sizeOf))
86−import Prelude hiding (getChar, succ, take, takeWhile)
82+import Prelude hiding (getChar, take, takeWhile)
87−import qualified Data.Attoparsec.ByteString.Buffer as Buf
88import qualified Data.Attoparsec.Internal.Types as T
83import qualified Data.Attoparsec.Internal.Types as T
89import qualified Data.ByteString as B8
84import qualified Data.ByteString as B8
90import qualified Data.ByteString.Char8 as B
85import qualified Data.ByteString.Char8 as B
@@ -92,10 +87,88 @@ import qualified Data.ByteString.Internal as B
92import qualified Data.ByteString.Lazy as L
87import qualified Data.ByteString.Lazy as L
93import qualified Data.ByteString.Unsafe as B
88import qualified Data.ByteString.Unsafe as B
94
89
90+#if defined(__GLASGOW_HASKELL__)
91+import GHC.Base (realWorld#)
92+import GHC.IO (IO(IO))
93+#else
94+import System.IO.Unsafe (unsafePerformIO)
95+#endif
96+
95−type Parser = T.Parser ByteString
97+type Parser = T.Parser B.ByteString
96−type Result = IResult ByteString
98+type Result = IResult B.ByteString
99+type Input = T.Input B.ByteString
100+type Added = T.Added B.ByteString
97−type Failure r = T.Failure ByteString Buffer r
101+type Failure r = T.Failure B.ByteString r
98−type Success a r = T.Success ByteString Buffer a r
102+type Success a r = T.Success B.ByteString a r
103+
104+ensure' :: Int -> Input -> Added -> More -> Failure r -> Success B.ByteString r
105+ -> IResult B.ByteString r
106+ensure' !n0 i0 a0 m0 kf0 ks0 =
107+ T.runParser (demandInput >> go n0) i0 a0 m0 kf0 ks0
108+ where
109+ go !n = T.Parser $ \i a m kf ks ->
110+ if B.length (unI i) >= n
111+ then ks i a m (unI i)
112+ else T.runParser (demandInput >> go n) i a m kf ks
113+
114+-- | If at least @n@ bytes of input are available, return the current
115+-- input, otherwise fail.
116+ensure :: Int -> Parser B.ByteString
117+ensure !n = T.Parser $ \i0 a0 m0 kf ks ->
118+ if B.length (unI i0) >= n
119+ then ks i0 a0 m0 (unI i0)
120+ -- The uncommon case is kept out-of-line to reduce code size:
121+ else ensure' n i0 a0 m0 kf ks
122+-- Non-recursive so the bounds check can be inlined:
123+{-# INLINE ensure #-}
124+
125+-- | Ask for input. If we receive any, pass it to a success
126+-- continuation, otherwise to a failure continuation.
127+prompt :: Input -> Added -> More
128+ -> (Input -> Added -> More -> Result r)
129+ -> (Input -> Added -> More -> Result r)
130+ -> Result r
131+prompt i0 a0 _m0 kf ks = Partial $ \s ->
132+ if B.null s
133+ then kf i0 a0 Complete
134+ else ks (i0 <> I s) (a0 <> A s) Incomplete
135+
136+-- | Immediately demand more input via a 'Partial' continuation
137+-- result.
138+demandInput :: Parser ()
139+demandInput = T.Parser $ \i0 a0 m0 kf ks ->
140+ if m0 == Complete
141+ then kf i0 a0 m0 ["demandInput"] "not enough bytes"
142+ else let kf' i a m = kf i a m ["demandInput"] "not enough bytes"
143+ ks' i a m = ks i a m ()
144+ in prompt i0 a0 m0 kf' ks'
145+
146+-- | This parser always succeeds. It returns 'True' if any input is
147+-- available either immediately or on demand, and 'False' if the end
148+-- of all input has been reached.
149+wantInput :: Parser Bool
150+wantInput = T.Parser $ \i0 a0 m0 _kf ks ->
151+ case () of
152+ _ | not (B.null (unI i0)) -> ks i0 a0 m0 True
153+ | m0 == Complete -> ks i0 a0 m0 False
154+ | otherwise -> let kf' i a m = ks i a m False
155+ ks' i a m = ks i a m True
156+ in prompt i0 a0 m0 kf' ks'
157+
158+get :: Parser B.ByteString
159+get = T.Parser $ \i0 a0 m0 _kf ks -> ks i0 a0 m0 (unI i0)
160+
161+put :: B.ByteString -> Parser ()
162+put s = T.Parser $ \_i0 a0 m0 _kf ks -> ks (I s) a0 m0 ()
163+
164+-- | Attempt a parse, and if it fails, rewind the input so that no
165+-- input appears to have been consumed.
166+--
167+-- This combinator is provided for compatibility with Parsec.
168+-- Attoparsec parsers always backtrack on failure.
169+try :: Parser a -> Parser a
170+try p = p
171+{-# INLINE try #-}
99
172
100-- | The parser @satisfy p@ succeeds for any byte for which the
173-- | The parser @satisfy p@ succeeds for any byte for which the
101-- predicate @p@ returns 'True'. Returns the byte that is actually
174-- predicate @p@ returns 'True'. Returns the byte that is actually
@@ -105,9 +178,10 @@ type Success a r = T.Success ByteString Buffer a r
105-- > where isDigit w = w >= 48 && w <= 57
178-- > where isDigit w = w >= 48 && w <= 57
106satisfy :: (Word8 -> Bool) -> Parser Word8
179satisfy :: (Word8 -> Bool) -> Parser Word8
107satisfy p = do
180satisfy p = do
108− h <- peekWord8'
181+ s <- ensure 1
182+ let !w = B.unsafeHead s
109− if p h
183+ if p w
110− then advance 1 >> return h
184+ then put (B.unsafeTail s) >> return w
111 else fail "satisfy"
185 else fail "satisfy"
112{-# INLINE satisfy #-}
186{-# INLINE satisfy #-}
113
187
@@ -118,9 +192,9 @@ satisfy p = do
118-- > where isDigit w = w >= 48 && w <= 57
192-- > where isDigit w = w >= 48 && w <= 57
119skip :: (Word8 -> Bool) -> Parser ()
193skip :: (Word8 -> Bool) -> Parser ()
120skip p = do
194skip p = do
121− h <- peekWord8'
195+ s <- ensure 1
122− if p h
196+ if p (B.unsafeHead s)
123− then advance 1
197+ then put (B.unsafeTail s)
124 else fail "skip"
198 else fail "skip"
125
199
126-- | The parser @satisfyWith f p@ transforms a byte, and succeeds if
200-- | The parser @satisfyWith f p@ transforms a byte, and succeeds if
@@ -128,10 +202,11 @@ skip p = do
128-- parser returns the transformed byte that was parsed.
202-- parser returns the transformed byte that was parsed.
129satisfyWith :: (Word8 -> a) -> (a -> Bool) -> Parser a
203satisfyWith :: (Word8 -> a) -> (a -> Bool) -> Parser a
130satisfyWith f p = do
204satisfyWith f p = do
131− h <- peekWord8'
205+ s <- ensure 1
132− let c = f h
206+ let c = f $! B.unsafeHead s
133 if p c
207 if p c
208+ then let !t = B.unsafeTail s
134− then advance 1 >> return c
209+ in put t >> return c
135 else fail "satisfyWith"
210 else fail "satisfyWith"
136{-# INLINE satisfyWith #-}
211{-# INLINE satisfyWith #-}
137
212
@@ -141,15 +216,24 @@ storable = hack undefined
141 hack :: Storable b => b -> Parser b
216 hack :: Storable b => b -> Parser b
142 hack dummy = do
217 hack dummy = do
143 (fp,o,_) <- B.toForeignPtr `fmap` take (sizeOf dummy)
218 (fp,o,_) <- B.toForeignPtr `fmap` take (sizeOf dummy)
144− return . inlinePerformIO . withForeignPtr fp $ \p ->
219+ return . B.inlinePerformIO . withForeignPtr fp $ \p ->
145 peek (castPtr $ p `plusPtr` o)
220 peek (castPtr $ p `plusPtr` o)
146
221
147−-- | Consume exactly @n@ bytes of input.
222+-- | Consume @n@ bytes of input, but succeed only if the predicate
223+-- returns 'True'.
148−take :: Int -> Parser ByteString
224+takeWith :: Int -> (B.ByteString -> Bool) -> Parser B.ByteString
149−take n0 = do
225+takeWith n0 p = do
150 let n = max n0 0
226 let n = max n0 0
151 s <- ensure n
227 s <- ensure n
228+ let h = B.unsafeTake n s
229+ t = B.unsafeDrop n s
230+ if p h
152− advance n >> return s
231+ then put t >> return h
232+ else fail "takeWith"
233+
234+-- | Consume exactly @n@ bytes of input.
235+take :: Int -> Parser B.ByteString
236+take n = takeWith n (const True)
153{-# INLINE take #-}
237{-# INLINE take #-}
154
238
155-- | @string s@ parses a sequence of bytes that identically match
239-- | @string s@ parses a sequence of bytes that identically match
@@ -165,71 +249,27 @@ take n0 = do
165--
249--
166-- The reason for its failure is that the first branch is a
250-- The reason for its failure is that the first branch is a
167-- partial match, and will consume the letters @\'f\'@ and @\'o\'@
251-- partial match, and will consume the letters @\'f\'@ and @\'o\'@
168−-- before failing. In attoparsec, the above parser will /succeed/ on
252+-- before failing. In Attoparsec, the above parser will /succeed/ on
169-- that input, because the failed first branch will consume nothing.
253-- that input, because the failed first branch will consume nothing.
170−string :: ByteString -> Parser ByteString
254+string :: B.ByteString -> Parser B.ByteString
171−string s = string_ (stringSuspended id) id s
255+string s = takeWith (B.length s) (==s)
172{-# INLINE string #-}
256{-# INLINE string #-}
173
257
174−-- ASCII-specific but fast, oh yes.
258+stringTransform :: (B.ByteString -> B.ByteString) -> B.ByteString
175−toLower :: Word8 -> Word8
259+ -> Parser B.ByteString
176−toLower w | w >= 65 && w <= 90 = w + 32
260+stringTransform f s = takeWith (B.length s) ((==f s) . f)
177− | otherwise = w
261+{-# INLINE stringTransform #-}
178−
179−-- | Satisfy a literal string, ignoring case.
180−stringCI :: ByteString -> Parser ByteString
181−stringCI s = string_ (stringSuspended lower) lower s
182− where lower = B8.map toLower
183−{-# INLINE stringCI #-}
184−
185−string_ :: (forall r. ByteString -> ByteString -> Buffer -> Pos -> More
186− -> Failure r -> Success ByteString r -> Result r)
187− -> (ByteString -> ByteString)
188− -> ByteString -> Parser ByteString
189−string_ suspended f s0 = T.Parser $ \t pos more lose succ ->
190− let n = B.length s
191− s = f s0
192− in if lengthAtLeast pos n t
193− then let t' = substring pos (Pos n) t
194− in if s == f t'
195− then succ t (pos + Pos n) more t'
196− else lose t pos more [] "string"
197− else let t' = Buf.unsafeDrop (fromPos pos) t
198− in if f t' `B.isPrefixOf` s
199− then suspended s (B.drop (B.length t') s) t pos more lose succ
200− else lose t pos more [] "string"
201−{-# INLINE string_ #-}
202−
203−stringSuspended :: (ByteString -> ByteString)
204− -> ByteString -> ByteString -> Buffer -> Pos -> More
205− -> Failure r
206− -> Success ByteString r
207− -> Result r
208−stringSuspended f s0 s t pos more lose succ =
209− runParser (demandInput_ >>= go) t pos more lose succ
210− where go s'0 = T.Parser $ \t' pos' more' lose' succ' ->
211− let m = B.length s
212− s' = f s'0
213− n = B.length s'
214− in if n >= m
215− then if B.unsafeTake m s' == s
216− then let o = Pos (B.length s0)
217− in succ' t' (pos' + o) more'
218− (substring pos' o t')
219− else lose' t' pos' more' [] "string"
220− else if s' == B.unsafeTake n s
221− then stringSuspended f s0 (B.unsafeDrop n s)
222− t' pos' more' lose' succ'
223− else lose' t' pos' more' [] "string"
224
262
225-- | Skip past input for as long as the predicate returns 'True'.
263-- | Skip past input for as long as the predicate returns 'True'.
226skipWhile :: (Word8 -> Bool) -> Parser ()
264skipWhile :: (Word8 -> Bool) -> Parser ()
227skipWhile p = go
265skipWhile p = go
228 where
266 where
229 go = do
267 go = do
230− t <- B8.takeWhile p <$> get
268+ t <- B8.dropWhile p <$> get
231− continue <- inputSpansChunks (B.length t)
269+ put t
270+ when (B.null t) $ do
271+ input <- wantInput
232− when continue go
272+ when input go
233{-# INLINE skipWhile #-}
273{-# INLINE skipWhile #-}
234
274
235-- | Consume input as long as the predicate returns 'False'
275-- | Consume input as long as the predicate returns 'False'
@@ -239,10 +279,9 @@ skipWhile p = go
239-- predicate returns 'True' on the first byte of input.
279-- predicate returns 'True' on the first byte of input.
240--
280--
241-- /Note/: Because this parser does not fail, do not use it with
281-- /Note/: Because this parser does not fail, do not use it with
242−-- combinators such as 'Control.Applicative.many', because such
282+-- combinators such as 'many', because such parsers loop until a
243−-- parsers loop until a failure occurs. Careless use will thus result
283+-- failure occurs. Careless use will thus result in an infinite loop.
244−-- in an infinite loop.
245−takeTill :: (Word8 -> Bool) -> Parser ByteString
284+takeTill :: (Word8 -> Bool) -> Parser B.ByteString
246takeTill p = takeWhile (not . p)
285takeTill p = takeWhile (not . p)
247{-# INLINE takeTill #-}
286{-# INLINE takeTill #-}
248
287
@@ -253,30 +292,24 @@ takeTill p = takeWhile (not . p)
253-- predicate returns 'False' on the first byte of input.
292-- predicate returns 'False' on the first byte of input.
254--
293--
255-- /Note/: Because this parser does not fail, do not use it with
294-- /Note/: Because this parser does not fail, do not use it with
256−-- combinators such as 'Control.Applicative.many', because such
295+-- combinators such as 'many', because such parsers loop until a
257−-- parsers loop until a failure occurs. Careless use will thus result
296+-- failure occurs. Careless use will thus result in an infinite loop.
258−-- in an infinite loop.
259−takeWhile :: (Word8 -> Bool) -> Parser ByteString
297+takeWhile :: (Word8 -> Bool) -> Parser B.ByteString
260−takeWhile p = do
298+takeWhile p = (B.concat . reverse) `fmap` go []
261− s <- B8.takeWhile p <$> get
262− continue <- inputSpansChunks (B.length s)
263− if continue
264− then takeWhileAcc p [s]
265− else return s
266−{-# INLINE takeWhile #-}
267−
268−takeWhileAcc :: (Word8 -> Bool) -> [ByteString] -> Parser ByteString
269−takeWhileAcc p = go
270 where
299 where
271 go acc = do
300 go acc = do
272− s <- B8.takeWhile p <$> get
301+ (h,t) <- B8.span p <$> get
273− continue <- inputSpansChunks (B.length s)
302+ put t
274− if continue
303+ if B.null t
304+ then do
305+ input <- wantInput
306+ if input
275− then go (s:acc)
307+ then go (h:acc)
276− else return $ concatReverse (s:acc)
308+ else return (h:acc)
277−{-# INLINE takeWhileAcc #-}
309+ else return (h:acc)
278−
310+{-# INLINE takeWhile #-}
311+
279−takeRest :: Parser [ByteString]
312+takeRest :: Parser [B.ByteString]
280takeRest = go []
313takeRest = go []
281 where
314 where
282 go acc = do
315 go acc = do
@@ -284,12 +317,12 @@ takeRest = go []
284 if input
317 if input
285 then do
318 then do
286 s <- get
319 s <- get
287− advance (B.length s)
320+ put B.empty
288 go (s:acc)
321 go (s:acc)
289 else return (reverse acc)
322 else return (reverse acc)
290
323
291-- | Consume all remaining input and return it as a single string.
324-- | Consume all remaining input and return it as a single string.
292−takeByteString :: Parser ByteString
325+takeByteString :: Parser B.ByteString
293takeByteString = B.concat `fmap` takeRest
326takeByteString = B.concat `fmap` takeRest
294
327
295-- | Consume all remaining input and return it as a single string.
328-- | Consume all remaining input and return it as a single string.
@@ -298,9 +331,23 @@ takeLazyByteString = L.fromChunks `fmap` takeRest
298
331
299data T s = T {-# UNPACK #-} !Int s
332data T s = T {-# UNPACK #-} !Int s
300
333
301−scan_ :: (s -> [ByteString] -> Parser r) -> s -> (s -> Word8 -> Maybe s)
334+-- | A stateful scanner. The predicate consumes and transforms a
302− -> Parser r
335+-- state argument, and each transformed state is passed to successive
303−scan_ f s0 p = go [] s0
336+-- invocations of the predicate on each byte of the input until one
337+-- returns 'Nothing' or the input ends.
338+--
339+-- This parser does not fail. It will return an empty string if the
340+-- predicate returns 'Nothing' on the first byte of input.
341+--
342+-- /Note/: Because this parser does not fail, do not use it with
343+-- combinators such as 'many', because such parsers loop until a
344+-- failure occurs. Careless use will thus result in an infinite loop.
345+scan :: s -> (s -> Word8 -> Maybe s) -> Parser B.ByteString
346+scan s0 p = do
347+ chunks <- go [] s0
348+ case chunks of
349+ [x] -> return x
350+ xs -> return $! B.concat $ reverse xs
304 where
351 where
305 go acc s1 = do
352 go acc s1 = do
306 let scanner (B.PS fp off len) =
353 let scanner (B.PS fp off len) =
@@ -319,54 +366,32 @@ scan_ f s0 p = go [] s0
319 bs <- get
366 bs <- get
320 let T i s' = inlinePerformIO $ scanner bs
367 let T i s' = inlinePerformIO $ scanner bs
321 !h = B.unsafeTake i bs
368 !h = B.unsafeTake i bs
322− continue <- inputSpansChunks i
369+ !t = B.unsafeDrop i bs
323− if continue
370+ put t
324− then go (h:acc) s'
371+ if B.null t
325− else f s' (h:acc)
372+ then do
326−{-# INLINE scan_ #-}
373+ input <- wantInput
327−
374+ if input
328−-- | A stateful scanner. The predicate consumes and transforms a
375+ then go (h:acc) s'
329−-- state argument, and each transformed state is passed to successive
376+ else return (h:acc)
330−-- invocations of the predicate on each byte of the input until one
377+ else return (h:acc)
331−-- returns 'Nothing' or the input ends.
332−--
333−-- This parser does not fail. It will return an empty string if the
334−-- predicate returns 'Nothing' on the first byte of input.
335−--
336−-- /Note/: Because this parser does not fail, do not use it with
337−-- combinators such as 'Control.Applicative.many', because such
338−-- parsers loop until a failure occurs. Careless use will thus result
339−-- in an infinite loop.
340−scan :: s -> (s -> Word8 -> Maybe s) -> Parser ByteString
341−scan = scan_ $ \_ chunks -> return $! concatReverse chunks
342{-# INLINE scan #-}
378{-# INLINE scan #-}
343
379
344−-- | Like 'scan', but generalized to return the final state of the
345−-- scanner.
346−runScanner :: s -> (s -> Word8 -> Maybe s) -> Parser (ByteString, s)
347−runScanner = scan_ $ \s xs -> let !sx = concatReverse xs in return (sx, s)
348−{-# INLINE runScanner #-}
349−
350-- | Consume input as long as the predicate returns 'True', and return
380-- | Consume input as long as the predicate returns 'True', and return
351-- the consumed input.
381-- the consumed input.
352--
382--
353-- This parser requires the predicate to succeed on at least one byte
383-- This parser requires the predicate to succeed on at least one byte
354-- of input: it will fail if the predicate never returns 'True' or if
384-- of input: it will fail if the predicate never returns 'True' or if
355-- there is no input left.
385-- there is no input left.
356−takeWhile1 :: (Word8 -> Bool) -> Parser ByteString
386+takeWhile1 :: (Word8 -> Bool) -> Parser B.ByteString
357takeWhile1 p = do
387takeWhile1 p = do
358− (`when` demandInput) =<< endOfChunk
388+ (`when` demandInput) =<< B.null <$> get
359− s <- B8.takeWhile p <$> get
389+ (h,t) <- B8.span p <$> get
360− let len = B.length s
361− if len == 0
362− then fail "takeWhile1"
390+ when (B.null h) $ fail "takeWhile1"
363− else do
391+ put t
364− advance len
392+ if B.null t
365− eoc <- endOfChunk
393+ then (h<>) `fmap` takeWhile p
366− if eoc
367− then takeWhileAcc p [s]
368− else return s
394+ else return h
369−{-# INLINE takeWhile1 #-}
370
395
371-- | Match any byte in a set.
396-- | Match any byte in a set.
372--
397--
@@ -408,129 +433,95 @@ notWord8 c = satisfy (/= c) <?> "not " ++ show c
408-- input has been reached. Does not consume any input.
433-- input has been reached. Does not consume any input.
409--
434--
410-- /Note/: Because this parser does not fail, do not use it with
435-- /Note/: Because this parser does not fail, do not use it with
411−-- combinators such as 'Control.Applicative.many', because such
436+-- combinators such as 'many', because such parsers loop until a
412−-- parsers loop until a failure occurs. Careless use will thus result
437+-- failure occurs. Careless use will thus result in an infinite loop.
413−-- in an infinite loop.
414peekWord8 :: Parser (Maybe Word8)
438peekWord8 :: Parser (Maybe Word8)
415−peekWord8 = T.Parser $ \t pos@(Pos pos_) more _lose succ ->
439+peekWord8 = T.Parser $ \i0 a0 m0 _kf ks ->
416− case () of
440+ if B.null (unI i0)
417− _| pos_ < Buf.length t ->
418− let !w = Buf.unsafeIndex t pos_
419− in succ t pos more (Just w)
420− | more == Complete ->
441+ then if m0 == Complete
421− succ t pos more Nothing
442+ then ks i0 a0 m0 Nothing
422− | otherwise ->
443+ else let ks' i a m = let !w = B.unsafeHead (unI i)
423− let succ' t' pos' more' = let !w = Buf.unsafeIndex t' pos_
424− in succ t' pos' more' (Just w)
444+ in ks i a m (Just w)
425− lose' t' pos' more' = succ t' pos' more' Nothing
445+ kf' i a m = ks i a m Nothing
426− in prompt t pos more lose' succ'
446+ in prompt i0 a0 m0 kf' ks'
447+ else let !w = B.unsafeHead (unI i0)
448+ in ks i0 a0 m0 (Just w)
427{-# INLINE peekWord8 #-}
449{-# INLINE peekWord8 #-}
428
450
429-- | Match any byte, to perform lookahead. Does not consume any
451-- | Match any byte, to perform lookahead. Does not consume any
430-- input, but will fail if end of input has been reached.
452-- input, but will fail if end of input has been reached.
431peekWord8' :: Parser Word8
453peekWord8' :: Parser Word8
432−peekWord8' = T.Parser $ \t pos more lose succ ->
454+peekWord8' = do
433− if lengthAtLeast pos 1 t
455+ s <- ensure 1
434− then succ t pos more (Buf.unsafeIndex t (fromPos pos))
456+ return $! B.unsafeHead s
435− else let succ' t' pos' more' bs' = succ t' pos' more' $! B.unsafeHead bs'
436− in ensureSuspended 1 t pos more lose succ'
437{-# INLINE peekWord8' #-}
457{-# INLINE peekWord8' #-}
438
458
459+-- | Match only if all input has been consumed.
460+endOfInput :: Parser ()
461+endOfInput = T.Parser $ \i0 a0 m0 kf ks ->
462+ if B.null (unI i0)
463+ then if m0 == Complete
464+ then ks i0 a0 m0 ()
465+ else let kf' i1 a1 m1 _ _ = addS i0 a0 m0 i1 a1 m1 $
466+ \ i2 a2 m2 -> ks i2 a2 m2 ()
467+ ks' i1 a1 m1 _ = addS i0 a0 m0 i1 a1 m1 $
468+ \ i2 a2 m2 -> kf i2 a2 m2 []
469+ "endOfInput"
470+ in T.runParser demandInput i0 a0 m0 kf' ks'
471+ else kf i0 a0 m0 [] "endOfInput"
472+
473+-- | Return an indication of whether the end of input has been
474+-- reached.
475+atEnd :: Parser Bool
476+atEnd = not <$> wantInput
477+{-# INLINE atEnd #-}
478+
439-- | Match either a single newline character @\'\\n\'@, or a carriage
479-- | Match either a single newline character @\'\\n\'@, or a carriage
440-- return followed by a newline character @\"\\r\\n\"@.
480-- return followed by a newline character @\"\\r\\n\"@.
441endOfLine :: Parser ()
481endOfLine :: Parser ()
442endOfLine = (word8 10 >> return ()) <|> (string "\r\n" >> return ())
482endOfLine = (word8 10 >> return ()) <|> (string "\r\n" >> return ())
443
483
484+-- | Name the parser, in case failure occurs.
485+(<?>) :: Parser a
486+ -> String -- ^ the name to use if parsing fails
487+ -> Parser a
488+p <?> msg0 = T.Parser $ \i0 a0 m0 kf ks ->
489+ let kf' i a m strs msg = kf i a m (msg0:strs) msg
490+ in T.runParser p i0 a0 m0 kf' ks
491+{-# INLINE (<?>) #-}
492+infix 0 <?>
493+
444-- | Terminal failure continuation.
494-- | Terminal failure continuation.
445failK :: Failure a
495failK :: Failure a
446−failK t (Pos pos) _more stack msg = Fail (Buf.unsafeDrop pos t) stack msg
496+failK i0 _a0 _m0 stack msg = Fail (unI i0) stack msg
447{-# INLINE failK #-}
497{-# INLINE failK #-}
448
498
449-- | Terminal success continuation.
499-- | Terminal success continuation.
450successK :: Success a a
500successK :: Success a a
451−successK t (Pos pos) _more a = Done (Buf.unsafeDrop pos t) a
501+successK i0 _a0 _m0 a = Done (unI i0) a
452{-# INLINE successK #-}
502{-# INLINE successK #-}
453
503
454-- | Run a parser.
504-- | Run a parser.
455−parse :: Parser a -> ByteString -> Result a
505+parse :: Parser a -> B.ByteString -> Result a
456−parse m s = T.runParser m (buffer s) (Pos 0) Incomplete failK successK
506+parse m s = T.runParser m (I s) mempty Incomplete failK successK
457{-# INLINE parse #-}
507{-# INLINE parse #-}
458
508
459-- | Run a parser that cannot be resupplied via a 'Partial' result.
509-- | Run a parser that cannot be resupplied via a 'Partial' result.
460−--
461−-- This function does not force a parser to consume all of its input.
462−-- Instead, any residual input will be discarded. To force a parser
463−-- to consume all of its input, use something like this:
464−--
465−-- @
466−--'parseOnly' (myParser 'Control.Applicative.<*' 'endOfInput')
467−-- @
468−parseOnly :: Parser a -> ByteString -> Either String a
510+parseOnly :: Parser a -> B.ByteString -> Either String a
469−parseOnly m s = case T.runParser m (buffer s) (Pos 0) Complete failK successK of
511+parseOnly m s = case T.runParser m (I s) mempty Complete failK successK of
470− Fail _ [] err -> Left err
471− Fail _ ctxs err -> Left (intercalate " > " ctxs ++ ": " ++ err)
512+ Fail _ _ err -> Left err
472− Done _ a -> Right a
513+ Done _ a -> Right a
473− _ -> error "parseOnly: impossible error!"
514+ _ -> error "parseOnly: impossible error!"
474{-# INLINE parseOnly #-}
515{-# INLINE parseOnly #-}
475
516
476−get :: Parser ByteString
517+-- | Just like unsafePerformIO, but we inline it. Big performance gains as
477−get = T.Parser $ \t pos more _lose succ ->
518+-- it exposes lots of things to further inlining. /Very unsafe/. In
478− succ t pos more (Buf.unsafeDrop (fromPos pos) t)
519+-- particular, you should do no memory allocation inside an
479−{-# INLINE get #-}
520+-- 'inlinePerformIO' block. On Hugs this is just @unsafePerformIO@.
480−
521+inlinePerformIO :: IO a -> a
481−endOfChunk :: Parser Bool
522+#if defined(__GLASGOW_HASKELL__)
482−endOfChunk = T.Parser $ \t pos more _lose succ ->
523+inlinePerformIO (IO m) = case m realWorld# of (# _, r #) -> r
483− succ t pos more (fromPos pos == Buf.length t)
524+#else
484−{-# INLINE endOfChunk #-}
525+inlinePerformIO = unsafePerformIO
485−
526+#endif
486−inputSpansChunks :: Int -> Parser Bool
527+{-# INLINE inlinePerformIO #-}
487−inputSpansChunks i = T.Parser $ \t pos_ more _lose succ ->
488− let pos = pos_ + Pos i
489− in if fromPos pos < Buf.length t || more == Complete
490− then succ t pos more False
491− else let lose' t' pos' more' = succ t' pos' more' False
492− succ' t' pos' more' = succ t' pos' more' True
493− in prompt t pos more lose' succ'
494−{-# INLINE inputSpansChunks #-}
495−
496−advance :: Int -> Parser ()
497−advance n = T.Parser $ \t pos more _lose succ ->
498− succ t (pos + Pos n) more ()
499−{-# INLINE advance #-}
500−
501−ensureSuspended :: Int -> Buffer -> Pos -> More
502− -> Failure r
503− -> Success ByteString r
504− -> Result r
505−ensureSuspended n t pos more lose succ =
506− runParser (demandInput >> go) t pos more lose succ
507− where go = T.Parser $ \t' pos' more' lose' succ' ->
508− if lengthAtLeast pos' n t'
509− then succ' t' pos' more' (substring pos (Pos n) t')
510− else runParser (demandInput >> go) t' pos' more' lose' succ'
511−
512−-- | If at least @n@ elements of input are available, return the
513−-- current input, otherwise fail.
514−ensure :: Int -> Parser ByteString
515−ensure n = T.Parser $ \t pos more lose succ ->
516− if lengthAtLeast pos n t
517− then succ t pos more (substring pos (Pos n) t)
518− -- The uncommon case is kept out-of-line to reduce code size:
519− else ensureSuspended n t pos more lose succ
520−{-# INLINE ensure #-}
521−
522−-- | Return both the result of a parse and the portion of the input
523−-- that was consumed while it was being parsed.
524−match :: Parser a -> Parser (ByteString, a)
525−match p = T.Parser $ \t pos more lose succ ->
526− let succ' t' pos' more' a =
527− succ t' pos' more' (substring pos (pos'-pos) t', a)
528− in runParser p t pos more lose succ'
529−
530−lengthAtLeast :: Pos -> Int -> Buffer -> Bool
531−lengthAtLeast (Pos pos) n bs = Buf.length bs >= pos + n
532−{-# INLINE lengthAtLeast #-}
533−
534−substring :: Pos -> Pos -> Buffer -> ByteString
535−substring (Pos pos) (Pos n) = Buf.substring pos n
536−{-# INLINE substring #-}
Data/Attoparsec/ByteString/Lazy.hs+9−17
@@ -1,19 +1,14 @@
1−{-# LANGUAGE CPP #-}
2−#if __GLASGOW_HASKELL__ >= 702
3−{-# LANGUAGE Trustworthy #-} -- Imports internal modules
4−#endif
5−
6-- |
1-- |
7-- Module : Data.Attoparsec.ByteString.Lazy
2-- Module : Data.Attoparsec.ByteString.Lazy
8−-- Copyright : Bryan O'Sullivan 2007-2015
3+-- Copyright : Bryan O'Sullivan 2010, 2011
9-- License : BSD3
4-- License : BSD3
10--
5--
11-- Maintainer : bos@serpentine.com
6-- Maintainer : bos@serpentine.com
12-- Stability : experimental
7-- Stability : experimental
13-- Portability : unknown
8-- Portability : unknown
14--
9--
15−-- Simple, efficient combinator parsing that can consume lazy
10+-- Simple, efficient combinator parsing for lazy 'ByteString'
16−-- 'ByteString' strings, loosely based on the Parsec library.
11+-- strings, loosely based on the Parsec library.
17--
12--
18-- This is essentially the same code as in the 'Data.Attoparsec'
13-- This is essentially the same code as in the 'Data.Attoparsec'
19-- module, only with a 'parse' function that can consume a lazy
14-- module, only with a 'parse' function that can consume a lazy
@@ -21,11 +16,10 @@
21-- more input to be fed in. Think of this as suitable for use with a
16-- more input to be fed in. Think of this as suitable for use with a
22-- lazily read file, e.g. via 'L.readFile' or 'L.hGetContents'.
17-- lazily read file, e.g. via 'L.readFile' or 'L.hGetContents'.
23--
18--
24−-- /Note:/ The various parser functions and combinators such as
25−-- 'string' still expect /strict/ 'B.ByteString' parameters, and
26−-- return strict 'B.ByteString' results. Behind the scenes, strict
27−-- 'B.ByteString' values are still used internally to store parser
19+-- Behind the scenes, strict 'B.ByteString' values are still used
28−-- input and manipulate it efficiently.
20+-- internally to store parser input and manipulate it efficiently.
21+-- High-performance parsers such as 'string' still expect strict
22+-- 'B.ByteString' parameters.
29
23
30module Data.Attoparsec.ByteString.Lazy
24module Data.Attoparsec.ByteString.Lazy
31 (
25 (
@@ -41,7 +35,6 @@ module Data.Attoparsec.ByteString.Lazy
41
35
42import Control.DeepSeq (NFData(rnf))
36import Control.DeepSeq (NFData(rnf))
43import Data.ByteString.Lazy.Internal (ByteString(..), chunk)
37import Data.ByteString.Lazy.Internal (ByteString(..), chunk)
44−import Data.List (intercalate)
45import qualified Data.ByteString as B
38import qualified Data.ByteString as B
46import qualified Data.Attoparsec.ByteString as A
39import qualified Data.Attoparsec.ByteString as A
47import qualified Data.Attoparsec.Internal.Types as T
40import qualified Data.Attoparsec.Internal.Types as T
@@ -105,6 +98,5 @@ maybeResult _ = Nothing
105
98
106-- | Convert a 'Result' value to an 'Either' value.
99-- | Convert a 'Result' value to an 'Either' value.
107eitherResult :: Result r -> Either String r
100eitherResult :: Result r -> Either String r
108−eitherResult (Done _ r) = Right r
101+eitherResult (Done _ r) = Right r
109−eitherResult (Fail _ [] msg) = Left msg
102+eitherResult (Fail _ _ msg) = Left msg
110−eitherResult (Fail _ ctxs msg) = Left (intercalate " > " ctxs ++ ": " ++ msg)
Data/Attoparsec/Char8.hs+2−7
@@ -1,6 +1,6 @@
1-- |
1-- |
2-- Module : Data.Attoparsec.Char8
2-- Module : Data.Attoparsec.Char8
3−-- Copyright : Bryan O'Sullivan 2007-2015
3+-- Copyright : Bryan O'Sullivan 2007-2011
4-- License : BSD3
4-- License : BSD3
5--
5--
6-- Maintainer : bos@serpentine.com
6-- Maintainer : bos@serpentine.com
@@ -8,14 +8,9 @@
8-- Portability : unknown
8-- Portability : unknown
9--
9--
10-- Simple, efficient, character-oriented combinator parsing for
10-- Simple, efficient, character-oriented combinator parsing for
11−-- 'Data.ByteString.ByteString' strings, loosely based on the Parsec
11+-- 'ByteString' strings, loosely based on the Parsec library.
12−-- library.
13−--
14−-- This module is deprecated. Use "Data.Attoparsec.ByteString.Char8"
15−-- instead.
16
12
17module Data.Attoparsec.Char8
13module Data.Attoparsec.Char8
18− {-# DEPRECATED "This module will be removed in the next major release." #-}
19 (
14 (
20 module Data.Attoparsec.ByteString.Char8
15 module Data.Attoparsec.ByteString.Char8
21 ) where
16 ) where
Data/Attoparsec/Combinator.hs+44−72
@@ -1,10 +1,7 @@
1{-# LANGUAGE BangPatterns, CPP #-}
1{-# LANGUAGE BangPatterns, CPP #-}
2−#if __GLASGOW_HASKELL__ >= 702
3−{-# LANGUAGE Trustworthy #-} -- Imports internal modules
4−#endif
5-- |
2-- |
6-- Module : Data.Attoparsec.Combinator
3-- Module : Data.Attoparsec.Combinator
7−-- Copyright : Daan Leijen 1999-2001, Bryan O'Sullivan 2007-2015
4+-- Copyright : Daan Leijen 1999-2001, Bryan O'Sullivan 2009-2010
8-- License : BSD3
5-- License : BSD3
9--
6--
10-- Maintainer : bos@serpentine.com
7-- Maintainer : bos@serpentine.com
@@ -14,10 +11,7 @@
14-- Useful parser combinators, similar to those provided by Parsec.
11-- Useful parser combinators, similar to those provided by Parsec.
15module Data.Attoparsec.Combinator
12module Data.Attoparsec.Combinator
16 (
13 (
17− -- * Combinators
18− try
19− , (<?>)
20− , choice
14+ choice
21 , count
15 , count
22 , option
16 , option
23 , many'
17 , many'
@@ -32,54 +26,32 @@ module Data.Attoparsec.Combinator
32 , skipMany
26 , skipMany
33 , skipMany1
27 , skipMany1
34 , eitherP
28 , eitherP
35− , feed
36− , satisfyElem
37− , endOfInput
38− , atEnd
39− , lookAhead
40 ) where
29 ) where
41
30
42−#if !MIN_VERSION_base(4,8,0)
43−import Control.Applicative (Applicative(..), (<$>))
44−import Data.Monoid (Monoid(mappend))
45−#endif
46−import Control.Applicative (Alternative(..), empty, liftA2, many, (<|>))
31+import Control.Applicative (Alternative(..), Applicative(..), empty, liftA2,
32+ (<|>), (*>), (<$>))
47import Control.Monad (MonadPlus(..))
33import Control.Monad (MonadPlus(..))
34+#if !MIN_VERSION_base(4,2,0)
35+import Control.Applicative (many)
36+#endif
37+
38+#if __GLASGOW_HASKELL__ >= 700
48−import Data.Attoparsec.Internal.Types (Parser(..), IResult(..))
39+import Data.Attoparsec.Internal.Types (Parser)
49−import Data.Attoparsec.Internal (endOfInput, atEnd, satisfyElem)
40+import qualified Data.Attoparsec.Zepto as Z
50import Data.ByteString (ByteString)
41import Data.ByteString (ByteString)
51import Data.Text (Text)
42import Data.Text (Text)
52−import qualified Data.Attoparsec.Zepto as Z
43+#endif
53−import Prelude hiding (succ)
54−
55−-- | Attempt a parse, and if it fails, rewind the input so that no
56−-- input appears to have been consumed.
57−--
58−-- This combinator is provided for compatibility with Parsec.
59−-- attoparsec parsers always backtrack on failure.
60−try :: Parser i a -> Parser i a
61−try p = p
62−{-# INLINE try #-}
63−
64−-- | Name the parser, in case failure occurs.
65−(<?>) :: Parser i a
66− -> String -- ^ the name to use if parsing fails
67− -> Parser i a
68−p <?> msg0 = Parser $ \t pos more lose succ ->
69− let lose' t' pos' more' strs msg = lose t' pos' more' (msg0:strs) msg
70− in runParser p t pos more lose' succ
71−{-# INLINE (<?>) #-}
72−infix 0 <?>
73
44
74-- | @choice ps@ tries to apply the actions in the list @ps@ in order,
45-- | @choice ps@ tries to apply the actions in the list @ps@ in order,
75-- until one of them succeeds. Returns the value of the succeeding
46-- until one of them succeeds. Returns the value of the succeeding
76-- action.
47-- action.
77choice :: Alternative f => [f a] -> f a
48choice :: Alternative f => [f a] -> f a
78choice = foldr (<|>) empty
49choice = foldr (<|>) empty
50+#if __GLASGOW_HASKELL__ >= 700
79−{-# SPECIALIZE choice :: [Parser ByteString a]
51+{-# SPECIALIZE choice :: [Parser ByteString a] -> Parser ByteString a #-}
80− -> Parser ByteString a #-}
81{-# SPECIALIZE choice :: [Parser Text a] -> Parser Text a #-}
52{-# SPECIALIZE choice :: [Parser Text a] -> Parser Text a #-}
82{-# SPECIALIZE choice :: [Z.Parser a] -> Z.Parser a #-}
53{-# SPECIALIZE choice :: [Z.Parser a] -> Z.Parser a #-}
54+#endif
83
55
84-- | @option x p@ tries to apply action @p@. If @p@ fails without
56-- | @option x p@ tries to apply action @p@. If @p@ fails without
85-- consuming input, it returns the value @x@, otherwise the value
57-- consuming input, it returns the value @x@, otherwise the value
@@ -88,9 +60,11 @@ choice = foldr (<|>) empty
88-- > priority = option 0 (digitToInt <$> digit)
60-- > priority = option 0 (digitToInt <$> digit)
89option :: Alternative f => a -> f a -> f a
61option :: Alternative f => a -> f a -> f a
90option x p = p <|> pure x
62option x p = p <|> pure x
63+#if __GLASGOW_HASKELL__ >= 700
91{-# SPECIALIZE option :: a -> Parser ByteString a -> Parser ByteString a #-}
64{-# SPECIALIZE option :: a -> Parser ByteString a -> Parser ByteString a #-}
92{-# SPECIALIZE option :: a -> Parser Text a -> Parser Text a #-}
65{-# SPECIALIZE option :: a -> Parser Text a -> Parser Text a #-}
93{-# SPECIALIZE option :: a -> Z.Parser a -> Z.Parser a #-}
66{-# SPECIALIZE option :: a -> Z.Parser a -> Z.Parser a #-}
67+#endif
94
68
95-- | A version of 'liftM2' that is strict in the result of its first
69-- | A version of 'liftM2' that is strict in the result of its first
96-- action.
70-- action.
@@ -132,102 +106,115 @@ many1' p = liftM2' (:) p (many' p)
132-- | @sepBy p sep@ applies /zero/ or more occurrences of @p@, separated
106-- | @sepBy p sep@ applies /zero/ or more occurrences of @p@, separated
133-- by @sep@. Returns a list of the values returned by @p@.
107-- by @sep@. Returns a list of the values returned by @p@.
134--
108--
135−-- > commaSep p = p `sepBy` (char ',')
109+-- > commaSep p = p `sepBy` (symbol ",")
136sepBy :: Alternative f => f a -> f s -> f [a]
110sepBy :: Alternative f => f a -> f s -> f [a]
137sepBy p s = liftA2 (:) p ((s *> sepBy1 p s) <|> pure []) <|> pure []
111sepBy p s = liftA2 (:) p ((s *> sepBy1 p s) <|> pure []) <|> pure []
112+#if __GLASGOW_HASKELL__ >= 700
138{-# SPECIALIZE sepBy :: Parser ByteString a -> Parser ByteString s
113{-# SPECIALIZE sepBy :: Parser ByteString a -> Parser ByteString s
139 -> Parser ByteString [a] #-}
114 -> Parser ByteString [a] #-}
140{-# SPECIALIZE sepBy :: Parser Text a -> Parser Text s -> Parser Text [a] #-}
115{-# SPECIALIZE sepBy :: Parser Text a -> Parser Text s -> Parser Text [a] #-}
141{-# SPECIALIZE sepBy :: Z.Parser a -> Z.Parser s -> Z.Parser [a] #-}
116{-# SPECIALIZE sepBy :: Z.Parser a -> Z.Parser s -> Z.Parser [a] #-}
117+#endif
142
118
143-- | @sepBy' p sep@ applies /zero/ or more occurrences of @p@, separated
119-- | @sepBy' p sep@ applies /zero/ or more occurrences of @p@, separated
144-- by @sep@. Returns a list of the values returned by @p@. The value
120-- by @sep@. Returns a list of the values returned by @p@. The value
145-- returned by @p@ is forced to WHNF.
121-- returned by @p@ is forced to WHNF.
146--
122--
147−-- > commaSep p = p `sepBy'` (char ',')
123+-- > commaSep p = p `sepBy'` (symbol ",")
148sepBy' :: (MonadPlus m) => m a -> m s -> m [a]
124sepBy' :: (MonadPlus m) => m a -> m s -> m [a]
149sepBy' p s = scan `mplus` return []
125sepBy' p s = scan `mplus` return []
150 where scan = liftM2' (:) p ((s >> sepBy1' p s) `mplus` return [])
126 where scan = liftM2' (:) p ((s >> sepBy1' p s) `mplus` return [])
127+#if __GLASGOW_HASKELL__ >= 700
151{-# SPECIALIZE sepBy' :: Parser ByteString a -> Parser ByteString s
128{-# SPECIALIZE sepBy' :: Parser ByteString a -> Parser ByteString s
152 -> Parser ByteString [a] #-}
129 -> Parser ByteString [a] #-}
153{-# SPECIALIZE sepBy' :: Parser Text a -> Parser Text s -> Parser Text [a] #-}
130{-# SPECIALIZE sepBy' :: Parser Text a -> Parser Text s -> Parser Text [a] #-}
154{-# SPECIALIZE sepBy' :: Z.Parser a -> Z.Parser s -> Z.Parser [a] #-}
131{-# SPECIALIZE sepBy' :: Z.Parser a -> Z.Parser s -> Z.Parser [a] #-}
132+#endif
155
133
156-- | @sepBy1 p sep@ applies /one/ or more occurrences of @p@, separated
134-- | @sepBy1 p sep@ applies /one/ or more occurrences of @p@, separated
157-- by @sep@. Returns a list of the values returned by @p@.
135-- by @sep@. Returns a list of the values returned by @p@.
158--
136--
159−-- > commaSep p = p `sepBy1` (char ',')
137+-- > commaSep p = p `sepBy1` (symbol ",")
160sepBy1 :: Alternative f => f a -> f s -> f [a]
138sepBy1 :: Alternative f => f a -> f s -> f [a]
161sepBy1 p s = scan
139sepBy1 p s = scan
162 where scan = liftA2 (:) p ((s *> scan) <|> pure [])
140 where scan = liftA2 (:) p ((s *> scan) <|> pure [])
141+#if __GLASGOW_HASKELL__ >= 700
163{-# SPECIALIZE sepBy1 :: Parser ByteString a -> Parser ByteString s
142{-# SPECIALIZE sepBy1 :: Parser ByteString a -> Parser ByteString s
164 -> Parser ByteString [a] #-}
143 -> Parser ByteString [a] #-}
165{-# SPECIALIZE sepBy1 :: Parser Text a -> Parser Text s -> Parser Text [a] #-}
144{-# SPECIALIZE sepBy1 :: Parser Text a -> Parser Text s -> Parser Text [a] #-}
166{-# SPECIALIZE sepBy1 :: Z.Parser a -> Z.Parser s -> Z.Parser [a] #-}
145{-# SPECIALIZE sepBy1 :: Z.Parser a -> Z.Parser s -> Z.Parser [a] #-}
146+#endif
167
147
168-- | @sepBy1' p sep@ applies /one/ or more occurrences of @p@, separated
148-- | @sepBy1' p sep@ applies /one/ or more occurrences of @p@, separated
169-- by @sep@. Returns a list of the values returned by @p@. The value
149-- by @sep@. Returns a list of the values returned by @p@. The value
170-- returned by @p@ is forced to WHNF.
150-- returned by @p@ is forced to WHNF.
171--
151--
172−-- > commaSep p = p `sepBy1'` (char ',')
152+-- > commaSep p = p `sepBy1'` (symbol ",")
173sepBy1' :: (MonadPlus m) => m a -> m s -> m [a]
153sepBy1' :: (MonadPlus m) => m a -> m s -> m [a]
174sepBy1' p s = scan
154sepBy1' p s = scan
175 where scan = liftM2' (:) p ((s >> scan) `mplus` return [])
155 where scan = liftM2' (:) p ((s >> scan) `mplus` return [])
156+#if __GLASGOW_HASKELL__ >= 700
176{-# SPECIALIZE sepBy1' :: Parser ByteString a -> Parser ByteString s
157{-# SPECIALIZE sepBy1' :: Parser ByteString a -> Parser ByteString s
177 -> Parser ByteString [a] #-}
158 -> Parser ByteString [a] #-}
178{-# SPECIALIZE sepBy1' :: Parser Text a -> Parser Text s -> Parser Text [a] #-}
159{-# SPECIALIZE sepBy1' :: Parser Text a -> Parser Text s -> Parser Text [a] #-}
179{-# SPECIALIZE sepBy1' :: Z.Parser a -> Z.Parser s -> Z.Parser [a] #-}
160{-# SPECIALIZE sepBy1' :: Z.Parser a -> Z.Parser s -> Z.Parser [a] #-}
161+#endif
180
162
181-- | @manyTill p end@ applies action @p@ /zero/ or more times until
163-- | @manyTill p end@ applies action @p@ /zero/ or more times until
182-- action @end@ succeeds, and returns the list of values returned by
164-- action @end@ succeeds, and returns the list of values returned by
183-- @p@. This can be used to scan comments:
165-- @p@. This can be used to scan comments:
184--
166--
185−-- > simpleComment = string "<!--" *> manyTill anyChar (string "-->")
167+-- > simpleComment = string "<!--" *> manyTill anyChar (try (string "-->"))
186--
168--
187−-- (Note the overlapping parsers @anyChar@ and @string \"-->\"@.
169+-- Note the overlapping parsers @anyChar@ and @string \"<!--\"@, and
188−-- While this will work, it is not very efficient, as it will cause a
170+-- therefore the use of the 'try' combinator.
189−-- lot of backtracking.)
190manyTill :: Alternative f => f a -> f b -> f [a]
171manyTill :: Alternative f => f a -> f b -> f [a]
191manyTill p end = scan
172manyTill p end = scan
192 where scan = (end *> pure []) <|> liftA2 (:) p scan
173 where scan = (end *> pure []) <|> liftA2 (:) p scan
174+#if __GLASGOW_HASKELL__ >= 700
193{-# SPECIALIZE manyTill :: Parser ByteString a -> Parser ByteString b
175{-# SPECIALIZE manyTill :: Parser ByteString a -> Parser ByteString b
194 -> Parser ByteString [a] #-}
176 -> Parser ByteString [a] #-}
195{-# SPECIALIZE manyTill :: Parser Text a -> Parser Text b -> Parser Text [a] #-}
177{-# SPECIALIZE manyTill :: Parser Text a -> Parser Text b -> Parser Text [a] #-}
196{-# SPECIALIZE manyTill :: Z.Parser a -> Z.Parser b -> Z.Parser [a] #-}
178{-# SPECIALIZE manyTill :: Z.Parser a -> Z.Parser b -> Z.Parser [a] #-}
179+#endif
197
180
198-- | @manyTill' p end@ applies action @p@ /zero/ or more times until
181-- | @manyTill' p end@ applies action @p@ /zero/ or more times until
199-- action @end@ succeeds, and returns the list of values returned by
182-- action @end@ succeeds, and returns the list of values returned by
200-- @p@. This can be used to scan comments:
183-- @p@. This can be used to scan comments:
201--
184--
202−-- > simpleComment = string "<!--" *> manyTill' anyChar (string "-->")
185+-- > simpleComment = string "<!--" *> manyTill' anyChar (try (string "-->"))
203--
186--
204−-- (Note the overlapping parsers @anyChar@ and @string \"-->\"@.
187+-- Note the overlapping parsers @anyChar@ and @string \"<!--\"@, and
205−-- While this will work, it is not very efficient, as it will cause a
188+-- therefore the use of the 'try' combinator. The value returned by @p@
206−-- lot of backtracking.)
207−--
208−-- The value returned by @p@ is forced to WHNF.
189+-- is forced to WHNF.
209manyTill' :: (MonadPlus m) => m a -> m b -> m [a]
190manyTill' :: (MonadPlus m) => m a -> m b -> m [a]
210manyTill' p end = scan
191manyTill' p end = scan
211 where scan = (end >> return []) `mplus` liftM2' (:) p scan
192 where scan = (end >> return []) `mplus` liftM2' (:) p scan
193+#if __GLASGOW_HASKELL__ >= 700
212{-# SPECIALIZE manyTill' :: Parser ByteString a -> Parser ByteString b
194{-# SPECIALIZE manyTill' :: Parser ByteString a -> Parser ByteString b
213 -> Parser ByteString [a] #-}
195 -> Parser ByteString [a] #-}
214{-# SPECIALIZE manyTill' :: Parser Text a -> Parser Text b -> Parser Text [a] #-}
196{-# SPECIALIZE manyTill' :: Parser Text a -> Parser Text b -> Parser Text [a] #-}
215{-# SPECIALIZE manyTill' :: Z.Parser a -> Z.Parser b -> Z.Parser [a] #-}
197{-# SPECIALIZE manyTill' :: Z.Parser a -> Z.Parser b -> Z.Parser [a] #-}
198+#endif
216
199
217-- | Skip zero or more instances of an action.
200-- | Skip zero or more instances of an action.
218skipMany :: Alternative f => f a -> f ()
201skipMany :: Alternative f => f a -> f ()
219skipMany p = scan
202skipMany p = scan
220 where scan = (p *> scan) <|> pure ()
203 where scan = (p *> scan) <|> pure ()
204+#if __GLASGOW_HASKELL__ >= 700
221{-# SPECIALIZE skipMany :: Parser ByteString a -> Parser ByteString () #-}
205{-# SPECIALIZE skipMany :: Parser ByteString a -> Parser ByteString () #-}
222{-# SPECIALIZE skipMany :: Parser Text a -> Parser Text () #-}
206{-# SPECIALIZE skipMany :: Parser Text a -> Parser Text () #-}
223{-# SPECIALIZE skipMany :: Z.Parser a -> Z.Parser () #-}
207{-# SPECIALIZE skipMany :: Z.Parser a -> Z.Parser () #-}
208+#endif
224
209
225-- | Skip one or more instances of an action.
210-- | Skip one or more instances of an action.
226skipMany1 :: Alternative f => f a -> f ()
211skipMany1 :: Alternative f => f a -> f ()
227skipMany1 p = p *> skipMany p
212skipMany1 p = p *> skipMany p
213+#if __GLASGOW_HASKELL__ >= 700
228{-# SPECIALIZE skipMany1 :: Parser ByteString a -> Parser ByteString () #-}
214{-# SPECIALIZE skipMany1 :: Parser ByteString a -> Parser ByteString () #-}
229{-# SPECIALIZE skipMany1 :: Parser Text a -> Parser Text () #-}
215{-# SPECIALIZE skipMany1 :: Parser Text a -> Parser Text () #-}
230{-# SPECIALIZE skipMany1 :: Z.Parser a -> Z.Parser () #-}
216{-# SPECIALIZE skipMany1 :: Z.Parser a -> Z.Parser () #-}
217+#endif
231
218
232-- | Apply the given action repeatedly, returning every result.
219-- | Apply the given action repeatedly, returning every result.
233count :: Monad m => Int -> m a -> m [a]
220count :: Monad m => Int -> m a -> m [a]
@@ -238,18 +225,3 @@ count n p = sequence (replicate n p)
238eitherP :: (Alternative f) => f a -> f b -> f (Either a b)
225eitherP :: (Alternative f) => f a -> f b -> f (Either a b)
239eitherP a b = (Left <$> a) <|> (Right <$> b)
226eitherP a b = (Left <$> a) <|> (Right <$> b)
240{-# INLINE eitherP #-}
227{-# INLINE eitherP #-}
241−
242−-- | If a parser has returned a 'T.Partial' result, supply it with more
243−-- input.
244−feed :: Monoid i => IResult i r -> i -> IResult i r
245−feed (Fail t ctxs msg) d = Fail (mappend t d) ctxs msg
246−feed (Partial k) d = k d
247−feed (Done t r) d = Done (mappend t d) r
248−{-# INLINE feed #-}
249−
250−-- | Apply a parser without consuming any input.
251−lookAhead :: Parser i a -> Parser i a
252−lookAhead p = Parser $ \t pos more lose succ ->
253− let succ' t' _pos' more' = succ t' pos more'
254− in runParser p t pos more lose succ'
255−{-# INLINE lookAhead #-}
Data/Attoparsec/Internal.hs+9−149
@@ -1,7 +1,6 @@
1−{-# LANGUAGE BangPatterns, CPP, ScopedTypeVariables #-}
2-- |
1-- |
3-- Module : Data.Attoparsec.Internal
2-- Module : Data.Attoparsec.Internal
4−-- Copyright : Bryan O'Sullivan 2007-2015
3+-- Copyright : Bryan O'Sullivan 2012
5-- License : BSD3
4-- License : BSD3
6--
5--
7-- Maintainer : bos@serpentine.com
6-- Maintainer : bos@serpentine.com
@@ -12,160 +11,21 @@
12-- library.
11-- library.
13
12
14module Data.Attoparsec.Internal
13module Data.Attoparsec.Internal
14+ (
15− ( compareResults
15+ compareResults
16− , prompt
17− , demandInput
18− , demandInput_
19− , wantInput
20− , endOfInput
21− , atEnd
22− , satisfyElem
23− , concatReverse
24 ) where
16 ) where
25
17
26−#if !MIN_VERSION_base(4,8,0)
27−import Control.Applicative ((<$>))
28−import Data.Monoid (Monoid, mconcat)
29−#endif
30−import Data.Attoparsec.Internal.Types
18+import Data.Attoparsec.Internal.Types (IResult(..))
31−import Data.ByteString (ByteString)
32−import Data.Text (Text)
33−import Prelude hiding (succ)
34
19
35-- | Compare two 'IResult' values for equality.
20-- | Compare two 'IResult' values for equality.
36--
21--
37-- If both 'IResult's are 'Partial', the result will be 'Nothing', as
22-- If both 'IResult's are 'Partial', the result will be 'Nothing', as
38-- they are incomplete and hence their equality cannot be known.
23-- they are incomplete and hence their equality cannot be known.
39-- (This is why there is no 'Eq' instance for 'IResult'.)
24-- (This is why there is no 'Eq' instance for 'IResult'.)
40−compareResults :: (Eq i, Eq r) => IResult i r -> IResult i r -> Maybe Bool
25+compareResults :: (Eq t, Eq r) => IResult t r -> IResult t r -> Maybe Bool
41−compareResults (Fail t0 ctxs0 msg0) (Fail t1 ctxs1 msg1) =
26+compareResults (Fail i0 ctxs0 msg0) (Fail i1 ctxs1 msg1) =
42− Just (t0 == t1 && ctxs0 == ctxs1 && msg0 == msg1)
27+ Just (i0 == i1 && ctxs0 == ctxs1 && msg0 == msg1)
43−compareResults (Done t0 r0) (Done t1 r1) =
28+compareResults (Done i0 r0) (Done i1 r1) =
44− Just (t0 == t1 && r0 == r1)
29+ Just (i0 == i1 && r0 == r1)
45compareResults (Partial _) (Partial _) = Nothing
30compareResults (Partial _) (Partial _) = Nothing
46compareResults _ _ = Just False
31compareResults _ _ = Just False
47−
48−-- | Ask for input. If we receive any, pass the augmented input to a
49−-- success continuation, otherwise to a failure continuation.
50−prompt :: Chunk t
51− => State t -> Pos -> More
52− -> (State t -> Pos -> More -> IResult t r)
53− -> (State t -> Pos -> More -> IResult t r)
54− -> IResult t r
55−prompt t pos _more lose succ = Partial $ \s ->
56− if nullChunk s
57− then lose t pos Complete
58− else succ (pappendChunk t s) pos Incomplete
59−{-# SPECIALIZE prompt :: State ByteString -> Pos -> More
60− -> (State ByteString -> Pos -> More
61− -> IResult ByteString r)
62− -> (State ByteString -> Pos -> More
63− -> IResult ByteString r)
64− -> IResult ByteString r #-}
65−{-# SPECIALIZE prompt :: State Text -> Pos -> More
66− -> (State Text -> Pos -> More -> IResult Text r)
67− -> (State Text -> Pos -> More -> IResult Text r)
68− -> IResult Text r #-}
69−
70−-- | Immediately demand more input via a 'Partial' continuation
71−-- result.
72−demandInput :: Chunk t => Parser t ()
73−demandInput = Parser $ \t pos more lose succ ->
74− case more of
75− Complete -> lose t pos more [] "not enough input"
76− _ -> let lose' _ pos' more' = lose t pos' more' [] "not enough input"
77− succ' t' pos' more' = succ t' pos' more' ()
78− in prompt t pos more lose' succ'
79−{-# SPECIALIZE demandInput :: Parser ByteString () #-}
80−{-# SPECIALIZE demandInput :: Parser Text () #-}
81−
82−-- | Immediately demand more input via a 'Partial' continuation
83−-- result. Return the new input.
84−demandInput_ :: Chunk t => Parser t t
85−demandInput_ = Parser $ \t pos more lose succ ->
86− case more of
87− Complete -> lose t pos more [] "not enough input"
88− _ -> Partial $ \s ->
89− if nullChunk s
90− then lose t pos Complete [] "not enough input"
91− else succ (pappendChunk t s) pos more s
92−{-# SPECIALIZE demandInput_ :: Parser ByteString ByteString #-}
93−{-# SPECIALIZE demandInput_ :: Parser Text Text #-}
94−
95−-- | This parser always succeeds. It returns 'True' if any input is
96−-- available either immediately or on demand, and 'False' if the end
97−-- of all input has been reached.
98−wantInput :: forall t . Chunk t => Parser t Bool
99−wantInput = Parser $ \t pos more _lose succ ->
100− case () of
101− _ | pos < atBufferEnd (undefined :: t) t -> succ t pos more True
102− | more == Complete -> succ t pos more False
103− | otherwise -> let lose' t' pos' more' = succ t' pos' more' False
104− succ' t' pos' more' = succ t' pos' more' True
105− in prompt t pos more lose' succ'
106−{-# INLINE wantInput #-}
107−
108−-- | Match only if all input has been consumed.
109−endOfInput :: forall t . Chunk t => Parser t ()
110−endOfInput = Parser $ \t pos more lose succ ->
111− case () of
112− _| pos < atBufferEnd (undefined :: t) t -> lose t pos more [] "endOfInput"
113− | more == Complete -> succ t pos more ()
114− | otherwise ->
115− let lose' t' pos' more' _ctx _msg = succ t' pos' more' ()
116− succ' t' pos' more' _a = lose t' pos' more' [] "endOfInput"
117− in runParser demandInput t pos more lose' succ'
118−{-# SPECIALIZE endOfInput :: Parser ByteString () #-}
119−{-# SPECIALIZE endOfInput :: Parser Text () #-}
120−
121−-- | Return an indication of whether the end of input has been
122−-- reached.
123−atEnd :: Chunk t => Parser t Bool
124−atEnd = not <$> wantInput
125−{-# INLINE atEnd #-}
126−
127−satisfySuspended :: forall t r . Chunk t
128− => (ChunkElem t -> Bool)
129− -> State t -> Pos -> More
130− -> Failure t (State t) r
131− -> Success t (State t) (ChunkElem t) r
132− -> IResult t r
133−satisfySuspended p t pos more lose succ =
134− runParser (demandInput >> go) t pos more lose succ
135− where go = Parser $ \t' pos' more' lose' succ' ->
136− case bufferElemAt (undefined :: t) pos' t' of
137− Just (e, l) | p e -> succ' t' (pos' + Pos l) more' e
138− | otherwise -> lose' t' pos' more' [] "satisfyElem"
139− Nothing -> runParser (demandInput >> go) t' pos' more' lose' succ'
140−{-# SPECIALIZE satisfySuspended :: (ChunkElem ByteString -> Bool)
141− -> State ByteString -> Pos -> More
142− -> Failure ByteString (State ByteString) r
143− -> Success ByteString (State ByteString)
144− (ChunkElem ByteString) r
145− -> IResult ByteString r #-}
146−{-# SPECIALIZE satisfySuspended :: (ChunkElem Text -> Bool)
147− -> State Text -> Pos -> More
148− -> Failure Text (State Text) r
149− -> Success Text (State Text)
150− (ChunkElem Text) r
151− -> IResult Text r #-}
152−
153−-- | The parser @satisfyElem p@ succeeds for any chunk element for which the
154−-- predicate @p@ returns 'True'. Returns the element that is
155−-- actually parsed.
156−satisfyElem :: forall t . Chunk t
157− => (ChunkElem t -> Bool) -> Parser t (ChunkElem t)
158−satisfyElem p = Parser $ \t pos more lose succ ->
159− case bufferElemAt (undefined :: t) pos t of
160− Just (e, l) | p e -> succ t (pos + Pos l) more e
161− | otherwise -> lose t pos more [] "satisfyElem"
162− Nothing -> satisfySuspended p t pos more lose succ
163−{-# INLINE satisfyElem #-}
164−
165−-- | Concatenate a monoid after reversing its elements. Used to
166−-- glue together a series of textual chunks that have been accumulated
167−-- \"backwards\".
168−concatReverse :: Monoid m => [m] -> m
169−concatReverse [x] = x
170−concatReverse xs = mconcat (reverse xs)
171−{-# INLINE concatReverse #-}
Data/Attoparsec/Internal/Fhthagn.hsdeleted−18
@@ -1,18 +0,0 @@
1−{-# LANGUAGE BangPatterns, Rank2Types, OverloadedStrings,
2− RecordWildCards, MagicHash, UnboxedTuples #-}
3−
4−module Data.Attoparsec.Internal.Fhthagn
5− (
6− inlinePerformIO
7− ) where
8−
9−import GHC.Base (realWorld#)
10−import GHC.IO (IO(IO))
11−
12−-- | Just like unsafePerformIO, but we inline it. Big performance gains as
13−-- it exposes lots of things to further inlining. /Very unsafe/. In
14−-- particular, you should do no memory allocation inside an
15−-- 'inlinePerformIO' block. On Hugs this is just @unsafePerformIO@.
16−inlinePerformIO :: IO a -> a
17−inlinePerformIO (IO m) = case m realWorld# of (# _, r #) -> r
18−{-# INLINE inlinePerformIO #-}
Data/Attoparsec/Internal/Types.hs+136−175
@@ -1,8 +1,8 @@
1−{-# LANGUAGE CPP, BangPatterns, GeneralizedNewtypeDeriving, OverloadedStrings,
1+{-# LANGUAGE BangPatterns, CPP, GeneralizedNewtypeDeriving, OverloadedStrings,
2− Rank2Types, RecordWildCards, TypeFamilies #-}
2+ Rank2Types, RecordWildCards #-}
3-- |
3-- |
4-- Module : Data.Attoparsec.Internal.Types
4-- Module : Data.Attoparsec.Internal.Types
5−-- Copyright : Bryan O'Sullivan 2007-2015
5+-- Copyright : Bryan O'Sullivan 2007-2011
6-- License : BSD3
6-- License : BSD3
7--
7--
8-- Maintainer : bos@serpentine.com
8-- Maintainer : bos@serpentine.com
@@ -15,82 +15,69 @@
15module Data.Attoparsec.Internal.Types
15module Data.Attoparsec.Internal.Types
16 (
16 (
17 Parser(..)
17 Parser(..)
18− , State
19 , Failure
18 , Failure
20 , Success
19 , Success
21− , Pos(..)
22 , IResult(..)
20 , IResult(..)
21+ , Input(..)
22+ , Added(..)
23 , More(..)
23 , More(..)
24+ , addS
24 , (<>)
25 , (<>)
25− , Chunk(..)
26 ) where
26 ) where
27
27
28−import Control.Applicative as App (Applicative(..), (<$>))
28+import Control.Applicative (Alternative(..), Applicative(..), (<$>))
29−import Control.Applicative (Alternative(..))
30import Control.DeepSeq (NFData(rnf))
29import Control.DeepSeq (NFData(rnf))
31import Control.Monad (MonadPlus(..))
30import Control.Monad (MonadPlus(..))
32−import qualified Control.Monad.Fail as Fail (MonadFail(..))
33−import Data.Monoid as Mon (Monoid(..))
31+import Data.Monoid (Monoid(..))
34−import Data.Semigroup (Semigroup(..))
35−import Data.Word (Word8)
36−import Data.ByteString (ByteString)
37−import qualified Data.ByteString as BS
38−import Data.ByteString.Internal (w2c)
39−import Data.Text (Text)
40−import qualified Data.Text as Text
41−import Data.Text.Unsafe (Iter(..))
42−import Prelude hiding (succ)
32+import Prelude hiding (getChar, take, takeWhile)
43−import qualified Data.Attoparsec.ByteString.Buffer as B
44−import qualified Data.Attoparsec.Text.Buffer as T
45
33
46−newtype Pos = Pos { fromPos :: Int }
47− deriving (Eq, Ord, Show, Num)
48−
49−-- | The result of a parse. This is parameterised over the type @i@
34+-- | The result of a parse. This is parameterised over the type @t@
50-- of string that was processed.
35-- of string that was processed.
51--
36--
52-- This type is an instance of 'Functor', where 'fmap' transforms the
37-- This type is an instance of 'Functor', where 'fmap' transforms the
53-- value in a 'Done' result.
38-- value in a 'Done' result.
54−data IResult i r =
55− Fail i [String] String
39+data IResult t r = Fail t [String] String
56− -- ^ The parse failed. The @i@ parameter is the input that had
40+ -- ^ The parse failed. The 't' parameter is the
57− -- not yet been consumed when the failure occurred. The
41+ -- input that had not yet been consumed when the
42+ -- failure occurred. The @[@'String'@]@ is a list of
58− -- @[@'String'@]@ is a list of contexts in which the error
43+ -- contexts in which the error occurred. The
59− -- occurred. The 'String' is the message describing the error, if
44+ -- 'String' is the message describing the error, if
60− -- any.
45+ -- any.
61− | Partial (i -> IResult i r)
46+ | Partial (t -> IResult t r)
62− -- ^ Supply this continuation with more input so that the parser
47+ -- ^ Supply this continuation with more input so that
63− -- can resume. To indicate that no more input is available, pass
48+ -- the parser can resume. To indicate that no more
64− -- an empty string to the continuation.
49+ -- input is available, use an empty string.
65− --
66− -- __Note__: if you get a 'Partial' result, do not call its
67− -- continuation more than once.
68− | Done i r
50+ | Done t r
69− -- ^ The parse succeeded. The @i@ parameter is the input that had
51+ -- ^ The parse succeeded. The 't' parameter is the
70− -- not yet been consumed (if any) when the parse succeeded.
52+ -- input that had not yet been consumed (if any) when
71−
53+ -- the parse succeeded.
54+
72−instance (Show i, Show r) => Show (IResult i r) where
55+instance (Show t, Show r) => Show (IResult t r) where
73− showsPrec d ir = showParen (d > 10) $
56+ show (Fail t stk msg) =
74− case ir of
57+ "Fail " ++ show t ++ " " ++ show stk ++ " " ++ show msg
75− (Fail t stk msg) -> showString "Fail" . f t . f stk . f msg
76− (Partial _) -> showString "Partial _"
58+ show (Partial _) = "Partial _"
77− (Done t r) -> showString "Done" . f t . f r
59+ show (Done t r) = "Done " ++ show t ++ " " ++ show r
78− where f :: Show a => a -> ShowS
60+
79− f x = showChar ' ' . showsPrec 11 x
80−
81−instance (NFData i, NFData r) => NFData (IResult i r) where
61+instance (NFData t, NFData r) => NFData (IResult t r) where
82 rnf (Fail t stk msg) = rnf t `seq` rnf stk `seq` rnf msg
62 rnf (Fail t stk msg) = rnf t `seq` rnf stk `seq` rnf msg
83 rnf (Partial _) = ()
63 rnf (Partial _) = ()
84 rnf (Done t r) = rnf t `seq` rnf r
64 rnf (Done t r) = rnf t `seq` rnf r
85 {-# INLINE rnf #-}
65 {-# INLINE rnf #-}
86
66
87−instance Functor (IResult i) where
67+fmapR :: (a -> b) -> IResult t a -> IResult t b
88− fmap _ (Fail t stk msg) = Fail t stk msg
68+fmapR _ (Fail t stk msg) = Fail t stk msg
89− fmap f (Partial k) = Partial (fmap f . k)
69+fmapR f (Partial k) = Partial (fmapR f . k)
90− fmap f (Done t r) = Done t (f r)
70+fmapR f (Done t r) = Done t (f r)
91
71
72+instance Functor (IResult t) where
73+ fmap = fmapR
74+ {-# INLINE fmap #-}
75+
76+newtype Input t = I {unI :: t} deriving (Monoid)
77+newtype Added t = A {unA :: t} deriving (Monoid)
78+
92−-- | The core parser type. This is parameterised over the type @i@
79+-- | The core parser type. This is parameterised over the type @t@ of
93−-- of string being processed.
80+-- string being processed.
94--
81--
95-- This type is an instance of the following classes:
82-- This type is an instance of the following classes:
96--
83--
@@ -103,115 +90,124 @@ instance Functor (IResult i) where
103-- 'mplus' executes the right-hand parser if the left-hand one
90-- 'mplus' executes the right-hand parser if the left-hand one
104-- fails. When the parser on the right executes, the input is reset
91-- fails. When the parser on the right executes, the input is reset
105-- to the same state as the parser on the left started with. (In
92-- to the same state as the parser on the left started with. (In
106−-- other words, attoparsec is a backtracking parser that supports
93+-- other words, Attoparsec is a backtracking parser that supports
107-- arbitrary lookahead.)
94-- arbitrary lookahead.)
108--
95--
109-- * 'Alternative', which follows 'MonadPlus'.
96-- * 'Alternative', which follows 'MonadPlus'.
110−newtype Parser i a = Parser {
97+newtype Parser t a = Parser {
111− runParser :: forall r.
98+ runParser :: forall r. Input t -> Added t -> More
112− State i -> Pos -> More
113− -> Failure i (State i) r
99+ -> Failure t r
114− -> Success i (State i) a r
100+ -> Success t a r
115− -> IResult i r
101+ -> IResult t r
116 }
102 }
117
103
118−type family State i
119−type instance State ByteString = B.Buffer
120−type instance State Text = T.Buffer
121−
122−type Failure i t r = t -> Pos -> More -> [String] -> String
104+type Failure t r = Input t -> Added t -> More -> [String] -> String
123− -> IResult i r
105+ -> IResult t r
124−type Success i t a r = t -> Pos -> More -> a -> IResult i r
106+type Success t a r = Input t -> Added t -> More -> a -> IResult t r
125
107
126-- | Have we read all available input?
108-- | Have we read all available input?
127data More = Complete | Incomplete
109data More = Complete | Incomplete
128 deriving (Eq, Show)
110 deriving (Eq, Show)
129
111
130−instance Semigroup More where
112+instance Monoid More where
131− c@Complete <> _ = c
113+ mappend c@Complete _ = c
132− _ <> m = m
114+ mappend _ m = m
133−
134−instance Mon.Monoid More where
135− mappend = (<>)
136− mempty = Incomplete
115+ mempty = Incomplete
137−
116+
117+addS :: (Monoid t) =>
118+ Input t -> Added t -> More
119+ -> Input t -> Added t -> More
120+ -> (Input t -> Added t -> More -> r) -> r
121+addS i0 a0 m0 _i1 a1 m1 f =
122+ let !i = i0 <> I (unA a1)
123+ a = a0 <> a1
124+ !m = m0 <> m1
125+ in f i a m
126+{-# INLINE addS #-}
127+
128+bindP :: Parser t a -> (a -> Parser t b) -> Parser t b
129+bindP m g =
130+ Parser $ \i0 a0 m0 kf ks -> runParser m i0 a0 m0 kf $
131+ \i1 a1 m1 a -> runParser (g a) i1 a1 m1 kf ks
132+{-# INLINE bindP #-}
133+
134+returnP :: a -> Parser t a
135+returnP a = Parser (\i0 a0 m0 _kf ks -> ks i0 a0 m0 a)
136+{-# INLINE returnP #-}
137+
138−instance Monad (Parser i) where
138+instance Monad (Parser t) where
139−#if !(MIN_VERSION_base(4,13,0))
139+ return = returnP
140− fail = Fail.fail
140+ (>>=) = bindP
141− {-# INLINE fail #-}
141+ fail = failDesc
142−#endif
142+
143−
143+noAdds :: (Monoid t) =>
144− return = App.pure
144+ Input t -> Added t -> More
145− {-# INLINE return #-}
145+ -> (Input t -> Added t -> More -> r) -> r
146−
146+noAdds i0 _a0 m0 f = f i0 mempty m0
147− m >>= k = Parser $ \t !pos more lose succ ->
148− let succ' t' !pos' more' a = runParser (k a) t' pos' more' lose succ
149− in runParser m t pos more lose succ'
150− {-# INLINE (>>=) #-}
147+{-# INLINE noAdds #-}
151−
148+
152− (>>) = (*>)
149+plus :: (Monoid t) => Parser t a -> Parser t a -> Parser t a
153− {-# INLINE (>>) #-}
150+plus a b = Parser $ \i0 a0 m0 kf ks ->
154−
151+ let kf' i1 a1 m1 _ _ = addS i0 a0 m0 i1 a1 m1 $
155−
152+ \ i2 a2 m2 -> runParser b i2 a2 m2 kf ks
156−instance Fail.MonadFail (Parser i) where
153+ ks' i1 a1 m1 = ks i1 (a0 <> a1) m1
157− fail err = Parser $ \t pos more lose _succ -> lose t pos more [] msg
154+ in noAdds i0 a0 m0 $ \i2 a2 m2 -> runParser a i2 a2 m2 kf' ks'
158− where msg = "Failed reading: " ++ err
155+{-# INLINE plus #-}
159− {-# INLINE fail #-}
156+
160−
161−plus :: Parser i a -> Parser i a -> Parser i a
162−plus f g = Parser $ \t pos more lose succ ->
163− let lose' t' _pos' more' _ctx _msg = runParser g t' pos more' lose succ
164− in runParser f t pos more lose' succ
165−
166−instance MonadPlus (Parser i) where
157+instance (Monoid t) => MonadPlus (Parser t) where
167− mzero = fail "mzero"
158+ mzero = failDesc "mzero"
168 {-# INLINE mzero #-}
159 {-# INLINE mzero #-}
169 mplus = plus
160 mplus = plus
170
161
162+fmapP :: (a -> b) -> Parser t a -> Parser t b
163+fmapP p m = Parser $ \i0 a0 m0 f k ->
164+ runParser m i0 a0 m0 f $ \i1 a1 s1 a -> k i1 a1 s1 (p a)
165+{-# INLINE fmapP #-}
166+
171−instance Functor (Parser i) where
167+instance Functor (Parser t) where
172− fmap f p = Parser $ \t pos more lose succ ->
168+ fmap = fmapP
173− let succ' t' pos' more' a = succ t' pos' more' (f a)
174− in runParser p t pos more lose succ'
175 {-# INLINE fmap #-}
169 {-# INLINE fmap #-}
176
170
177−apP :: Parser i (a -> b) -> Parser i a -> Parser i b
171+apP :: Parser t (a -> b) -> Parser t a -> Parser t b
178apP d e = do
172apP d e = do
179 b <- d
173 b <- d
180 a <- e
174 a <- e
181 return (b a)
175 return (b a)
182{-# INLINE apP #-}
176{-# INLINE apP #-}
183
177
184−instance Applicative (Parser i) where
178+instance Applicative (Parser t) where
185− pure v = Parser $ \t !pos more _lose succ -> succ t pos more v
179+ pure = returnP
186 {-# INLINE pure #-}
180 {-# INLINE pure #-}
187 (<*>) = apP
181 (<*>) = apP
188 {-# INLINE (<*>) #-}
182 {-# INLINE (<*>) #-}
189− m *> k = m >>= \_ -> k
183+
184+#if MIN_VERSION_base(4,2,0)
185+ -- These definitions are equal to the defaults, but this
186+ -- way the optimizer doesn't have to work so hard to figure
187+ -- that out.
188+ (*>) = (>>)
190 {-# INLINE (*>) #-}
189 {-# INLINE (*>) #-}
191− x <* y = x >>= \a -> y >> pure a
190+ x <* y = x >>= \a -> y >> return a
192 {-# INLINE (<*) #-}
191 {-# INLINE (<*) #-}
192+#endif
193
193
194−instance Semigroup (Parser i a) where
195− (<>) = plus
196− {-# INLINE (<>) #-}
197−
198−instance Monoid (Parser i a) where
194+instance (Monoid t) => Monoid (Parser t a) where
199− mempty = fail "mempty"
195+ mempty = failDesc "mempty"
200 {-# INLINE mempty #-}
196 {-# INLINE mempty #-}
201− mappend = (<>)
197+ mappend = plus
202 {-# INLINE mappend #-}
198 {-# INLINE mappend #-}
203
199
204−instance Alternative (Parser i) where
200+instance (Monoid t) => Alternative (Parser t) where
205− empty = fail "empty"
201+ empty = failDesc "empty"
206 {-# INLINE empty #-}
202 {-# INLINE empty #-}
207
203
208 (<|>) = plus
204 (<|>) = plus
209 {-# INLINE (<|>) #-}
205 {-# INLINE (<|>) #-}
210
206
207+#if MIN_VERSION_base(4,2,0)
211 many v = many_v
208 many v = many_v
212− where
213− many_v = some_v <|> pure []
209+ where many_v = some_v <|> pure []
214− some_v = (:) <$> v <*> many_v
210+ some_v = (:) <$> v <*> many_v
215 {-# INLINE many #-}
211 {-# INLINE many #-}
216
212
217 some v = some_v
213 some v = some_v
@@ -219,48 +215,13 @@ instance Alternative (Parser i) where
219 many_v = some_v <|> pure []
215 many_v = some_v <|> pure []
220 some_v = (:) <$> v <*> many_v
216 some_v = (:) <$> v <*> many_v
221 {-# INLINE some #-}
217 {-# INLINE some #-}
218+#endif
222
219
223−-- | A common interface for input chunks.
220+failDesc :: String -> Parser t a
224−class Monoid c => Chunk c where
221+failDesc err = Parser (\i0 a0 m0 kf _ks -> kf i0 a0 m0 [] msg)
225− type ChunkElem c
222+ where msg = "Failed reading: " ++ err
226− -- | Test if the chunk is empty.
223+{-# INLINE failDesc #-}
227− nullChunk :: c -> Bool
228− -- | Append chunk to a buffer.
229− pappendChunk :: State c -> c -> State c
230− -- | Position at the end of a buffer. The first argument is ignored.
231− atBufferEnd :: c -> State c -> Pos
232− -- | Return the buffer element at the given position along with its length.
233− bufferElemAt :: c -> Pos -> State c -> Maybe (ChunkElem c, Int)
234− -- | Map an element to the corresponding character.
235− -- The first argument is ignored.
236− chunkElemToChar :: c -> ChunkElem c -> Char
237−
238−instance Chunk ByteString where
239− type ChunkElem ByteString = Word8
240− nullChunk = BS.null
241− {-# INLINE nullChunk #-}
242− pappendChunk = B.pappend
243− {-# INLINE pappendChunk #-}
244− atBufferEnd _ = Pos . B.length
245− {-# INLINE atBufferEnd #-}
246− bufferElemAt _ (Pos i) buf
247− | i < B.length buf = Just (B.unsafeIndex buf i, 1)
248− | otherwise = Nothing
249− {-# INLINE bufferElemAt #-}
250− chunkElemToChar _ = w2c
251− {-# INLINE chunkElemToChar #-}
252
224
253−instance Chunk Text where
225+(<>) :: (Monoid m) => m -> m -> m
254− type ChunkElem Text = Char
226+(<>) = mappend
255− nullChunk = Text.null
256− {-# INLINE nullChunk #-}
257− pappendChunk = T.pappend
258− {-# INLINE pappendChunk #-}
259− atBufferEnd _ = Pos . T.length
260− {-# INLINE atBufferEnd #-}
261− bufferElemAt _ (Pos i) buf
262− | i < T.length buf = let Iter c l = T.iter buf i in Just (c, l)
263− | otherwise = Nothing
264− {-# INLINE bufferElemAt #-}
265− chunkElemToChar _ = id
266− {-# INLINE chunkElemToChar #-}
227+{-# INLINE (<>) #-}
Data/Attoparsec/Lazy.hs+1−1
@@ -1,6 +1,6 @@
1-- |
1-- |
2-- Module : Data.Attoparsec.Lazy
2-- Module : Data.Attoparsec.Lazy
3−-- Copyright : Bryan O'Sullivan 2007-2015
3+-- Copyright : Bryan O'Sullivan 2010
4-- License : BSD3
4-- License : BSD3
5--
5--
6-- Maintainer : bos@serpentine.com
6-- Maintainer : bos@serpentine.com
Data/Attoparsec/Number.hs+2−15
@@ -1,25 +1,16 @@
1{-# LANGUAGE DeriveDataTypeable #-}
1{-# LANGUAGE DeriveDataTypeable #-}
2-- |
2-- |
3-- Module : Data.Attoparsec.Number
3-- Module : Data.Attoparsec.Number
4−-- Copyright : Bryan O'Sullivan 2007-2015
4+-- Copyright : Bryan O'Sullivan 2011
5-- License : BSD3
5-- License : BSD3
6--
6--
7-- Maintainer : bos@serpentine.com
7-- Maintainer : bos@serpentine.com
8-- Stability : experimental
8-- Stability : experimental
9-- Portability : unknown
9-- Portability : unknown
10--
10--
11−-- This module is deprecated, and both the module and 'Number' type
12−-- will be removed in the next major release. Use the
13−-- <http://hackage.haskell.org/package/scientific scientific> package
14−-- and the 'Data.Scientific.Scientific' type instead.
15−--
16-- A simple number type, useful for parsing both exact and inexact
11-- A simple number type, useful for parsing both exact and inexact
17-- quantities without losing much precision.
12-- quantities without losing much precision.
18−module Data.Attoparsec.Number
13+module Data.Attoparsec.Number ( Number(..) ) where
19− {-# DEPRECATED "This module will be removed in the next major release." #-}
20− (
21− Number(..)
22− ) where
23
14
24import Control.DeepSeq (NFData(rnf))
15import Control.DeepSeq (NFData(rnf))
25import Data.Data (Data)
16import Data.Data (Data)
@@ -28,13 +19,9 @@ import Data.Typeable (Typeable)
28
19
29-- | A numeric type that can represent integers accurately, and
20-- | A numeric type that can represent integers accurately, and
30-- floating point numbers to the precision of a 'Double'.
21-- floating point numbers to the precision of a 'Double'.
31−--
32−-- /Note/: this type is deprecated, and will be removed in the next
33−-- major release. Use the 'Data.Scientific.Scientific' type instead.
34data Number = I !Integer
22data Number = I !Integer
35 | D {-# UNPACK #-} !Double
23 | D {-# UNPACK #-} !Double
36 deriving (Typeable, Data)
24 deriving (Typeable, Data)
37−{-# DEPRECATED Number "Use Scientific instead." #-}
38
25
39instance Show Number where
26instance Show Number where
40 show (I a) = show a
27 show (I a) = show a
Data/Attoparsec/Text.hs+90−127
@@ -1,12 +1,8 @@
1−{-# LANGUAGE BangPatterns, CPP, FlexibleInstances, TypeSynonymInstances #-}
1+{-# LANGUAGE BangPatterns, FlexibleInstances, TypeSynonymInstances #-}
2−#if __GLASGOW_HASKELL__ >= 702
3−{-# LANGUAGE Trustworthy #-} -- Imports internal modules
4−#endif
5−{-# OPTIONS_GHC -fno-warn-warnings-deprecations #-}
6
2
7-- |
3-- |
8-- Module : Data.Attoparsec.Text
4-- Module : Data.Attoparsec.Text
9−-- Copyright : Bryan O'Sullivan 2007-2015
5+-- Copyright : Bryan O'Sullivan 2011
10-- License : BSD3
6-- License : BSD3
11--
7--
12-- Maintainer : bos@serpentine.com
8-- Maintainer : bos@serpentine.com
@@ -44,6 +40,11 @@ module Data.Attoparsec.Text
44 , maybeResult
40 , maybeResult
45 , eitherResult
41 , eitherResult
46
42
43+ -- * Combinators
44+ , (I.<?>)
45+ , I.try
46+ , module Data.Attoparsec.Combinator
47+
47 -- * Parsing individual characters
48 -- * Parsing individual characters
48 , I.char
49 , I.char
49 , I.anyChar
50 , I.anyChar
@@ -72,7 +73,6 @@ module Data.Attoparsec.Text
72 , skipSpace
73 , skipSpace
73 , I.skipWhile
74 , I.skipWhile
74 , I.scan
75 , I.scan
75− , I.runScanner
76 , I.take
76 , I.take
77 , I.takeWhile
77 , I.takeWhile
78 , I.takeWhile1
78 , I.takeWhile1
@@ -100,48 +100,22 @@ module Data.Attoparsec.Text
100 , Number(..)
100 , Number(..)
101 , number
101 , number
102 , rational
102 , rational
103− , scientific
104
103
105− -- * Combinators
106− , try
107− , (<?>)
108− , choice
109− , count
110− , option
111− , many'
112− , many1
113− , many1'
114− , manyTill
115− , manyTill'
116− , sepBy
117− , sepBy'
118− , sepBy1
119− , sepBy1'
120− , skipMany
121− , skipMany1
122− , eitherP
123− , I.match
124 -- * State observation and manipulation functions
104 -- * State observation and manipulation functions
125 , I.endOfInput
105 , I.endOfInput
126 , I.atEnd
106 , I.atEnd
127 ) where
107 ) where
128
108
129−#if !MIN_VERSION_base(4,8,0)
130−import Control.Applicative (pure, (*>), (<*), (<$>))
109+import Control.Applicative (pure, (<$>), (*>), (<*), (<|>))
131−import Data.Word (Word)
132−#endif
133−import Control.Applicative ((<|>))
134import Data.Attoparsec.Combinator
110import Data.Attoparsec.Combinator
135import Data.Attoparsec.Number (Number(..))
111import Data.Attoparsec.Number (Number(..))
136−import Data.Scientific (Scientific)
112+import Data.Scientific (Scientific, scientific, coefficient, base10Exponent)
137−import qualified Data.Scientific as Sci
138−import Data.Attoparsec.Text.Internal (Parser, Result, parse, takeWhile1)
113+import Data.Attoparsec.Text.Internal ((<?>), Parser, Result, parse, takeWhile1)
139import Data.Bits (Bits, (.|.), shiftL)
114import Data.Bits (Bits, (.|.), shiftL)
140import Data.Char (isAlpha, isDigit, isSpace, ord)
115import Data.Char (isAlpha, isDigit, isSpace, ord)
141import Data.Int (Int8, Int16, Int32, Int64)
116import Data.Int (Int8, Int16, Int32, Int64)
142−import Data.List (intercalate)
143import Data.Text (Text)
117import Data.Text (Text)
144−import Data.Word (Word8, Word16, Word32, Word64)
118+import Data.Word (Word8, Word16, Word32, Word64, Word)
145import qualified Data.Attoparsec.Internal as I
119import qualified Data.Attoparsec.Internal as I
146import qualified Data.Attoparsec.Internal.Types as T
120import qualified Data.Attoparsec.Internal.Types as T
147import qualified Data.Attoparsec.Text.Internal as I
121import qualified Data.Attoparsec.Text.Internal as I
@@ -149,50 +123,49 @@ import qualified Data.Text as T
149
123
150-- $parsec
124-- $parsec
151--
125--
152−-- Compared to Parsec 3, attoparsec makes several tradeoffs. It is
126+-- Compared to Parsec 3, Attoparsec makes several tradeoffs. It is
153-- not intended for, or ideal for, all possible uses.
127-- not intended for, or ideal for, all possible uses.
154--
128--
155−-- * While attoparsec can consume input incrementally, Parsec cannot.
129+-- * While Attoparsec can consume input incrementally, Parsec cannot.
156-- Incremental input is a huge deal for efficient and secure network
130-- Incremental input is a huge deal for efficient and secure network
157-- and system programming, since it gives much more control to users
131-- and system programming, since it gives much more control to users
158-- of the library over matters such as resource usage and the I/O
132-- of the library over matters such as resource usage and the I/O
159-- model to use.
133-- model to use.
160--
134--
161−-- * Much of the performance advantage of attoparsec is gained via
135+-- * Much of the performance advantage of Attoparsec is gained via
162-- high-performance parsers such as 'I.takeWhile' and 'I.string'.
136-- high-performance parsers such as 'I.takeWhile' and 'I.string'.
163-- If you use complicated combinators that return lists of
137-- If you use complicated combinators that return lists of
164-- characters, there is less performance difference between the two
138-- characters, there is less performance difference between the two
165-- libraries.
139-- libraries.
166--
140--
167−-- * Unlike Parsec 3, attoparsec does not support being used as a
141+-- * Unlike Parsec 3, Attoparsec does not support being used as a
168-- monad transformer.
142-- monad transformer.
169--
143--
170−-- * attoparsec is specialised to deal only with strict 'Text'
144+-- * Attoparsec is specialised to deal only with strict 'Text'
171-- input. Efficiency concerns rule out both lists and lazy text.
145-- input. Efficiency concerns rule out both lists and lazy text.
172-- The usual use for lazy text would be to allow consumption of very
146-- The usual use for lazy text would be to allow consumption of very
173-- large input without a large footprint. For this need,
147-- large input without a large footprint. For this need,
174−-- attoparsec's incremental input provides an excellent substitute,
148+-- Attoparsec's incremental input provides an excellent substitute,
175-- with much more control over when input takes place. If you must
149-- with much more control over when input takes place. If you must
176-- use lazy text, see the 'Lazy' module, which feeds lazy chunks to
150-- use lazy text, see the 'Lazy' module, which feeds lazy chunks to
177-- a regular parser.
151-- a regular parser.
178--
152--
179-- * Parsec parsers can produce more helpful error messages than
153-- * Parsec parsers can produce more helpful error messages than
180−-- attoparsec parsers. This is a matter of focus: attoparsec avoids
154+-- Attoparsec parsers. This is a matter of focus: Attoparsec avoids
181-- the extra book-keeping in favour of higher performance.
155-- the extra book-keeping in favour of higher performance.
182
156
183-- $incremental
157-- $incremental
184--
158--
185−-- attoparsec supports incremental input, meaning that you can feed it
159+-- Attoparsec supports incremental input, meaning that you can feed it
186-- a 'Text' that represents only part of the expected total amount
160-- a 'Text' that represents only part of the expected total amount
187-- of data to parse. If your parser reaches the end of a fragment of
161-- of data to parse. If your parser reaches the end of a fragment of
188-- input and could consume more input, it will suspend parsing and
162-- input and could consume more input, it will suspend parsing and
189-- return a 'T.Partial' continuation.
163-- return a 'T.Partial' continuation.
190--
164--
191-- Supplying the 'T.Partial' continuation with another string will
165-- Supplying the 'T.Partial' continuation with another string will
192−-- resume parsing at the point where it was suspended, with the string
166+-- resume parsing at the point where it was suspended. You must be
193−-- you supplied used as new input at the end of the existing
194−-- input. You must be prepared for the result of the resumed parse to
167+-- prepared for the result of the resumed parse to be another
195−-- be another 'Partial' continuation.
168+-- 'Partial' continuation.
196--
169--
197-- To indicate that you have no more input, supply the 'Partial'
170-- To indicate that you have no more input, supply the 'Partial'
198-- continuation with an 'T.empty' 'Text'.
171-- continuation with an 'T.empty' 'Text'.
@@ -204,19 +177,12 @@ import qualified Data.Text as T
204-- If you do not need support for incremental input, consider using
177-- If you do not need support for incremental input, consider using
205-- the 'I.parseOnly' function to run your parser. It will never
178-- the 'I.parseOnly' function to run your parser. It will never
206-- prompt for more input.
179-- prompt for more input.
207−--
208−-- /Note/: incremental input does /not/ imply that attoparsec will
209−-- release portions of its internal state for garbage collection as it
210−-- proceeds. Its internal representation is equivalent to a single
211−-- 'Text': if you feed incremental input to an a parser, it will
212−-- require memory proportional to the amount of input you supply.
213−-- (This is necessary to support arbitrary backtracking.)
214
180
215-- $performance
181-- $performance
216--
182--
217−-- If you write an attoparsec-based parser carefully, it can be
183+-- If you write an Attoparsec-based parser carefully, it can be
218−-- realistic to expect it to perform similarly to a hand-rolled C
184+-- realistic to expect it to perform within a factor of 2 of a
219−-- parser (measuring megabytes parsed per second).
185+-- hand-rolled C parser (measuring megabytes parsed per second).
220--
186--
221-- To actually achieve high performance, there are a few guidelines
187-- To actually achieve high performance, there are a few guidelines
222-- that it is useful to follow.
188-- that it is useful to follow.
@@ -237,6 +203,14 @@ import qualified Data.Text as T
237-- Make active use of benchmarking and profiling tools to measure,
203-- Make active use of benchmarking and profiling tools to measure,
238-- find the problems with, and improve the performance of your parser.
204-- find the problems with, and improve the performance of your parser.
239
205
206+-- | If a parser has returned a 'Partial' result, supply it with more
207+-- input.
208+feed :: Result r -> Text -> Result r
209+feed f@(T.Fail _ _ _) _ = f
210+feed (T.Partial k) d = k d
211+feed (T.Done bs r) d = T.Done (T.append bs d) r
212+{-# INLINE feed #-}
213+
240-- | Run a parser and print its result to standard output.
214-- | Run a parser and print its result to standard output.
241parseTest :: (Show a) => I.Parser a -> Text -> IO ()
215parseTest :: (Show a) => I.Parser a -> Text -> IO ()
242parseTest p s = print (parse p s)
216parseTest p s = print (parse p s)
@@ -266,10 +240,9 @@ maybeResult _ = Nothing
266-- | Convert a 'Result' value to an 'Either' value. A 'Partial' result
240-- | Convert a 'Result' value to an 'Either' value. A 'Partial' result
267-- is treated as failure.
241-- is treated as failure.
268eitherResult :: Result r -> Either String r
242eitherResult :: Result r -> Either String r
269−eitherResult (T.Done _ r) = Right r
243+eitherResult (T.Done _ r) = Right r
270−eitherResult (T.Fail _ [] msg) = Left msg
244+eitherResult (T.Fail _ _ msg) = Left msg
271−eitherResult (T.Fail _ ctxs msg) = Left (intercalate " > " ctxs ++ ": " ++ msg)
272−eitherResult _ = Left "Result: incomplete input"
245+eitherResult _ = Left "Result: incomplete input"
273
246
274-- | A predicate that matches either a carriage return @\'\\r\'@ or
247-- | A predicate that matches either a carriage return @\'\\r\'@ or
275-- newline @\'\\n\'@ character.
248-- newline @\'\\n\'@ character.
@@ -342,24 +315,6 @@ signed p = (negate <$> (I.char '-' *> p))
342 <|> (I.char '+' *> p)
315 <|> (I.char '+' *> p)
343 <|> p
316 <|> p
344
317
345−-- | Parse a rational number.
346−--
347−-- The syntax accepted by this parser is the same as for 'double'.
348−--
349−-- /Note/: this parser is not safe for use with inputs from untrusted
350−-- sources. An input with a suitably large exponent such as
351−-- @"1e1000000000"@ will cause a huge 'Integer' to be allocated,
352−-- resulting in what is effectively a denial-of-service attack.
353−--
354−-- In most cases, it is better to use 'double' or 'scientific'
355−-- instead.
356−rational :: Fractional a => Parser a
357−{-# SPECIALIZE rational :: Parser Double #-}
358−{-# SPECIALIZE rational :: Parser Float #-}
359−{-# SPECIALIZE rational :: Parser Rational #-}
360−{-# SPECIALIZE rational :: Parser Scientific #-}
361−rational = scientifically realToFrac
362−
363-- | Parse a rational number.
318-- | Parse a rational number.
364--
319--
365-- This parser accepts an optional leading sign character, followed by
320-- This parser accepts an optional leading sign character, followed by
@@ -387,32 +342,49 @@ rational = scientifically realToFrac
387--
342--
388-- This function does not accept string representations of \"NaN\" or
343-- This function does not accept string representations of \"NaN\" or
389-- \"Infinity\".
344-- \"Infinity\".
345+rational :: Fractional a => Parser a
346+{-# SPECIALIZE rational :: Parser Double #-}
347+{-# SPECIALIZE rational :: Parser Float #-}
348+{-# SPECIALIZE rational :: Parser Rational #-}
349+{-# SPECIALIZE rational :: Parser Scientific #-}
350+rational = scientifically realToFrac
351+
352+-- | Parse a rational number.
353+--
354+-- The syntax accepted by this parser is the same as for 'rational'.
355+--
356+-- /Note/: This function is almost ten times faster than 'rational',
357+-- but is slightly less accurate.
358+--
359+-- The 'Double' type supports about 16 decimal places of accuracy.
360+-- For 94.2% of numbers, this function and 'rational' give identical
361+-- results, but for the remaining 5.8%, this function loses precision
362+-- around the 15th decimal place. For 0.001% of numbers, this
363+-- function will lose precision at the 13th or 14th decimal place.
364+--
365+-- This function does not accept string representations of \"NaN\" or
366+-- \"Infinity\".
390double :: Parser Double
367double :: Parser Double
391−double = scientifically Sci.toRealFloat
368+double = rational
392
369
393-- | Parse a number, attempting to preserve both speed and precision.
370-- | Parse a number, attempting to preserve both speed and precision.
394--
371--
395−-- The syntax accepted by this parser is the same as for 'double'.
372+-- The syntax accepted by this parser is the same as for 'rational'.
373+--
374+-- /Note/: This function is almost ten times faster than 'rational'.
375+-- On integral inputs, it gives perfectly accurate answers, and on
376+-- floating point inputs, it is slightly less accurate than
377+-- 'rational'.
396--
378--
397-- This function does not accept string representations of \"NaN\" or
379-- This function does not accept string representations of \"NaN\" or
398-- \"Infinity\".
380-- \"Infinity\".
399number :: Parser Number
381number :: Parser Number
400number = scientifically $ \s ->
382number = scientifically $ \s ->
401− let e = Sci.base10Exponent s
383+ let e = base10Exponent s
402− c = Sci.coefficient s
384+ c = coefficient s
403 in if e >= 0
385 in if e >= 0
404 then I (c * 10 ^ e)
386 then I (c * 10 ^ e)
405− else D (Sci.toRealFloat s)
387+ else D (fromInteger c / 10 ^ negate e)
406−{-# DEPRECATED number "Use 'scientific' instead." #-}
407−
408−-- | Parse a scientific number.
409−--
410−-- The syntax accepted by this parser is the same as for 'double'.
411−scientific :: Parser Scientific
412−scientific = scientifically id
413−
414−-- A strict pair
415−data SP = SP !Integer {-# UNPACK #-}!Int
416
388
417{-# INLINE scientifically #-}
389{-# INLINE scientifically #-}
418scientifically :: (Scientific -> a) -> Parser a
390scientifically :: (Scientific -> a) -> Parser a
@@ -422,19 +394,19 @@ scientifically h = do
422
394
423 n <- decimal
395 n <- decimal
424
396
425− let f fracDigits = SP (T.foldl' step n fracDigits)
397+ let f fracDigits = scientific (T.foldl' step n fracDigits)
426− (negate $ T.length fracDigits)
398+ (negate $ T.length fracDigits)
427 step a c = a * 10 + fromIntegral (ord c - 48)
399 step a c = a * 10 + fromIntegral (ord c - 48)
428
400
429− SP c e <- (I.satisfy (=='.') *> (f <$> I.takeWhile isDigit)) <|>
401+ s <- (I.satisfy (=='.') *> (f <$> I.takeWhile isDigit)) <|>
430− pure (SP n 0)
402+ pure (scientific n 0)
431
403
432− let !signedCoeff | positive = c
404+ let !signedCoeff | positive = coefficient s
433− | otherwise = -c
405+ | otherwise = negate $ coefficient s
434
406
435− (I.satisfy (\w -> w == 'e' || w == 'E') *>
407+ (I.satisfy (\c -> c == 'e' || c == 'E') *>
436− fmap (h . Sci.scientific signedCoeff . (e +)) (signed decimal)) <|>
408+ fmap (h . scientific signedCoeff . (base10Exponent s +)) (signed decimal)) <|>
437− return (h $ Sci.scientific signedCoeff e)
409+ return (h $ scientific signedCoeff (base10Exponent s))
438
410
439-- | Parse a single digit, as recognised by 'isDigit'.
411-- | Parse a single digit, as recognised by 'isDigit'.
440digit :: Parser Char
412digit :: Parser Char
@@ -458,36 +430,27 @@ skipSpace = I.skipWhile isSpace
458
430
459-- $specalt
431-- $specalt
460--
432--
461−-- If you enable the @OverloadedStrings@ language extension, you can
433+-- The '.*>' and '<*.' combinators are intended for use with the
462−-- use the '*>' and '<*' combinators to simplify the common task of
434+-- @OverloadedStrings@ language extension. They simplify the common
463−-- matching a statically known string, then immediately parsing
435+-- task of matching a statically known string, then immediately
464−-- something else.
436+-- parsing something else.
465--
437--
466−-- Instead of writing something like this:
438+-- An example makes this easier to understand:
467--
439--
468−-- @
440+-- @{-\# LANGUAGE OverloadedStrings #-}
469−--'I.string' \"foo\" '*>' wibble
470−-- @
471--
441--
472−-- Using @OverloadedStrings@, you can omit the explicit use of
442+-- shoeSize = \"Shoe size: \" '.*>' 'decimal'
473−-- 'I.string', and write a more compact version:
474−--
475−-- @
476−-- \"foo\" '*>' wibble
477-- @
443-- @
478--
444--
479−-- (Note: the '.*>' and '<*.' combinators that were originally
445+-- If we were to try to use '*>' above instead, the type checker would
480−-- provided for this purpose are obsolete and unnecessary, and will be
446+-- not be able to tell which 'IsString' instance to use for the text
481−-- removed in the next major version.)
447+-- in quotes. We would have to be explicit, using either a type
448+-- signature or the 'I.string' parser.
482
449
483−-- | /Obsolete/. A type-specialized version of '*>' for 'Text'. Use
450+-- | Type-specialized version of '*>' for 'Text'.
484−-- '*>' instead.
485(.*>) :: Text -> Parser a -> Parser a
451(.*>) :: Text -> Parser a -> Parser a
486s .*> f = I.string s *> f
452s .*> f = I.string s *> f
487−{-# DEPRECATED (.*>) "This is no longer necessary, and will be removed. Use '*>' instead." #-}
488
453
489−-- | /Obsolete/. A type-specialized version of '<*' for 'Text'. Use
454+-- | Type-specialized version of '<*' for 'Text'.
490−-- '*>' instead.
491(<*.) :: Parser a -> Text -> Parser a
455(<*.) :: Parser a -> Text -> Parser a
492f <*. s = f <* I.string s
456f <*. s = f <* I.string s
493−{-# DEPRECATED (<*.) "This is no longer necessary, and will be removed. Use '<*' instead." #-}
Data/Attoparsec/Text/Buffer.hsdeleted−172
@@ -1,172 +0,0 @@
1−{-# LANGUAGE BangPatterns, CPP, MagicHash, RankNTypes, RecordWildCards,
2− UnboxedTuples #-}
3−
4−-- |
5−-- Module : Data.Attoparsec.Text.Buffer
6−-- Copyright : Bryan O'Sullivan 2007-2015
7−-- License : BSD3
8−--
9−-- Maintainer : bos@serpentine.com
10−-- Stability : experimental
11−-- Portability : GHC
12−--
13−-- An immutable buffer that supports cheap appends.
14−
15−-- A Buffer is divided into an immutable read-only zone, followed by a
16−-- mutable area that we've preallocated, but not yet written to.
17−--
18−-- We overallocate at the end of a Buffer so that we can cheaply
19−-- append. Since a user of an existing Buffer cannot see past the end
20−-- of its immutable zone into the data that will change during an
21−-- append, this is safe.
22−--
23−-- Once we run out of space at the end of a Buffer, we do the usual
24−-- doubling of the buffer size.
25−
26−module Data.Attoparsec.Text.Buffer
27− (
28− Buffer
29− , buffer
30− , unbuffer
31− , unbufferAt
32− , length
33− , pappend
34− , iter
35− , iter_
36− , substring
37− , dropWord16
38− ) where
39−
40−import Control.Exception (assert)
41−import Data.Bits (shiftR)
42−import Data.List (foldl1')
43−import Data.Monoid as Mon (Monoid(..))
44−import Data.Semigroup (Semigroup(..))
45−import Data.Text ()
46−import Data.Text.Internal (Text(..))
47−import Data.Text.Internal.Encoding.Utf16 (chr2)
48−import Data.Text.Internal.Unsafe.Char (unsafeChr)
49−import Data.Text.Unsafe (Iter(..))
50−import Foreign.Storable (sizeOf)
51−import GHC.Base (Int(..), indexIntArray#, unsafeCoerce#, writeIntArray#)
52−import GHC.ST (ST(..), runST)
53−import Prelude hiding (length)
54−import qualified Data.Text.Array as A
55−
56−-- If _cap is zero, this buffer is empty.
57−data Buffer = Buf {
58− _arr :: {-# UNPACK #-} !A.Array
59− , _off :: {-# UNPACK #-} !Int
60− , _len :: {-# UNPACK #-} !Int
61− , _cap :: {-# UNPACK #-} !Int
62− , _gen :: {-# UNPACK #-} !Int
63− }
64−
65−instance Show Buffer where
66− showsPrec p = showsPrec p . unbuffer
67−
68−-- | The initial 'Buffer' has no mutable zone, so we can avoid all
69−-- copies in the (hopefully) common case of no further input being fed
70−-- to us.
71−buffer :: Text -> Buffer
72−buffer (Text arr off len) = Buf arr off len len 0
73−
74−unbuffer :: Buffer -> Text
75−unbuffer (Buf arr off len _ _) = Text arr off len
76−
77−unbufferAt :: Int -> Buffer -> Text
78−unbufferAt s (Buf arr off len _ _) =
79− assert (s >= 0 && s <= len) $
80− Text arr (off+s) (len-s)
81−
82−instance Semigroup Buffer where
83− (Buf _ _ _ 0 _) <> b = b
84− a <> (Buf _ _ _ 0 _) = a
85− buf <> (Buf arr off len _ _) = append buf arr off len
86− {-# INLINE (<>) #-}
87−
88−instance Monoid Buffer where
89− mempty = Buf A.empty 0 0 0 0
90− {-# INLINE mempty #-}
91−
92− mappend = (<>)
93−
94− mconcat [] = Mon.mempty
95− mconcat xs = foldl1' (<>) xs
96−
97−pappend :: Buffer -> Text -> Buffer
98−pappend (Buf _ _ _ 0 _) t = buffer t
99−pappend buf (Text arr off len) = append buf arr off len
100−
101−append :: Buffer -> A.Array -> Int -> Int -> Buffer
102−append (Buf arr0 off0 len0 cap0 gen0) !arr1 !off1 !len1 = runST $ do
103− let woff = sizeOf (0::Int) `shiftR` 1
104− newlen = len0 + len1
105− !gen = if gen0 == 0 then 0 else readGen arr0
106− if gen == gen0 && newlen <= cap0
107− then do
108− let newgen = gen + 1
109− marr <- unsafeThaw arr0
110− writeGen marr newgen
111− A.copyI marr (off0+len0) arr1 off1 (off0+newlen)
112− arr2 <- A.unsafeFreeze marr
113− return (Buf arr2 off0 newlen cap0 newgen)
114− else do
115− let newcap = newlen * 2
116− newgen = 1
117− marr <- A.new (newcap + woff)
118− writeGen marr newgen
119− A.copyI marr woff arr0 off0 (woff+len0)
120− A.copyI marr (woff+len0) arr1 off1 (woff+newlen)
121− arr2 <- A.unsafeFreeze marr
122− return (Buf arr2 woff newlen newcap newgen)
123−
124−length :: Buffer -> Int
125−length (Buf _ _ len _ _) = len
126−{-# INLINE length #-}
127−
128−substring :: Int -> Int -> Buffer -> Text
129−substring s l (Buf arr off len _ _) =
130− assert (s >= 0 && s <= len) .
131− assert (l >= 0 && l <= len-s) $
132− Text arr (off+s) l
133−{-# INLINE substring #-}
134−
135−dropWord16 :: Int -> Buffer -> Text
136−dropWord16 s (Buf arr off len _ _) =
137− assert (s >= 0 && s <= len) $
138− Text arr (off+s) (len-s)
139−{-# INLINE dropWord16 #-}
140−
141−-- | /O(1)/ Iterate (unsafely) one step forwards through a UTF-16
142−-- array, returning the current character and the delta to add to give
143−-- the next offset to iterate at.
144−iter :: Buffer -> Int -> Iter
145−iter (Buf arr off _ _ _) i
146− | m < 0xD800 || m > 0xDBFF = Iter (unsafeChr m) 1
147− | otherwise = Iter (chr2 m n) 2
148− where m = A.unsafeIndex arr j
149− n = A.unsafeIndex arr k
150− j = off + i
151− k = j + 1
152−{-# INLINE iter #-}
153−
154−-- | /O(1)/ Iterate one step through a UTF-16 array, returning the
155−-- delta to add to give the next offset to iterate at.
156−iter_ :: Buffer -> Int -> Int
157−iter_ (Buf arr off _ _ _) i | m < 0xD800 || m > 0xDBFF = 1
158− | otherwise = 2
159− where m = A.unsafeIndex arr (off+i)
160−{-# INLINE iter_ #-}
161−
162−unsafeThaw :: A.Array -> ST s (A.MArray s)
163−unsafeThaw A.Array{..} = ST $ \s# ->
164− (# s#, A.MArray (unsafeCoerce# aBA) #)
165−
166−readGen :: A.Array -> Int
167−readGen a = case indexIntArray# (A.aBA a) 0# of r# -> I# r#
168−
169−writeGen :: A.MArray s -> Int -> ST s ()
170−writeGen a (I# gen#) = ST $ \s0# ->
171− case writeIntArray# (A.maBA a) 0# gen# s0# of
172− s1# -> (# s1#, () #)
Data/Attoparsec/Text/FastSet.hs+27−85
@@ -1,20 +1,16 @@
1−{-# LANGUAGE BangPatterns #-}
1+-----------------------------------------------------------------------------
2−
3−------------------------------------------------------------------------------
4-- |
2-- |
5-- Module : Data.Attoparsec.FastSet
3-- Module : Data.Attoparsec.FastSet
6−-- Copyright : Felipe Lessa 2010, Bryan O'Sullivan 2007-2015
4+-- Copyright : Felipe Lessa 2010, Bryan O'Sullivan 2008
7-- License : BSD3
5-- License : BSD3
8--
6--
9-- Maintainer : felipe.lessa@gmail.com
7-- Maintainer : felipe.lessa@gmail.com
10-- Stability : experimental
8-- Stability : experimental
11-- Portability : unknown
9-- Portability : unknown
12--
10--
13−-- Fast set membership tests for 'Char' values. We test for
11+-- Fast set membership tests for 'Char' values. The set
14−-- membership using a hashtable implemented with Robin Hood
15−-- collision resolution. The set representation is unboxed,
12+-- representation is unboxed for efficiency. We test for
16−-- and the characters and hashes interleaved, for efficiency.
13+-- membership using a binary search.
17−--
18--
14--
19-----------------------------------------------------------------------------
15-----------------------------------------------------------------------------
20module Data.Attoparsec.Text.FastSet
16module Data.Attoparsec.Text.FastSet
@@ -30,92 +26,38 @@ module Data.Attoparsec.Text.FastSet
30 , charClass
26 , charClass
31 ) where
27 ) where
32
28
33−import Data.Bits ((.|.), (.&.), shiftR)
29+import Data.List (sort)
34−import Data.Function (on)
35−import Data.List (sort, sortBy)
36import qualified Data.Array.Base as AB
30import qualified Data.Array.Base as AB
37import qualified Data.Array.Unboxed as A
31import qualified Data.Array.Unboxed as A
38import qualified Data.Text as T
32import qualified Data.Text as T
39
33
40−data FastSet = FastSet {
34+newtype FastSet = FastSet (A.UArray Int Char)
41− table :: {-# UNPACK #-} !(A.UArray Int Int)
35+ deriving (Eq, Ord, Show)
42− , mask :: {-# UNPACK #-} !Int
43− }
44−
45−data Entry = Entry {
46− key :: {-# UNPACK #-} !Char
47− , initialIndex :: {-# UNPACK #-} !Int
48− , index :: {-# UNPACK #-} !Int
49− }
50−
51−offset :: Entry -> Int
52−offset e = index e - initialIndex e
53−
54−resolveCollisions :: [Entry] -> [Entry]
55−resolveCollisions [] = []
56−resolveCollisions [e] = [e]
57−resolveCollisions (a:b:entries) = a' : resolveCollisions (b' : entries)
58− where (a', b')
59− | index a < index b = (a, b)
60− | offset a < offset b = (b { index=index a }, a { index=index a + 1 })
61− | otherwise = (a, b { index=index a + 1 })
62
36
63−pad :: Int -> [Entry] -> [Entry]
37+-- | Create a set.
64−pad = go 0
38+set :: T.Text -> FastSet
65− where -- ensure that we pad enough so that lookups beyond the
39+set t = mkSet (T.length t) (sort $ T.unpack t)
66− -- last hash in the table fall within the array
67− go !_ !m [] = replicate (max 1 m + 1) empty
68− go k m (e:entries) = map (const empty) [k..i - 1] ++ e :
69− go (i + 1) (m + i - k - 1) entries
70− where i = index e
71− empty = Entry '\0' maxBound 0
72−
73−nextPowerOf2 :: Int -> Int
74−nextPowerOf2 0 = 1
75−nextPowerOf2 x = go (x - 1) 1
76− where go y 32 = y + 1
77− go y k = go (y .|. (y `shiftR` k)) $ k * 2
78−
79−fastHash :: Char -> Int
80−fastHash = fromEnum
81−
82−fromList :: String -> FastSet
83−fromList s = FastSet (AB.listArray (0, length interleaved - 1) interleaved)
84− mask'
85− where s' = ordNub (sort s)
86− l = length s'
87− mask' = nextPowerOf2 ((5 * l) `div` 4) - 1
88− entries = pad mask' .
89− resolveCollisions .
90− sortBy (compare `on` initialIndex) .
91− zipWith (\c i -> Entry c i i) s' .
92− map ((.&. mask') . fastHash) $ s'
93− interleaved = concatMap (\e -> [fromEnum $ key e, initialIndex e])
94− entries
95
40
96−ordNub :: Eq a => [a] -> [a]
41+fromList :: [Char] -> FastSet
97−ordNub [] = []
42+fromList cs = mkSet (length cs) (sort cs)
98−ordNub (y:ys) = go y ys
99− where go x (z:zs)
100− | x == z = go x zs
101− | otherwise = x : go z zs
102− go x [] = [x]
103
43
104−set :: T.Text -> FastSet
44+mkSet :: Int -> [Char] -> FastSet
105−set = fromList . T.unpack
45+mkSet l = FastSet . A.listArray (0,l-1)
106
46
107-- | Check the set for membership.
47-- | Check the set for membership.
108member :: Char -> FastSet -> Bool
48member :: Char -> FastSet -> Bool
109−member c a = go (2 * i)
49+member c (FastSet a) = uncurry search (A.bounds a)
110− where i = fastHash c .&. mask a
50+ where search lo hi
111− lookupAt j b = (i' <= i) && (c == c' || b)
51+ | hi < lo = False
112− where c' = toEnum $ AB.unsafeAt (table a) j
52+ | otherwise =
53+ let mid = (lo + hi) `quot` 2
113− i' = AB.unsafeAt (table a) $ j + 1
54+ in case compare c (AB.unsafeAt a mid) of
114− go j = lookupAt j . lookupAt (j + 2) . lookupAt (j + 4) .
55+ GT -> search (mid + 1) hi
115− lookupAt (j + 6) . go $ j + 8
56+ LT -> search lo (mid - 1)
57+ _ -> True
116
58
117charClass :: String -> FastSet
59charClass :: String -> FastSet
118charClass = fromList . go
60charClass = fromList . go
119− where go (a:'-':b:xs) = [a..b] ++ go xs
61+ where go (a:'-':b:xs) = [a..b] ++ go xs
120− go (x:xs) = x : go xs
62+ go (x:xs) = x : go xs
121− go _ = ""
63+ go _ = ""
Data/Attoparsec/Text/Internal.hs+238−258
@@ -1,16 +1,16 @@
1−{-# LANGUAGE BangPatterns, FlexibleInstances, GADTs, OverloadedStrings,
1+{-# LANGUAGE BangPatterns, CPP, FlexibleInstances, GADTs, OverloadedStrings,
2 Rank2Types, RecordWildCards, TypeFamilies, TypeSynonymInstances #-}
2 Rank2Types, RecordWildCards, TypeFamilies, TypeSynonymInstances #-}
3{-# OPTIONS_GHC -fno-warn-orphans #-}
3{-# OPTIONS_GHC -fno-warn-orphans #-}
4-- |
4-- |
5-- Module : Data.Attoparsec.Text.Internal
5-- Module : Data.Attoparsec.Text.Internal
6−-- Copyright : Bryan O'Sullivan 2007-2015
6+-- Copyright : Bryan O'Sullivan 2011
7-- License : BSD3
7-- License : BSD3
8--
8--
9-- Maintainer : bos@serpentine.com
9-- Maintainer : bos@serpentine.com
10-- Stability : experimental
10-- Stability : experimental
11-- Portability : unknown
11-- Portability : unknown
12--
12--
13−-- Simple, efficient parser combinators for 'Text' strings, loosely
13+-- Simple, efficient parser combinators for 'T.Text' strings, loosely
14-- based on the Parsec library.
14-- based on the Parsec library.
15
15
16module Data.Attoparsec.Text.Internal
16module Data.Attoparsec.Text.Internal
@@ -24,6 +24,8 @@ module Data.Attoparsec.Text.Internal
24 , parseOnly
24 , parseOnly
25
25
26 -- * Combinators
26 -- * Combinators
27+ , (<?>)
28+ , try
27 , module Data.Attoparsec.Combinator
29 , module Data.Attoparsec.Combinator
28
30
29 -- * Parsing individual characters
31 -- * Parsing individual characters
@@ -49,7 +51,6 @@ module Data.Attoparsec.Text.Internal
49 , asciiCI
51 , asciiCI
50 , take
52 , take
51 , scan
53 , scan
52− , runScanner
53 , takeWhile
54 , takeWhile
54 , takeWhile1
55 , takeWhile1
55 , takeTill
56 , takeTill
@@ -58,39 +59,117 @@ module Data.Attoparsec.Text.Internal
58 , takeText
59 , takeText
59 , takeLazyText
60 , takeLazyText
60
61
61− -- * Utilities
62+ -- * State observation and manipulation functions
62− , endOfLine
63 , endOfInput
63 , endOfInput
64− , match
65 , atEnd
64 , atEnd
65+
66+ -- * Utilities
67+ , endOfLine
66 ) where
68 ) where
67
69
68−import Control.Applicative ((<|>), (<$>), pure, (*>))
70+import Control.Applicative ((<|>), (<$>))
69import Control.Monad (when)
71import Control.Monad (when)
70−import Data.Attoparsec.Combinator ((<?>))
72+import Data.Attoparsec.Combinator
71−import Data.Attoparsec.Internal
72−import Data.Attoparsec.Internal.Types hiding (Parser, Failure, Success)
73+import Data.Attoparsec.Internal.Types hiding (Parser, Input, Added, Failure, Success)
73−import qualified Data.Attoparsec.Text.Buffer as Buf
74+import Data.Monoid (Monoid(..))
74−import Data.Attoparsec.Text.Buffer (Buffer, buffer)
75−import Data.Char (isAsciiUpper, isAsciiLower, toUpper, toLower)
76−import Data.List (intercalate)
77import Data.String (IsString(..))
75import Data.String (IsString(..))
78−import Data.Text.Internal (Text(..))
76+import Data.Text (Text)
79−import Prelude hiding (getChar, succ, take, takeWhile)
77+import Prelude hiding (getChar, take, takeWhile)
78+import Data.Char (chr, ord)
80import qualified Data.Attoparsec.Internal.Types as T
79import qualified Data.Attoparsec.Internal.Types as T
81import qualified Data.Attoparsec.Text.FastSet as Set
80import qualified Data.Attoparsec.Text.FastSet as Set
82import qualified Data.Text as T
81import qualified Data.Text as T
82+import qualified Data.Text.Internal as T
83import qualified Data.Text.Lazy as L
83import qualified Data.Text.Lazy as L
84−import qualified Data.Text.Unsafe as T
85
84
86type Parser = T.Parser Text
85type Parser = T.Parser Text
87type Result = IResult Text
86type Result = IResult Text
87+type Input = T.Input Text
88+type Added = T.Added Text
88−type Failure r = T.Failure Text Buffer r
89+type Failure r = T.Failure Text r
89−type Success a r = T.Success Text Buffer a r
90+type Success a r = T.Success Text a r
90
91
91instance (a ~ Text) => IsString (Parser a) where
92instance (a ~ Text) => IsString (Parser a) where
92 fromString = string . T.pack
93 fromString = string . T.pack
93
94
95+lengthAtLeast :: T.Text -> Int -> Bool
96+lengthAtLeast t@(T.Text _ _ len) n = (len `quot` 2) >= n || T.length t >= n
97+{-# INLINE lengthAtLeast #-}
98+
99+-- | If at least @n@ characters of input are available, return the
100+-- current input, otherwise fail.
101+ensure :: Int -> Parser Text
102+ensure !n = T.Parser $ \i0 a0 m0 kf ks ->
103+ if lengthAtLeast (unI i0) n
104+ then ks i0 a0 m0 (unI i0)
105+ else runParser (demandInput >> go n) i0 a0 m0 kf ks
106+ where
107+ go n' = T.Parser $ \i0 a0 m0 kf ks ->
108+ if lengthAtLeast (unI i0) n'
109+ then ks i0 a0 m0 (unI i0)
110+ else runParser (demandInput >> go n') i0 a0 m0 kf ks
111+{-# INLINE ensure #-}
112+
113+-- | Ask for input. If we receive any, pass it to a success
114+-- continuation, otherwise to a failure continuation.
115+prompt :: Input -> Added -> More
116+ -> (Input -> Added -> More -> Result r)
117+ -> (Input -> Added -> More -> Result r)
118+ -> Result r
119+prompt i0 a0 _m0 kf ks = Partial $ \s ->
120+ if T.null s
121+ then kf i0 a0 Complete
122+ else ks (i0 <> I s) (a0 <> A s) Incomplete
123+
124+-- | Immediately demand more input via a 'Partial' continuation
125+-- result.
126+demandInput :: Parser ()
127+demandInput = T.Parser $ \i0 a0 m0 kf ks ->
128+ if m0 == Complete
129+ then kf i0 a0 m0 ["demandInput"] "not enough input"
130+ else let kf' i a m = kf i a m ["demandInput"] "not enough input"
131+ ks' i a m = ks i a m ()
132+ in prompt i0 a0 m0 kf' ks'
133+
134+-- | This parser always succeeds. It returns 'True' if any input is
135+-- available either immediately or on demand, and 'False' if the end
136+-- of all input has been reached.
137+wantInput :: Parser Bool
138+wantInput = T.Parser $ \i0 a0 m0 _kf ks ->
139+ case () of
140+ _ | not (T.null (unI i0)) -> ks i0 a0 m0 True
141+ | m0 == Complete -> ks i0 a0 m0 False
142+ | otherwise -> let kf' i a m = ks i a m False
143+ ks' i a m = ks i a m True
144+ in prompt i0 a0 m0 kf' ks'
145+
146+get :: Parser Text
147+get = T.Parser $ \i0 a0 m0 _kf ks -> ks i0 a0 m0 (unI i0)
148+
149+put :: Text -> Parser ()
150+put s = T.Parser $ \_i0 a0 m0 _kf ks -> ks (I s) a0 m0 ()
151+
152+-- | Attempt a parse, and if it fails, rewind the input so that no
153+-- input appears to have been consumed.
154+--
155+-- This combinator is provided for compatibility with Parsec.
156+-- Attoparsec parsers always backtrack on failure.
157+try :: Parser a -> Parser a
158+try p = p
159+{-# INLINE try #-}
160+
161+unsafeHead :: Text -> Char
162+unsafeHead = T.head
163+
164+unsafeTail :: Text -> Text
165+unsafeTail = T.tail
166+
167+unsafeTake :: Int -> Text -> Text
168+unsafeTake = T.take
169+
170+unsafeDrop :: Int -> Text -> Text
171+unsafeDrop = T.drop
172+
94-- | The parser @satisfy p@ succeeds for any character for which the
173-- | The parser @satisfy p@ succeeds for any character for which the
95-- predicate @p@ returns 'True'. Returns the character that is
174-- predicate @p@ returns 'True'. Returns the character that is
96-- actually parsed.
175-- actually parsed.
@@ -99,10 +178,10 @@ instance (a ~ Text) => IsString (Parser a) where
99-- > where isDigit c = c >= '0' && c <= '9'
178-- > where isDigit c = c >= '0' && c <= '9'
100satisfy :: (Char -> Bool) -> Parser Char
179satisfy :: (Char -> Bool) -> Parser Char
101satisfy p = do
180satisfy p = do
102− (k,c) <- ensure 1
181+ s <- ensure 1
103− let !h = T.unsafeHead c
182+ let !w = unsafeHead s
104− if p h
183+ if p w
105− then advance k >> return h
184+ then put (unsafeTail s) >> return w
106 else fail "satisfy"
185 else fail "satisfy"
107{-# INLINE satisfy #-}
186{-# INLINE satisfy #-}
108
187
@@ -113,9 +192,9 @@ satisfy p = do
113-- > where isDigit c = c >= '0' && c <= '9'
192-- > where isDigit c = c >= '0' && c <= '9'
114skip :: (Char -> Bool) -> Parser ()
193skip :: (Char -> Bool) -> Parser ()
115skip p = do
194skip p = do
116− (k,s) <- ensure 1
195+ s <- ensure 1
117− if p (T.unsafeHead s)
196+ if p (unsafeHead s)
118− then advance k
197+ then put (unsafeTail s)
119 else fail "skip"
198 else fail "skip"
120
199
121-- | The parser @satisfyWith f p@ transforms a character, and succeeds
200-- | The parser @satisfyWith f p@ transforms a character, and succeeds
@@ -123,10 +202,11 @@ skip p = do
123-- parser returns the transformed character that was parsed.
202-- parser returns the transformed character that was parsed.
124satisfyWith :: (Char -> a) -> (a -> Bool) -> Parser a
203satisfyWith :: (Char -> a) -> (a -> Bool) -> Parser a
125satisfyWith f p = do
204satisfyWith f p = do
126− (k,s) <- ensure 1
205+ s <- ensure 1
127− let c = f $! T.unsafeHead s
206+ let c = f $! unsafeHead s
128 if p c
207 if p c
208+ then let !t = unsafeTail s
129− then advance k >> return c
209+ in put t >> return c
130 else fail "satisfyWith"
210 else fail "satisfyWith"
131{-# INLINE satisfyWith #-}
211{-# INLINE satisfyWith #-}
132
212
@@ -134,14 +214,15 @@ satisfyWith f p = do
134-- predicate returns 'True'.
214-- predicate returns 'True'.
135takeWith :: Int -> (Text -> Bool) -> Parser Text
215takeWith :: Int -> (Text -> Bool) -> Parser Text
136takeWith n p = do
216takeWith n p = do
137− (k,s) <- ensure n
217+ s <- ensure n
218+ let (h,t) = T.splitAt n s
138− if p s
219+ if p h
139− then advance k >> return s
220+ then put t >> return h
140 else fail "takeWith"
221 else fail "takeWith"
141
222
142-- | Consume exactly @n@ characters of input.
223-- | Consume exactly @n@ characters of input.
143take :: Int -> Parser Text
224take :: Int -> Parser Text
144−take n = takeWith (max n 0) (const True)
225+take n = takeWith n (const True)
145{-# INLINE take #-}
226{-# INLINE take #-}
146
227
147-- | @string s@ parses a sequence of characters that identically match
228-- | @string s@ parses a sequence of characters that identically match
@@ -157,49 +238,12 @@ take n = takeWith (max n 0) (const True)
157--
238--
158-- The reason for its failure is that the first branch is a
239-- The reason for its failure is that the first branch is a
159-- partial match, and will consume the letters @\'f\'@ and @\'o\'@
240-- partial match, and will consume the letters @\'f\'@ and @\'o\'@
160−-- before failing. In attoparsec, the above parser will /succeed/ on
241+-- before failing. In Attoparsec, the above parser will /succeed/ on
161-- that input, because the failed first branch will consume nothing.
242-- that input, because the failed first branch will consume nothing.
162string :: Text -> Parser Text
243string :: Text -> Parser Text
163−string s = string_ (stringSuspended id) id s
244+string s = takeWith (T.length s) (==s)
164{-# INLINE string #-}
245{-# INLINE string #-}
165
246
166−string_ :: (forall r. Text -> Text -> Buffer -> Pos -> More
167− -> Failure r -> Success Text r -> Result r)
168− -> (Text -> Text)
169− -> Text -> Parser Text
170−string_ suspended f s0 = T.Parser $ \t pos more lose succ ->
171− let s = f s0
172− ft = f (Buf.unbufferAt (fromPos pos) t)
173− in case T.commonPrefixes s ft of
174− Nothing
175− | T.null s -> succ t pos more T.empty
176− | T.null ft -> suspended s s t pos more lose succ
177− | otherwise -> lose t pos more [] "string"
178− Just (pfx,ssfx,tsfx)
179− | T.null ssfx -> let l = Pos (T.lengthWord16 pfx)
180− in succ t (pos + l) more (substring pos l t)
181− | not (T.null tsfx) -> lose t pos more [] "string"
182− | otherwise -> suspended s ssfx t pos more lose succ
183−{-# INLINE string_ #-}
184−
185−stringSuspended :: (Text -> Text)
186− -> Text -> Text -> Buffer -> Pos -> More
187− -> Failure r
188− -> Success Text r
189− -> Result r
190−stringSuspended f s000 s0 t0 pos0 more0 lose0 succ0 =
191− runParser (demandInput_ >>= go) t0 pos0 more0 lose0 succ0
192− where
193− go s' = T.Parser $ \t pos more lose succ ->
194− let s = f s'
195− in case T.commonPrefixes s0 s of
196− Nothing -> lose t pos more [] "string"
197− Just (_pfx,ssfx,tsfx)
198− | T.null ssfx -> let l = Pos (T.lengthWord16 s000)
199− in succ t (pos + l) more (substring pos l t)
200− | T.null tsfx -> stringSuspended f s000 ssfx t pos more lose succ
201− | otherwise -> lose t pos more [] "string"
202−
203-- | Satisfy a literal string, ignoring case.
247-- | Satisfy a literal string, ignoring case.
204--
248--
205-- Note: this function is currently quite inefficient. Unicode case
249-- Note: this function is currently quite inefficient. Unicode case
@@ -212,9 +256,10 @@ stringCI s = go 0
212 go !n
256 go !n
213 | n > T.length fs = fail "stringCI"
257 | n > T.length fs = fail "stringCI"
214 | otherwise = do
258 | otherwise = do
215− (k,t) <- ensure n
259+ t <- ensure n
260+ let h = unsafeTake n t
216− if T.toCaseFold t == fs
261+ if T.toCaseFold h == fs
217− then advance k >> return t
262+ then put (unsafeDrop n t) >> return h
218 else go (n+1)
263 else go (n+1)
219 fs = T.toCaseFold s
264 fs = T.toCaseFold s
220{-# INLINE stringCI #-}
265{-# INLINE stringCI #-}
@@ -222,24 +267,34 @@ stringCI s = go 0
222
267
223-- | Satisfy a literal string, ignoring case for characters in the ASCII range.
268-- | Satisfy a literal string, ignoring case for characters in the ASCII range.
224asciiCI :: Text -> Parser Text
269asciiCI :: Text -> Parser Text
225−asciiCI s = fmap fst $ match $ T.foldr ((*>) . asciiCharCI) (pure ()) s
270+asciiCI input = do
271+ t <- ensure n
272+ let h = unsafeTake n t
273+ if asciiToLower h == s
274+ then put (unsafeDrop n t) >> return h
275+ else fail "asciiCI"
276+ where
277+ n = T.length input
278+ s = asciiToLower input
279+
280+ -- convert letters in the ASCII range to lower-case
281+ asciiToLower = T.map f
282+ where
283+ offset = ord 'a' - ord 'A'
284+ f c | 'A' <= c && c <= 'Z' = chr (ord c + offset)
285+ | otherwise = c
226{-# INLINE asciiCI #-}
286{-# INLINE asciiCI #-}
227
287
228−asciiCharCI :: Char -> Parser Char
229−asciiCharCI c
230− | isAsciiUpper c = char c <|> char (toLower c)
231− | isAsciiLower c = char c <|> char (toUpper c)
232− | otherwise = char c
233−{-# INLINE asciiCharCI #-}
234−
235-- | Skip past input for as long as the predicate returns 'True'.
288-- | Skip past input for as long as the predicate returns 'True'.
236skipWhile :: (Char -> Bool) -> Parser ()
289skipWhile :: (Char -> Bool) -> Parser ()
237skipWhile p = go
290skipWhile p = go
238 where
291 where
239 go = do
292 go = do
240− t <- T.takeWhile p <$> get
293+ t <- T.dropWhile p <$> get
241− continue <- inputSpansChunks (size t)
294+ put t
295+ when (T.null t) $ do
296+ input <- wantInput
242− when continue go
297+ when input go
243{-# INLINE skipWhile #-}
298{-# INLINE skipWhile #-}
244
299
245-- | Consume input as long as the predicate returns 'False'
300-- | Consume input as long as the predicate returns 'False'
@@ -249,9 +304,8 @@ skipWhile p = go
249-- predicate returns 'True' on the first character of input.
304-- predicate returns 'True' on the first character of input.
250--
305--
251-- /Note/: Because this parser does not fail, do not use it with
306-- /Note/: Because this parser does not fail, do not use it with
252−-- combinators such as 'Control.Applicative.many', because such
307+-- combinators such as 'many', because such parsers loop until a
253−-- parsers loop until a failure occurs. Careless use will thus result
308+-- failure occurs. Careless use will thus result in an infinite loop.
254−-- in an infinite loop.
255takeTill :: (Char -> Bool) -> Parser Text
309takeTill :: (Char -> Bool) -> Parser Text
256takeTill p = takeWhile (not . p)
310takeTill p = takeWhile (not . p)
257{-# INLINE takeTill #-}
311{-# INLINE takeTill #-}
@@ -263,29 +317,21 @@ takeTill p = takeWhile (not . p)
263-- predicate returns 'False' on the first character of input.
317-- predicate returns 'False' on the first character of input.
264--
318--
265-- /Note/: Because this parser does not fail, do not use it with
319-- /Note/: Because this parser does not fail, do not use it with
266−-- combinators such as 'Control.Applicative.many', because such
320+-- combinators such as 'many', because such parsers loop until a
267−-- parsers loop until a failure occurs. Careless use will thus result
321+-- failure occurs. Careless use will thus result in an infinite loop.
268−-- in an infinite loop.
269takeWhile :: (Char -> Bool) -> Parser Text
322takeWhile :: (Char -> Bool) -> Parser Text
270−takeWhile p = do
323+takeWhile p = (T.concat . reverse) `fmap` go []
271− h <- T.takeWhile p <$> get
272− continue <- inputSpansChunks (size h)
273− -- only use slow concat path if necessary
274− if continue
275− then takeWhileAcc p [h]
276− else return h
277−{-# INLINE takeWhile #-}
278−
279−takeWhileAcc :: (Char -> Bool) -> [Text] -> Parser Text
280−takeWhileAcc p = go
281 where
324 where
282 go acc = do
325 go acc = do
283− h <- T.takeWhile p <$> get
326+ (h,t) <- T.span p <$> get
284− continue <- inputSpansChunks (size h)
327+ put t
285− if continue
328+ if T.null t
329+ then do
330+ input <- wantInput
331+ if input
286− then go (h:acc)
332+ then go (h:acc)
287− else return $ concatReverse (h:acc)
333+ else return (h:acc)
288−{-# INLINE takeWhileAcc #-}
334+ else return (h:acc)
289
335
290takeRest :: Parser [Text]
336takeRest :: Parser [Text]
291takeRest = go []
337takeRest = go []
@@ -295,7 +341,7 @@ takeRest = go []
295 if input
341 if input
296 then do
342 then do
297 s <- get
343 s <- get
298− advance (size s)
344+ put T.empty
299 go (s:acc)
345 go (s:acc)
300 else return (reverse acc)
346 else return (reverse acc)
301
347
@@ -308,27 +354,7 @@ takeLazyText :: Parser L.Text
308takeLazyText = L.fromChunks `fmap` takeRest
354takeLazyText = L.fromChunks `fmap` takeRest
309
355
310data Scan s = Continue s
356data Scan s = Continue s
311− | Finished s {-# UNPACK #-} !Int Text
357+ | Finished {-# UNPACK #-} !Int T.Text
312−
313−scan_ :: (s -> [Text] -> Parser r) -> s -> (s -> Char -> Maybe s) -> Parser r
314−scan_ f s0 p = go [] s0
315− where
316− scanner s !n t =
317− case T.uncons t of
318− Just (c,t') -> case p s c of
319− Just s' -> scanner s' (n+1) t'
320− Nothing -> Finished s n t
321− Nothing -> Continue s
322− go acc s = do
323− input <- get
324− case scanner s 0 input of
325− Continue s' -> do continue <- inputSpansChunks (size input)
326− if continue
327− then go (input : acc) s'
328− else f s' (input : acc)
329− Finished s' n t -> do advance (size input - size t)
330− f s' (T.take n input : acc)
331−{-# INLINE scan_ #-}
332
358
333-- | A stateful scanner. The predicate consumes and transforms a
359-- | A stateful scanner. The predicate consumes and transforms a
334-- state argument, and each transformed state is passed to successive
360-- state argument, and each transformed state is passed to successive
@@ -339,19 +365,32 @@ scan_ f s0 p = go [] s0
339-- predicate returns 'Nothing' on the first character of input.
365-- predicate returns 'Nothing' on the first character of input.
340--
366--
341-- /Note/: Because this parser does not fail, do not use it with
367-- /Note/: Because this parser does not fail, do not use it with
342−-- combinators such as 'Control.Applicative.many', because such
368+-- combinators such as 'many', because such parsers loop until a
343−-- parsers loop until a failure occurs. Careless use will thus result
369+-- failure occurs. Careless use will thus result in an infinite loop.
344−-- in an infinite loop.
345scan :: s -> (s -> Char -> Maybe s) -> Parser Text
370scan :: s -> (s -> Char -> Maybe s) -> Parser Text
346−scan = scan_ $ \_ chunks -> return $! concatReverse chunks
371+scan s0 p = do
372+ chunks <- go [] s0
373+ case chunks of
374+ [x] -> return x
375+ xs -> return . T.concat . reverse $ xs
376+ where
377+ scanner s !n t =
378+ case T.uncons t of
379+ Just (c,t') -> case p s c of
380+ Just s' -> scanner s' (n+1) t'
381+ Nothing -> Finished n t
382+ Nothing -> Continue s
383+ go acc s = do
384+ input <- get
385+ case scanner s 0 input of
386+ Continue s' -> do put T.empty
387+ more <- wantInput
388+ if more
389+ then go (input : acc) s'
390+ else return (input : acc)
391+ Finished n t -> put t >> return (T.take n input : acc)
347{-# INLINE scan #-}
392{-# INLINE scan #-}
348
393
349−-- | Like 'scan', but generalized to return the final state of the
350−-- scanner.
351−runScanner :: s -> (s -> Char -> Maybe s) -> Parser (Text, s)
352−runScanner = scan_ $ \s xs -> let !sx = concatReverse xs in return (sx, s)
353−{-# INLINE runScanner #-}
354−
355-- | Consume input as long as the predicate returns 'True', and return
394-- | Consume input as long as the predicate returns 'True', and return
356-- the consumed input.
395-- the consumed input.
357--
396--
@@ -360,16 +399,13 @@ runScanner = scan_ $ \s xs -> let !sx = concatReverse xs in return (sx, s)
360-- 'True' or if there is no input left.
399-- 'True' or if there is no input left.
361takeWhile1 :: (Char -> Bool) -> Parser Text
400takeWhile1 :: (Char -> Bool) -> Parser Text
362takeWhile1 p = do
401takeWhile1 p = do
363− (`when` demandInput) =<< endOfChunk
402+ (`when` demandInput) =<< T.null <$> get
364− h <- T.takeWhile p <$> get
403+ (h,t) <- T.span p <$> get
365− let size' = size h
366− when (size' == 0) $ fail "takeWhile1"
404+ when (T.null h) $ fail "takeWhile1"
367− advance size'
405+ put t
368− eoc <- endOfChunk
406+ if T.null t
369− if eoc
407+ then (h<>) `fmap` takeWhile p
370− then takeWhileAcc p [h]
371 else return h
408 else return h
372−{-# INLINE takeWhile1 #-}
373
409
374-- | Match any character in a set.
410-- | Match any character in a set.
375--
411--
@@ -411,139 +447,83 @@ notChar c = satisfy (/= c) <?> "not " ++ show c
411-- end of input has been reached. Does not consume any input.
447-- end of input has been reached. Does not consume any input.
412--
448--
413-- /Note/: Because this parser does not fail, do not use it with
449-- /Note/: Because this parser does not fail, do not use it with
414−-- combinators such as 'Control.Applicative.many', because such
450+-- combinators such as 'many', because such parsers loop until a
415−-- parsers loop until a failure occurs. Careless use will thus result
451+-- failure occurs. Careless use will thus result in an infinite loop.
416−-- in an infinite loop.
417peekChar :: Parser (Maybe Char)
452peekChar :: Parser (Maybe Char)
418−peekChar = T.Parser $ \t pos more _lose succ ->
453+peekChar = T.Parser $ \i0 a0 m0 _kf ks ->
419− case () of
454+ if T.null (unI i0)
420− _| pos < lengthOf t ->
421− let T.Iter !c _ = Buf.iter t (fromPos pos)
422− in succ t pos more (Just c)
423− | more == Complete ->
455+ then if m0 == Complete
424− succ t pos more Nothing
456+ then ks i0 a0 m0 Nothing
425− | otherwise ->
457+ else let ks' i a m = let !c = unsafeHead (unI i)
426− let succ' t' pos' more' =
427− let T.Iter !c _ = Buf.iter t' (fromPos pos')
428− in succ t' pos' more' (Just c)
458+ in ks i a m (Just c)
429− lose' t' pos' more' = succ t' pos' more' Nothing
459+ kf' i a m = ks i a m Nothing
430− in prompt t pos more lose' succ'
460+ in prompt i0 a0 m0 kf' ks'
461+ else let !c = unsafeHead (unI i0)
462+ in ks i0 a0 m0 (Just c)
431{-# INLINE peekChar #-}
463{-# INLINE peekChar #-}
432
464
433-- | Match any character, to perform lookahead. Does not consume any
465-- | Match any character, to perform lookahead. Does not consume any
434-- input, but will fail if end of input has been reached.
466-- input, but will fail if end of input has been reached.
435peekChar' :: Parser Char
467peekChar' :: Parser Char
436peekChar' = do
468peekChar' = do
437− (_,s) <- ensure 1
469+ s <- ensure 1
438− return $! T.unsafeHead s
470+ return $! unsafeHead s
439{-# INLINE peekChar' #-}
471{-# INLINE peekChar' #-}
440
472
473+-- | Match only if all input has been consumed.
474+endOfInput :: Parser ()
475+endOfInput = T.Parser $ \i0 a0 m0 kf ks ->
476+ if T.null (unI i0)
477+ then if m0 == Complete
478+ then ks i0 a0 m0 ()
479+ else let kf' i1 a1 m1 _ _ = addS i0 a0 m0 i1 a1 m1 $
480+ \ i2 a2 m2 -> ks i2 a2 m2 ()
481+ ks' i1 a1 m1 _ = addS i0 a0 m0 i1 a1 m1 $
482+ \ i2 a2 m2 -> kf i2 a2 m2 []
483+ "endOfInput"
484+ in runParser demandInput i0 a0 m0 kf' ks'
485+ else kf i0 a0 m0 [] "endOfInput"
486+
487+-- | Return an indication of whether the end of input has been
488+-- reached.
489+atEnd :: Parser Bool
490+atEnd = not <$> wantInput
491+{-# INLINE atEnd #-}
492+
441-- | Match either a single newline character @\'\\n\'@, or a carriage
493-- | Match either a single newline character @\'\\n\'@, or a carriage
442-- return followed by a newline character @\"\\r\\n\"@.
494-- return followed by a newline character @\"\\r\\n\"@.
443endOfLine :: Parser ()
495endOfLine :: Parser ()
444endOfLine = (char '\n' >> return ()) <|> (string "\r\n" >> return ())
496endOfLine = (char '\n' >> return ()) <|> (string "\r\n" >> return ())
445
497
498+-- | Name the parser, in case failure occurs.
499+(<?>) :: Parser a
500+ -> String -- ^ the name to use if parsing fails
501+ -> Parser a
502+p <?> msg0 = T.Parser $ \i0 a0 m0 kf ks ->
503+ let kf' i a m strs msg = kf i a m (msg0:strs) msg
504+ in runParser p i0 a0 m0 kf' ks
505+{-# INLINE (<?>) #-}
506+infix 0 <?>
507+
446-- | Terminal failure continuation.
508-- | Terminal failure continuation.
447failK :: Failure a
509failK :: Failure a
448−failK t (Pos pos) _more stack msg = Fail (Buf.dropWord16 pos t) stack msg
510+failK i0 _a0 _m0 stack msg = Fail (unI i0) stack msg
449{-# INLINE failK #-}
511{-# INLINE failK #-}
450
512
451-- | Terminal success continuation.
513-- | Terminal success continuation.
452successK :: Success a a
514successK :: Success a a
453−successK t (Pos pos) _more a = Done (Buf.dropWord16 pos t) a
515+successK i0 _a0 _m0 a = Done (unI i0) a
454{-# INLINE successK #-}
516{-# INLINE successK #-}
455
517
456-- | Run a parser.
518-- | Run a parser.
457parse :: Parser a -> Text -> Result a
519parse :: Parser a -> Text -> Result a
458−parse m s = runParser m (buffer s) 0 Incomplete failK successK
520+parse m s = runParser m (I s) mempty Incomplete failK successK
459{-# INLINE parse #-}
521{-# INLINE parse #-}
460
522
461-- | Run a parser that cannot be resupplied via a 'Partial' result.
523-- | Run a parser that cannot be resupplied via a 'Partial' result.
462−--
463−-- This function does not force a parser to consume all of its input.
464−-- Instead, any residual input will be discarded. To force a parser
465−-- to consume all of its input, use something like this:
466−--
467−-- @
468−--'parseOnly' (myParser 'Control.Applicative.<*' 'endOfInput')
469−-- @
470parseOnly :: Parser a -> Text -> Either String a
524parseOnly :: Parser a -> Text -> Either String a
471−parseOnly m s = case runParser m (buffer s) 0 Complete failK successK of
525+parseOnly m s = case runParser m (I s) mempty Complete failK successK of
472− Fail _ [] err -> Left err
473− Fail _ ctxs err -> Left (intercalate " > " ctxs ++ ": " ++ err)
526+ Fail _ _ err -> Left err
474− Done _ a -> Right a
527+ Done _ a -> Right a
475− _ -> error "parseOnly: impossible error!"
528+ _ -> error "parseOnly: impossible error!"
476{-# INLINE parseOnly #-}
529{-# INLINE parseOnly #-}
477−
478−get :: Parser Text
479−get = T.Parser $ \t pos more _lose succ ->
480− succ t pos more (Buf.dropWord16 (fromPos pos) t)
481−{-# INLINE get #-}
482−
483−endOfChunk :: Parser Bool
484−endOfChunk = T.Parser $ \t pos more _lose succ ->
485− succ t pos more (pos == lengthOf t)
486−{-# INLINE endOfChunk #-}
487−
488−inputSpansChunks :: Pos -> Parser Bool
489−inputSpansChunks i = T.Parser $ \t pos_ more _lose succ ->
490− let pos = pos_ + i
491− in if pos < lengthOf t || more == Complete
492− then succ t pos more False
493− else let lose' t' pos' more' = succ t' pos' more' False
494− succ' t' pos' more' = succ t' pos' more' True
495− in prompt t pos more lose' succ'
496−{-# INLINE inputSpansChunks #-}
497−
498−advance :: Pos -> Parser ()
499−advance n = T.Parser $ \t pos more _lose succ -> succ t (pos+n) more ()
500−{-# INLINE advance #-}
501−
502−ensureSuspended :: Int -> Buffer -> Pos -> More
503− -> Failure r -> Success (Pos, Text) r
504− -> Result r
505−ensureSuspended n t pos more lose succ =
506− runParser (demandInput >> go) t pos more lose succ
507− where go = T.Parser $ \t' pos' more' lose' succ' ->
508− case lengthAtLeast pos' n t' of
509− Just n' -> succ' t' pos' more' (n', substring pos n' t')
510− Nothing -> runParser (demandInput >> go) t' pos' more' lose' succ'
511−
512−-- | If at least @n@ elements of input are available, return the
513−-- current input, otherwise fail.
514−ensure :: Int -> Parser (Pos, Text)
515−ensure n = T.Parser $ \t pos more lose succ ->
516− case lengthAtLeast pos n t of
517− Just n' -> succ t pos more (n', substring pos n' t)
518− -- The uncommon case is kept out-of-line to reduce code size:
519− Nothing -> ensureSuspended n t pos more lose succ
520−{-# INLINE ensure #-}
521−
522−-- | Return both the result of a parse and the portion of the input
523−-- that was consumed while it was being parsed.
524−match :: Parser a -> Parser (Text, a)
525−match p = T.Parser $ \t pos more lose succ ->
526− let succ' t' pos' more' a = succ t' pos' more'
527− (substring pos (pos'-pos) t', a)
528− in runParser p t pos more lose succ'
529−
530−-- | Ensure that at least @n@ code points of input are available.
531−-- Returns the number of words consumed while traversing.
532−lengthAtLeast :: Pos -> Int -> Buffer -> Maybe Pos
533−lengthAtLeast pos n t = go 0 (fromPos pos)
534− where go i !p
535− | i == n = Just (Pos p - pos)
536− | p == len = Nothing
537− | otherwise = go (i+1) (p + Buf.iter_ t p)
538− Pos len = lengthOf t
539−{-# INLINE lengthAtLeast #-}
540−
541−substring :: Pos -> Pos -> Buffer -> Text
542−substring (Pos pos) (Pos n) = Buf.substring pos n
543−{-# INLINE substring #-}
544−
545−lengthOf :: Buffer -> Pos
546−lengthOf = Pos . Buf.length
547−
548−size :: Text -> Pos
549−size (Text _ _ l) = Pos l
Data/Attoparsec/Text/Lazy.hs+15−20
@@ -1,19 +1,13 @@
1−{-# LANGUAGE CPP #-}
2−#if __GLASGOW_HASKELL__ >= 702
3−{-# LANGUAGE Trustworthy #-} -- Imports internal modules
4−#endif
5−
6−{-# OPTIONS_GHC -fno-warn-warnings-deprecations #-}
7-- |
1-- |
8-- Module : Data.Attoparsec.Text.Lazy
2-- Module : Data.Attoparsec.Text.Lazy
9−-- Copyright : Bryan O'Sullivan 2007-2015
3+-- Copyright : Bryan O'Sullivan 2011
10-- License : BSD3
4-- License : BSD3
11--
5--
12-- Maintainer : bos@serpentine.com
6-- Maintainer : bos@serpentine.com
13-- Stability : experimental
7-- Stability : experimental
14-- Portability : unknown
8-- Portability : unknown
15--
9--
16−-- Simple, efficient combinator parsing that can consume lazy 'Text'
10+-- Simple, efficient combinator parsing for lazy 'Text'
17-- strings, loosely based on the Parsec library.
11-- strings, loosely based on the Parsec library.
18--
12--
19-- This is essentially the same code as in the 'Data.Attoparsec.Text'
13-- This is essentially the same code as in the 'Data.Attoparsec.Text'
@@ -22,11 +16,10 @@
22-- more input to be fed in. Think of this as suitable for use with a
16-- more input to be fed in. Think of this as suitable for use with a
23-- lazily read file, e.g. via 'L.readFile' or 'L.hGetContents'.
17-- lazily read file, e.g. via 'L.readFile' or 'L.hGetContents'.
24--
18--
25−-- /Note:/ The various parser functions and combinators such as
26−-- 'string' still expect /strict/ 'T.Text' parameters, and return
27−-- strict 'T.Text' results. Behind the scenes, strict 'T.Text' values
19+-- Behind the scenes, strict 'T.Text' values are still used
28−-- are still used internally to store parser input and manipulate it
20+-- internally to store parser input and manipulate it efficiently.
29−-- efficiently.
21+-- High-performance parsers such as 'string' still expect strict
22+-- 'T.Text' parameters.
30
23
31module Data.Attoparsec.Text.Lazy
24module Data.Attoparsec.Text.Lazy
32 (
25 (
@@ -41,7 +34,6 @@ module Data.Attoparsec.Text.Lazy
41 ) where
34 ) where
42
35
43import Control.DeepSeq (NFData(rnf))
36import Control.DeepSeq (NFData(rnf))
44−import Data.List (intercalate)
45import Data.Text.Lazy.Internal (Text(..), chunk)
37import Data.Text.Lazy.Internal (Text(..), chunk)
46import qualified Data.Attoparsec.Internal.Types as T
38import qualified Data.Attoparsec.Internal.Types as T
47import qualified Data.Attoparsec.Text as A
39import qualified Data.Attoparsec.Text as A
@@ -51,16 +43,20 @@ import Data.Attoparsec.Text hiding (IResult(..), Result, eitherResult,
51
43
52-- | The result of a parse.
44-- | The result of a parse.
53data Result r = Fail Text [String] String
45data Result r = Fail Text [String] String
54− -- ^ The parse failed. The 'Text' is the input
46+ -- ^ The parse failed. The 'ByteString' is the input
55 -- that had not yet been consumed when the failure
47 -- that had not yet been consumed when the failure
56 -- occurred. The @[@'String'@]@ is a list of contexts
48 -- occurred. The @[@'String'@]@ is a list of contexts
57 -- in which the error occurred. The 'String' is the
49 -- in which the error occurred. The 'String' is the
58 -- message describing the error, if any.
50 -- message describing the error, if any.
59 | Done Text r
51 | Done Text r
60− -- ^ The parse succeeded. The 'Text' is the
52+ -- ^ The parse succeeded. The 'ByteString' is the
61 -- input that had not yet been consumed (if any) when
53 -- input that had not yet been consumed (if any) when
62 -- the parse succeeded.
54 -- the parse succeeded.
63− deriving (Show)
55+
56+instance Show r => Show (Result r) where
57+ show (Fail bs stk msg) =
58+ "Fail " ++ show bs ++ " " ++ show stk ++ " " ++ show msg
59+ show (Done bs r) = "Done " ++ show bs ++ " " ++ show r
64
60
65instance NFData r => NFData (Result r) where
61instance NFData r => NFData (Result r) where
66 rnf (Fail bs ctxs msg) = rnf bs `seq` rnf ctxs `seq` rnf msg
62 rnf (Fail bs ctxs msg) = rnf bs `seq` rnf ctxs `seq` rnf msg
@@ -96,6 +92,5 @@ maybeResult _ = Nothing
96
92
97-- | Convert a 'Result' value to an 'Either' value.
93-- | Convert a 'Result' value to an 'Either' value.
98eitherResult :: Result r -> Either String r
94eitherResult :: Result r -> Either String r
99−eitherResult (Done _ r) = Right r
95+eitherResult (Done _ r) = Right r
100−eitherResult (Fail _ [] msg) = Left msg
96+eitherResult (Fail _ _ msg) = Left msg
101−eitherResult (Fail _ ctxs msg) = Left (intercalate " > " ctxs ++ ": " ++ msg)
Data/Attoparsec/Types.hs+2−3
@@ -1,6 +1,6 @@
1-- |
1-- |
2-- Module : Data.Attoparsec.Types
2-- Module : Data.Attoparsec.Types
3−-- Copyright : Bryan O'Sullivan 2007-2015
3+-- Copyright : Bryan O'Sullivan 2011
4-- License : BSD3
4-- License : BSD3
5--
5--
6-- Maintainer : bos@serpentine.com
6-- Maintainer : bos@serpentine.com
@@ -14,7 +14,6 @@ module Data.Attoparsec.Types
14 (
14 (
15 Parser
15 Parser
16 , IResult(..)
16 , IResult(..)
17− , Chunk(chunkElemToChar)
18 ) where
17 ) where
19
18
20−import Data.Attoparsec.Internal.Types (Parser(..), IResult(..), Chunk(..))
19+import Data.Attoparsec.Internal.Types (Parser(..), IResult(..))
Data/Attoparsec/Zepto.hs+46−88
@@ -1,12 +1,8 @@
1−{-# LANGUAGE CPP #-}
1+{-# LANGUAGE BangPatterns, MagicHash, UnboxedTuples #-}
2−#if __GLASGOW_HASKELL__ >= 702
3−{-# LANGUAGE Trustworthy #-} -- Data.ByteString.Unsafe
4−#endif
5−{-# LANGUAGE BangPatterns #-}
6
2
7-- |
3-- |
8-- Module : Data.Attoparsec.Zepto
4-- Module : Data.Attoparsec.Zepto
9−-- Copyright : Bryan O'Sullivan 2007-2015
5+-- Copyright : Bryan O'Sullivan 2011
10-- License : BSD3
6-- License : BSD3
11--
7--
12-- Maintainer : bos@serpentine.com
8-- Maintainer : bos@serpentine.com
@@ -16,150 +12,112 @@
16-- A tiny, highly specialized combinator parser for 'B.ByteString'
12-- A tiny, highly specialized combinator parser for 'B.ByteString'
17-- strings.
13-- strings.
18--
14--
19−-- While the main attoparsec module generally performs well, this
15+-- While the main Attoparsec module generally performs well, this
20-- module is particularly fast for simple non-recursive loops that
16-- module is particularly fast for simple non-recursive loops that
21-- should not normally result in failed parses.
17-- should not normally result in failed parses.
22--
18--
23-- /Warning/: on more complex inputs involving recursion or failure,
19-- /Warning/: on more complex inputs involving recursion or failure,
24-- parsers based on this module may be as much as /ten times slower/
20-- parsers based on this module may be as much as /ten times slower/
25−-- than regular attoparsec! You should /only/ use this module when you
21+-- than regular Attoparsec! You should /only/ use this module when you
26-- have benchmarks that prove that its use speeds your code up.
22-- have benchmarks that prove that its use speeds your code up.
27module Data.Attoparsec.Zepto
23module Data.Attoparsec.Zepto
28 (
24 (
29 Parser
25 Parser
30− , ZeptoT
31 , parse
26 , parse
32− , parseT
33 , atEnd
27 , atEnd
34 , string
28 , string
35 , take
29 , take
36 , takeWhile
30 , takeWhile
37 ) where
31 ) where
38
32
39−import Control.Applicative
40−import Control.Monad (MonadPlus(..), ap)
41−import qualified Control.Monad.Fail as Fail
42−import Control.Monad.IO.Class (MonadIO(..))
43−import Data.ByteString (ByteString)
44−import Data.Functor.Identity (Identity(runIdentity))
45−import Data.Monoid as Mon (Monoid(..))
46−import Data.Semigroup (Semigroup(..))
47import Data.Word (Word8)
33import Data.Word (Word8)
48−import Prelude hiding (take, takeWhile)
34+import Control.Applicative
35+import Control.Monad
36+import Data.Monoid
49import qualified Data.ByteString as B
37import qualified Data.ByteString as B
50import qualified Data.ByteString.Unsafe as B
38import qualified Data.ByteString.Unsafe as B
39+import Data.ByteString (ByteString)
40+import Prelude hiding (take, takeWhile)
51
41
52newtype S = S {
42newtype S = S {
53 input :: ByteString
43 input :: ByteString
54 }
44 }
55
45
56data Result a = Fail String
46data Result a = Fail String
57− | OK !a S
47+ | OK !a
58
48
59-- | A simple parser.
49-- | A simple parser.
60--
50--
61-- This monad is strict in its state, and the monadic bind operator
51-- This monad is strict in its state, and the monadic bind operator
62-- ('>>=') evaluates each result to weak head normal form before
52-- ('>>=') evaluates each result to weak head normal form before
63-- passing it along.
53-- passing it along.
64−newtype ZeptoT m a = Parser {
54+newtype Parser a = Parser {
65− runParser :: S -> m (Result a)
55+ runParser :: S -> (# Result a, S #)
66 }
56 }
67
57
68−type Parser a = ZeptoT Identity a
69−
70−instance Monad m => Functor (ZeptoT m) where
58+instance Functor Parser where
71− fmap f m = Parser $ \s -> do
59+ fmap f m = Parser $ \s -> case runParser m s of
72− result <- runParser m s
73− case result of
74− OK a s' -> return (OK (f a) s')
60+ (# OK a, s' #) -> (# OK (f a), s' #)
75− Fail err -> return (Fail err)
61+ (# Fail err, s' #) -> (# Fail err, s' #)
76 {-# INLINE fmap #-}
62 {-# INLINE fmap #-}
77
63
78−instance MonadIO m => MonadIO (ZeptoT m) where
64+instance Monad Parser where
79− liftIO act = Parser $ \s -> do
65+ return a = Parser $ \s -> (# OK a, s #)
80− result <- liftIO act
81− return (OK result s)
82− {-# INLINE liftIO #-}
83−
84−instance Monad m => Monad (ZeptoT m) where
85− return = pure
86 {-# INLINE return #-}
66 {-# INLINE return #-}
87
67
88− m >>= k = Parser $ \s -> do
68+ m >>= k = Parser $ \s -> case runParser m s of
89− result <- runParser m s
90− case result of
91− OK a s' -> runParser (k a) s'
69+ (# OK a, s' #) -> runParser (k a) s'
92− Fail err -> return (Fail err)
70+ (# Fail err, s' #) -> (# Fail err, s' #)
93 {-# INLINE (>>=) #-}
71 {-# INLINE (>>=) #-}
94
72
95−#if !(MIN_VERSION_base(4,13,0))
96− fail = Fail.fail
73+ fail msg = Parser $ \s -> (# Fail msg, s #)
97− {-# INLINE fail #-}
98−#endif
99
74
100−instance Monad m => Fail.MonadFail (ZeptoT m) where
101− fail msg = Parser $ \_ -> return (Fail msg)
102− {-# INLINE fail #-}
103−
104−instance Monad m => MonadPlus (ZeptoT m) where
75+instance MonadPlus Parser where
105 mzero = fail "mzero"
76 mzero = fail "mzero"
106 {-# INLINE mzero #-}
77 {-# INLINE mzero #-}
107
78
108− mplus a b = Parser $ \s -> do
79+ mplus a b = Parser $ \s ->
109− result <- runParser a s
80+ case runParser a s of
110− case result of
81+ (# ok@(OK _), s' #) -> (# ok, s' #)
82+ (# _, _ #) -> case runParser b s of
111− ok@(OK _ _) -> return ok
83+ (# ok@(OK _), s'' #) -> (# ok, s'' #)
112− _ -> runParser b s
84+ (# err, s'' #) -> (# err, s'' #)
113 {-# INLINE mplus #-}
85 {-# INLINE mplus #-}
114
86
115−instance (Monad m) => Applicative (ZeptoT m) where
87+instance Applicative Parser where
116− pure a = Parser $ \s -> return (OK a s)
88+ pure = return
117 {-# INLINE pure #-}
89 {-# INLINE pure #-}
118 (<*>) = ap
90 (<*>) = ap
119 {-# INLINE (<*>) #-}
91 {-# INLINE (<*>) #-}
120
92
121−gets :: Monad m => (S -> a) -> ZeptoT m a
93+gets :: (S -> a) -> Parser a
122−gets f = Parser $ \s -> return (OK (f s) s)
94+gets f = Parser $ \s -> (# OK (f s), s #)
123{-# INLINE gets #-}
95{-# INLINE gets #-}
124
96
125−put :: Monad m => S -> ZeptoT m ()
97+put :: S -> Parser ()
126−put s = Parser $ \_ -> return (OK () s)
98+put s = Parser $ \_ -> (# OK (), s #)
127{-# INLINE put #-}
99{-# INLINE put #-}
128
100
129-- | Run a parser.
101-- | Run a parser.
130parse :: Parser a -> ByteString -> Either String a
102parse :: Parser a -> ByteString -> Either String a
131−parse p bs = case runIdentity (runParser p (S bs)) of
103+parse p bs = case runParser p (S bs) of
132− (OK a _) -> Right a
104+ (# OK a, _ #) -> Right a
133− (Fail err) -> Left err
134−{-# INLINE parse #-}
135−
136−-- | Run a parser on top of the given base monad.
137−parseT :: Monad m => ZeptoT m a -> ByteString -> m (Either String a)
138−parseT p bs = do
139− result <- runParser p (S bs)
140− case result of
141− OK a _ -> return (Right a)
142− Fail err -> return (Left err)
105+ (# Fail err, _ #) -> Left err
143−{-# INLINE parseT #-}
106+
144−
107+instance Monoid (Parser a) where
145−instance Monad m => Semigroup (ZeptoT m a) where
146− (<>) = mplus
147− {-# INLINE (<>) #-}
148−
149−instance Monad m => Mon.Monoid (ZeptoT m a) where
150 mempty = fail "mempty"
108 mempty = fail "mempty"
151 {-# INLINE mempty #-}
109 {-# INLINE mempty #-}
152− mappend = (<>)
110+ mappend = mplus
153 {-# INLINE mappend #-}
111 {-# INLINE mappend #-}
154
112
155−instance Monad m => Alternative (ZeptoT m) where
113+instance Alternative Parser where
156 empty = fail "empty"
114 empty = fail "empty"
157 {-# INLINE empty #-}
115 {-# INLINE empty #-}
158 (<|>) = mplus
116 (<|>) = mplus
159 {-# INLINE (<|>) #-}
117 {-# INLINE (<|>) #-}
160
118
161-- | Consume input while the predicate returns 'True'.
119-- | Consume input while the predicate returns 'True'.
162−takeWhile :: Monad m => (Word8 -> Bool) -> ZeptoT m ByteString
120+takeWhile :: (Word8 -> Bool) -> Parser ByteString
163takeWhile p = do
121takeWhile p = do
164 (h,t) <- gets (B.span p . input)
122 (h,t) <- gets (B.span p . input)
165 put (S t)
123 put (S t)
@@ -167,7 +125,7 @@ takeWhile p = do
167{-# INLINE takeWhile #-}
125{-# INLINE takeWhile #-}
168
126
169-- | Consume @n@ bytes of input.
127-- | Consume @n@ bytes of input.
170−take :: Monad m => Int -> ZeptoT m ByteString
128+take :: Int -> Parser ByteString
171take !n = do
129take !n = do
172 s <- gets input
130 s <- gets input
173 if B.length s >= n
131 if B.length s >= n
@@ -176,7 +134,7 @@ take !n = do
176{-# INLINE take #-}
134{-# INLINE take #-}
177
135
178-- | Match a string exactly.
136-- | Match a string exactly.
179−string :: Monad m => ByteString -> ZeptoT m ()
137+string :: ByteString -> Parser ()
180string s = do
138string s = do
181 i <- gets input
139 i <- gets input
182 if s `B.isPrefixOf` i
140 if s `B.isPrefixOf` i
@@ -185,7 +143,7 @@ string s = do
185{-# INLINE string #-}
143{-# INLINE string #-}
186
144
187-- | Indicate whether the end of the input has been reached.
145-- | Indicate whether the end of the input has been reached.
188−atEnd :: Monad m => ZeptoT m Bool
146+atEnd :: Parser Bool
189atEnd = do
147atEnd = do
190 i <- gets input
148 i <- gets input
191 return $! B.null i
149 return $! B.null i
README.markdown+6
@@ -16,6 +16,12 @@ Master [git repository](https://github.com/bos/attoparsec):
16
16
17* `git clone git://github.com/bos/attoparsec.git`
17* `git clone git://github.com/bos/attoparsec.git`
18
18
19+There's also a [Mercurial mirror](https://bitbucket.org/bos/attoparsec):
20+
21+* `hg clone https://bitbucket.org/bos/attoparsec`
22+
23+(You can create and contribute changes using either Mercurial or git.)
24+
19Authors
25Authors
20-------
26-------
21
27
attoparsec.cabal+36−120
@@ -1,13 +1,12 @@
1name: attoparsec
1name: attoparsec
2−version: 0.13.2.2
2+version: 0.11.0.0
3−x-revision: 3
4license: BSD3
3license: BSD3
5license-file: LICENSE
4license-file: LICENSE
6category: Text, Parsing
5category: Text, Parsing
7author: Bryan O'Sullivan <bos@serpentine.com>
6author: Bryan O'Sullivan <bos@serpentine.com>
8−maintainer: Bryan O'Sullivan <bos@serpentine.com>, Ben Gamari <ben@smart-cactus.org>
7+maintainer: Bryan O'Sullivan <bos@serpentine.com>
9stability: experimental
8stability: experimental
10−tested-with: GHC == 7.0.4, GHC == 7.2.2, GHC == 7.4.2, GHC ==7.6.3, GHC ==7.8.4, GHC ==7.10.3, GHC ==8.0.2, GHC ==8.2.2, GHC==8.4.4, GHC==8.6.5, GHC==8.8.1
9+tested-with: GHC == 7.0, GHC == 7.2, GHC == 7.4, GHC == 7.6, GHC == 7.8
11synopsis: Fast combinator parsing for bytestrings and text
10synopsis: Fast combinator parsing for bytestrings and text
12cabal-version: >= 1.8
11cabal-version: >= 1.8
13homepage: https://github.com/bos/attoparsec
12homepage: https://github.com/bos/attoparsec
@@ -19,42 +18,33 @@ description:
19 file formats.
18 file formats.
20extra-source-files:
19extra-source-files:
21 README.markdown
20 README.markdown
22− benchmarks/*.cabal
21+ benchmarks/Benchmarks.hs
23− benchmarks/*.hs
24− benchmarks/*.txt
25− benchmarks/json-data/*.json
26 benchmarks/Makefile
22 benchmarks/Makefile
23+ benchmarks/Tiny.hs
24+ benchmarks/attoparsec-benchmarks.cabal
27 benchmarks/med.txt.bz2
25 benchmarks/med.txt.bz2
28− changelog.md
29− examples/*.c
30− examples/*.hs
31 examples/Makefile
26 examples/Makefile
27+ examples/Parsec_RFC2616.hs
28+ examples/RFC2616.hs
29+ examples/TestRFC2616.hs
30+ examples/rfc2616.c
32− tests/*.hs
31+ tests/Makefile
32+ tests/QC.hs
33 tests/QC/*.hs
33 tests/QC/*.hs
34− tests/QC/IPv6/*.hs
34+ tests/TestFastSet.hs
35
35
36Flag developer
36Flag developer
37 Description: Whether to build the library in development mode
37 Description: Whether to build the library in development mode
38 Default: False
38 Default: False
39− Manual: True
40
39
41library
40library
42 build-depends: array,
41 build-depends: array,
43− base >= 4.3 && < 5,
42+ base >= 3 && < 5,
44 bytestring,
43 bytestring,
45 containers,
44 containers,
46 deepseq,
45 deepseq,
46+ text >= 0.11.1.5,
47− scientific >= 0.3.1 && < 0.4,
47+ scientific >= 0.0.0.2
48− transformers >= 0.2 && (< 0.4 || >= 0.4.1.0) && < 0.6,
49− text >= 1.1.1.3
50− if impl(ghc < 7.4)
51− build-depends:
52− bytestring < 0.10.4.0
53−
54− if !impl(ghc >= 8.0)
55− -- Data.Semigroup && Control.Monad.Fail are available in base-4.9+
56− build-depends: fail == 4.9.*,
57− semigroups >=0.16.1 && <0.20
58
48
59 exposed-modules: Data.Attoparsec
49 exposed-modules: Data.Attoparsec
60 Data.Attoparsec.ByteString
50 Data.Attoparsec.ByteString
@@ -62,133 +52,59 @@ library
62 Data.Attoparsec.ByteString.Lazy
52 Data.Attoparsec.ByteString.Lazy
63 Data.Attoparsec.Char8
53 Data.Attoparsec.Char8
64 Data.Attoparsec.Combinator
54 Data.Attoparsec.Combinator
65− Data.Attoparsec.Internal
66− Data.Attoparsec.Internal.Types
67 Data.Attoparsec.Lazy
55 Data.Attoparsec.Lazy
68 Data.Attoparsec.Number
56 Data.Attoparsec.Number
69 Data.Attoparsec.Text
57 Data.Attoparsec.Text
70 Data.Attoparsec.Text.Lazy
58 Data.Attoparsec.Text.Lazy
71 Data.Attoparsec.Types
59 Data.Attoparsec.Types
72 Data.Attoparsec.Zepto
60 Data.Attoparsec.Zepto
73− other-modules: Data.Attoparsec.ByteString.Buffer
61+ other-modules: Data.Attoparsec.ByteString.FastSet
74− Data.Attoparsec.ByteString.FastSet
75 Data.Attoparsec.ByteString.Internal
62 Data.Attoparsec.ByteString.Internal
76− Data.Attoparsec.Internal.Fhthagn
63+ Data.Attoparsec.Internal
77− Data.Attoparsec.Text.Buffer
64+ Data.Attoparsec.Internal.Types
78 Data.Attoparsec.Text.FastSet
65 Data.Attoparsec.Text.FastSet
79 Data.Attoparsec.Text.Internal
66 Data.Attoparsec.Text.Internal
80 ghc-options: -O2 -Wall
67 ghc-options: -O2 -Wall
81
68
82 if flag(developer)
69 if flag(developer)
83 ghc-prof-options: -auto-all
70 ghc-prof-options: -auto-all
84− ghc-options: -Werror
85
71
86test-suite tests
72test-suite tests
87 type: exitcode-stdio-1.0
73 type: exitcode-stdio-1.0
88− hs-source-dirs: tests .
74+ hs-source-dirs: tests
89 main-is: QC.hs
75 main-is: QC.hs
90− other-modules: QC.Buffer
76+ other-modules: QC.ByteString
91− QC.ByteString
92− QC.Combinator
93− QC.Common
94− QC.IPv6.Internal
95− QC.IPv6.Types
96− QC.Rechunked
97− QC.Simple
98 QC.Text
77 QC.Text
99− QC.Text.FastSet
100− QC.Text.Regressions
101−
102− other-modules: Data.Attoparsec.ByteString
103− Data.Attoparsec.ByteString.Buffer
104− Data.Attoparsec.ByteString.Char8
105− Data.Attoparsec.ByteString.FastSet
106− Data.Attoparsec.ByteString.Internal
107− Data.Attoparsec.ByteString.Lazy
108− Data.Attoparsec.Combinator
109− Data.Attoparsec.Internal
110− Data.Attoparsec.Internal.Fhthagn
111− Data.Attoparsec.Internal.Types
112− Data.Attoparsec.Number
113− Data.Attoparsec.Text
114− Data.Attoparsec.Text.Buffer
115− Data.Attoparsec.Text.FastSet
116− Data.Attoparsec.Text.Internal
117− Data.Attoparsec.Text.Lazy
118− Data.Attoparsec.Zepto
119
78
120 ghc-options:
79 ghc-options:
121 -Wall -threaded -rtsopts
80 -Wall -threaded -rtsopts
122
81
123− if flag(developer)
124− ghc-options: -Werror
125−
126 build-depends:
82 build-depends:
127− array,
83+ attoparsec,
128− base,
84+ base >= 4 && < 5,
129 bytestring,
85 bytestring,
130− deepseq >= 1.1,
131− QuickCheck >= 2.13.2 && < 2.14,
86+ QuickCheck >= 2.4,
132− quickcheck-unicode,
87+ test-framework >= 0.4,
133− scientific,
88+ test-framework-quickcheck2 >= 0.2,
134− tasty >= 0.11,
135− tasty-quickcheck >= 0.8,
136− text,
89+ text
137− transformers >= 0.2 && (< 0.4 || >= 0.4.1.0) && < 0.6,
138− vector
139−
140− if !impl(ghc >= 8.0)
141− -- Data.Semigroup && Control.Monad.Fail are available in base-4.9+
142− build-depends: fail == 4.9.*,
143− semigroups >=0.16.1 && <0.20
144
90
145benchmark benchmarks
91benchmark benchmarks
146 type: exitcode-stdio-1.0
92 type: exitcode-stdio-1.0
147− hs-source-dirs: benchmarks benchmarks/warp-3.0.1.1 .
93+ hs-source-dirs: benchmarks
148− ghc-options: -O2 -Wall -rtsopts
149 main-is: Benchmarks.hs
94 main-is: Benchmarks.hs
150− other-modules:
151− Common
152− HeadersByteString
153− HeadersByteString.Atto
154− HeadersText
155− Links
156− Network.Wai.Handler.Warp.ReadInt
157− Network.Wai.Handler.Warp.RequestHeader
158− Numbers
159− Sets
160− TextFastSet
161− Warp
162− ghc-options: -O2 -Wall
163−
164− if flag(developer)
165− ghc-options: -Werror
166−
167 build-depends:
95 build-depends:
168− array,
96+ attoparsec,
169− base == 4.*,
97+ base,
170− bytestring >= 0.10.4.0,
98+ bytestring,
171− case-insensitive,
172− containers,
173− criterion >= 1.0,
99+ criterion >= 0.5,
174 deepseq >= 1.1,
100 deepseq >= 1.1,
175− directory,
176− filepath,
177− ghc-prim,
178− http-types,
179 parsec >= 3.1.2,
101 parsec >= 3.1.2,
180− scientific,
181− text >= 1.1.1.0,
102+ text
182− transformers >= 0.2 && (< 0.4 || >= 0.4.1.0) && < 0.6,
183− unordered-containers,
184− vector
185−
186− if !impl(ghc >= 8.0)
187− -- Data.Semigroup && Control.Monad.Fail are available in base-4.9+
188− build-depends: fail == 4.9.*,
189− semigroups >=0.16.1 && <0.19
190
103
191source-repository head
104source-repository head
192 type: git
105 type: git
193 location: https://github.com/bos/attoparsec
106 location: https://github.com/bos/attoparsec
194
107
108+source-repository head
109+ type: mercurial
110+ location: https://bitbucket.org/bos/attoparsec
benchmarks/Aeson.hsdeleted−353
@@ -1,353 +0,0 @@
1−{-# LANGUAGE BangPatterns, CPP, OverloadedStrings #-}
2−{-# OPTIONS_GHC -fno-warn-unused-binds #-}
3−
4−module Aeson
5− (
6− aeson
7− , value'
8− ) where
9−
10−import Data.ByteString.Builder
11− (Builder, byteString, toLazyByteString, charUtf8, word8)
12−
13−#if !MIN_VERSION_base(4,8,0)
14−import Control.Applicative ((*>), (<$>), (<*), pure)
15−import Data.Monoid (mappend, mempty)
16−#endif
17−
18−import Common (pathTo)
19−import Control.Applicative (liftA2)
20−import Control.DeepSeq (NFData(..))
21−import Control.Monad (forM)
22−import Data.Attoparsec.ByteString.Char8 (Parser, char, endOfInput, scientific,
23− skipSpace, string)
24−import Data.Bits ((.|.), shiftL)
25−import Data.ByteString (ByteString)
26−import Data.Char (chr)
27−import Data.List (sort)
28−import Data.Scientific (Scientific)
29−import Data.Text (Text)
30−import Data.Text.Encoding (decodeUtf8')
31−import Data.Vector as Vector (Vector, foldl', fromList)
32−import Data.Word (Word8)
33−import System.Directory (getDirectoryContents)
34−import System.FilePath ((</>), dropExtension)
35−import qualified Data.Attoparsec.ByteString as A
36−import qualified Data.Attoparsec.Lazy as L
37−import qualified Data.Attoparsec.Zepto as Z
38−import qualified Data.ByteString as B
39−import qualified Data.ByteString.Lazy as L
40−import qualified Data.ByteString.Unsafe as B
41−import qualified Data.HashMap.Strict as H
42−import Criterion.Main
43−
44−#define BACKSLASH 92
45−#define CLOSE_CURLY 125
46−#define CLOSE_SQUARE 93
47−#define COMMA 44
48−#define DOUBLE_QUOTE 34
49−#define OPEN_CURLY 123
50−#define OPEN_SQUARE 91
51−#define C_0 48
52−#define C_9 57
53−#define C_A 65
54−#define C_F 70
55−#define C_a 97
56−#define C_f 102
57−#define C_n 110
58−#define C_t 116
59−
60−data Result a = Error String
61− | Success a
62− deriving (Eq, Show)
63−
64−
65−-- | A JSON \"object\" (key\/value map).
66−type Object = H.HashMap Text Value
67−
68−-- | A JSON \"array\" (sequence).
69−type Array = Vector Value
70−
71−-- | A JSON value represented as a Haskell value.
72−data Value = Object !Object
73− | Array !Array
74− | String !Text
75− | Number !Scientific
76− | Bool !Bool
77− | Null
78− deriving (Eq, Show)
79−
80−instance NFData Value where
81− rnf (Object o) = rnf o
82− rnf (Array a) = Vector.foldl' (\x y -> rnf y `seq` x) () a
83− rnf (String s) = rnf s
84− rnf (Number n) = rnf n
85− rnf (Bool b) = rnf b
86− rnf Null = ()
87−
88−-- | Parse a top-level JSON value. This must be either an object or
89−-- an array, per RFC 4627.
90−--
91−-- The conversion of a parsed value to a Haskell value is deferred
92−-- until the Haskell value is needed. This may improve performance if
93−-- only a subset of the results of conversions are needed, but at a
94−-- cost in thunk allocation.
95−json :: Parser Value
96−json = json_ object_ array_
97−
98−-- | Parse a top-level JSON value. This must be either an object or
99−-- an array, per RFC 4627.
100−--
101−-- This is a strict version of 'json' which avoids building up thunks
102−-- during parsing; it performs all conversions immediately. Prefer
103−-- this version if most of the JSON data needs to be accessed.
104−json' :: Parser Value
105−json' = json_ object_' array_'
106−
107−json_ :: Parser Value -> Parser Value -> Parser Value
108−json_ obj ary = do
109− w <- skipSpace *> A.satisfy (\w -> w == OPEN_CURLY || w == OPEN_SQUARE)
110− if w == OPEN_CURLY
111− then obj
112− else ary
113−{-# INLINE json_ #-}
114−
115−object_ :: Parser Value
116−object_ = {-# SCC "object_" #-} Object <$> objectValues jstring value
117−
118−object_' :: Parser Value
119−object_' = {-# SCC "object_'" #-} do
120− !vals <- objectValues jstring' value'
121− return (Object vals)
122− where
123− jstring' = do
124− !s <- jstring
125− return s
126−
127−objectValues :: Parser Text -> Parser Value -> Parser (H.HashMap Text Value)
128−objectValues str val = do
129− skipSpace
130− let pair = liftA2 (,) (str <* skipSpace) (char ':' *> skipSpace *> val)
131− H.fromList <$> commaSeparated pair CLOSE_CURLY
132−{-# INLINE objectValues #-}
133−
134−array_ :: Parser Value
135−array_ = {-# SCC "array_" #-} Array <$> arrayValues value
136−
137−array_' :: Parser Value
138−array_' = {-# SCC "array_'" #-} do
139− !vals <- arrayValues value'
140− return (Array vals)
141−
142−commaSeparated :: Parser a -> Word8 -> Parser [a]
143−commaSeparated item endByte = do
144− w <- A.peekWord8'
145− if w == endByte
146− then A.anyWord8 >> return []
147− else loop
148− where
149− loop = do
150− v <- item <* skipSpace
151− ch <- A.satisfy $ \w -> w == COMMA || w == endByte
152− if ch == COMMA
153− then skipSpace >> (v:) <$> loop
154− else return [v]
155−{-# INLINE commaSeparated #-}
156−
157−arrayValues :: Parser Value -> Parser (Vector Value)
158−arrayValues val = do
159− skipSpace
160− Vector.fromList <$> commaSeparated val CLOSE_SQUARE
161−{-# INLINE arrayValues #-}
162−
163−-- | Parse any JSON value. You should usually 'json' in preference to
164−-- this function, as this function relaxes the object-or-array
165−-- requirement of RFC 4627.
166−--
167−-- In particular, be careful in using this function if you think your
168−-- code might interoperate with Javascript. A na&#xef;ve Javascript
169−-- library that parses JSON data using @eval@ is vulnerable to attack
170−-- unless the encoded data represents an object or an array. JSON
171−-- implementations in other languages conform to that same restriction
172−-- to preserve interoperability and security.
173−value :: Parser Value
174−value = do
175− w <- A.peekWord8'
176− case w of
177− DOUBLE_QUOTE -> A.anyWord8 *> (String <$> jstring_)
178− OPEN_CURLY -> A.anyWord8 *> object_
179− OPEN_SQUARE -> A.anyWord8 *> array_
180− C_f -> string "false" *> pure (Bool False)
181− C_t -> string "true" *> pure (Bool True)
182− C_n -> string "null" *> pure Null
183− _ | w >= 48 && w <= 57 || w == 45
184− -> Number <$> scientific
185− | otherwise -> fail "not a valid json value"
186−
187−-- | Strict version of 'value'. See also 'json''.
188−value' :: Parser Value
189−value' = do
190− w <- A.peekWord8'
191− case w of
192− DOUBLE_QUOTE -> do
193− !s <- A.anyWord8 *> jstring_
194− return (String s)
195− OPEN_CURLY -> A.anyWord8 *> object_'
196− OPEN_SQUARE -> A.anyWord8 *> array_'
197− C_f -> string "false" *> pure (Bool False)
198− C_t -> string "true" *> pure (Bool True)
199− C_n -> string "null" *> pure Null
200− _ | w >= 48 && w <= 57 || w == 45
201− -> do
202− !n <- scientific
203− return (Number n)
204− | otherwise -> fail "not a valid json value"
205−
206−-- | Parse a quoted JSON string.
207−jstring :: Parser Text
208−jstring = A.word8 DOUBLE_QUOTE *> jstring_
209−
210−-- | Parse a string without a leading quote.
211−jstring_ :: Parser Text
212−jstring_ = {-# SCC "jstring_" #-} do
213− s <- A.scan False $ \s c -> if s then Just False
214− else if c == DOUBLE_QUOTE
215− then Nothing
216− else Just (c == BACKSLASH)
217− _ <- A.word8 DOUBLE_QUOTE
218− s1 <- if BACKSLASH `B.elem` s
219− then case Z.parse unescape s of
220− Right r -> return r
221− Left err -> fail err
222− else return s
223−
224− case decodeUtf8' s1 of
225− Right r -> return r
226− Left err -> fail $ show err
227−
228−{-# INLINE jstring_ #-}
229−
230−unescape :: Z.Parser ByteString
231−unescape = toByteString <$> go mempty where
232− go acc = do
233− h <- Z.takeWhile (/=BACKSLASH)
234− let rest = do
235− start <- Z.take 2
236− let !slash = B.unsafeHead start
237− !t = B.unsafeIndex start 1
238− escape = case B.findIndex (==t) "\"\\/ntbrfu" of
239− Just i -> i
240− _ -> 255
241− if slash /= BACKSLASH || escape == 255
242− then fail "invalid JSON escape sequence"
243− else do
244− let cont m = go (acc `mappend` byteString h `mappend` m)
245− {-# INLINE cont #-}
246− if t /= 117 -- 'u'
247− then cont (word8 (B.unsafeIndex mapping escape))
248− else do
249− a <- hexQuad
250− if a < 0xd800 || a > 0xdfff
251− then cont (charUtf8 (chr a))
252− else do
253− b <- Z.string "\\u" *> hexQuad
254− if a <= 0xdbff && b >= 0xdc00 && b <= 0xdfff
255− then let !c = ((a - 0xd800) `shiftL` 10) +
256− (b - 0xdc00) + 0x10000
257− in cont (charUtf8 (chr c))
258− else fail "invalid UTF-16 surrogates"
259− done <- Z.atEnd
260− if done
261− then return (acc `mappend` byteString h)
262− else rest
263− mapping = "\"\\/\n\t\b\r\f"
264−
265−hexQuad :: Z.Parser Int
266−hexQuad = do
267− s <- Z.take 4
268− let hex n | w >= C_0 && w <= C_9 = w - C_0
269− | w >= C_a && w <= C_f = w - 87
270− | w >= C_A && w <= C_F = w - 55
271− | otherwise = 255
272− where w = fromIntegral $ B.unsafeIndex s n
273− a = hex 0; b = hex 1; c = hex 2; d = hex 3
274− if (a .|. b .|. c .|. d) /= 255
275− then return $! d .|. (c `shiftL` 4) .|. (b `shiftL` 8) .|. (a `shiftL` 12)
276− else fail "invalid hex escape"
277−
278−decodeWith :: Parser Value -> (Value -> Result a) -> L.ByteString -> Maybe a
279−decodeWith p to s =
280− case L.parse p s of
281− L.Done _ v -> case to v of
282− Success a -> Just a
283− _ -> Nothing
284− _ -> Nothing
285−{-# INLINE decodeWith #-}
286−
287−decodeStrictWith :: Parser Value -> (Value -> Result a) -> B.ByteString
288− -> Maybe a
289−decodeStrictWith p to s =
290− case either Error to (A.parseOnly p s) of
291− Success a -> Just a
292− Error _ -> Nothing
293−{-# INLINE decodeStrictWith #-}
294−
295−eitherDecodeWith :: Parser Value -> (Value -> Result a) -> L.ByteString
296− -> Either String a
297−eitherDecodeWith p to s =
298− case L.parse p s of
299− L.Done _ v -> case to v of
300− Success a -> Right a
301− Error msg -> Left msg
302− L.Fail _ _ msg -> Left msg
303−{-# INLINE eitherDecodeWith #-}
304−
305−eitherDecodeStrictWith :: Parser Value -> (Value -> Result a) -> B.ByteString
306− -> Either String a
307−eitherDecodeStrictWith p to s =
308− case either Error to (A.parseOnly p s) of
309− Success a -> Right a
310− Error msg -> Left msg
311−{-# INLINE eitherDecodeStrictWith #-}
312−
313−-- $lazy
314−--
315−-- The 'json' and 'value' parsers decouple identification from
316−-- conversion. Identification occurs immediately (so that an invalid
317−-- JSON document can be rejected as early as possible), but conversion
318−-- to a Haskell value is deferred until that value is needed.
319−--
320−-- This decoupling can be time-efficient if only a smallish subset of
321−-- elements in a JSON value need to be inspected, since the cost of
322−-- conversion is zero for uninspected elements. The trade off is an
323−-- increase in memory usage, due to allocation of thunks for values
324−-- that have not yet been converted.
325−
326−-- $strict
327−--
328−-- The 'json'' and 'value'' parsers combine identification with
329−-- conversion. They consume more CPU cycles up front, but have a
330−-- smaller memory footprint.
331−
332−-- | Parse a top-level JSON value followed by optional whitespace and
333−-- end-of-input. See also: 'json'.
334−jsonEOF :: Parser Value
335−jsonEOF = json <* skipSpace <* endOfInput
336−
337−-- | Parse a top-level JSON value followed by optional whitespace and
338−-- end-of-input. See also: 'json''.
339−jsonEOF' :: Parser Value
340−jsonEOF' = json' <* skipSpace <* endOfInput
341−
342−toByteString :: Builder -> ByteString
343−toByteString = L.toStrict . toLazyByteString
344−{-# INLINE toByteString #-}
345−
346−aeson :: IO Benchmark
347−aeson = do
348− path <- pathTo "json-data"
349− names <- sort . filter (`notElem` [".", ".."]) <$> getDirectoryContents path
350− benches <- forM names $ \name -> do
351− bs <- B.readFile (path </> name)
352− return . bench (dropExtension name) $ nf (A.parseOnly jsonEOF') bs
353− return $ bgroup "aeson" benches
benchmarks/Alternative.hsdeleted−20
@@ -1,20 +0,0 @@
1−{-# LANGUAGE OverloadedStrings #-}
2−
3−-- This benchmark reveals a huge performance regression that showed up
4−-- under GHC 7.8.1 (https://github.com/bos/attoparsec/issues/56).
5−--
6−-- With GHC 7.6.3 and older, this program runs in 0.04 seconds. Under
7−-- GHC 7.8.1 with (<|>) inlined, time jumps to 12 seconds!
8−
9−import Control.Applicative
10−import Data.Text (Text)
11−import qualified Data.Attoparsec.Text as A
12−import qualified Data.Text as T
13−
14−testParser :: Text -> Either String Int
15−testParser f = fmap length -- avoid printing out the entire matched list
16− . A.parseOnly (many ((() <$ A.string "b") <|> (() <$ A.anyChar)))
17− $ f
18−
19−main :: IO ()
20−main = print . testParser $ T.replicate 50000 "a"
benchmarks/Benchmarks.hs+80−42
@@ -1,19 +1,15 @@
1{-# LANGUAGE BangPatterns, CPP #-}
1{-# LANGUAGE BangPatterns, CPP #-}
2
2
3−import Common ()
4−import Control.Applicative (many)
3+import Control.Applicative
4+import Control.DeepSeq (NFData(rnf))
5−import Criterion.Main (bench, bgroup, defaultMain, nf)
5+import Criterion.Main (bench, bgroup, defaultMain, nf, whnf)
6−import Data.Bits
6+import Data.Bits (unsafeShiftL)
7+import Data.ByteString.Internal (ByteString(..))
7−import Data.Char (isAlpha)
8+import Data.Char
9+import Data.Scientific (Scientific(..))
8import Data.Word (Word32)
10import Data.Word (Word32)
9−import Data.Word (Word8)
10−import Numbers (numbers)
11−import Common (chunksOf)
12import Text.Parsec.Text ()
11import Text.Parsec.Text ()
13import Text.Parsec.Text.Lazy ()
12import Text.Parsec.Text.Lazy ()
14−import qualified Warp
15−import qualified Aeson
16−import qualified Genome
17import qualified Data.Attoparsec.ByteString as AB
13import qualified Data.Attoparsec.ByteString as AB
18import qualified Data.Attoparsec.ByteString.Char8 as AC
14import qualified Data.Attoparsec.ByteString.Char8 as AC
19import qualified Data.Attoparsec.ByteString.Lazy as ABL
15import qualified Data.Attoparsec.ByteString.Lazy as ABL
@@ -24,22 +20,32 @@ import qualified Data.ByteString.Char8 as BC
24import qualified Data.ByteString.Lazy as BL
20import qualified Data.ByteString.Lazy as BL
25import qualified Data.Text as T
21import qualified Data.Text as T
26import qualified Data.Text.Lazy as TL
22import qualified Data.Text.Lazy as TL
27−import qualified HeadersByteString
23+import Data.Word (Word8)
28−import qualified HeadersText
29−import qualified Links
30import qualified Text.Parsec as P
24import qualified Text.Parsec as P
31−import qualified Sets
32
25
33−main :: IO ()
26+#if !MIN_VERSION_bytestring(0,10,0)
27+instance NFData ByteString where
28+ rnf (PS _ _ _) = ()
29+#endif
30+
31+instance NFData P.ParseError where
32+ rnf = rnf . show
33+
34+chunksOf :: Int -> [a] -> [[a]]
35+chunksOf k = go
36+ where go xs = case splitAt k xs of
37+ ([],_) -> []
38+ (y, ys) -> y : go ys
39+
40+fromLazy :: BL.ByteString -> B.ByteString
41+fromLazy = B.concat . BL.toChunks
42+
34main = do
43main = do
35 let s = take 1024 . cycle $ ['a'..'z'] ++ ['A'..'Z']
44 let s = take 1024 . cycle $ ['a'..'z'] ++ ['A'..'Z']
36 !b = BC.pack s
45 !b = BC.pack s
37 !bl = BL.fromChunks . map BC.pack . chunksOf 4 $ s
46 !bl = BL.fromChunks . map BC.pack . chunksOf 4 $ s
38 !t = T.pack s
47 !t = T.pack s
39 !tl = TL.fromChunks . map T.pack . chunksOf 4 $ s
48 !tl = TL.fromChunks . map T.pack . chunksOf 4 $ s
40− aeson <- Aeson.aeson
41− headersBS <- HeadersByteString.headers
42− headersT <- HeadersText.headers
43 defaultMain [
49 defaultMain [
44 bgroup "many" [
50 bgroup "many" [
45 bgroup "attoparsec" [
51 bgroup "attoparsec" [
@@ -69,30 +75,67 @@ main = do
69 , bgroup "takeWhile" [
75 , bgroup "takeWhile" [
70 bench "isAlpha" $ nf (ABL.parse (AC.takeWhile isAlpha)) bl
76 bench "isAlpha" $ nf (ABL.parse (AC.takeWhile isAlpha)) bl
71 , bench "isAlpha_ascii" $ nf (ABL.parse (AC.takeWhile AC.isAlpha_ascii)) bl
77 , bench "isAlpha_ascii" $ nf (ABL.parse (AC.takeWhile AC.isAlpha_ascii)) bl
72− , bench "isAlpha_iso8859_15" $
73− nf (ABL.parse (AC.takeWhile AC.isAlpha_iso8859_15)) bl
78+ , bench "isAlpha_iso8859_15" $ nf (ABL.parse (AC.takeWhile AC.isAlpha_iso8859_15)) bl
74− , bench "T isAlpha" $ nf (AT.parse (AT.takeWhile isAlpha)) t
75− , bench "TL isAlpha" $ nf (ATL.parse (AT.takeWhile isAlpha)) tl
76− ]
77− , bgroup "takeWhile1" [
78− bench "isAlpha" $ nf (ABL.parse (AC.takeWhile1 isAlpha)) bl
79− , bench "isAlpha_ascii" $ nf (ABL.parse (AC.takeWhile1 AC.isAlpha_ascii)) bl
80− , bench "T isAlpha" $ nf (AT.parse (AT.takeWhile1 isAlpha)) t
81− , bench "TL isAlpha" $ nf (ATL.parse (AT.takeWhile1 isAlpha)) tl
82 ]
79 ]
83 , bench "word32LE" $ nf (AB.parse word32LE) b
80 , bench "word32LE" $ nf (AB.parse word32LE) b
84 , bgroup "scan" [
81 , bgroup "scan" [
85 bench "short" $ nf (AB.parse quotedString) (BC.pack "abcdefghijk\"")
82 bench "short" $ nf (AB.parse quotedString) (BC.pack "abcdefghijk\"")
86 , bench "long" $ nf (AB.parse quotedString) b
83 , bench "long" $ nf (AB.parse quotedString) b
87 ]
84 ]
88− , aeson
85+
89− , Genome.genome
86+ , let strN = "1234.56789"
90− , headersBS
87+ strNePos = "1234.56789e3"
91− , headersT
88+ strNeNeg = "1234.56789e-3"
92− , Links.links
89+ in
93− , numbers
90+ bgroup "numbers"
94− , Sets.benchmarks
91+ [ let !tN = T.pack strN
95− , Warp.benchmarks
92+ !tNePos = T.pack strNePos
93+ !tNeNeg = T.pack strNeNeg
94+ in bgroup "Text"
95+ [
96+ bgroup "no power"
97+ [ bench "double" $ nf (AT.parseOnly AT.double) tN
98+ , bench "number" $ nf (AT.parseOnly AT.number) tN
99+ , bench "rational" $ nf (AT.parseOnly (AT.rational :: AT.Parser Rational)) tN
100+ , bench "scientific" $ nf (AT.parseOnly (AT.rational :: AT.Parser Scientific)) tN
101+ ]
102+ , bgroup "positive power"
103+ [ bench "double" $ nf (AT.parseOnly AT.double) tNePos
104+ , bench "number" $ nf (AT.parseOnly AT.number) tNePos
105+ , bench "rational" $ nf (AT.parseOnly (AT.rational :: AT.Parser Rational)) tNePos
106+ , bench "scientific" $ nf (AT.parseOnly (AT.rational :: AT.Parser Scientific)) tNePos
107+ ]
108+ , bgroup "negative power"
109+ [ bench "double" $ nf (AT.parseOnly AT.double) tNeNeg
110+ , bench "number" $ nf (AT.parseOnly AT.number) tNeNeg
111+ , bench "rational" $ nf (AT.parseOnly (AT.rational :: AT.Parser Rational)) tNeNeg
112+ , bench "scientific" $ nf (AT.parseOnly (AT.rational :: AT.Parser Scientific)) tNeNeg
113+ ]
114+ ]
115+ , let !bN = BC.pack strN
116+ !bNePos = BC.pack strNePos
117+ !bNeNeg = BC.pack strNeNeg
118+ in bgroup "ByteString"
119+ [ bgroup "no power"
120+ [ bench "double" $ nf (AC.parseOnly AC.double) bN
121+ , bench "number" $ nf (AC.parseOnly AC.number) bN
122+ , bench "rational" $ nf (AC.parseOnly (AC.rational :: AC.Parser Rational)) bN
123+ , bench "scientific" $ nf (AC.parseOnly (AC.rational :: AC.Parser Scientific)) bN
124+ ]
125+ , bgroup "positive power"
126+ [ bench "double" $ nf (AC.parseOnly AC.double) bNePos
127+ , bench "number" $ nf (AC.parseOnly AC.number) bNePos
128+ , bench "rational" $ nf (AC.parseOnly (AC.rational :: AC.Parser Rational)) bNePos
129+ , bench "scientific" $ nf (AC.parseOnly (AC.rational :: AC.Parser Scientific)) bNePos
130+ ]
131+ , bgroup "negative power"
132+ [ bench "double" $ nf (AC.parseOnly AC.double) bNeNeg
133+ , bench "number" $ nf (AC.parseOnly AC.number) bNeNeg
134+ , bench "rational" $ nf (AC.parseOnly (AC.rational :: AC.Parser Rational)) bNeNeg
135+ , bench "scientific" $ nf (AC.parseOnly (AC.rational :: AC.Parser Scientific)) bNeNeg
136+ ]
137+ ]
138+ ]
96 ]
139 ]
97
140
98-- Benchmarks bind and (potential) bounds-check merging.
141-- Benchmarks bind and (potential) bounds-check merging.
@@ -119,8 +162,3 @@ quotedString = AB.scan False $ \s c -> if s then Just False
119 else if c == doubleQuote
162 else if c == doubleQuote
120 then Nothing
163 then Nothing
121 else Just (c == backslash)
164 else Just (c == backslash)
122−
123−#if !MIN_VERSION_base(4,5,0)
124−unsafeShiftL :: Bits a => a -> Int -> a
125−unsafeShiftL = shiftL
126−#endif
benchmarks/Common.hsdeleted−47
@@ -1,47 +0,0 @@
1−{-# LANGUAGE CPP #-}
2−{-# OPTIONS_GHC -fno-warn-orphans #-}
3−
4−module Common (
5− chunksOf
6− , pathTo
7− , rechunkBS
8− , rechunkT
9− ) where
10−
11−import Control.DeepSeq (NFData(rnf))
12−import System.Directory (doesDirectoryExist)
13−import System.FilePath ((</>))
14−import Text.Parsec (ParseError)
15−import qualified Data.ByteString as B
16−import qualified Data.ByteString.Lazy as BL
17−import qualified Data.Text as T
18−import qualified Data.Text.Lazy as TL
19−
20−#if !MIN_VERSION_bytestring(0,10,0)
21−import Data.ByteString.Internal (ByteString(..))
22−
23−instance NFData ByteString where
24− rnf (PS _ _ _) = ()
25−#endif
26−
27−instance NFData ParseError where
28− rnf = rnf . show
29−
30−chunksOf :: Int -> [a] -> [[a]]
31−chunksOf k = go
32− where go xs = case splitAt k xs of
33− ([],_) -> []
34− (y, ys) -> y : go ys
35−
36−rechunkBS :: Int -> B.ByteString -> BL.ByteString
37−rechunkBS n = BL.fromChunks . map B.pack . chunksOf n . B.unpack
38−
39−rechunkT :: Int -> T.Text -> TL.Text
40−rechunkT n = TL.fromChunks . map T.pack . chunksOf n . T.unpack
41−
42−pathTo :: String -> IO FilePath
43−pathTo wat = do
44− exists <- doesDirectoryExist "benchmarks"
45− return $ if exists
46− then "benchmarks" </> wat
47− else wat
benchmarks/Genome.hsdeleted−75
@@ -1,75 +0,0 @@
1−{-# LANGUAGE OverloadedStrings #-}
2−
3−module Genome
4− (
5− genome
6− ) where
7−
8−import Control.Applicative
9−import Criterion.Main
10−import Data.ByteString (ByteString)
11−import qualified Data.ByteString.Char8 as B8
12−import qualified Data.ByteString.Lazy.Char8 as L8
13−import Data.Attoparsec.ByteString.Char8 as B
14−import qualified Data.Attoparsec.ByteString.Lazy as BL
15−import Data.Text (Text)
16−import qualified Data.Text as T
17−import qualified Data.Text.Lazy as TL
18−import Data.Attoparsec.Text as T
19−import qualified Data.Attoparsec.Text.Lazy as TL
20−import Common (rechunkBS, rechunkT)
21−
22−genome :: Benchmark
23−genome = bgroup "genome" [
24− bgroup "bytestring" [
25− bench "s" $ nf (map (B.parse searchBS)) (B8.tails geneB)
26− , bench "l" $ nf (map (BL.parse searchBS)) (L8.tails geneBL)
27− , bgroup "CI" [
28− bench "s" $ nf (map (B.parse searchBSCI)) (B8.tails geneB)
29− , bench "l" $ nf (map (BL.parse searchBSCI)) (L8.tails geneBL)
30− ]
31− ]
32− , bgroup "text" [
33− bench "s" $ nf (map (T.parse searchT)) (T.tails geneT)
34− , bench "l" $ nf (map (TL.parse searchT)) (TL.tails geneTL)
35− , bgroup "CI" [
36− bench "s" $ nf (map (T.parse searchTCI)) (T.tails geneT)
37− , bench "l" $ nf (map (TL.parse searchTCI)) (TL.tails geneTL)
38− ]
39− ]
40− ]
41− where geneB = B8.pack gene
42− geneBL = rechunkBS 4 geneB
43− geneT = T.pack gene
44− geneTL = rechunkT 4 geneT
45−
46−searchBS :: B.Parser ByteString
47−searchBS = "caac" *> ("aaca" <|> "aact")
48−
49−searchBSCI :: B.Parser ByteString
50−searchBSCI = B.stringCI "CAAC" *> (B.stringCI "AACA" <|> B.stringCI "AACT")
51−
52−searchT :: T.Parser Text
53−searchT = "caac" *> ("aaca" <|> "aact")
54−
55−searchTCI :: T.Parser Text
56−searchTCI = T.asciiCI "CAAC" *> (T.asciiCI "AACA" <|> T.asciiCI "AACT")
57−
58−-- Dictyostelium discoideum developmental protein DG1094 (gacT) gene,
59−-- partial cds. http://www.ncbi.nlm.nih.gov/nuccore/AF081586.1
60−
61−gene :: String
62−gene = "atcgatttagaaagatacaaagatagaaccatcaataataaacaagagaagagagcaagt\
63− \agagatattaataaagagattgaaagagagattgaaaagaagagattatcaccaagagaa\
64− \agattaaatttatttggtctttcttcctcatcttcatcagtgaattcaacattaacaaga\
65− \tctacagcaaatattatctctacaatagacggtagtggaggtagtaatcgtaatagtaaa\
66− \aattatggtaatggctcatcctcctcctcaaatagaagatatagtaatactattaatcaa\
67− \caattacaaatgcaattacaacaacttcaaatccaacaacaacaatatcaacaaactcaa\
68− \caatctcaaataccattacaatatcaacaacaacaacagcaacaacaacaacaaaccact\
69− \acaactacaactacatcaagtggtagtaatagattctcttcaaatagatataaaccagtt\
70− \gatcttacacaatcatcttcaaactttcgttattcacgtgaaatttatgatgatgattat\
71− \tattcaaataataatttaatgatgtttggtaatgagcaaccaaatcaaacaccaatttct\
72− \gtatcatcttcatctgcattcacacgtcaaagatctcaaagttgctttgaaccagagaat\
73− \cttgtattgctacaacaacaatatcaacaatatcaacaacaacaacaacaacaacaacaa\
74− \attccattccaagcaaatccacaatatagtaatgctgttattgaacaaaaattggatcaa\
75− \attagagataccattaataatttacatagagataaccgagtctctaga"
benchmarks/HeadersByteString.hsdeleted−37
@@ -1,37 +0,0 @@
1−module HeadersByteString (headers) where
2−
3−import Common (pathTo, rechunkBS)
4−import Criterion.Main (bench, bgroup, nf, nfIO)
5−import Criterion.Types (Benchmark)
6−import HeadersByteString.Atto (request, response)
7−import Network.Wai.Handler.Warp.RequestHeader (parseHeaderLines)
8−import qualified Data.Attoparsec.ByteString.Char8 as B
9−import qualified Data.Attoparsec.ByteString.Lazy as BL
10−import qualified Data.ByteString.Char8 as B
11−
12−-- Note: In the benchmarks for parsing an http request
13−-- from a strict bytestring, we consider warp's implementation,
14−-- which has highly optimized code for handling the first
15−-- line in particular. It's treatment of the headers
16−-- is more relaxed from the treatment they are given by the
17−-- attoparsec parser benchmarked here. Consequently, it
18−-- is should not be possible to match its performance since
19−-- it accepts header names with disallowed characters.
20−
21−headers :: IO Benchmark
22−headers = do
23− req <- B.readFile =<< pathTo "http-request.txt"
24− resp <- B.readFile =<< pathTo "http-response.txt"
25− let reql = rechunkBS 4 req
26− respl = rechunkBS 4 resp
27− return $ bgroup "headers" [
28− bgroup "B" [
29− bench "request" $ nf (B.parseOnly request) req
30− , bench "warp" $ nfIO (parseHeaderLines (B.split '\n' req))
31− , bench "response" $ nf (B.parseOnly response) resp
32− ]
33− , bgroup "BL" [
34− bench "request" $ nf (BL.parse request) reql
35− , bench "response" $ nf (BL.parse response) respl
36− ]
37− ]
benchmarks/HeadersByteString/Atto.hsdeleted−57
@@ -1,57 +0,0 @@
1−{-# LANGUAGE BangPatterns, OverloadedStrings #-}
2−{-# OPTIONS_GHC -fno-warn-missing-signatures -fno-warn-orphans #-}
3−module HeadersByteString.Atto
4− (
5− request
6− , response
7− ) where
8−
9−import Control.Applicative
10−import Control.DeepSeq (NFData(..))
11−import Network.HTTP.Types.Version (HttpVersion, http11)
12−import qualified Data.Attoparsec.ByteString.Char8 as B
13−import qualified Data.ByteString.Char8 as B
14−
15−instance NFData HttpVersion where
16− rnf !_ = ()
17−
18−isHeaderChar :: Char -> Bool
19−isHeaderChar c =
20− (c >= 'a' && c <= 'z') ||
21− (c >= 'A' && c <= 'Z') ||
22− (c >= '0' && c <= '9') ||
23− (c == '_') ||
24− (c == '-')
25−
26−header = do
27− name <- B.takeWhile1 isHeaderChar <* B.char ':' <* B.skipSpace
28− body <- bodyLine
29− return (name, body)
30−
31−bodyLine = B.takeTill (\c -> c == '\r' || c == '\n') <* B.endOfLine
32−
33−requestLine = do
34− m <- (B.takeTill B.isSpace <* B.char ' ')
35− (p,q) <- B.break (=='?') <$> (B.takeTill B.isSpace <* B.char ' ')
36− v <- httpVersion
37− return (m,p,q,v)
38−
39−httpVersion = http11 <$ "HTTP/1.1"
40−
41−responseLine = (,,) <$>
42− (httpVersion <* B.skipSpace) <*>
43− (int <* B.skipSpace) <*>
44− bodyLine
45−
46−int :: B.Parser Int
47−int = B.decimal
48−
49−request = (,) <$> (requestLine <* B.endOfLine) <*> manyheader
50−
51−response = (,) <$> responseLine <*> many header
52−
53−manyheader = do
54− c <- B.peekChar'
55− if c == '\r' || c == '\n'
56− then return []
57− else (:) <$> header <*> manyheader
benchmarks/HeadersText.hsdeleted−57
@@ -1,57 +0,0 @@
1−{-# LANGUAGE OverloadedStrings #-}
2−{-# OPTIONS_GHC -fno-warn-missing-signatures #-}
3−module HeadersText (headers) where
4−
5−import Common (pathTo, rechunkT)
6−import Control.Applicative
7−import Criterion.Main (bench, bgroup, nf)
8−import Criterion.Types (Benchmark)
9−import Data.Char (isSpace)
10−import qualified Data.Attoparsec.Text as T
11−import qualified Data.Attoparsec.Text.Lazy as TL
12−import qualified Data.Text.IO as T
13−
14−header = do
15− name <- T.takeWhile1 (T.inClass "a-zA-Z0-9_-") <* T.char ':' <* T.skipSpace
16− body <- (:) <$> bodyLine <*> many (T.takeWhile1 isSpace *> bodyLine)
17− return (name, body)
18−
19−bodyLine = T.takeTill (\c -> c == '\r' || c == '\n') <* T.endOfLine
20−
21−requestLine =
22− (,,) <$>
23− (method <* T.skipSpace) <*>
24− (T.takeTill isSpace <* T.skipSpace) <*>
25− httpVersion
26− where method = "GET" <|> "POST"
27−
28−httpVersion = "HTTP/" *> ((,) <$> (int <* T.char '.') <*> int)
29−
30−responseLine = (,,) <$>
31− (httpVersion <* T.skipSpace) <*>
32− (int <* T.skipSpace) <*>
33− bodyLine
34−
35−int :: T.Parser Int
36−int = T.decimal
37−
38−request = (,) <$> (requestLine <* T.endOfLine) <*> many header
39−
40−response = (,) <$> responseLine <*> many header
41−
42−headers :: IO Benchmark
43−headers = do
44− req <- T.readFile =<< pathTo "http-request.txt"
45− resp <- T.readFile =<< pathTo "http-response.txt"
46− let reql = rechunkT 4 req
47− respl = rechunkT 4 resp
48− return $ bgroup "headers" [
49− bgroup "T" [
50− bench "request" $ nf (T.parseOnly request) req
51− , bench "response" $ nf (T.parseOnly response) resp
52− ]
53− , bgroup "TL" [
54− bench "request" $ nf (TL.parse request) reql
55− , bench "response" $ nf (TL.parse response) respl
56− ]
57− ]
benchmarks/Links.hsdeleted−63
@@ -1,63 +0,0 @@
1−{-# LANGUAGE OverloadedStrings #-}
2−
3−module Links (links) where
4−
5−import Control.Applicative
6−import Control.DeepSeq (NFData(..))
7−import Criterion.Main (Benchmark, bench, nf)
8−import Data.Attoparsec.ByteString as A
9−import Data.Attoparsec.ByteString.Char8 as A8
10−import Data.ByteString.Char8 as B8
11−
12−data Link = Link {
13− linkURL :: ByteString
14− , linkParams :: [(ByteString, ByteString)]
15− } deriving (Eq, Show)
16−
17−instance NFData Link where
18− rnf l = rnf (linkURL l) `seq` rnf (linkParams l)
19−
20−link :: Parser Link
21−link = Link <$> url <*> many (char8 ';' *> skipSpace *> param)
22− where url = char8 '<' *> A8.takeTill (=='>') <* char8 '>' <* skipSpace
23−
24−param :: Parser (ByteString, ByteString)
25−param = do
26− name <- paramName
27− skipSpace *> "=" *> skipSpace
28− c <- peekChar'
29− let isTokenChar = A.inClass "!#$%&'()*+./0-9:<=>?@a-zA-Z[]^_`{|}~-"
30− val <- case c of
31− '"' -> quotedString
32− _ -> A.takeWhile isTokenChar
33− skipSpace
34− return (name, val)
35−
36−data Quot = Literal | Backslash
37−
38−quotedString :: Parser ByteString
39−quotedString = char '"' *> (fixup <$> body) <* char '"'
40− where body = A8.scan Literal $ \s c ->
41− case (s,c) of
42− (Literal, '\\') -> backslash
43− (Literal, '"') -> Nothing
44− _ -> literal
45− literal = Just Literal
46− backslash = Just Backslash
47− fixup = B8.pack . go . B8.unpack
48− where go ('\\' : x@'\\' : xs) = x : go xs
49− go ('\\' : x@'"' : xs) = x : go xs
50− go (x : xs) = x : go xs
51− go xs = xs
52−
53−paramName :: Parser ByteString
54−paramName = do
55− name <- A.takeWhile1 $ A.inClass "a-zA-Z0-9!#$&+-.^_`|~"
56− c <- peekChar
57− return $ case c of
58− Just '*' -> B8.snoc name '*'
59− _ -> name
60−
61−links :: Benchmark
62−links = bench "links" $ nf (A.parseOnly link) lnk
63− where lnk = "<https://api.github.com/search/code?q=addClass+user%3Amozilla&page=2>; rel=\"next\", <https://api.github.com/search/code?q=addClass+user%3Amozilla&page=34>; rel=\"last\""
benchmarks/Numbers.hsdeleted−82
@@ -1,82 +0,0 @@
1−{-# LANGUAGE BangPatterns #-}
2−{-# OPTIONS_GHC -fno-warn-deprecations #-}
3−
4−module Numbers (numbers) where
5−
6−import Criterion.Main (bench, bgroup, nf)
7−import Criterion.Types (Benchmark)
8−import Data.Scientific (Scientific(..))
9−import Text.Parsec.Text ()
10−import Text.Parsec.Text.Lazy ()
11−import qualified Data.Attoparsec.ByteString.Char8 as AC
12−import qualified Data.Attoparsec.Text as AT
13−import qualified Data.ByteString.Char8 as BC
14−import qualified Data.Text as T
15−
16−strN, strNePos, strNeNeg :: String
17−strN = "1234.56789"
18−strNePos = "1234.56789e3"
19−strNeNeg = "1234.56789e-3"
20−
21−numbers :: Benchmark
22−numbers = bgroup "numbers" [
23− let !tN = T.pack strN
24− !tNePos = T.pack strNePos
25− !tNeNeg = T.pack strNeNeg
26− in bgroup "Text"
27− [
28− bgroup "no power"
29− [ bench "double" $ nf (AT.parseOnly AT.double) tN
30− , bench "number" $ nf (AT.parseOnly AT.number) tN
31− , bench "rational" $
32− nf (AT.parseOnly (AT.rational :: AT.Parser Rational)) tN
33− , bench "scientific" $
34− nf (AT.parseOnly (AT.rational :: AT.Parser Scientific)) tN
35− ]
36− , bgroup "positive power"
37− [ bench "double" $ nf (AT.parseOnly AT.double) tNePos
38− , bench "number" $ nf (AT.parseOnly AT.number) tNePos
39− , bench "rational" $
40− nf (AT.parseOnly (AT.rational :: AT.Parser Rational)) tNePos
41− , bench "scientific" $
42− nf (AT.parseOnly (AT.rational :: AT.Parser Scientific)) tNePos
43− ]
44− , bgroup "negative power"
45− [ bench "double" $ nf (AT.parseOnly AT.double) tNeNeg
46− , bench "number" $ nf (AT.parseOnly AT.number) tNeNeg
47− , bench "rational" $
48− nf (AT.parseOnly (AT.rational :: AT.Parser Rational)) tNeNeg
49− , bench "scientific" $
50− nf (AT.parseOnly (AT.rational :: AT.Parser Scientific)) tNeNeg
51− ]
52− ]
53− , let !bN = BC.pack strN
54− !bNePos = BC.pack strNePos
55− !bNeNeg = BC.pack strNeNeg
56− in bgroup "ByteString"
57− [ bgroup "no power"
58− [ bench "double" $ nf (AC.parseOnly AC.double) bN
59− , bench "number" $ nf (AC.parseOnly AC.number) bN
60− , bench "rational" $
61− nf (AC.parseOnly (AC.rational :: AC.Parser Rational)) bN
62− , bench "scientific" $
63− nf (AC.parseOnly (AC.rational :: AC.Parser Scientific)) bN
64− ]
65− , bgroup "positive power"
66− [ bench "double" $ nf (AC.parseOnly AC.double) bNePos
67− , bench "number" $ nf (AC.parseOnly AC.number) bNePos
68− , bench "rational" $
69− nf (AC.parseOnly (AC.rational :: AC.Parser Rational)) bNePos
70− , bench "scientific" $
71− nf (AC.parseOnly (AC.rational :: AC.Parser Scientific)) bNePos
72− ]
73− , bgroup "negative power"
74− [ bench "double" $ nf (AC.parseOnly AC.double) bNeNeg
75− , bench "number" $ nf (AC.parseOnly AC.number) bNeNeg
76− , bench "rational" $
77− nf (AC.parseOnly (AC.rational :: AC.Parser Rational)) bNeNeg
78− , bench "scientific" $
79− nf (AC.parseOnly (AC.rational :: AC.Parser Scientific)) bNeNeg
80− ]
81− ]
82− ]
benchmarks/Sets.hsdeleted−21
@@ -1,21 +0,0 @@
1−module Sets (benchmarks) where
2−
3−import Criterion
4−import Data.Char (ord)
5−import qualified Data.Attoparsec.Text.FastSet as FastSet
6−import qualified TextFastSet
7−import qualified Data.HashSet as HashSet
8−import qualified Data.IntSet as IntSet
9−
10−smallSet :: String
11−smallSet = ['a'..'z'] ++ ['A'..'Z'] ++ ['0'..'9']
12−
13−benchmarks :: Benchmark
14−benchmarks = bgroup "sets" [
15− bench "Fast" $ whnf (FastSet.member '*') (FastSet.fromList smallSet)
16− , bench "Hash" $ whnf (HashSet.member '*') (HashSet.fromList smallSet)
17− , bench "Int" $ whnf (IntSet.member (ord '*'))
18− (IntSet.fromList (map ord smallSet))
19− , bench "TextFast" $ whnf (TextFastSet.member '*')
20− (TextFastSet.fromList smallSet)
21− ]
benchmarks/TextFastSet.hsdeleted−121
@@ -1,121 +0,0 @@
1−{-# LANGUAGE BangPatterns #-}
2−
3−------------------------------------------------------------------------------
4−-- |
5−-- Module : Data.Attoparsec.FastSet
6−-- Copyright : Felipe Lessa 2010, Bryan O'Sullivan 2007-2015
7−-- License : BSD3
8−--
9−-- Maintainer : felipe.lessa@gmail.com
10−-- Stability : experimental
11−-- Portability : unknown
12−--
13−-- Fast set membership tests for 'Char' values. We test for
14−-- membership using a hashtable implemented with Robin Hood
15−-- collision resolution. The set representation is unboxed,
16−-- and the characters and hashes interleaved, for efficiency.
17−--
18−--
19−-----------------------------------------------------------------------------
20−module TextFastSet
21− (
22− -- * Data type
23− FastSet
24− -- * Construction
25− , fromList
26− , set
27− -- * Lookup
28− , member
29− -- * Handy interface
30− , charClass
31− ) where
32−
33−import Data.Bits ((.|.), (.&.), shiftR)
34−import Data.Function (on)
35−import Data.List (sort, sortBy)
36−import qualified Data.Array.Base as AB
37−import qualified Data.Array.Unboxed as A
38−import qualified Data.Text as T
39−
40−data FastSet = FastSet {
41− table :: {-# UNPACK #-} !(A.UArray Int Int)
42− , mask :: {-# UNPACK #-} !Int
43− }
44−
45−data Entry = Entry {
46− key :: {-# UNPACK #-} !Char
47− , initialIndex :: {-# UNPACK #-} !Int
48− , index :: {-# UNPACK #-} !Int
49− }
50−
51−offset :: Entry -> Int
52−offset e = index e - initialIndex e
53−
54−resolveCollisions :: [Entry] -> [Entry]
55−resolveCollisions [] = []
56−resolveCollisions [e] = [e]
57−resolveCollisions (a:b:entries) = a' : resolveCollisions (b' : entries)
58− where (a', b')
59− | index a < index b = (a, b)
60− | offset a < offset b = (b { index=index a }, a { index=index a + 1 })
61− | otherwise = (a, b { index=index a + 1 })
62−
63−pad :: Int -> [Entry] -> [Entry]
64−pad = go 0
65− where -- ensure that we pad enough so that lookups beyond the
66− -- last hash in the table fall within the array
67− go !_ !m [] = replicate (max 1 m + 1) empty
68− go k m (e:entries) = map (const empty) [k..i - 1] ++ e :
69− go (i + 1) (m + i - k - 1) entries
70− where i = index e
71− empty = Entry '\0' maxBound 0
72−
73−nextPowerOf2 :: Int -> Int
74−nextPowerOf2 0 = 1
75−nextPowerOf2 x = go (x - 1) 1
76− where go y 32 = y + 1
77− go y k = go (y .|. (y `shiftR` k)) $ k * 2
78−
79−fastHash :: Char -> Int
80−fastHash = fromEnum
81−
82−fromList :: String -> FastSet
83−fromList s = FastSet (AB.listArray (0, length interleaved - 1) interleaved)
84− mask'
85− where s' = ordNub (sort s)
86− l = length s'
87− mask' = nextPowerOf2 ((5 * l) `div` 4) - 1
88− entries = pad mask' .
89− resolveCollisions .
90− sortBy (compare `on` initialIndex) .
91− zipWith (\c i -> Entry c i i) s' .
92− map ((.&. mask') . fastHash) $ s'
93− interleaved = concatMap (\e -> [fromEnum $ key e, initialIndex e])
94− entries
95−
96−ordNub :: Eq a => [a] -> [a]
97−ordNub [] = []
98−ordNub (y:ys) = go y ys
99− where go x (z:zs)
100− | x == z = go x zs
101− | otherwise = x : go z zs
102− go x [] = [x]
103−
104−set :: T.Text -> FastSet
105−set = fromList . T.unpack
106−
107−-- | Check the set for membership.
108−member :: Char -> FastSet -> Bool
109−member c a = go (2 * i)
110− where i = fastHash c .&. mask a
111− lookupAt j b = (i' <= i) && (c == c' || b)
112− where c' = toEnum $ AB.unsafeAt (table a) j
113− i' = AB.unsafeAt (table a) $ j + 1
114− go j = lookupAt j . lookupAt (j + 2) . lookupAt (j + 4) .
115− lookupAt (j + 6) . go $ j + 8
116−
117−charClass :: String -> FastSet
118−charClass = fromList . go
119− where go (a:'-':b:xs) = [a..b] ++ go xs
120− go (x:xs) = x : go xs
121− go _ = ""
benchmarks/Warp.hsdeleted−17
@@ -1,17 +0,0 @@
1−{-# LANGUAGE OverloadedStrings #-}
2−
3−module Warp (benchmarks) where
4−
5−import Criterion.Main (bench, bgroup, nf)
6−import Criterion.Types (Benchmark)
7−import Data.ByteString (ByteString)
8−import Network.Wai.Handler.Warp.ReadInt (readInt)
9−import qualified Data.Attoparsec.ByteString.Char8 as B
10−
11−benchmarks :: Benchmark
12−benchmarks = bgroup "warp" [
13− bgroup "decimal" [
14− bench "warp" $ nf (readInt :: ByteString -> Int) "31337"
15− , bench "atto" $ nf (B.parse (B.decimal :: B.Parser Int)) "31337"
16− ]
17− ]
benchmarks/attoparsec-benchmarks.cabal+6−26
@@ -8,34 +8,14 @@ build-type: Simple
8
8
9executable attoparsec-benchmarks
9executable attoparsec-benchmarks
10 main-is: Benchmarks.hs
10 main-is: Benchmarks.hs
11− other-modules:
12− Common
13− HeadersByteString
14− HeadersByteString.Atto
15− HeadersText
16− Links
17− Numbers
18− Network.Wai.Handler.Warp.ReadInt
19− Sets
20− TextFastSet
21− Warp
22− hs-source-dirs: .. . warp-3.0.1.1
11+ hs-source-dirs: .. .
23− ghc-options: -O2 -Wall -rtsopts
12+ ghc-options: -O2
24 build-depends:
13 build-depends:
25 array,
14 array,
26 base == 4.*,
15 base == 4.*,
27− bytestring >= 0.10.4.0,
16+ bytestring,
28− case-insensitive,
29− containers,
30− criterion >= 1.0,
17+ criterion >= 0.5,
31 deepseq >= 1.1,
18 deepseq >= 1.1,
32− directory,
33− filepath,
34− ghc-prim,
35− http-types,
36 parsec >= 3.1.2,
19 parsec >= 3.1.2,
37− scientific >= 0.3.1,
20+ scientific,
38− text >= 1.1.1.0,
21+ text
39− transformers,
40− unordered-containers,
41− vector
benchmarks/http-request.txtdeleted−9
@@ -1,9 +0,0 @@
1−GET / HTTP/1.1
2−Host: twitter.com
3−Accept: text/html, application/xhtml+xml, application/xml; q=0.9, image/webp, */*; q=0.8
4−Accept-Encoding: gzip,deflate,sdch
5−Accept-Language: en-GB,en-US;q=0.8,en;q=0.6
6−Cache-Control: max-age=0
7−Cookie: guest_id=v1%3A139; _twitter_sess=BAh7CSIKZmxhc2hJQz-e1e1; __utma=43838368.452555194.1399611824.1; __utmb=43838368; __utmc=43838368; __utmz=1399611824.1.1.utmcsr=(direct)|utmcmd=(none)
8−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/35.0.1916.86 Safari/537.36
9−
benchmarks/http-response.txtdeleted−14
@@ -1,14 +0,0 @@
1−HTTP/1.1 200 OK
2−Date: Fri, 09 May 2014 04:24:57 GMT
3−Expires: -1
4−Cache-Control: private, max-age=0
5−Content-Type: text/html; charset=ISO-8859-1
6−Set-Cookie: PREF=ID=1a871afc4240db5e:FF:LM=1399609497:S=e5MZ0itEekjVwNcU; expires=Sun, 08-May-2016 04:24:57 GMT; path=/; domain=.google.com
7−Set-Cookie: NID=67=-WlfaDG6VSEPk7abAjrK98HBSoCD2ID6JKkUR95tEumzDmg7Fc8pSQ8; expires=Sat, 08-Nov-2014 04:24:57 GMT; path=/; domain=.google.com; HttpOnly
8−P3P: CP="This is not a P3P policy! See http://www.google.com/support/accounts/bin/answer.py?hl=en&answer=151657 for more info."
9−Server: gws
10−X-XSS-Protection: 1; mode=block
11−X-Frame-Options: SAMEORIGIN
12−Alternate-Protocol: 80:quic
13−Transfer-Encoding: chunked
14−
benchmarks/json-data/example.jsondeleted−88
@@ -1,88 +0,0 @@
1−{"web-app": {
2− "servlet": [
3− {
4− "servlet-name": "cofaxCDS",
5− "servlet-class": "org.cofax.cds.CDSServlet",
6− "init-param": {
7− "configGlossary:installationAt": "Philadelphia, PA",
8− "configGlossary:adminEmail": "ksm@pobox.com",
9− "configGlossary:poweredBy": "Cofax",
10− "configGlossary:poweredByIcon": "/images/cofax.gif",
11− "configGlossary:staticPath": "/content/static",
12− "templateProcessorClass": "org.cofax.WysiwygTemplate",
13− "templateLoaderClass": "org.cofax.FilesTemplateLoader",
14− "templatePath": "templates",
15− "templateOverridePath": "",
16− "defaultListTemplate": "listTemplate.htm",
17− "defaultFileTemplate": "articleTemplate.htm",
18− "useJSP": false,
19− "jspListTemplate": "listTemplate.jsp",
20− "jspFileTemplate": "articleTemplate.jsp",
21− "cachePackageTagsTrack": 200,
22− "cachePackageTagsStore": 200,
23− "cachePackageTagsRefresh": 60,
24− "cacheTemplatesTrack": 100,
25− "cacheTemplatesStore": 50,
26− "cacheTemplatesRefresh": 15,
27− "cachePagesTrack": 200,
28− "cachePagesStore": 100,
29− "cachePagesRefresh": 10,
30− "cachePagesDirtyRead": 10,
31− "searchEngineListTemplate": "forSearchEnginesList.htm",
32− "searchEngineFileTemplate": "forSearchEngines.htm",
33− "searchEngineRobotsDb": "WEB-INF/robots.db",
34− "useDataStore": true,
35− "dataStoreClass": "org.cofax.SqlDataStore",
36− "redirectionClass": "org.cofax.SqlRedirection",
37− "dataStoreName": "cofax",
38− "dataStoreDriver": "com.microsoft.jdbc.sqlserver.SQLServerDriver",
39− "dataStoreUrl": "jdbc:microsoft:sqlserver://LOCALHOST:1433;DatabaseName=goon",
40− "dataStoreUser": "sa",
41− "dataStorePassword": "dataStoreTestQuery",
42− "dataStoreTestQuery": "SET NOCOUNT ON;select test='test';",
43− "dataStoreLogFile": "/usr/local/tomcat/logs/datastore.log",
44− "dataStoreInitConns": 10,
45− "dataStoreMaxConns": 100,
46− "dataStoreConnUsageLimit": 100,
47− "dataStoreLogLevel": "debug",
48− "maxUrlLength": 500}},
49− {
50− "servlet-name": "cofaxEmail",
51− "servlet-class": "org.cofax.cds.EmailServlet",
52− "init-param": {
53− "mailHost": "mail1",
54− "mailHostOverride": "mail2"}},
55− {
56− "servlet-name": "cofaxAdmin",
57− "servlet-class": "org.cofax.cds.AdminServlet"},
58−
59− {
60− "servlet-name": "fileServlet",
61− "servlet-class": "org.cofax.cds.FileServlet"},
62− {
63− "servlet-name": "cofaxTools",
64− "servlet-class": "org.cofax.cms.CofaxToolsServlet",
65− "init-param": {
66− "templatePath": "toolstemplates/",
67− "log": 1,
68− "logLocation": "/usr/local/tomcat/logs/CofaxTools.log",
69− "logMaxSize": "",
70− "dataLog": 1,
71− "dataLogLocation": "/usr/local/tomcat/logs/dataLog.log",
72− "dataLogMaxSize": "",
73− "removePageCache": "/content/admin/remove?cache=pages&id=",
74− "removeTemplateCache": "/content/admin/remove?cache=templates&id=",
75− "fileTransferFolder": "/usr/local/tomcat/webapps/content/fileTransferFolder",
76− "lookInContext": 1,
77− "adminGroupID": 4,
78− "betaServer": true}}],
79− "servlet-mapping": {
80− "cofaxCDS": "/",
81− "cofaxEmail": "/cofaxutil/aemail/*",
82− "cofaxAdmin": "/admin/*",
83− "fileServlet": "/static/*",
84− "cofaxTools": "/tools/*"},
85−
86− "taglib": {
87− "taglib-uri": "cofax.tld",
88− "taglib-location": "/WEB-INF/tlds/cofax.tld"}}}
benchmarks/json-data/geometry.jsondeleted−1
@@ -1 +0,0 @@
1−{"geometry": {"type": "Polygon", "coordinates": [[[-0.939359853061118, 51.57401065198471], [-0.939440892477492, 51.57431080772057], [-0.939543636564569, 51.57460846194951], [-0.939564627628489, 51.574822653966265], [-0.939763179055758, 51.575406210178826], [-0.939787182642249, 51.575552991614], [-0.939819571231525, 51.57564949527348], [-0.939851290904264, 51.57571272360808], [-0.939975682132949, 51.57588648747347], [-0.940036822193859, 51.57598774653439], [-0.940072640734852, 51.57606090267849], [-0.940109693338918, 51.576205104339515], [-0.940125502187331, 51.57645611534466], [-0.940118623499009, 51.57662779459441], [-0.94008851367835, 51.57680555827417], [-0.939998015208524, 51.57709787034017], [-0.939928028667517, 51.577252794653916], [-0.939830628174189, 51.57740747134858], [-0.939796941313687, 51.57749078985784], [-0.939785586773343, 51.57754463746666], [-0.939770656147318, 51.57769016804059], [-0.939658154074368, 51.57824573765943], [-0.939485738834128, 51.57883313597966], [-0.93945717030888, 51.579192545519916], [-0.939524336079755, 51.57928306919007], [-0.939540939284811, 51.57931379092206], [-0.939553921057406, 51.579748206813974], [-0.939549110634237, 51.57983088690364], [-0.939520940649101, 51.58004913048237], [-0.93951863934971, 51.58014801827346], [-0.939525037302583, 51.580245186310094], [-0.939540364690294, 51.58033074581249], [-0.939561798495469, 51.58040197377017], [-0.939594984852117, 51.58046431619436], [-0.939708262827559, 51.580619996404984], [-0.939729069878358, 51.58065615108302], [-0.939759224390201, 51.58072476025555], [-0.939813615319267, 51.58093026195459], [-0.939900523550716, 51.58172321441459], [-0.939894144544868, 51.581997403240464], [-0.939910832471369, 51.58208657162566], [-0.940114353648015, 51.582457967531546], [-0.94022333049887, 51.58267475179605], [-0.940267247821581, 51.58277225843995], [-0.94038427828014, 51.583077233742756], [-0.940493362377966, 51.583289522851196], [-0.940571515796737, 51.58340442254201], [-0.940725857371931, 51.58359464061899], [-0.941198340240742, 51.584069167875626], [-0.941335307610427, 51.584261925920295], [-0.941372786463165, 51.5843261048293], [-0.941416540699353, 51.58443080287741], [-0.941461326187118, 51.584739621364996], [-0.941517445876004, 51.5849954910945], [-0.941575869597484, 51.58533860085252], [-0.941574762730556, 51.58538624677686], [-0.941565185406358, 51.58542572382202], [-0.941550002863301, 51.58545795698674], [-0.941515976834126, 51.58549361692739], [-0.941470510606583, 51.585524677868065], [-0.941423872780384, 51.585544039043356], [-0.94131509921043, 51.585566436558274], [-0.941075026707647, 51.58558675057684], [-0.940953181611661, 51.58561262652464], [-0.940734943851404, 51.58568708689612], [-0.940229533088359, 51.585883040066975], [-0.940067635923264, 51.58595531027499], [-0.939917220191166, 51.58603038143916], [-0.939797255285709, 51.586099433232604], [-0.939675637701456, 51.586177461657186], [-0.939611074554604, 51.58622273608784], [-0.939340396866166, 51.586441486256], [-0.93912244296424, 51.58662744303347], [-0.938817233975319, 51.58671729893312], [-0.938661522913105, 51.586771639765516], [-0.938087678078033, 51.586992141762096], [-0.937332636663603, 51.5873072119485], [-0.93492634290483, 51.58836081134952], [-0.934774110277819, 51.58845114531925], [-0.934663126573178, 51.588505886685766], [-0.934565467487243, 51.588546362183585], [-0.934462140700832, 51.588582290320545], [-0.934337145222589, 51.58861892084846], [-0.934213782000904, 51.588647473549656], [-0.934055887760941, 51.588671216763295], [-0.933259701136762, 51.58864510257983], [-0.933213278816969, 51.588716614209304], [-0.932681740160827, 51.588792708227174], [-0.931992471253759, 51.58900853446031], [-0.930629113767652, 51.58946908647644], [-0.928525036745892, 51.59005953842682], [-0.928533690860491, 51.59024394687689], [-0.928456010745829, 51.59047792078815], [-0.928256501298223, 51.5906748158337], [-0.927916132025856, 51.59066181734799], [-0.927671608556404, 51.590624516635486], [-0.927319567022116, 51.59061680481465], [-0.926850285435352, 51.59062240702726], [-0.926313746570405, 51.59066425819173], [-0.925516790702947, 51.59079184232522], [-0.925387133168341, 51.59078076476673], [-0.925293323156809, 51.59077990606886], [-0.925202187496562, 51.59078806346173], [-0.925112304116411, 51.59080432476366], [-0.925036768134577, 51.59082431403807], [-0.924968299737815, 51.59085066215826], [-0.924899640304234, 51.59088510100373], [-0.924851228495836, 51.590917926896914], [-0.924734051019008, 51.59105082982951], [-0.924694255912291, 51.59108553291224], [-0.924446018071168, 51.59126668934789], [-0.924204972773907, 51.59150995377465], [-0.923492520665307, 51.59215352189589], [-0.922775141969353, 51.59288246146081], [-0.922298613651092, 51.59343737077436], [-0.922101568270595, 51.59365046303728], [-0.92149319027045, 51.59422483935332], [-0.921029930136652, 51.59464499018023], [-0.919455791303858, 51.595519790418045], [-0.919908472816787, 51.59560757835559], [-0.919902358174605, 51.595621908790214], [-0.919721503870405, 51.59588190272939], [-0.919513222918683, 51.59614164398608], [-0.919057326435374, 51.59661490568889], [-0.918991959815932, 51.59669253146064], [-0.918853979663433, 51.59690975873926], [-0.91882720841051, 51.59694278142396], [-0.918711889332325, 51.597056812913756], [-0.918614808732714, 51.59713234806153], [-0.918297245740306, 51.59749448485627], [-0.918073703114389, 51.59778825130676], [-0.917853804369843, 51.59811082427763], [-0.917772408698363, 51.59831598343439], [-0.917709563771812, 51.59853030520902], [-0.917692745480418, 51.59856971355161], [-0.917634249201942, 51.59866178857289], [-0.917443039919903, 51.59887043094418], [-0.917335250471836, 51.598971042984616], [-0.916888284039272, 51.599309503426845], [-0.916921110547038, 51.59938623548714], [-0.916942485633783, 51.5995195094582], [-0.916937652924948, 51.599601289122916], [-0.916945811778801, 51.599683188627004], [-0.916964246289877, 51.599757989575366], [-0.917049297107238, 51.59994580090974], [-0.917089705367533, 51.60000731699611], [-0.917171120773417, 51.60010517795964], [-0.91752823274465, 51.60044925531009], [-0.917834023417531, 51.600765883511485], [-0.917913079603466, 51.600902386385464], [-0.918033251654948, 51.60107073894696], [-0.91851090277833, 51.601507638962644], [-0.918694916056997, 51.601663091331545], [-0.919167224655989, 51.60214309940451], [-0.919302231291783, 51.6024167896932], [-0.919552009673002, 51.60266096432073], [-0.919812571846437, 51.60293760761218], [-0.920091738726093, 51.60358667644501], [-0.920208566517809, 51.603592246724574], [-0.920644522919282, 51.60359715428394], [-0.921093152621479, 51.6036156641763], [-0.921168285587618, 51.603613657034074], [-0.921469264587163, 51.6035867495928], [-0.921584776688781, 51.603586911416876], [-0.921718864440287, 51.603595336217005], [-0.921999521996191, 51.60363387995426], [-0.922136050325758, 51.603661209181794], [-0.922248015684399, 51.60368921195661], [-0.922346882036963, 51.60372159023333], [-0.922478548042792, 51.60377135359644], [-0.922605777045377, 51.603825571929555], [-0.92269948345521, 51.60389297005248], [-0.922855181916126, 51.60396453348124], [-0.922908065211369, 51.60398749776935], [-0.923525984356841, 51.604174796116844], [-0.923689774691443, 51.6042095667925], [-0.923842334751645, 51.60423074681459], [-0.924020987014581, 51.604247669912816], [-0.924152253615336, 51.604253368572344], [-0.924379056519158, 51.60424915231234], [-0.924491916632975, 51.60423939614583], [-0.925129396784027, 51.604149022807746], [-0.925308707040747, 51.60413807581467], [-0.925396812395019, 51.604137083863186], [-0.925816640142735, 51.60415261457396], [-0.926339243350925, 51.604157394450915], [-0.926627592983669, 51.60417621577326], [-0.928219342008724, 51.60433911850777], [-0.928540897883304, 51.60435823822504], [-0.928666454251138, 51.6043611822271], [-0.928925123731038, 51.60435275210506], [-0.929272427371303, 51.60432085222454], [-0.929350681081097, 51.604308977474346], [-0.929525019586135, 51.60426381040009], [-0.929730308556221, 51.60419195021111], [-0.929806393059037, 51.60414948374236], [-0.929854111423592, 51.60408517871234], [-0.929877477717563, 51.604012559228565], [-0.929880189120251, 51.60395863398061], [-0.930157001898001, 51.603362311928585], [-0.930233415197893, 51.60324431822904], [-0.930397156019029, 51.60303540508514], [-0.93058677482955, 51.602831223239896], [-0.930747612253953, 51.60268432562219], [-0.931065151604954, 51.602443542878724], [-0.931358556224333, 51.60224659876122], [-0.931494751600125, 51.602165114969594], [-0.931807666849096, 51.601998019766675], [-0.932115553298882, 51.60186055047904], [-0.932344261944379, 51.601774512081256], [-0.932581062209752, 51.601712824287226], [-0.932837650566022, 51.60166929919289], [-0.93304760157037, 51.60164423223924], [-0.933247236692325, 51.60162806284857], [-0.933524572231589, 51.601623388892406], [-0.93367307135076, 51.60163283011416], [-0.933854562367985, 51.601651562386515], [-0.934222940436163, 51.60170526005669], [-0.934582321335698, 51.60177326158339], [-0.935176916778695, 51.60190903449902], [-0.935323237909383, 51.60194992468383], [-0.935449328012611, 51.60199153042619], [-0.935555166022244, 51.60203475076641], [-0.935754957696255, 51.60213547009268], [-0.935920944220561, 51.60219991608389], [-0.936105992086264, 51.60225194623237], [-0.936251123590137, 51.60228203448254], [-0.9362553703842, 51.602285669620606], [-0.935954861941404, 51.603034649313756], [-0.936025513047831, 51.60328615677915], [-0.937604653681525, 51.60374194595848], [-0.937842729718605, 51.6037494948452], [-0.937998245297976, 51.60376798569096], [-0.938149157504488, 51.60379812385097], [-0.938282536474463, 51.60383709493093], [-0.938398403200176, 51.60388400001471], [-0.938549544157173, 51.60396629131982], [-0.938542113846477, 51.60403725821696], [-0.938540670189083, 51.60403724516617], [-0.938690470772444, 51.60417707075241], [-0.93885671831091, 51.60429276731543], [-0.938949655717409, 51.60433227129961], [-0.939171393952754, 51.60435945147724], [-0.939491406642938, 51.60438302306183], [-0.939580914110842, 51.60438383145672], [-0.939698081584302, 51.604374998744255], [-0.939860253923854, 51.60435578228165], [-0.940131370864495, 51.60430877574863], [-0.940224037565311, 51.60429792302206], [-0.941065905352937, 51.604358569226044], [-0.941456261791824, 51.60439985396626], [-0.94172260946072, 51.604433725629356], [-0.942065117075164, 51.604483568721975], [-0.942405972956444, 51.60454238758566], [-0.942542307804962, 51.60457868292929], [-0.942668453620936, 51.60461848302318], [-0.942754322773386, 51.60465162617505], [-0.942930037674105, 51.6047332338937], [-0.94300827141212, 51.60478429141865], [-0.943050642772121, 51.60482513526179], [-0.943095505071305, 51.604883085645305], [-0.943175837511794, 51.60503037259752], [-0.943199044776033, 51.60508812802956], [-0.943264927978451, 51.605360268787045], [-0.94328295289835, 51.6055168856955], [-0.943285556153251, 51.605653582182974], [-0.94327790338372, 51.60573443814757], [-0.943262026480571, 51.60579633763445], [-0.943228365851772, 51.605877858692274], [-0.943092212068021, 51.60614458434088], [-0.943074097962666, 51.60624063192375], [-0.943061365824471, 51.606415854446915], [-0.943044862244347, 51.60650472320056], [-0.943017897594943, 51.606608783583646], [-0.942979591589439, 51.606703750216774], [-0.942905884027612, 51.60683076806164], [-0.942741267849139, 51.60707925374213], [-0.942655006715899, 51.607249318295594], [-0.942630361430127, 51.60731563455148], [-0.942616263944651, 51.607425205688976], [-0.942621958529523, 51.60749089598715], [-0.942636336634899, 51.60755576531453], [-0.942660904708633, 51.607617129739225], [-0.942696981288364, 51.607680396114986], [-0.942747433102709, 51.60774648940761], [-0.942856244975984, 51.6078490746924], [-0.94299552290573, 51.60794563997599], [-0.943040847342192, 51.60798381288104], [-0.943186973159248, 51.608158666884215], [-0.943285889122319, 51.60825217104693], [-0.943509689787491, 51.60844031193307], [-0.94379690141149, 51.609007570967925], [-0.943824004868445, 51.60908424372538], [-0.943831400135399, 51.609201201602104], [-0.943839541642426, 51.60922375393887], [-0.943852077204152, 51.6092436483043], [-0.943874740412961, 51.60926273459518], [-0.943900416430683, 51.60927645299323], [-0.944008015202393, 51.60930709311221], [-0.944074894993692, 51.60934995527111], [-0.944126815315737, 51.60941516198104], [-0.944143328071964, 51.60945037786937], [-0.944150844233183, 51.609499899486615], [-0.944148608042361, 51.60953404761941], [-0.944074023202655, 51.60969882315075], [-0.94403415265091, 51.60986121332522], [-0.944017357658548, 51.60996266784037], [-0.943992023164905, 51.61030771903426], [-0.943965568458423, 51.61051428886229], [-0.943938629028152, 51.61067949277199], [-0.943919488028492, 51.61075754789674], [-0.943885949921455, 51.61083367520212], [-0.943827406881077, 51.61092935920088], [-0.943739589608875, 51.61104186395993], [-0.943638735204063, 51.61115604969767], [-0.943533757272514, 51.611261206608894], [-0.942952360107171, 51.61179457356613], [-0.942768364001955, 51.61194397664764], [-0.942436714102017, 51.61217027698273], [-0.942010518369458, 51.61248743929258], [-0.941742162181165, 51.61266215641604], [-0.941369087685306, 51.61286829880399], [-0.941218061678922, 51.612965845186196], [-0.941055044244821, 51.613082165678385], [-0.940962318642569, 51.61315685920963], [-0.940802313735133, 51.613329853845215], [-0.940532273923746, 51.613638528438315], [-0.940201080800705, 51.61403027273604], [-0.940058816377521, 51.614185443187054], [-0.939985695447699, 51.614286388653916], [-0.939953592073967, 51.614362527773245], [-0.939906859457064, 51.614508669589505], [-0.939802341993177, 51.61490335803689], [-0.939554942446072, 51.615603370947234], [-0.939452722231603, 51.61596121406953], [-0.939421935085161, 51.61604275989804], [-0.939387192811998, 51.616108085051245], [-0.939207265482904, 51.61639149465681], [-0.939036585027605, 51.61671185322904], [-0.938852844916865, 51.61697274874371], [-0.938765881571911, 51.61710953487875], [-0.938636321443754, 51.617400592062225], [-0.93858227703968, 51.617550263869646], [-0.938563060896774, 51.61763101488344], [-0.938557821588965, 51.617793716095726], [-0.938568952285691, 51.6178738422429], [-0.938586194898738, 51.61793963701825], [-0.93864824402059, 51.61806608070808], [-0.938712639101221, 51.61815388154161], [-0.938801458484915, 51.61824729803767], [-0.938902019778203, 51.61833272809444], [-0.939001577491258, 51.61839926656718], [-0.939080060597956, 51.6184404379885], [-0.939144458958051, 51.618466196342986], [-0.93924483456823, 51.61849767462955], [-0.939389936057716, 51.61853135511866], [-0.939533886937889, 51.618552436752374], [-0.939605967169062, 51.618558482633226], [-0.939704125343146, 51.618561167280205], [-0.940011869234288, 51.61855765138392], [-0.940970156479417, 51.61846828865034], [-0.942814559287174, 51.61834913395653], [-0.9433943585448, 51.61832378069166], [-0.943791844341078, 51.61831207069643], [-0.944095316626396, 51.61830580819228], [-0.944345189840605, 51.61830625638639], [-0.944633949874169, 51.618311549349706], [-0.944866264500346, 51.618321729423634], [-0.945069571918896, 51.61833704343469], [-0.945259736594118, 51.618358533188456], [-0.945405071369022, 51.6183823175338], [-0.945538707551366, 51.61841229079249], [-0.945670733169093, 51.618449442740584], [-0.945789657802543, 51.61849097274293], [-0.945898390514756, 51.618536007789324], [-0.946002624502939, 51.61858819565799], [-0.946144975691139, 51.61867849034559], [-0.946290660655923, 51.61881197458077], [-0.946424293873759, 51.618966930407886], [-0.94648587943588, 51.619052004215185], [-0.946597289998464, 51.61923103785771], [-0.946748500992991, 51.619500344620654], [-0.946865282768134, 51.619759451627154], [-0.94692090631825, 51.619852564183816], [-0.946986743272162, 51.619941272483025], [-0.947121992710119, 51.62008904866086], [-0.947221067183078, 51.620177155655796], [-0.947357337089385, 51.62028088174252], [-0.947636341593443, 51.62045871900467], [-0.947732020809812, 51.62050633282523], [-0.947832261440868, 51.62054409665008], [-0.948024909405708, 51.6205835873772], [-0.948272727755043, 51.62061098363029], [-0.94903310890345, 51.62064836261257], [-0.949342820854191, 51.62068530212313], [-0.949548509996597, 51.62072310869445], [-0.949603327033706, 51.620726296510135], [-0.94966121922192, 51.62072141934501], [-0.949725095662238, 51.62070760405018], [-0.949813979767225, 51.620674230793945], [-0.949850856696741, 51.620766275113425], [-0.949938127431095, 51.62092800552347], [-0.95012170684362, 51.62142328688538], [-0.950137689181391, 51.621481875301626], [-0.950144591409982, 51.621558365780544], [-0.950143525838059, 51.62166715485939], [-0.950086848280287, 51.62218276713024], [-0.950081566444785, 51.62234906486587], [-0.950091380322934, 51.6227375905417], [-0.950012857804674, 51.623198158520914], [-0.949963053357781, 51.62366617649237], [-0.94993621019599, 51.62382778558582], [-0.949887611273865, 51.62405573809743], [-0.94981748429385, 51.62434014525264], [-0.949698012983878, 51.6246969431444], [-0.949601071539472, 51.62520410239216], [-0.949519655994856, 51.62547671925938], [-0.949509640700394, 51.62553507516918], [-0.949509569744091, 51.62560071332227], [-0.949517625184728, 51.6256898023632], [-0.949539397678852, 51.62581048474923], [-0.949602831958219, 51.626066413978656], [-0.949622600072634, 51.6262113557699], [-0.949625807500304, 51.62644786389373], [-0.949588359660548, 51.62688092470566], [-0.949587162842075, 51.62718303218221], [-0.949593421398238, 51.627287390862], [-0.949641886384285, 51.62762860642186], [-0.949677564559904, 51.627772791296934], [-0.949732061930258, 51.62791534613564], [-0.949847071945823, 51.62812767746571], [-0.95005020451512, 51.62890367131774], [-0.949860358893705, 51.62924185674224], [-0.949849459019953, 51.62927592739189], [-0.949848649628705, 51.62931098742953], [-0.949857806222275, 51.62935243070728], [-0.949882540677514, 51.62940750068883], [-0.949782851646605, 51.62940750843079], [-0.949684104107472, 51.6296170289926], [-0.949619670293909, 51.62984214210067], [-0.949589348281571, 51.62990391300069], [-0.949478823262764, 51.63006027755304], [-0.949419643728549, 51.63018293320961], [-0.949378577882241, 51.63033452402259], [-0.949364251310331, 51.63051692549393], [-0.949339228920643, 51.63059942443184], [-0.949248633732607, 51.63076855530058], [-0.949181283974238, 51.630869557872636], [-0.949044504574139, 51.63103647701982], [-0.948893935504611, 51.63136242402941], [-0.948761069414249, 51.631297394415576], [-0.948669492362367, 51.63125880992652], [-0.948537801268757, 51.63120547966423], [-0.948447461288637, 51.63117589768262], [-0.948353982967507, 51.63115707745748], [-0.948302104865814, 51.63115121794117], [-0.948079606840815, 51.63115102360314], [-0.947964190602531, 51.63114369566099], [-0.94782149485015, 51.63112892992514], [-0.947725107052886, 51.63111098229264], [-0.947684910040859, 51.63109983219839], [-0.947483021604023, 51.63102069524269], [-0.947447137482345, 51.63101048287877], [-0.947306094892948, 51.630986739722026], [-0.947000710620611, 51.63094713644845], [-0.946674033898238, 51.6308911565172], [-0.946364247153943, 51.63079216747898], [-0.946230490849763, 51.63076579091048], [-0.946172752135344, 51.63076347450912], [-0.94612066649297, 51.630766603772976], [-0.945914796224295, 51.63079712600587], [-0.94583241748209, 51.63079818492752], [-0.945382953779145, 51.63067905708907], [-0.945085984219956, 51.63058827220451], [-0.944883205963743, 51.630547786680644], [-0.944304065189339, 51.630538086402446], [-0.94394898927073, 51.630523204990325], [-0.943611477254356, 51.63049858971805], [-0.943603681926519, 51.6307098224617], [-0.943277115569317, 51.63102249010073], [-0.943359247728321, 51.63109426279834], [-0.942862682241593, 51.631385618132356], [-0.942777562378065, 51.63144239822567], [-0.942532313252267, 51.63161282917167], [-0.942337892928893, 51.63177202827151], [-0.94226606523137, 51.631816339444626], [-0.942197377359527, 51.63184988892168], [-0.942115813951467, 51.631877927416205], [-0.941937005967162, 51.631924871353945], [-0.941512981586086, 51.63201636159427], [-0.94144898217334, 51.6320346671529], [-0.94125937051438, 51.632111184999914], [-0.940790185204025, 51.6323425346351], [-0.940501042462563, 51.632535943664614], [-0.940243238615803, 51.63268647504363], [-0.940131608045529, 51.632764593869275], [-0.939328651391563, 51.63361514453957], [-0.939011405652477, 51.634145481445906], [-0.93882930544315, 51.63451878632893], [-0.93850479164515, 51.63486472819315], [-0.93841585373771, 51.63483694950617], [-0.938308667759282, 51.63503379600045], [-0.938237520065274, 51.63511048065125], [-0.938174497877949, 51.635148574806536], [-0.938097155068085, 51.63518114448376], [-0.938014243480848, 51.63520467214815], [-0.937885103100742, 51.635227781700706], [-0.937899482630853, 51.63529265131639], [-0.937852791962712, 51.635312010611116], [-0.937756752174709, 51.63534081433219], [-0.93768849662133, 51.635355482713884], [-0.937445207164159, 51.63537845841074], [-0.937282775985471, 51.6354039635962], [-0.936848828519967, 51.635485456519916], [-0.935951432459366, 51.63561220386278], [-0.935719677036262, 51.635636179646525], [-0.935420148631615, 51.63565414571281], [-0.935249454884316, 51.63560044703531], [-0.935077590540852, 51.635535048401415], [-0.934717727795324, 51.63535285185533], [-0.934413155884105, 51.635216113905294], [-0.934240481559584, 51.635123731852076], [-0.934130824273522, 51.63505529964683], [-0.934018404467151, 51.63498144729724], [-0.93379675026591, 51.63482118293064], [-0.933679892303923, 51.6347517857655], [-0.933595523374065, 51.63471415412531], [-0.933350473747258, 51.63462740768713], [-0.933261876876166, 51.63458524160035], [-0.933052343088727, 51.63446285066096], [-0.932887751506176, 51.63439571653097], [-0.932638117941304, 51.63431971687678], [-0.932307197466639, 51.63419801967628], [-0.931343887912331, 51.63380981222079], [-0.931071830619705, 51.63376597498289], [-0.930956833347264, 51.63374065092008], [-0.930823331188951, 51.63370346918478], [-0.930701576222194, 51.633658301797674], [-0.930601553796263, 51.63361063468632], [-0.930506119022842, 51.63355221932683], [-0.930386739592999, 51.633467510133144], [-0.930286034494439, 51.633387466714524], [-0.930225334024314, 51.63332666999925], [-0.930188937852857, 51.633276884582266], [-0.930114567680391, 51.63312155131756], [-0.92999324620862, 51.63293521875163], [-0.929900400330813, 51.63282827174111], [-0.929602366751531, 51.6325378240622], [-0.929499431873266, 51.632429885607195], [-0.929341000864788, 51.63222433167361], [-0.929059923028374, 51.631889079042224], [-0.928963213558906, 51.63176231446386], [-0.928896162303318, 51.6316645934755], [-0.928844852932023, 51.631573310156845], [-0.928688841592085, 51.63126527289447], [-0.928672375509884, 51.6312282570475], [-0.928615004479859, 51.631026321392014], [-0.928599834825331, 51.63099561149414], [-0.928552267379979, 51.63092953870757], [-0.928477466267079, 51.630854225808044], [-0.928389580173335, 51.630782390113474], [-0.928294323595921, 51.6307167812279], [-0.928190294396403, 51.63065558801307], [-0.928078937075949, 51.630598823630024], [-0.927494137115659, 51.630339021667446], [-0.927177150281751, 51.63017967221046], [-0.927053070740772, 51.63011110151437], [-0.926922044883713, 51.63003077810591], [-0.926774152423019, 51.6299305188448], [-0.926569924361936, 51.62976860145066], [-0.926465515994788, 51.62966244509719], [-0.926222881099496, 51.62935271335746], [-0.925807083215573, 51.62885077488713], [-0.925685153671251, 51.62869140695483], [-0.925627779063265, 51.628612654944924], [-0.925107975398826, 51.62780494620014], [-0.925039238852947, 51.627717997425265], [-0.924853081975605, 51.627525670804864], [-0.924566287633664, 51.62725149768458], [-0.924018135317732, 51.62666651663998], [-0.9236755124427, 51.62631000590676], [-0.923506463123086, 51.62618886774415], [-0.92325024557972, 51.62602736696645], [-0.923179326155173, 51.62597186775246], [-0.923151247824846, 51.62593744208942], [-0.923025917353845, 51.62573937605691], [-0.922746731858051, 51.625388839233764], [-0.922647729925315, 51.625421200084226], [-0.922438316532782, 51.62517470633975], [-0.922266691774008, 51.62491866820555], [-0.922176577184834, 51.624819832363215], [-0.921722712186069, 51.62440384906751], [-0.921324388846087, 51.624082786314446], [-0.921078577970903, 51.623909687134365], [-0.920860652296657, 51.62377910436709], [-0.920574889783577, 51.623646099345635], [-0.920239048968319, 51.623492851580735], [-0.920014292502202, 51.62371107994427], [-0.919774493442185, 51.623954346092496], [-0.9196346398006, 51.62406455586703], [-0.919395541436808, 51.62427815528515], [-0.919291601043514, 51.624396787581134], [-0.919216417933559, 51.6245210794288], [-0.919153464283899, 51.62467785367513], [-0.919134125069682, 51.624762197061855], [-0.919115026043568, 51.62495803894169], [-0.919049238753011, 51.62517323267518], [-0.919009465019033, 51.625266379578875], [-0.918926652164549, 51.625407685106715], [-0.91889138185638, 51.62549368011671], [-0.918887531877765, 51.62553410703284], [-0.918896749679156, 51.62569334383204], [-0.918892707420934, 51.62574186144837], [-0.918872585162246, 51.62579832350382], [-0.918836276012485, 51.62586722482348], [-0.918763089019947, 51.62596815648993], [-0.918486277330256, 51.626309088016214], [-0.918317614737411, 51.62653682130949], [-0.917905561785174, 51.626975413689514], [-0.917718470441796, 51.62724883363936], [-0.917588198962995, 51.627380709193844], [-0.917518986462533, 51.627435819379606], [-0.917391270738013, 51.627520961779815], [-0.916852199941663, 51.62783249660931], [-0.916708494011591, 51.62822500463541], [-0.916564194300437, 51.62882431452802], [-0.91642514281193, 51.62950639562586], [-0.916399138398425, 51.62974892972319], [-0.916394191477189, 51.62995659074321], [-0.917260413231125, 51.62992321851857], [-0.917422640699178, 51.63166639247214], [-0.91745600722272, 51.63232848375385], [-0.917204699151121, 51.632324368705305], [-0.916787813832452, 51.632356490901394], [-0.916473041038736, 51.63240843616508], [-0.91615824611563, 51.63246127954521], [-0.916096846672852, 51.632491284427324], [-0.916000979824314, 51.632573122584574], [-0.916035541448316, 51.63300234215989], [-0.916058746179642, 51.633180590521675], [-0.916070697537387, 51.63322475979131], [-0.916098260729099, 51.63328076225654], [-0.916287121367376, 51.6334803208717], [-0.916556537933578, 51.63369500893812], [-0.916833436931067, 51.63389897542989], [-0.916980624704717, 51.63396776999687], [-0.917236275570907, 51.634093312450645], [-0.91746761535009, 51.63414759643489], [-0.917599467742121, 51.63382870989293], [-0.917652284973834, 51.63367364156546], [-0.917677934007693, 51.63362802065708], [-0.917745133700401, 51.63359716923921], [-0.917749446066394, 51.633598108140106], [-0.917778102484095, 51.633608262991594], [-0.918084580428658, 51.633662338963], [-0.918258883815884, 51.633684625273325], [-0.918506861448772, 51.63370758977881], [-0.918953829589691, 51.63374767133924], [-0.919245145699076, 51.633771033193085], [-0.919300707852053, 51.63386505735126], [-0.919518444759651, 51.63449197843591], [-0.919277685382965, 51.63446908250848], [-0.919031520477806, 51.63467362436313], [-0.918786199566619, 51.63490335001199], [-0.918632752044247, 51.63503681158531], [-0.918623327237537, 51.63512933850577], [-0.918590569006466, 51.635413172104], [-0.918679820058316, 51.63554886817429], [-0.918329488250497, 51.63557621368664], [-0.918276435808259, 51.635741170885815], [-0.918247752304029, 51.6360358318421], [-0.918226764712395, 51.6364321689642], [-0.918316733144818, 51.63702374696847], [-0.918287332378286, 51.63783452012518], [-0.918306713699577, 51.63835621240955], [-0.918316674296085, 51.639213205140855], [-0.918347519668651, 51.639799742499974], [-0.918322169732004, 51.63995416480466], [-0.918318885834364, 51.64003146244247], [-0.91832686087795, 51.64012145202931], [-0.91837911416845, 51.640354816042915], [-0.918418495846573, 51.64070405330022], [-0.918530296534871, 51.64128953760163], [-0.918512952473936, 51.64147190762244], [-0.918367217757134, 51.64200916315153], [-0.917905817511154, 51.6420255938785], [-0.917874522823857, 51.64200462484983], [-0.9178264462409, 51.64196012300076], [-0.917792775459127, 51.641917552189355], [-0.917773553228143, 51.64187511449974], [-0.917765526057023, 51.64184806570082], [-0.917757894232724, 51.6417436926823], [-0.917749532884981, 51.64142711089125], [-0.917739557627689, 51.64136048104305], [-0.917720785029217, 51.641299165096676], [-0.917688816437575, 51.64124581999865], [-0.917649452591449, 51.641199600032465], [-0.917568381483579, 51.64114490323613], [-0.917433423830488, 51.64098630616572], [-0.917315173490429, 51.64079369481265], [-0.916601390868836, 51.640243120219885], [-0.916329281834837, 51.640018517003504], [-0.916001068304932, 51.63966211774633], [-0.915790319174844, 51.63947044935813], [-0.915502073944432, 51.63913509831614], [-0.915393357554307, 51.63902799332443], [-0.915169439572157, 51.63884339546647], [-0.914312592230519, 51.638234837864296], [-0.913969150495335, 51.63797270396478], [-0.913808719070197, 51.63773204326735], [-0.913709021859032, 51.63761063348384], [-0.913238840648949, 51.637814889395024], [-0.912211197236081, 51.63818662075986], [-0.912057780107923, 51.6382571327065], [-0.911911629192503, 51.63832591344631], [-0.911683066608314, 51.6384568717294], [-0.911571655864317, 51.638583520328496], [-0.910821072629623, 51.63897039510019], [-0.910799442348496, 51.63890815232427], [-0.910457034748542, 51.63884473254883], [-0.90959863753988, 51.63872527019996], [-0.909397970101408, 51.639078576087414], [-0.909048252097236, 51.63925965643008], [-0.909362542404515, 51.63959166868019], [-0.90780907162756, 51.64013291512084], [-0.906217399025103, 51.640939038154336], [-0.905898125060113, 51.64111499768922], [-0.905490384709512, 51.641363863281036], [-0.905329841704473, 51.64154939281248], [-0.905189541321435, 51.641794455508446], [-0.90489098319803, 51.64194992468491], [-0.904781623731163, 51.641990266433346], [-0.904676706895303, 51.64202615370086], [-0.904609919053975, 51.64203901826923], [-0.904237228330216, 51.64209218907456], [-0.90337364044862, 51.64224597828853], [-0.902975191138407, 51.642348358507896], [-0.90292303291413, 51.6422939216028], [-0.902563354675933, 51.64240655335107], [-0.902346768622897, 51.642458479170756], [-0.900824166346957, 51.64291090498388], [-0.900831401206159, 51.64297031739377], [-0.900456613238591, 51.64299018760407], [-0.900019098619797, 51.64297440185565], [-0.899740380937974, 51.64290615240652], [-0.899740489711103, 51.64290165761423], [-0.899316872364163, 51.642849133775655], [-0.899203336991784, 51.642822893203494], [-0.898949902655656, 51.64272520647125], [-0.898783095909619, 51.642631028913314], [-0.898613530793898, 51.64253143027416], [-0.898274969154989, 51.64230885935864], [-0.898003026265053, 51.642080618381755], [-0.897815191816853, 51.641840577798526], [-0.897681652652772, 51.6416262230417], [-0.897327401428262, 51.64091885338664], [-0.896908641882592, 51.6401308512027], [-0.896689777704333, 51.63985994571793], [-0.896199107519928, 51.639356299928586], [-0.896147069948886, 51.63929736526477], [-0.896071667668875, 51.63912941223961], [-0.896034388155249, 51.63881974973283], [-0.89604243255033, 51.63866696761571], [-0.896079873457203, 51.63849378104931], [-0.896158355572289, 51.63829670279626], [-0.896345617779906, 51.63796397393339], [-0.896436991088377, 51.637771512438086], [-0.896627579786388, 51.63748017587825], [-0.896853716275347, 51.63721255114492], [-0.896930541034958, 51.63714313797598], [-0.897052325259386, 51.63706695367484], [-0.897622203318074, 51.636806151704704], [-0.897875248140837, 51.636679946210485], [-0.898045509693898, 51.63657094674504], [-0.898161794997489, 51.63648302058021], [-0.898300490282884, 51.636364732965696], [-0.898761753797595, 51.63587451909389], [-0.898944791614438, 51.635595696246455], [-0.899167964890093, 51.63497197055003], [-0.899296205851425, 51.63450920414348], [-0.899574174378538, 51.633591065468096], [-0.89965934952667, 51.63323579470252], [-0.899745200652967, 51.632733067337156], [-0.89977291429982, 51.632065248259224], [-0.899749317297925, 51.63190587518938], [-0.899730833669311, 51.631833768913715], [-0.899698165870897, 51.631750739777836], [-0.89965967663145, 51.63166945441679], [-0.899415121605884, 51.63126703489972], [-0.899342021743563, 51.6311233827535], [-0.899274678557411, 51.630980683675816], [-0.899221406706553, 51.63067446858268], [-0.899099405183406, 51.63046202142283], [-0.899036514315775, 51.63037421293725], [-0.898969246754073, 51.63028816171176], [-0.898790586842518, 51.63008867047265], [-0.898592010806669, 51.62987640386868], [-0.898497321924236, 51.62978919602221], [-0.898330098469121, 51.62965455114822], [-0.898092642525963, 51.62949676796704], [-0.897090362270362, 51.62894426419184], [-0.896737033461809, 51.62879887742956], [-0.896347312922056, 51.6286648367393], [-0.895633444660858, 51.62837398981453], [-0.895432402381131, 51.628264199314984], [-0.895328663542796, 51.62819308870188], [-0.895257753282041, 51.62813847178444], [-0.895144755729953, 51.62803220648194], [-0.894948239644532, 51.627795675481295], [-0.894944118635818, 51.62766795529761], [-0.894659948504904, 51.62723368184], [-0.894597856997988, 51.62711350846984], [-0.894557343909314, 51.62699713484451], [-0.894469809950127, 51.62655661915932], [-0.894297931114171, 51.625960652861906], [-0.894027819576293, 51.62530531541029], [-0.893931965007508, 51.62514795788166], [-0.893770350871199, 51.62496210671055], [-0.893637995566781, 51.62476124514902], [-0.893507481839104, 51.62466290563429], [-0.892108104715385, 51.62369479825078], [-0.891788795844237, 51.623459800649094], [-0.891922368328922, 51.62337294285213], [-0.891402229815371, 51.62296161084893], [-0.891224922435199, 51.622768414566416], [-0.890089770742591, 51.621276764770215], [-0.890188416566163, 51.62120036880181], [-0.889947380146256, 51.62101466068101], [-0.889727152716072, 51.62086421627997], [-0.889328903798693, 51.62066892786315], [-0.889153387824523, 51.620758083474584], [-0.888409981594066, 51.6201459098237], [-0.888016456293258, 51.619876030785385], [-0.887588982852847, 51.619754191291285], [-0.887143566599165, 51.61965735685454], [-0.88701981132148, 51.61963820065132], [-0.886790744842007, 51.619613550199404], [-0.886603228328527, 51.619602780759124], [-0.886388075513318, 51.619599841439666], [-0.886090409498186, 51.61960421155123], [-0.8851368584814, 51.61967159165818], [-0.883828125903616, 51.61979133688442], [-0.883515973065361, 51.619797361107345], [-0.883424375160774, 51.6198216668555], [-0.883259776293847, 51.619877648328995], [-0.883163867754863, 51.61990101371408], [-0.883044634749604, 51.619815357981636], [-0.881854770311083, 51.61956485587701], [-0.881704286246311, 51.61951666620604], [-0.881635675440863, 51.619487239450166], [-0.881560131370525, 51.619446057447796], [-0.881477720403852, 51.619390423316226], [-0.881374708667671, 51.619291432867335], [-0.880834298239682, 51.61853547912722], [-0.880617549323506, 51.618127888748454], [-0.880388345702594, 51.61816796449318], [-0.879226788544387, 51.6185884841998], [-0.878534686661489, 51.61883184500677], [-0.878385021629543, 51.61898507235025], [-0.878148819949825, 51.61913297697072], [-0.878102165244257, 51.61915051459153], [-0.87804120240859, 51.61916252048532], [-0.877967464227806, 51.619165412606506], [-0.877896924603018, 51.61915574690363], [-0.877839648002824, 51.61913541789456], [-0.877812586845032, 51.61911987344738], [-0.877382402665225, 51.61869944717381], [-0.877261875140598, 51.61866682400238], [-0.877087293116294, 51.618600414623565], [-0.876592344555959, 51.61846350297477], [-0.876408990128558, 51.61845995037962], [-0.876374465270622, 51.61845422502283], [-0.876347205240439, 51.61844677083749], [-0.87630299358364, 51.61842386858449], [-0.876241963569583, 51.618380124514495], [-0.876216636094276, 51.618352907107045], [-0.876152781748704, 51.618131100785114], [-0.876106882196741, 51.61811807314475], [-0.876305643178539, 51.617614643124426], [-0.875030363348109, 51.6174927341714], [-0.874705473526163, 51.61748872204597], [-0.874564111923802, 51.6174810731233], [-0.874279482039409, 51.61730930128958], [-0.874259717266618, 51.61699889890464], [-0.874416434195306, 51.61673604585861], [-0.874423036602998, 51.61652750219062], [-0.870144618410033, 51.61769939147719], [-0.870074692270606, 51.617607003497994], [-0.869665459226217, 51.61768399010514], [-0.869137937974611, 51.617812887107476], [-0.868711126950696, 51.61789959196275], [-0.868460959800069, 51.617969115035805], [-0.866874516019656, 51.61827841686334], [-0.866642434191741, 51.6183175388698], [-0.866517885416195, 51.61833072340073], [-0.866392071649004, 51.61833670224208], [-0.865776872894858, 51.61833166083683], [-0.865633662902087, 51.618340168339564], [-0.865493072065054, 51.618359490991885], [-0.864874419821269, 51.618492883413026], [-0.864829070270363, 51.61851582340227], [-0.8648101986804, 51.61846169086974], [-0.864778464993556, 51.618402038980314], [-0.864733824417545, 51.61833866562683], [-0.864681918741689, 51.61827702035103], [-0.864649512487616, 51.61824433697217], [-0.864492159027339, 51.61812502442397], [-0.864510219622979, 51.618037979732996], [-0.864490008258273, 51.61792179156664], [-0.863791866117017, 51.616668790850674], [-0.863578496430752, 51.61619016667409], [-0.863939572338851, 51.6160749702936], [-0.864141702322916, 51.61602027805823], [-0.864343742093738, 51.615969181278444], [-0.864684853799959, 51.61590144547291], [-0.864287415633653, 51.61573755014447], [-0.864114344880943, 51.615611790807684], [-0.86394143216696, 51.615479738556914], [-0.863424226660599, 51.6150224515856], [-0.863108525016747, 51.61470918210108], [-0.862999136822108, 51.61463618943345], [-0.862947760773663, 51.614611414387845], [-0.862827479233939, 51.614569786988696], [-0.862764327092327, 51.6145538895073], [-0.862690954996651, 51.614542388851355], [-0.862422671693898, 51.614528100870835], [-0.862278208948609, 51.61452939875511], [-0.862025067586916, 51.614544929155834], [-0.861633333855888, 51.61461576315295], [-0.861195617216796, 51.61467715820802], [-0.860991546767721, 51.61469406144679], [-0.860819513274215, 51.61470048511226], [-0.860591345418716, 51.61469917048917], [-0.860366335624517, 51.61468709604235], [-0.860199196800327, 51.61467108707321], [-0.860140174693704, 51.6146633207896], [-0.859842784619867, 51.61460018922178], [-0.85969929013584, 51.61456282905675], [-0.859501466379857, 51.61450336097874], [-0.859306643699259, 51.614439425872085], [-0.859175017225196, 51.614389591981386], [-0.858977780895874, 51.61430675031806], [-0.858172868778381, 51.61392127488393], [-0.856305510909038, 51.61299763777437], [-0.855879431428414, 51.61282624136621], [-0.855413827571698, 51.612676038205095], [-0.855073660630441, 51.61259179657028], [-0.854915624510577, 51.612558784566126], [-0.854688372582268, 51.61252150056368], [-0.854459541396129, 51.6124895957323], [-0.854208848612115, 51.61246556965946], [-0.853413812340721, 51.612436228916096], [-0.851724243907319, 51.61242871018406], [-0.851450292115, 51.612410744947404], [-0.850998615679464, 51.61233888823236], [-0.850653274334699, 51.61223120468302], [-0.850372939737194, 51.61235164666859], [-0.850315593337778, 51.61233490012849], [-0.850193999216673, 51.612288751000705], [-0.850146601119627, 51.612278395984944], [-0.849926028861458, 51.61226274823948], [-0.849854084982468, 51.61225215268858], [-0.849714847013531, 51.612218418620564], [-0.849473435162227, 51.61217019573735], [-0.849372523204365, 51.61216291272777], [-0.849235958321253, 51.61219484371945], [-0.849170915863905, 51.6121969037703], [-0.849112126238191, 51.61218014249445], [-0.8487984760956, 51.61201881385575], [-0.848813983178796, 51.61186251023449], [-0.848805967905994, 51.611779707971536], [-0.848777693193183, 51.61169850541887], [-0.848751669639592, 51.61164250170296], [-0.848740414389996, 51.61163070213332], [-0.848685616135578, 51.61162746733029], [-0.848598109857592, 51.61148993537107], [-0.848561752293423, 51.61144282198033], [-0.848420551583887, 51.61131555337684], [-0.848346143135118, 51.61123120073643], [-0.848017978126262, 51.61073074025961], [-0.84803240586268, 51.61067423405594], [-0.848009203184881, 51.61062095534751], [-0.848010806265629, 51.61061467688053], [-0.848360723390725, 51.61054078070849], [-0.848731046077576, 51.61040234328455], [-0.848814480324059, 51.61035820278237], [-0.848820437461021, 51.610351067821576], [-0.848690278305866, 51.610072847084595], [-0.847947554822518, 51.60900543974003], [-0.847435103308081, 51.6083125448088], [-0.847167998407497, 51.60796823756615], [-0.846186886755928, 51.60662333116728], [-0.845549998419521, 51.605828497430636], [-0.845383680959569, 51.60566770865375], [-0.844840468159951, 51.60522267062485], [-0.84443530295085, 51.60497141150611], [-0.844232696249957, 51.60481835643492], [-0.843486943931864, 51.60416181103064], [-0.84332558359401, 51.60420428093958], [-0.842908147301968, 51.603868373383044], [-0.842663709069561, 51.603714004109015], [-0.842310199280505, 51.603533382087996], [-0.841471682375652, 51.60311958453644], [-0.841215384127901, 51.602977683579475], [-0.840873068217364, 51.60281155440105], [-0.840467421086961, 51.602637605395635], [-0.840268344470896, 51.602516948405764], [-0.840203154295604, 51.60246864832527], [-0.838474883614574, 51.601841924417336], [-0.838334815858368, 51.60178568911777], [-0.838125139250388, 51.60168470536249], [-0.837520083534699, 51.60134782062488], [-0.837365310402971, 51.60124558073874], [-0.837143016970701, 51.6010734356079], [-0.83702163004049, 51.600964332538595], [-0.836879440722268, 51.60082175386177], [-0.836733036616179, 51.60067463738169], [-0.836105420124444, 51.59992210370809], [-0.836001567218505, 51.59980508080317], [-0.835894758960057, 51.59969072601903], [-0.835646409012494, 51.5994652683849], [-0.835572705263831, 51.59941148620318], [-0.835355212679077, 51.599278049641256], [-0.835001490423373, 51.59910819321327], [-0.834666328550124, 51.59894661249016], [-0.834023851532118, 51.59860753956394], [-0.833813699592692, 51.59846967713012], [-0.832219972267628, 51.59727861587006], [-0.831975375091702, 51.59713321406168], [-0.83180286996819, 51.597047874561696], [-0.83156138306724, 51.59695015903964], [-0.831279067386554, 51.596868221715724], [-0.831119729288761, 51.59683246683902], [-0.830996129682144, 51.596810555210986], [-0.830798964246538, 51.59678611250204], [-0.829935838169309, 51.596720865686486], [-0.82967342169104, 51.596707460026586], [-0.829378950815281, 51.59670542343618], [-0.828672101908656, 51.596738836236966], [-0.828529092462618, 51.59674190522934], [-0.828241907711544, 51.596737240965595], [-0.828066024571149, 51.59672739285258], [-0.827854311754233, 51.596707295846045], [-0.827399248313258, 51.59666228882735], [-0.827164974703315, 51.59662128423301], [-0.827063074447412, 51.59659778687348], [-0.826830893268571, 51.59653162563389], [-0.826403126611598, 51.596379885757386], [-0.826320361645679, 51.596342192238744], [-0.826196596762853, 51.596270819297594], [-0.825930135887572, 51.596078429107884], [-0.825702044863314, 51.59590980062742], [-0.825239717878873, 51.595531118786504], [-0.824901250965003, 51.59522021379687], [-0.824412039116432, 51.59470908081712], [-0.8242790371805, 51.59460434384618], [-0.824162427084317, 51.59453573788591], [-0.823734544991122, 51.59433363318264], [-0.822923577534385, 51.59387232098135], [-0.82274220720895, 51.593740122024236], [-0.822758790294358, 51.59343366962803], [-0.822450529949737, 51.592123177421634], [-0.822408018987733, 51.591980681321466], [-0.82236394886053, 51.59184266543808], [-0.822242174035691, 51.59158338051977], [-0.821801765862476, 51.5908065697487], [-0.821372709449585, 51.59009371260957], [-0.821171850754746, 51.58982284235581], [-0.820679968304875, 51.58936291919855], [-0.820417155492676, 51.58914357740762], [-0.82015811620844, 51.5888901042506], [-0.820045903377484, 51.58876399099103], [-0.81975498206002, 51.5884040936899], [-0.819793038416411, 51.58838379523831], [-0.819648800144719, 51.588268149727725], [-0.819147039514258, 51.58763368041164], [-0.818936357700162, 51.58740856531028], [-0.818746726401906, 51.58698404449756], [-0.818744261992127, 51.58691208559554], [-0.818786542624285, 51.586561832259704], [-0.818798419467402, 51.58638211648965], [-0.818772601288344, 51.58593047014409], [-0.818622316220491, 51.585380460186784], [-0.818493730937228, 51.58471737211902], [-0.818460174123387, 51.58461992329734], [-0.818316632401033, 51.58436670899539], [-0.818092592164715, 51.58404524580265], [-0.817774082795079, 51.58341531231479], [-0.817553796530972, 51.58311636524129], [-0.817445537064436, 51.58300557512581], [-0.81689125274485, 51.582562990062094], [-0.816348587477007, 51.58217357091916], [-0.816214612729635, 51.58210837837547], [-0.816144330954904, 51.58209148442308], [-0.816059129697027, 51.58209332267878], [-0.815742672724781, 51.5820523651453], [-0.815217212787465, 51.58194545592985], [-0.815002344756643, 51.58188304223224], [-0.814826435408141, 51.5818210214772], [-0.814485295861823, 51.581730356582035], [-0.81444044205173, 51.581790148477246], [-0.813566956536122, 51.581635656767844], [-0.813282023122958, 51.58154825394594], [-0.813052037332166, 51.581456910143594], [-0.812870182657061, 51.581346270732034], [-0.812790810356639, 51.58129061819263], [-0.812604263086127, 51.581138568732094], [-0.812386509085548, 51.58085492331321], [-0.812249092317067, 51.58070067277682], [-0.812167619564544, 51.58055957666617], [-0.812051961231651, 51.58029045130041], [-0.812042798783181, 51.580254391465495], [-0.812034433182585, 51.580187767648724], [-0.812033188044369, 51.58012481260171], [-0.812058064730261, 51.580000977815104], [-0.81229781440549, 51.579440518478464], [-0.812247901650195, 51.57941753400863], [-0.812446355706805, 51.57916777205078], [-0.81277233113049, 51.578787120404634], [-0.813191367818544, 51.57821318632392], [-0.813476583358647, 51.57767926033569], [-0.81372993476285, 51.57714950751218], [-0.813894821439398, 51.57669169369027], [-0.813998634879093, 51.57614064720803], [-0.814138744624452, 51.57508193151095], [-0.814120940539715, 51.57493428638376], [-0.81419874804071, 51.57321943977239], [-0.814492542549023, 51.572575897898666], [-0.814547744449169, 51.57211787423915], [-0.814549364628156, 51.57200009817749], [-0.81449843948966, 51.57157247390041], [-0.81447275908744, 51.57022974030085], [-0.814470739157426, 51.56964165674743], [-0.814429823166273, 51.56938407823071], [-0.814416473674158, 51.5693425811485], [-0.814362577800679, 51.569251219648685], [-0.81406844007837, 51.5689659058573], [-0.813908308238922, 51.56874308971205], [-0.813853532979604, 51.56863013877188], [-0.81375715260415, 51.56839717647337], [-0.81371284208748, 51.56815934527622], [-0.813667666933597, 51.567788426746645], [-0.813915408556528, 51.567527470860746], [-0.814280993234198, 51.56684059466537], [-0.814704823511867, 51.56613272518902], [-0.814994772052415, 51.56569055892733], [-0.815202529336662, 51.56519091397622], [-0.815219131565213, 51.56505170869626], [-0.815351636137841, 51.564671793906264], [-0.815511116853932, 51.56436408558186], [-0.815565592175225, 51.5642108755608], [-0.815662011458114, 51.564053592855515], [-0.815731002538058, 51.56389693250399], [-0.815762954470268, 51.56377766396064], [-0.815882314039101, 51.56307031436626], [-0.815899206541573, 51.563030920866616], [-0.815918960262566, 51.5629924554096], [-0.816100387305838, 51.56272812828101], [-0.816239061970809, 51.562387838558415], [-0.816351227865814, 51.56217946080997], [-0.816402225233145, 51.562104443964415], [-0.816445731089239, 51.56204014171416], [-0.816755073070336, 51.56173843863565], [-0.81682883069147, 51.5615089920632], [-0.81709149295673, 51.56100450196165], [-0.817126546068515, 51.5610435199925], [-0.817036868291134, 51.56144185218239], [-0.817602599672938, 51.56148891511105], [-0.817650902097453, 51.56129517879352], [-0.81772376875861, 51.56109989153342], [-0.818544773098936, 51.56114952106405], [-0.818940645385275, 51.56112652991029], [-0.819286252234888, 51.56087194248433], [-0.820505192935939, 51.560762809232635], [-0.821152924392013, 51.56109751750433], [-0.821401734784996, 51.56112699167495], [-0.821468077854438, 51.561127657861135], [-0.821837057068471, 51.56108460493917], [-0.822551882107614, 51.56083281445182], [-0.822991148836609, 51.56069335159132], [-0.823298868990794, 51.56056425765945], [-0.823427756279142, 51.560489119484224], [-0.823816316952276, 51.56018999039105], [-0.823841530161624, 51.56016326766115], [-0.823879440321637, 51.5600917131651], [-0.823939663402364, 51.55926686943448], [-0.824000930577316, 51.55924050793579], [-0.823876052668265, 51.55798579953388], [-0.823797968341331, 51.557154174451156], [-0.823813910366727, 51.55698348995032], [-0.824268965579194, 51.556733581409404], [-0.824612742777356, 51.55649154853787], [-0.826344281900068, 51.55484359477631], [-0.826657025878971, 51.55457337099326], [-0.827233265990788, 51.554040521447654], [-0.827929376968602, 51.55344502444081], [-0.828029419518581, 51.553368693973354], [-0.828246668974642, 51.55322159923911], [-0.828485269800709, 51.5530855074047], [-0.828605105979095, 51.55302466009866], [-0.829372820563392, 51.55267264797847], [-0.830416538296143, 51.552300003050114], [-0.830341853307235, 51.55217517181714], [-0.830015969895102, 51.55217192349864], [-0.82991663595149, 51.55216463892005], [-0.829524156953837, 51.55211486704629], [-0.829282415323888, 51.552092673855796], [-0.828838545910614, 51.55207835426137], [-0.828599504055965, 51.55206338004898], [-0.828680519991051, 51.55199764928292], [-0.828534433277995, 51.55195752639793], [-0.828384829125967, 51.55188589688778], [-0.827987906418731, 51.55167242458396], [-0.827957477145366, 51.551621766572], [-0.827834232346298, 51.55159086272802], [-0.827633977763617, 51.551525919798664], [-0.827259642164726, 51.55144395104261], [-0.826879262755715, 51.5513727108443], [-0.826619197529414, 51.551334143723224], [-0.825020961294276, 51.55117248609027], [-0.825087548806697, 51.55099511486544], [-0.825080332863119, 51.55093929339289], [-0.825041927300218, 51.55086247849746], [-0.82502361605882, 51.55078946149474], [-0.825044884876699, 51.55069166368164], [-0.825058487270179, 51.550667521970404], [-0.82509857658956, 51.550622964257876], [-0.825145597538488, 51.55058926609727], [-0.825325151596322, 51.5505056412203], [-0.824909915146001, 51.550164291306395], [-0.82525013660448, 51.550002248032946], [-0.825332063085088, 51.549957209837], [-0.825638185418255, 51.54977504214384], [-0.82578350044032, 51.54967668704559], [-0.825923116734683, 51.54957557721289], [-0.826170603160388, 51.54937393870707], [-0.826371785812396, 51.54917813090106], [-0.826492161334072, 51.549039961540565], [-0.826611394860751, 51.548890091280356], [-0.82670116630089, 51.54876420424681], [-0.826782355507479, 51.54863553380353], [-0.826823019292071, 51.54856850170786], [-0.827062757600335, 51.548106920435835], [-0.827101368877001, 51.54800749719491], [-0.827194201898492, 51.54770629998806], [-0.827307057244965, 51.54741159704493], [-0.827582602426052, 51.54684696658141], [-0.827901482950928, 51.54639156924703], [-0.828226190833503, 51.54604592938406], [-0.828636291311094, 51.545744301711125], [-0.82879259021163, 51.54566673370386], [-0.828904643767125, 51.545627388779295], [-0.829074413403866, 51.54558682127211], [-0.829642313890905, 51.54554213206049], [-0.831137752395514, 51.5457125947128], [-0.831296230672639, 51.545718668970665], [-0.831381409559054, 51.545715021306385], [-0.831520416985355, 51.54569302674314], [-0.831658465956176, 51.54565213966273], [-0.832162223002951, 51.54540897973132], [-0.832259763552867, 51.545373083913695], [-0.832342495362879, 51.54535232675641], [-0.832449690786029, 51.545333611293344], [-0.832560958333776, 51.54532482723805], [-0.832748224427793, 51.54533298427906], [-0.833594396864807, 51.5455158387706], [-0.833803468208608, 51.5455736658201], [-0.834066591719905, 51.54566080332341], [-0.834319302360527, 51.54576042533909], [-0.834632701147966, 51.545911902800114], [-0.834743597643834, 51.54597414830218], [-0.834972095381443, 51.546118487532766], [-0.835101437527799, 51.546192605160904], [-0.835308853525451, 51.54642845092972], [-0.835597379030446, 51.546650714213946], [-0.835675530378703, 51.54669644865621], [-0.835765285050956, 51.54673960061442], [-0.835946924814448, 51.54679895002405], [-0.836738145066418, 51.54693268079673], [-0.837616543696299, 51.54698454508781], [-0.837668585980954, 51.546979665457], [-0.837867989708348, 51.546964555807335], [-0.83797367625272, 51.54694851789646], [-0.838105566972017, 51.54692284834119], [-0.838233315283634, 51.54688994418392], [-0.838329229403341, 51.54686122067977], [-0.838482151664417, 51.546802489195365], [-0.839036827411148, 51.54642762424692], [-0.83955396219585, 51.54605418383688], [-0.840116011657223, 51.54567219327131], [-0.840736658187885, 51.54525391246058], [-0.840941426195899, 51.54514083988849], [-0.841049279937165, 51.54509604683764], [-0.841194847094701, 51.5450426342828], [-0.841299520083949, 51.545009498946165], [-0.841898633062652, 51.544870644649805], [-0.842282244574123, 51.54481328536381], [-0.842762474116396, 51.54475597844143], [-0.843565178344648, 51.54477737891959], [-0.844086979548171, 51.54484366398717], [-0.845732620874625, 51.545006428046236], [-0.847066038668597, 51.54519847249473], [-0.847735465249349, 51.545415455459946], [-0.84773690700669, 51.54541546961599], [-0.848634731053663, 51.54572550693968], [-0.849946581441456, 51.54620234699594], [-0.850255922443757, 51.54628810259981], [-0.850450510421732, 51.5463493547082], [-0.850677807173489, 51.54642891042725], [-0.850994850981171, 51.546552505063595], [-0.852786328510159, 51.547342426670774], [-0.85300310746802, 51.547496506935786], [-0.853571212311598, 51.54778799706584], [-0.854020445083318, 51.54798930492918], [-0.854581807452525, 51.548205193183556], [-0.85478620907829, 51.54827822314386], [-0.854963577157503, 51.54833660211785], [-0.855161244465997, 51.54839068294659], [-0.855663052553423, 51.5485088736389], [-0.856166529832507, 51.54867563412252], [-0.856279761006, 51.54870371304979], [-0.856530960852844, 51.54875111981111], [-0.856804082121709, 51.54878705024175], [-0.857112033920981, 51.54881432744164], [-0.857381573472553, 51.548820548731904], [-0.857549123049589, 51.54881049056259], [-0.857844479857821, 51.548764809719025], [-0.858057604662229, 51.54872012637499], [-0.858337617310588, 51.54865361386837], [-0.858552497890933, 51.54859635820055], [-0.859049392399301, 51.548450127924276], [-0.859439117962245, 51.5483792842905], [-0.859697682244768, 51.54836291412634], [-0.859779823131423, 51.54836551056866], [-0.860170027263243, 51.548390881318824], [-0.860456238387038, 51.54842243448379], [-0.861009536104037, 51.548500639150554], [-0.861158816462501, 51.54852906321894], [-0.861352413335375, 51.54857320311727], [-0.861544411683264, 51.54862362144007], [-0.861731905414109, 51.5486811891874], [-0.862073439754406, 51.548807688741114], [-0.86254414698236, 51.54901726458452], [-0.86282747298222, 51.54916477803516], [-0.863015068128655, 51.549276295417606], [-0.863120154717426, 51.549342054318615], [-0.863285809311142, 51.54946594721784], [-0.863418211576468, 51.54959311456195], [-0.863530092020445, 51.54973357070672], [-0.863653360363745, 51.549937978681236], [-0.863733641061499, 51.550131180181424], [-0.863790336700716, 51.5503448343906], [-0.863824973966162, 51.550691353426465], [-0.863841717303786, 51.55100353042492], [-0.863889686614544, 51.55116225019172], [-0.863971345177536, 51.55135816235228], [-0.864192531443895, 51.5518009005184], [-0.864636908176204, 51.552606367995786], [-0.864885616784935, 51.55304487507487], [-0.864984710926909, 51.55317801261536], [-0.865042267578469, 51.5532415116859], [-0.86524661818949, 51.553434113390985], [-0.866448255146234, 51.55464702695421], [-0.866553639357719, 51.55475954277147], [-0.86713929523259, 51.555454866418074], [-0.86728119491555, 51.55560729781788], [-0.867357192432134, 51.55568356216347], [-0.867846797612144, 51.55612348793147], [-0.867948777192819, 51.5561991033314], [-0.868039688780355, 51.55625572917072], [-0.868162193200772, 51.55631805467487], [-0.868334859667638, 51.55639345221028], [-0.868507816648064, 51.556457162985154], [-0.868686743286876, 51.556512838449954], [-0.868885971532242, 51.55656421341042], [-0.869870431325262, 51.55700170522159], [-0.870538382015661, 51.557289577406756], [-0.87065953954758, 51.55734829060127], [-0.870968323528286, 51.55751940747054], [-0.871084688448939, 51.55759695683154], [-0.871173919806704, 51.55766345498963], [-0.871421843971099, 51.55790412108149], [-0.871517352960249, 51.558008444760674], [-0.871560414081151, 51.55807539786269], [-0.871689483441928, 51.558339198343305], [-0.871715457861831, 51.558455441841], [-0.871819115572425, 51.558871857901316], [-0.872116688986198, 51.559438501590606], [-0.87224925001588, 51.559678057158926], [-0.872395481580982, 51.5598898694294], [-0.872503199025109, 51.56002578071336], [-0.872616797176149, 51.56015725249727], [-0.872767427555836, 51.560307962534345], [-0.873712440787397, 51.560887112412736], [-0.874019840047307, 51.56105730856152], [-0.874413245272104, 51.56124990894107], [-0.875159636577155, 51.56157807024888], [-0.875469862748955, 51.561692540724444], [-0.875618818634067, 51.561736229028845], [-0.87605776549836, 51.56183754414599], [-0.876366373823489, 51.56190074371407], [-0.87668521195865, 51.561958645316366], [-0.876968369886447, 51.56200091867397], [-0.877197163756339, 51.56202468778881], [-0.877516822654725, 51.5620493254706], [-0.878098847659676, 51.56208186543848], [-0.879220205739232, 51.56212315048378], [-0.879742407250114, 51.562124539056946], [-0.8803196812009, 51.56211566057546], [-0.88047709073344, 51.562109069498774], [-0.880781923890852, 51.5620912956137], [-0.881058065229737, 51.56206695318683], [-0.881262135404653, 51.56204012483733], [-0.881418631531618, 51.562011943580096], [-0.881649213834679, 51.56196288783239], [-0.882003250428868, 51.56187993977645], [-0.882376388095226, 51.56178278572967], [-0.882764299497775, 51.56167138432022], [-0.883194585739291, 51.561537905452155], [-0.883498576630078, 51.5614364931922], [-0.883756281221724, 51.56134003501421], [-0.884086956514705, 51.56120920221847], [-0.884407665982054, 51.56107287871968], [-0.885457870533961, 51.5606602434964], [-0.885606584631741, 51.56059601575753], [-0.88578613479336, 51.56050960117672], [-0.88595858283258, 51.56041862303493], [-0.886091760097573, 51.560340759581955], [-0.886521253482028, 51.56006159461465], [-0.886883345687433, 51.559824949307504], [-0.887389733197074, 51.559468282123994], [-0.887580604245187, 51.55927227271282], [-0.887708691217493, 51.559107139161064], [-0.888191015763102, 51.55861266662589], [-0.888192457957821, 51.55861268028735], [-0.888287760756616, 51.55849039596854], [-0.888562664893145, 51.558278995716826], [-0.888677108662246, 51.55814070717499], [-0.888887527216288, 51.55791161122132], [-0.889030158653071, 51.55774121885465], [-0.889203011709727, 51.557514464273005], [-0.88945350380216, 51.55717964382524], [-0.889600043815338, 51.556967026485395], [-0.889736358446423, 51.55670036168757], [-0.889858423154084, 51.55648571413559], [-0.889957478394766, 51.55626815130874], [-0.88999480235023, 51.556157006507235], [-0.890171676314085, 51.5555274577222], [-0.89040150985715, 51.554855248874496], [-0.891496918227321, 51.55316795557777], [-0.892148150167392, 51.55212836271704], [-0.892302414411729, 51.5517746441604], [-0.892679622502675, 51.55097074336506], [-0.892968782461996, 51.55046633574481], [-0.893655961353766, 51.54930928124159], [-0.894173495307085, 51.548604708475054], [-0.894625223197592, 51.54805597035748], [-0.895275002004698, 51.547308578527485], [-0.895581553072133, 51.54691762432374], [-0.89567259455686, 51.54679079793778], [-0.895853734572665, 51.54651645501248], [-0.896746527292651, 51.54508077321264], [-0.896901839906062, 51.544860136456265], [-0.897255891587921, 51.54494888564188], [-0.898115394177492, 51.545187148067974], [-0.89822539056202, 51.54523044209882], [-0.898280925208036, 51.54525973711452], [-0.898317695099433, 51.54528975512979], [-0.898473190139101, 51.54530020648797], [-0.899619101095523, 51.54544313546729], [-0.901006352145532, 51.54562517973134], [-0.901825064903737, 51.54570208025918], [-0.903152296119515, 51.54586195719927], [-0.903215411109321, 51.54587603470979], [-0.903297183099556, 51.545893883241035], [-0.903017403675823, 51.54655396139701], [-0.902616538461231, 51.54745118838641], [-0.902395351374664, 51.54801290343283], [-0.902224993241029, 51.54837997226972], [-0.902166365216381, 51.54859882282856], [-0.902146545476892, 51.54876318664974], [-0.902208891983797, 51.54892921824649], [-0.902230894835185, 51.549033728477525], [-0.902380735585514, 51.54999904656443], [-0.902673692529055, 51.551610411429984], [-0.902806620567669, 51.55250003963136], [-0.902816651036337, 51.55268266601908], [-0.902804979597758, 51.55292803179951], [-0.902756997764027, 51.55318384821566], [-0.902654701329301, 51.55353896524768], [-0.902427419928527, 51.55423280167036], [-0.901847751389036, 51.555843197130926], [-0.901770133963284, 51.556011515784924], [-0.90172081219273, 51.556082988265544], [-0.902203201151337, 51.55617741874876], [-0.906010818638152, 51.55679743475821], [-0.906204734572883, 51.556771367660915], [-0.906311884484255, 51.55675438267928], [-0.906358975073264, 51.55689599188705], [-0.90638590166065, 51.55691602462513], [-0.906615524939952, 51.55696492104195], [-0.907278267614382, 51.55705831304524], [-0.907858939004531, 51.55720578727805], [-0.908174621569804, 51.5572752632291], [-0.908339760107985, 51.55730647205926], [-0.908420198492941, 51.557320707807335], [-0.908923514869315, 51.557385632424236], [-0.909322889103033, 51.5574540848968], [-0.909506497855653, 51.557497152980005], [-0.909658336207082, 51.557541723987356], [-0.909754316957776, 51.55756959081508], [-0.909871264277585, 51.557625526703404], [-0.91002439519459, 51.55767640345812], [-0.91014009429463, 51.557724234915874], [-0.910363938659539, 51.55783421414451], [-0.910769828656022, 51.55805288423369], [-0.910899633150579, 51.55817457810929], [-0.911134211672749, 51.55843931338367], [-0.911191431662737, 51.558519870694006], [-0.911262279817118, 51.55863382382822], [-0.911345597527786, 51.558829717406], [-0.911347039740573, 51.55882973078292], [-0.911354152248679, 51.55895478193117], [-0.911501156990394, 51.55932300828838], [-0.911744284152759, 51.55977395051585], [-0.911784714781588, 51.55983277167005], [-0.911848028397377, 51.559899897522016], [-0.911951124589094, 51.55999256899618], [-0.912043240814804, 51.56006176008463], [-0.912343203354435, 51.560247072388215], [-0.91252735254784, 51.560389049785144], [-0.912663001694362, 51.56050809825428], [-0.913644040185922, 51.561715780647766], [-0.914729932802775, 51.56149024267299], [-0.915936249212879, 51.561720788632314], [-0.917099342153636, 51.56255696600573], [-0.917716153850379, 51.56209778262442], [-0.918510926061236, 51.561494569835055], [-0.919190082061234, 51.56187308324347], [-0.919265061021478, 51.56187467281339], [-0.919319677161742, 51.561883268238525], [-0.919395565855925, 51.56190734542486], [-0.919450182060758, 51.561915940789575], [-0.919451624375034, 51.56191595406745], [-0.919612764956992, 51.561873377936905], [-0.919684473323871, 51.562134798108005], [-0.919731696029427, 51.56227280618616], [-0.919795125391412, 51.562396576626476], [-0.919877773921036, 51.56250074208832], [-0.920024454979703, 51.56264236275641], [-0.920273793481437, 51.562835281288635], [-0.920455811890565, 51.56300779833283], [-0.92054707457537, 51.56311384087594], [-0.920622684574115, 51.56321074767881], [-0.920768557091237, 51.56344767224896], [-0.920815933327546, 51.56357938704838], [-0.92087756775181, 51.56365728255545], [-0.920897207761338, 51.56368084160506], [-0.920950783915168, 51.5637334861553], [-0.921113636188415, 51.563862665653886], [-0.921195103215065, 51.56395602921301], [-0.921351882125165, 51.56422002842434], [-0.921395592904906, 51.56432383493418], [-0.921420893006769, 51.56441308549212], [-0.921438619701684, 51.56451755238376], [-0.921413985191466, 51.56464410933019], [-0.92167481147157, 51.56453500840272], [-0.923479752756133, 51.56373602685831], [-0.924155377789785, 51.5634113259626], [-0.924873111301507, 51.56399247344971], [-0.924951149378637, 51.56404803772923], [-0.925274524870032, 51.56428388466152], [-0.92664770764064, 51.56515336065692], [-0.927393574791524, 51.56558368874587], [-0.927927453464337, 51.5659491340051], [-0.92835633038721, 51.56599441223158], [-0.928244524844939, 51.56725223174753], [-0.928125342518282, 51.56741209518939], [-0.9281054698832, 51.56745956981058], [-0.927839528670842, 51.568092855254655], [-0.93052584537502, 51.568532778436946], [-0.930434864440691, 51.56872077542371], [-0.930290537945866, 51.568968530677175], [-0.93032458943141, 51.568993118606556], [-0.930407160146686, 51.56904062792432], [-0.930494248489543, 51.56908008580425], [-0.93056005729139, 51.5691040638391], [-0.930644619283805, 51.56912821268005], [-0.930755210497826, 51.569149901051155], [-0.931002865082897, 51.56917193845677], [-0.931506345671459, 51.5692367670135], [-0.9319179887186, 51.56928007686346], [-0.93222706378822, 51.569328746497334], [-0.932389335623021, 51.56936169347699], [-0.932508352034028, 51.56939334769875], [-0.932608510110525, 51.56942932617174], [-0.932871163025979, 51.56955040480943], [-0.933086053531851, 51.569616199317096], [-0.933414865356232, 51.569684826955594], [-0.93386895042082, 51.56976448240679], [-0.934635570791928, 51.5700537823344], [-0.934785550106084, 51.57011898456062], [-0.934985327167408, 51.57021431104797], [-0.935122135234023, 51.5702874858722], [-0.935333952219633, 51.570423383659445], [-0.935683954424458, 51.570697207984594], [-0.935948857561102, 51.57084617434456], [-0.936321009353978, 51.57109861741231], [-0.936776166293208, 51.57138058458356], [-0.936874033955222, 51.57139136186155], [-0.937185388877335, 51.57140497135624], [-0.937358713203379, 51.57139754881963], [-0.937474500211682, 51.571382411871916], [-0.937604964789291, 51.57135661760672], [-0.938082770631526, 51.571224267138255], [-0.938303744516349, 51.57115343316592], [-0.938622419406116, 51.57103852370375], [-0.938583754985448, 51.57127375671787], [-0.938615426417796, 51.5714008261012], [-0.938651384040882, 51.57152973256723], [-0.938810396393867, 51.572013125409214], [-0.938917102284257, 51.5723881447753], [-0.938977920287056, 51.572564931845086], [-0.939147081147104, 51.57298457478389], [-0.93921529881351, 51.57340150695511], [-0.939295227462625, 51.57374930879435], [-0.939359853061118, 51.57401065198471]]]}}
benchmarks/json-data/integers.jsondeleted−1
@@ -1 +0,0 @@
1−[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 6, 6, 7, 7, 7, 8, 9, 9, 10, 10, 11, 12, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 23, 24, 26, 27, 29, 31, 33, 35, 37, 39, 42, 44, 47, 50, 53, 56, 60, 63, 67, 72, 76, 81, 86, 91, 96, 102, 109, 115, 122, 130, 138, 146, 155, 165, 175, 186, 197, 209, 222, 236, 250, 266, 282, 299, 318, 337, 358, 380, 403, 428, 454, 482, 511, 543, 576, 611, 649, 688, 730, 775, 823, 873, 926, 983, 1043, 1107, 1175, 1247, 1323, 1404, 1490, 1582, 1679, 1781, 1890, 2006, 2129, 2259, 2398, 2544, 2700, 2865, 3041, 3227, 3425, 3634, 3857, 4093, 4343, 4609, 4891, 5191, 5509, 5846, 6204, 6583, 6986, 7414, 7868, 8349, 8860, 9403, 9978, 10589, 11237, 11925, 12655, 13430, 14252, 15124, 16050, 17032, 18075, 19181, 20355, 21601, 22923, 24326, 25815, 27396, 29072, 30852, 32740, 34744, 36871, 39128, 41523, 44064, 46762, 49624, 52661, 55884, 59305, 62935, 66787, 70875, 75213, 79817, 84702, 89887, 95389, 101227, 107423, 113998, 120976, 128381, 136239, 144578, 153427, 162818, 172784, 183360, 194583, 206493, 219132, 232545, 246778, 261883, 277912, 294923, 312975, 332131, 352460, 374034, 396928, 421223, 447005, 474365, 503400, 534212, 566911, 601610, 638433, 677511, 718980, 762987, 809688, 859247, 911840, 967652, 1026880, 1089734, 1156434, 1227217, 1302333, 1382046, 1466638, 1556408, 1651673, 1752769, 1860052, 1973902, 2094721, 2222934, 2358996, 2503385, 2656613, 2819219, 2991777, 3174898, 3369227, 3575451, 3794297, 4026539, 4272995, 4534536, 4812086, 5106625, 5419191, 5750889, 6102889, 6476435, 6872845, 7293518, 7739939, 8213686, 8716429, 9249944, 9816115, 10416939, 11054539, 11731166, 12449207, 13211198, 14019829, 14877955, 15788605, 16754994, 17780533, 18868844, 20023768, 21249383, 22550016, 23930257, 25394980, 26949356, 28598872, 30349352, 32206975, 34178300, 36270285, 38490317, 40846232, 43346349, 45999492, 48815029, 51802899, 54973651, 58338478, 61909260, 65698602, 69719882, 73987297, 78515911, 83321713, 88421668, 93833782, 99577160, 105672079, 112140056, 119003924, 126287916, 134017747, 142220706, 150925751, 160163614, 169966908, 180370243, 191410345, 203126189, 215559137, 228753081, 242754599, 257613123, 273381107, 290114218, 307871529, 326715729, 346713346, 367934976, 390455540, 414354543, 439716356, 466630515, 495192035, 525501749, 557666661, 591800322, 628023236, 666463282, 707256166, 750545902, 796485316, 845236589, 896971830, 951873682, 1010135966, 1071964368, 1137577163, 1207205986, 1281096650, 1359510014, 1442722903, 1531029087, 1624740315, 1724187420, 1829721484, 1941715077, 2060563573, 2186686548, 2320529259, 2462564214, 2613292844, 2773247272, 2942992191, 3123126858, 3314287206, 3517148098, 3732425698, 3960880011, 4203317554, 4460594215, 4733618266, 5023353573, 5330822998, 5657112012, 6003372524, 6370826950, 6760772526, 7174585891, 7613727944, 8079749004, 8574294281, 9099109685, 9656047991, 10247075377, 10874278366, 11539871197, 12246203633, 12995769265, 13791214310, 14635346955, 15531147272, 16481777734, 17490594386, 18561158687, 19697250088, 20902879371, 22182302812, 23540037202, 24980875800, 26509905246, 28132523526, 29854459026, 31681790754, 33620969802, 35678842122, 37862672691, 40180171161, 42639519077, 45249398761, 48019023960, 50958172379, 54077220194, 57387178688, 60899733121, 64627283986, 68582990784, 72780818484, 77235586822, 81963022620, 86979815309, 92303675844, 97953399235, 103948930895, 110311437058, 117063379497, 124228594829, 131832378662, 139901574895, 148464670491, 157551896043, 167195332496, 177429024407, 188289100133, 199813899374, 212044108527, 225022904322, 238796106249, 253412338321, 268923200725, 285383451995, 302851202324, 321388118716, 341059642687, 361935221296, 384088552321, 407597844432, 432546093294, 459021374572, 487117154867, 516932621682, 548573033590, 582150091830, 617782334651, 655595555791, 695723248569, 738307077168, 783497376747, 831453684183, 882345301285, 936351892486, 993664119121, 1054484312524, 1119027188325, 1187520604468, 1260206365627, 1337341076854, 1419197049486, 1506063262491, 1598246382662, 1696071847252, 1799885012878, 1910052374747, 2026962860500, 2151029203266, 2282689398739, 2422408251457, 2570679015712, 2728025136906, 2895002099486, 3072199387991, 3260242568131, 3459795495242, 3671562657914, 3896291665080, 4134775885316, 4387857247705, 4656429214122, 4941439933460, 5243895588908, 5564863950114, 5905478142772, 6266940648935, 6650527552175, 7057593042589, 7489574197539, 7947996055022, 8434476997558, 8950734465625, 9498591020797, 10079980779998, 10696956243580, 11351695541337, 12046510122031, 12783852913581, 13566326982715, 14396694724673, 15277887615381, 16213016560543, 17205382878181, 18258489953389, 19376055606456, 20562025218016, 21820585657560, 23156180064488, 24573523533875, 26077619762337, 27673778712750, 29367635360200, 31165169585327, 33072727285306, 35097042776985, 37245262571278, 39524970602741, 41944215003394, 44511536515321, 47235998642351, 50127219647252, 53195406507421, 56451390948928, 59906667686130, 63573435001862, 67464637811456, 71594013362620, 75976139732519, 80626487293267, 85561473327514, 90798519986944, 96356115798305, 102253880934088, 108512636478302, 115154477931865, 122202853217119, 129682645456833, 137620260819954, 146043721744222, 154982765864743, 164468950997792, 174535766550465, 185218751749486, 196555621106568, 208586397563259, 221353553785311, 234902162105402, 249280053643550, 264537987166964, 280729828285480, 297912739615178, 316147382581544, 335498131574595, 356033301212013, 377825387512598, 400951323831468, 425492752460545, 451536312853150, 479173947490266, 508503226468250, 539627691953919, 572657223723034, 607708427072674, 644905044476938, 684378392439283, 726267825083707, 770721226121430, 817895530929871, 867957280587026, 921083209817197, 977460870923688, 1037289295911185, 1100779699135317, 1168156222959992, 1239656729054927, 1315533638126921, 1396054821049394, 1481504544536185, 1572184474698156, 1668414742025481, 1770535071555377, 1878905982215138, 1993910059574563, 2115953306501003, 2245466576485316, 2382907094698829, 2528760072151156, 2683540418647385, 2847794560591953]
benchmarks/json-data/jp10.jsondeleted−1
@@ -1 +0,0 @@
1−{"results":[{"from_user_id_str":"2458313","profile_image_url":"http://a2.twimg.com/profile_images/1203653060/fure091226_normal.png","created_at":"Thu, 27 Jan 2011 20:30:04 +0000","from_user":"19princess","id_str":"30724239224995840","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u6d77\u6674\u300c\u672c\u65e5\u306e\u6771\u4eac\u306e\u304a\u5929\u6c17\u306f\u6674\u6642\u3005\u66c7\u3067\u3057\u3087\u3046\u3002\u6700\u9ad8\u6c17\u6e29\u306f8\u5ea6\u3001\u6700\u4f4e\u6c17\u6e29\u306f1\u5ea6\u3067\u3059\u3002\u3042\u306a\u305f\u306e\u4eca\u65e5\u306e\u4eba\u751f\u306b\u3068\u3073\u3063\u304d\u308a\u306e\u304a\u5929\u6c17\u3092\u2665\u300d","id":30724239224995840,"from_user_id":2458313,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://babyprincess.sakura.ne.jp/about/&quot; rel=&quot;nofollow&quot;&gt;\u5929\u4f7f\u5bb6\u306e\u88cf\u5c71&lt;/a&gt;"},{"from_user_id_str":"66578965","profile_image_url":"http://a0.twimg.com/profile_images/1183763267/fossetta_normal.png","created_at":"Thu, 27 Jan 2011 20:00:04 +0000","from_user":"Fossetta_Tokyo","id_str":"30716689779785729","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u304a\u306f\u3088\u3046\u3054\u3056\u3044\u307e\u3059!!\u6771\u4eac\u90fd\u3001\u672c\u65e5\u306e\u304a\u5929\u6c17\u306f\u6674\u6642\u3005\u66c7\u3002\u6700\u9ad8\u6c17\u6e298\u5ea6\u3001\u6700\u4f4e\u6c17\u6e291\u5ea6\u3002\u6771\u4eac\u5730\u65b9\u3067\u306f\u3001\u7a7a\u6c17\u306e\u4e7e\u71e5\u3057\u305f\u72b6\u614b\u304c\u7d9a\u3044\u3066\u3044\u307e\u3059\u3002\u706b\u306e\u53d6\u308a\u6271\u3044\u306b\u6ce8\u610f\u3057\u3066\u4e0b\u3055\u3044\u3002\u4f0a\u8c46\u8af8\u5cf6\u3068\u5c0f\u7b20\u539f\u8af8\u5cf6\u306b\u306f\u3001\u5f37\u98a8\u3001\u6ce2\u6d6a\u3001\u4e7e\u71e5\u3001\u971c\u306e\u6ce8\u610f\u5831\u3092\u767a\u8868\u4e2d\u3067\u3059\u3002","id":30716689779785729,"from_user_id":66578965,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://bit.ly/Fossetta&quot; rel=&quot;nofollow&quot;&gt;\u30d5\u30a9\u30bb\u30c3\u30bf ver.3.1.1&lt;/a&gt;"},{"from_user_id_str":"104041146","profile_image_url":"http://a2.twimg.com/profile_images/863965118/001jwatokyo_normal.jpg","created_at":"Thu, 27 Jan 2011 19:44:33 +0000","from_user":"jwa_tokyo","id_str":"30712787537756160","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u6c17\u8c61\u5e81\u304b\u3089\u6771\u4eac\u306e\u5929\u6c17\u4e88\u5831\u304c\u767a\u8868\u3055\u308c\u307e\u3057\u305f\u3000\u305d\u306e\u5929\u6c17\u4e88\u5831\u3092\u3053\u3053\u3067\u3064\u3076\u3084\u3053\u3046\u304b\u306a\u3041\uff5e\uff1f\u3000\u8003\u3048\u4e2d\u3000\u307e\u3066\u6b21\u53f7\uff08\u7b11","id":30712787537756160,"from_user_id":104041146,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.docodemo.jp/twil/&quot; rel=&quot;nofollow&quot;&gt;Twil2 (Tweet Anytime, Anywhere by Mail)&lt;/a&gt;"},{"from_user_id_str":"144500192","profile_image_url":"http://a3.twimg.com/a/1294874399/images/default_profile_3_normal.png","created_at":"Thu, 27 Jan 2011 18:59:33 +0000","from_user":"kyo4to4","id_str":"30701462774358016","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u6771\u4eac\u90fd \u516b\u4e08\u5cf6 - \u4eca\u65e5\u306e\u5929\u6c17\u306f\u30fb\u30fb\u30fb\u66c7\u306e\u3061\u6674\u3067\u3059\u306e\uff01","id":30701462774358016,"from_user_id":144500192,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/kyo4to4&quot; rel=&quot;nofollow&quot;&gt;lost-sheep-bot&lt;/a&gt;"},{"from_user_id_str":"165724582","profile_image_url":"http://a0.twimg.com/profile_images/1222842347/163087_1256281064506_1753997852_484926_2761052_n_normal.jpg","created_at":"Thu, 27 Jan 2011 17:39:06 +0000","from_user":"Rifqi_19931020","id_str":"30681213748387840","metadata":{"result_type":"recent"},"to_user_id":113796067,"text":"@CHLionRagbaby \u30b1\u30f3\u3061\u3083\u3093\u3001\u671d\u4eca\u307e\u3067\u306e\u81ea\u5206\u306e\u30db\u30fc\u30e0\u30a8\u30ea\u30a2\u304b\u3089\u307e\u3060\u975e\u5e38\u306b\u5bd2\u3044\u3068\u96e8\u304c\u964d\u3063\u3066\u3044\u305f..\u3069\u306e\u3088\u3046\u306b\u73fe\u5728\u306e\u6771\u4eac\u306e\u5929\u6c17\uff1f","id":30681213748387840,"from_user_id":165724582,"to_user":"CHLionRagbaby","geo":null,"iso_language_code":"ja","to_user_id_str":"113796067","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"120911929","profile_image_url":"http://a0.twimg.com/profile_images/772435076/20100312___capture2_normal.png","created_at":"Thu, 27 Jan 2011 17:28:30 +0000","from_user":"Cirno_fan","id_str":"30678546020040705","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u4eca\u65e5\u306e\u6771\u4eac\u306e\u5929\u6c17\u306f\u3001\u66c7\u6642\u3005\u6674\u3067\u6700\u9ad8\u6c17\u6e29\u306f8\u2103\uff01 \u6700\u4f4e\u6c17\u6e29\u306f2\u2103\u3060\u3063\u305f\u3088\uff01 RT @mimi22999 \uff08\uff65\u2200\uff65\uff09\uff4c\u3001\u865a\u5f31\u306a\u8005\u306b\u3068\u3063\u3066\u3001\u6717\u3089\u304b\u306a\u9854\u306f\u4e0a\u5929\u6c17\u3068\u540c\u3058\u304f\u3089\u3044\u3046\u308c\u3057\u3044\u3082\u306e\u3060\u3002\u30d5\u30e9\u30f3\u30af\u30ea\u30f3 #tenki #bot","id":30678546020040705,"from_user_id":120911929,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://blog.livedoor.jp/fairycirno/archives/34686.html&quot; rel=&quot;nofollow&quot;&gt;\u5e7b\u60f3\u90f7 \u9727\u306e\u6e56&lt;/a&gt;"},{"from_user_id_str":"65976527","profile_image_url":"http://a0.twimg.com/profile_images/452810990/little_italies_____normal.jpg","created_at":"Thu, 27 Jan 2011 17:00:03 +0000","from_user":"heta_weather01","id_str":"30671388754845696","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3010\u30d8\u30bf\u5929\u3011Tere hommikust.\u30a8\u30b9\u30c8\u30cb\u30a2\u3067\u3059\u3002\u4eca\u65e5\u306e\u6771\u4eac\u306e\u5929\u6c17\u306f\u6674\u6642\u3005\u66c7\u3067\u660e\u65e5\u306f\u66c7\u308a\u3067\u3059\u3002\u3061\u306a\u307f\u306b\u50d5\u306e\u3068\u3053\u308d\u3067\u306f\u66c7\u308a\u3067\u6c17\u6e29-7\u2103\u3067\u3059\u3002\u3061\u306a\u307f\u306b\u30b9\u30ab\u30a4\u30d7\u306e\u958b\u767a\u672c\u90e8\u306f\u50d5\u306e\u5bb6\u306b\u3042\u308b\u3093\u3067\u3059\u3002","id":30671388754845696,"from_user_id":65976527,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www15.atpages.jp/~kageyanma/&quot; rel=&quot;nofollow&quot;&gt;\u5730\u7403\u306e\u4e2d&lt;/a&gt;"},{"from_user_id_str":"7278433","profile_image_url":"http://a3.twimg.com/profile_images/1218965303/michael-1_normal.png","created_at":"Thu, 27 Jan 2011 16:50:16 +0000","from_user":"shimohiko","id_str":"30668926035689472","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3042\u308a\u3002\n\u3010\u7f8e\u4eba\u5929\u6c17/\u6771\u4eac\u3011\u7f8e\u4eba\u5929\u6c17\u30ad\u30e3\u30b9\u30bf\u30fc\u306e&quot;\u3055\u3042\u3084\u3093\u3055\u3093&quot;\u306b\u3088\u308b\u3068\u300c1/29(\u571f)\u306f\u304f\u3082\u308a\u3067\u3001\u964d\u6c34\u78ba\u738740%\u3001\u6700\u9ad8\u6c17\u6e29\u306f6\u2103\u3067\u6700\u4f4e\u6c17\u6e29\u306f1\u2103\u3067\u3059\u300d\u7f8e\u4eba\u5929\u6c17\u21d2http://bit.ly/djB8th http://twitpic.com/3twnl0 #bt_tenki","id":30668926035689472,"from_user_id":7278433,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://bijintenki.jp&quot; rel=&quot;nofollow&quot;&gt;bijintenki.jp&lt;/a&gt;"},{"from_user_id_str":"61770","profile_image_url":"http://a3.twimg.com/profile_images/1206955079/tw172a_normal.png","created_at":"Thu, 27 Jan 2011 16:40:52 +0000","from_user":"rsky","id_str":"30666561853333504","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3075\u3068\u591c\u7a7a\u3092\u898b\u4e0a\u3052\u3066\u30aa\u30ea\u30aa\u30f3\u304c\u898b\u3048\u306a\u304f\u3066\u300c\u6771\u4eac\u306b\u306f\u7a7a\u304c\u306a\u3044\u300d\u3068\u667a\u6075\u5b50\u306e\u3088\u3046\u306a\u3053\u3068\u3092\u601d\u3063\u305f\u308f\u3051\u3060\u304c\u3001\u305f\u3076\u3093\u534a\u5206\u3050\u3089\u3044\u306f\u5929\u6c17\u306e\u305b\u3044\u3067\u3059","id":30666561853333504,"from_user_id":61770,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.hootsuite.com&quot; rel=&quot;nofollow&quot;&gt;HootSuite&lt;/a&gt;"},{"from_user_id_str":"103259265","profile_image_url":"http://a0.twimg.com/profile_images/767857973/anime_icon_normal.gif","created_at":"Thu, 27 Jan 2011 16:37:42 +0000","from_user":"liveshowonly","id_str":"30665765698928640","metadata":{"result_type":"recent"},"to_user_id":null,"text":"iPhone\u5929\u6c17\u3002\u6771\u4eac4\u2103\u3063\u3066\u7d50\u69cb\u5bd2\u304f\u306a\u3044\u3058\u3083\u3093\u3002\uff08\u78ba\u304b\u306b\u3082\u306e\u51c4\u304f\u5bd2\u3044\u8a33\u3067\u306f\u7121\u3044\uff09\u3002\u798f\u5ca1\u5e02\u306f1\u2103\u3060\u3002\u52dd\u3061\u3060\u305c\u3002Rock'n'roll","id":30665765698928640,"from_user_id":103259265,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"165242761","profile_image_url":"http://a1.twimg.com/profile_images/1147334744/SN3E00600001_normal.jpg","created_at":"Thu, 27 Jan 2011 16:37:35 +0000","from_user":"deuxavril0502","id_str":"30665736556912640","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u6b8b\u5ff5\u3001\u79c1\u306f\u6c96\u7e04\u3067\u3059(&gt;_&lt;)\u3067\u3082\u304a\u5929\u6c17\u826f\u3055\u305d\u3046\u3067\u826f\u304b\u3063\u305f\u306d\u3002\u3053\u3061\u3089\u306f\u96e8\u3088\uff5eRT @rinandy2010: \u305d\u3046\u3067\u3059\u3063\u266a\u51fa\u5f35\u3067(^^)\u304a\u306d\u3048\u3055\u307e\u306f\u6771\u4eac\u3067\u3059\u304b\uff1f\u3081\u3063\u3061\u3083\u5929\u6c17\u826f\u304f\u3066\u3073\u3063\u304f\u308a\u3067\u3059\u3002\u624b\u888b\u3068\u304b\u5168\u7136\u3044\u3089\u306a\u3044\u3067\u3059\u306d\u30fc RT @deuxavril0502 \u6771\u4eac\u306a\u306e\u30fc\uff1f","id":30665736556912640,"from_user_id":165242761,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.echofon.com/&quot; rel=&quot;nofollow&quot;&gt;Echofon&lt;/a&gt;"},{"from_user_id_str":"163900288","profile_image_url":"http://a1.twimg.com/profile_images/1210224823/icon12945064955238_normal.jpg","created_at":"Thu, 27 Jan 2011 16:24:37 +0000","from_user":"nyao_yurichan","id_str":"30662472734089216","metadata":{"result_type":"recent"},"to_user_id":100985873,"text":"@ray_ko302 \u767a\u898b\u3042\u308a\u304c\u3068\u3067\u3059\u3045\u3002\u3053\u3061\u3089\u3067\u3082\u3088\u308d\u3057\u304f\u306d\u3002\u6771\u4eac\u306f\u4eca\u65e5\u3082\u4e7e\u71e5\u3067\u5927\u5909\u3088\u3002\u305d\u3063\u3061\u3068\u771f\u9006\u306e\u5929\u6c17\u3060\u306d\u3002\u30a2\u30a4\u30b9\u30d0\u30fc\u30f3\u304d\u3092\u3064\u3051\u3066\u3088\u306d\u3002","id":30662472734089216,"from_user_id":163900288,"to_user":"ray_ko302","geo":null,"iso_language_code":"ja","to_user_id_str":"100985873","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"49227098","profile_image_url":"http://a3.twimg.com/profile_images/965007882/____normal.jpg","created_at":"Thu, 27 Jan 2011 15:52:26 +0000","from_user":"dosannko6","id_str":"30654371016478720","metadata":{"result_type":"recent"},"to_user_id":108570870,"text":"@peke_hajiP \u4ffa\u304c\u6771\u4eac \u6765\u3066\u6700\u521d\u306b\u9a5a\u3044\u305f\u306e\u304c\u3001\u5929\u6c17\u4e88\u5831\u3067\u82b1\u7c89\u60c5\u5831\u304c\u6d41\u308c\u308b\u3053\u3068\u3067\u3001\u6700\u521d\u306b\u8a66\u3057\u305f\u306e\u304c \u30b4\u30ad\u69d8 \u53ec\u559a\u306e\u5100\u5f0f\u3067\u3059\u304a\uff1f","id":30654371016478720,"from_user_id":49227098,"to_user":"peke_hajip","geo":null,"iso_language_code":"ja","to_user_id_str":"108570870","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"71148934","profile_image_url":"http://a0.twimg.com/profile_images/1209223630/image_normal.jpg","created_at":"Thu, 27 Jan 2011 15:46:49 +0000","from_user":"123keiko","id_str":"30652958311981058","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u9727\u5cf6\u306e\u964d\u7070\u306e\u30cb\u30e5\u30fc\u30b9\u3092\u898b\u3066\u601d\u3044\u51fa\u3057\u307e\u3057\u305f\u3002\u4e0a\u4eac\u3057\u305f\u59cb\u3081\u306e\u9803\u3001\u6771\u4eac\u306f1\u5e74\u4e2d\u3001\u7070\u304c\u964d\u3089\u306a\u3044\u304b\u3089\u7a7a\u6c17\u304c\u6f84\u3093\u3067\u3066\u904e\u3054\u3057\u3084\u3059\u3044\u306a\u3041\u3001\u3068\u601d\u3063\u305f\u306a\u3041\u3001\u3063\u3066\u3002\n\u5b9f\u5bb6\u306f\u51ac\u306e\u5b63\u7bc0\u98a8\u3067\u685c\u5cf6\u306e\u7070\u304c\u964d\u308b\u5730\u533a\u3067\u3057\u305f\u3002\u9e7f\u5150\u5cf6\u306e\u5929\u6c17\u4e88\u5831\u3067\u306f\u3001\u6bce\u65e5\u3001\u685c\u5cf6\u4e0a\u7a7a\u306e\u98a8\u5411\u304d\u4e88\u5831\u304c\u3067\u307e\u3059\u3002\u3053\u308c\u304b\u3089\u306f\u9727\u5cf6\u3082\u304b\u306a\uff1f","id":30652958311981058,"from_user_id":71148934,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"91124773","profile_image_url":"http://a3.twimg.com/profile_images/1139308356/prof101007_3-1_normal.jpg","created_at":"Thu, 27 Jan 2011 15:43:35 +0000","from_user":"sanposuruhito","id_str":"30652146277945345","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u4eca\u5bb5\u306e\u90fd\u5fc3\u306f\u3001\u8eab\u3082\u5f15\u304d\u7de0\u307e\u308b\u3068\u3044\u3046\u3088\u308a\u306f\u51cd\u3048\u308b\u7a0b\u306e\u51b7\u6c17\u3092\u611f\u3058\u308b\u5bd2\u3044\u591c\u3067\u3059\u3002\u660e\u65e5\u65e5\u4e2d\u306e\u6771\u4eac\u306e\u5929\u6c17\u306f\u3001\u5915\u65b9\u306b\u591a\u5c11\u96f2\u304c\u51fa\u308b\u5834\u6240\u304c\u3042\u308a\u305d\u3046\u306a\u3082\u306e\u306e\u6982\u306d\u6674\u308c\u7a7a\u304c\u5e83\u304c\u308a\u7d9a\u3051\u305d\u3046\u3067\u3059\u3002\u6700\u9ad8\u6c17\u6e29\u306f\u30015-6\u5ea6\u4f4d\u3068\u306a\u308a\u305d\u3046\u3067\u3059\u3002#weather_tokyo","id":30652146277945345,"from_user_id":91124773,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://projects.playwell.jp/go/Saezuri&quot; rel=&quot;nofollow&quot;&gt;Saezuri&lt;/a&gt;"}],"max_id":30724239224995840,"since_id":28179956995457024,"refresh_url":"?since_id=30724239224995840&q=%E6%9D%B1%E4%BA%AC%E3%80%80%E5%A4%A9%E6%B0%97","next_page":"?page=2&max_id=30724239224995840&lang=ja&q=%E6%9D%B1%E4%BA%AC%E3%80%80%E5%A4%A9%E6%B0%97","results_per_page":15,"page":1,"completed_in":0.104827,"warning":"adjusted since_id to 28179956995457024 (), requested since_id was older than allowed -- since_id removed for pagination.","since_id_str":"28179956995457024","max_id_str":"30724239224995840","query":"%E6%9D%B1%E4%BA%AC%E3%80%80%E5%A4%A9%E6%B0%97"}
benchmarks/json-data/jp100.jsondeleted−1
@@ -1 +0,0 @@
1−{"results":[{"from_user_id_str":"178045354","profile_image_url":"http://a0.twimg.com/profile_images/1214479381/154722_10100141954893059_808622_55276626_7445050_n_normal.jpg","created_at":"Fri, 25 Feb 2011 17:40:04 +0000","from_user":"ChuriSta_gt","id_str":"41190705623732224","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3072\u3089\u304c\u306a\u306e\u300c\u3064\u300d\u306f\u3082\u3046Twitter\u306e\u300c\u3064\u300d\u3060\uff01","id":41190705623732224,"from_user_id":178045354,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twipple.jp/&quot; rel=&quot;nofollow&quot;&gt;\u3064\u3044\u3063\u3077\u308b for iPhone&lt;/a&gt;"},{"from_user_id_str":"71746558","profile_image_url":"http://a2.twimg.com/profile_images/591641547/wwd_normal.gif","created_at":"Fri, 25 Feb 2011 17:40:02 +0000","from_user":"fuckkilldiestar","id_str":"41190699571494912","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u306b\u3057\u3066\u3082Twitter\u3084pixiv\u96e2\u308c\u3092\u3069\u3046\u306b\u304b\u3057\u308d\u674f\u4ec1\u30d6\u30eb\u30de","id":41190699571494912,"from_user_id":71746558,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"131230176","profile_image_url":"http://a2.twimg.com/sticky/default_profile_images/default_profile_5_normal.png","created_at":"Fri, 25 Feb 2011 17:39:58 +0000","from_user":"proory_bot","id_str":"41190683922546688","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u30ea\u30cd\u30f3\u30dd\u30fc\u30c1 http://bit.ly/btjqlH","id":41190683922546688,"from_user_id":131230176,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://proory.com/&quot; rel=&quot;nofollow&quot;&gt;proory tems&lt;/a&gt;"},{"from_user_id_str":"120359038","profile_image_url":"http://a1.twimg.com/profile_images/946521484/200805161826000_normal.jpg","created_at":"Fri, 25 Feb 2011 17:39:58 +0000","from_user":"tukinosuke","id_str":"41190680835391488","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @fuefukioyasumi: \u3082\u3046\u3044\u3044\u3002\u300c\u671d\u751f\u300d\u306a\u3093\u304b\u3044\u3044\u3002BBC\u3082CNN\u3082\u82f1\u8a9e\u653e\u9001\u3060\u3002\u307f\u3093\u306a\u3001\u30c6\u30ec\u30d3\u3092\u3076\u3061\u3063\u3068\u5207\u3063\u3066Twitter\u3092\u898b\u3088\u3046\u3002\u3053\u3053\u306b\u300c\u751f\u304d\u305f\u60c5\u5831\u300d\u304c\u6d41\u308c\u3066\u3044\u308b\u3002\u300c\u751f\u304d\u305f\u53eb\u3073\u300d\u304c\u3042\u308b\u3002\u3053\u3053\u304b\u3089\u3067\u3082\u6b74\u53f2\u306e\u8ee2\u63db\u70b9\u3092\u611f\u3058\u308b\u4e8b\u304c\u3067\u304d\u308b\u306e\u3060\u3002 @gjmorley #libjp","id":41190680835391488,"from_user_id":120359038,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"166512109","profile_image_url":"http://a3.twimg.com/profile_images/1224583217/image_normal.jpg","created_at":"Fri, 25 Feb 2011 17:39:50 +0000","from_user":"yurii1129","id_str":"41190649839620096","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u4eca\u6c17\u4ed8\u3044\u305f\u2026\u307f\u3043\u304f\u3093\u306eTwitter\u540d\u3001\u3084\u307e\u306d\u3084\u3093(\uffe3\u25c7\uffe3;)","id":41190649839620096,"from_user_id":166512109,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"228999619","profile_image_url":"http://a3.twimg.com/sticky/default_profile_images/default_profile_6_normal.png","created_at":"Fri, 25 Feb 2011 17:39:49 +0000","from_user":"takami926","id_str":"41190644793745408","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u7530\u539f\u3055\u3093\u3001\u5fdc\u63f4\u3057\u3066\u307e\u3059\u3002WEB\u3082TWITTER\u3082\u62dd\u898b\u3057\u3066\u307e\u3059\u3002\u7530\u539f\u3055\u3093\u304c\u653f\u6cbb\u5bb6\u306b\u306a\u3063\u3066\u3001\u65e5\u672c\u3092\u5909\u3048\u3066\u304f\u3060\u3055\u3044\u3002\u5c16\u95a3\u3001\u5317\u65b9\u554f\u984c\u5171\u306b\u65e5\u672c\u306e\u653f\u6cbb\u306e\u5931\u6557\u3067\u3059\u3002\u8a55\u8ad6\u5bb6\u306f\u8272\u3005\u8a00\u3063\u3066\u307e\u3059\u304c\u3001\u4e2d\u6771\u307b\u3069\u56fd\u6c11\u306e\u71b1\u6c17\u304c\u7121\u304f\u3001\u683c\u5dee\u304c\u3042\u308a\u3001\u4f55\u3082\u5909\u308f\u3089\u306a\u3044\u666f\u6c17\u4f4e\u8ff7\u306e\u65e5\u672c\u306b\u56fd\u6c11\u306f\u8ae6\u3081\u3066\u308b\u3093\u3067\u3059\u3002","id":41190644793745408,"from_user_id":228999619,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"151773701","profile_image_url":"http://a0.twimg.com/profile_images/1213699753/obi_nao_normal.jpg","created_at":"Fri, 25 Feb 2011 17:39:44 +0000","from_user":"obi_nao","id_str":"41190622949941248","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3060\u3044\u3076\u5e74\u4e0b\u306e\u5f8c\u8f29\u306b\u3001\u30d3\u30b8\u30cd\u30b9\u3084\u308b\u306a\u3089\u771f\u5263\u306bTwitter\u3084\u308c\uff01\u3063\u3066\u6012\u3089\u308c\u305f\u3002\u306a\u306e\u3067\u4eca\u65e5\u304b\u3089\u771f\u5263\u306b\u3064\u3076\u3084\u304f\u3053\u3068\u306b\u3057\u307e\u3059\u3002\u3088\u308d\u3057\u304f\u3067\u3059\u3002","id":41190622949941248,"from_user_id":151773701,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.flight.co.jp/iPhone/TweetMe/&quot; rel=&quot;nofollow&quot;&gt;TweetMe for iPhone&lt;/a&gt;"},{"from_user_id_str":"20817229","profile_image_url":"http://a0.twimg.com/profile_images/1212012721/205_normal.jpg","created_at":"Fri, 25 Feb 2011 17:39:43 +0000","from_user":"allte","id_str":"41190619804082176","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u7206\u7b11\u3057\u3066\u547c\u5438\u56f0\u96e3\u3067\u75d9\u6523\u3059\u308b\u5618\u304f\u3093\u304c\u898b\u308c\u308b\u306e\u306fTwitter\u3060\u3051","id":41190619804082176,"from_user_id":20817229,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.movatwi.jp&quot; rel=&quot;nofollow&quot;&gt;www.movatwi.jp&lt;/a&gt;"},{"from_user_id_str":"166907967","profile_image_url":"http://a2.twimg.com/profile_images/1250526230/___normal.jpg","created_at":"Fri, 25 Feb 2011 17:39:43 +0000","from_user":"NTTYAHOOOOOOOI","id_str":"41190618235412480","metadata":{"result_type":"recent"},"to_user_id":106469594,"text":"@takahirororo \u3066\u304b\u4f55\u3067twitter\u4e0a\u3067\u30a2\u30c9\u30d0\u30a4\u30b9\u3082\u3089\u3063\u3066\u3093\u306d\u3093\uff57","id":41190618235412480,"from_user_id":166907967,"to_user":"takahirororo","geo":null,"iso_language_code":"ja","to_user_id_str":"106469594","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"82581287","profile_image_url":"http://a0.twimg.com/profile_images/774721566/miyaru2_normal.jpg","created_at":"Fri, 25 Feb 2011 17:39:38 +0000","from_user":"kine_rahchaos","id_str":"41190598132244480","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u30a2\u30aa\u30b7\u30de\u3055\u3093\u304cTwitter\u59cb\u3081\u305f\u3060\u3068\u2026","id":41190598132244480,"from_user_id":82581287,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://sourceforge.jp/projects/tween/wiki/FrontPage&quot; rel=&quot;nofollow&quot;&gt;Tween&lt;/a&gt;"},{"from_user_id_str":"136633905","profile_image_url":"http://a2.twimg.com/profile_images/1247161991/yama_normal.png","created_at":"Fri, 25 Feb 2011 17:39:35 +0000","from_user":"yamachi39","id_str":"41190584706285568","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3084\u3063\u3071\u308amixi\u3088\u308atwitter\u306e\u304c\u597d\u304d\u304b\u3082","id":41190584706285568,"from_user_id":136633905,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://jigtwi.jp/?p=1&quot; rel=&quot;nofollow&quot;&gt;jigtwi&lt;/a&gt;"},{"from_user_id_str":"44029295","profile_image_url":"http://a2.twimg.com/profile_images/1112965522/image_normal.jpg","created_at":"Fri, 25 Feb 2011 17:39:32 +0000","from_user":"no2yosee","id_str":"41190572769280000","metadata":{"result_type":"recent"},"to_user_id":97721124,"text":"@hn0345 \u3042\u3001\u500b\u4eba\u7684\u306b\u306f\u4eca\u306ftwitter\u306e\u30d7\u30ed\u30d5\u30a3\u30fc\u30eb\u306b\u66f8\u3044\u3066\u3042\u308b\u30d6\u30ed\u30b0\u306e\u30e6\u30cb\u30c3\u30c8\u3092\u306e\u3093\u3073\u308a\u3084\u3063\u3066\u307e\u3059w","id":41190572769280000,"from_user_id":44029295,"to_user":"hn0345","geo":null,"iso_language_code":"ja","to_user_id_str":"97721124","source":"&lt;a href=&quot;http://www.flight.co.jp/iPhone/TweetMe/&quot; rel=&quot;nofollow&quot;&gt;TweetMe for iPhone&lt;/a&gt;"},{"from_user_id_str":"149872179","profile_image_url":"http://a0.twimg.com/profile_images/1145770150/Winter11_normal.jpg","created_at":"Fri, 25 Feb 2011 17:39:31 +0000","from_user":"xmyyyxx","id_str":"41190566951653376","metadata":{"result_type":"recent"},"to_user_id":95069405,"text":"@rindofu \u653b\u7565\u672c\u3042\u308c\u3070\u3044\u3044\u306e\u306b\u3063\u3066\u601d\u3044\u307e\u3059(T\u03c9T)/~~~ \u79c1\u3082\u76f4\u3057\u305f\u3044\u3068\u3053\u3044\u3063\u3071\u3044\u3060\u3051\u3069\u3001\u3042\u306860\u5e74\u304f\u3089\u3044\u3044\u304d\u3089\u308c\u308b\u306f\u305a\u3060\u3057\u3001\u306e\u3093\u3073\u308a\u76f4\u308c\u3070\u3044\u3044\u306a\u3042 \u304a\u3084\u3059\u307f\u3067\u3059^^\uff01\u308a\u3093\u3055\u3093\u3068twitter\u3067\u4ef2\u826f\u304f\u306a\u308c\u3066\u3088\u304b\u3063\u305f\u3067\u3059\u3063","id":41190566951653376,"from_user_id":149872179,"to_user":"rindofu","geo":null,"iso_language_code":"ja","to_user_id_str":"95069405","source":"&lt;a href=&quot;http://twtr.jp&quot; rel=&quot;nofollow&quot;&gt;Keitai Web&lt;/a&gt;"},{"from_user_id_str":"105579892","profile_image_url":"http://a0.twimg.com/profile_images/1212950455/love_happy_pink_normal.jpg","created_at":"Fri, 25 Feb 2011 17:39:30 +0000","from_user":"love_happy_pink","id_str":"41190566494601216","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u305d\u308c\u898b\u305f\u3044\u306a\u266aRT @kazukt \u3046\u308b\u304a\u307c\u7d75\u3001\u4ed6\u306e\u4eba\u306e\u3082\u898b\u3066\u3044\u305f\u3089\u3084\u305f\u3089\u30de\u30f3\u30ac\u306e\u30ad\u30e3\u30e9\u30af\u30bf\u30fc\u3067\u3080\u3061\u3083\u304f\u3061\u3083\u4e0a\u624b\u3044\u4eba\u304c\uff01\u2026\u3068\u3001\u30d7\u30ed\u30d5\u30a3\u30fc\u30eb\u898b\u305f\u3089\u3001\u306a\u3093\u3068\u3054\u672c\u4eba\u304c\u66f8\u3044\u3066\u3044\u3089\u3063\u3057\u3083\u3063\u305f\u3002Twitter\u3063\u3066\u30b9\u30b4\u30a4\u308f\u3002","id":41190566494601216,"from_user_id":105579892,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.nibirutech.com/&quot; rel=&quot;nofollow&quot;&gt;TwitBird iPad&lt;/a&gt;"},{"from_user_id_str":"16996368","profile_image_url":"http://a0.twimg.com/profile_images/1198892387/pochi_normal.jpg","created_at":"Fri, 25 Feb 2011 17:39:30 +0000","from_user":"HyoYoshikawa","id_str":"41190564187611136","metadata":{"result_type":"recent"},"to_user_id":1800565,"text":"@shinichiro_beck \u73fe\u5730\u304b\u3089\u306a\u3089\u826f\u304f\u3066\u4ed6\u306e\u5730\u57df\u304b\u3089\u3060\u4f59\u8a08\u306a\u3089\u3001\u4f55\u306e\u305f\u3081\u306bTwitter\u304c\u3042\u308b\u306e\u304b\u308f\u304b\u3089\u306a\u3044\u3088\u3002\u3044\u307e\u8d77\u304d\u3066\u308b\u3053\u3068\u306e\u8aac\u660e\u3082\u3064\u304b\u306a\u3044\u3002\u30a2\u30eb\u30b8\u30e3\u30b8\u30fc\u30e9\u304c\u4f1d\u3048\u3066\u308b\u3053\u3068\u304c\u5168\u3066\u3058\u3083\u306a\u3044\u3057\u3001\u65e5\u672c\u306eTV\u306f\u4f1d\u3048\u306a\u3044\u3067\u3057\u3087\u3046\u3002\u77e5\u308a\u305f\u304c\u3063\u3066\u308b\u4eba\u3082\u305f\u304f\u3055\u3093\u3044\u308b\u3002","id":41190564187611136,"from_user_id":16996368,"to_user":"shinichiro_beck","geo":null,"iso_language_code":"ja","to_user_id_str":"1800565","source":"&lt;a href=&quot;http://www.hootsuite.com&quot; rel=&quot;nofollow&quot;&gt;HootSuite&lt;/a&gt;"},{"from_user_id_str":"119070802","profile_image_url":"http://a2.twimg.com/profile_images/1229773005/346d8435099798113a1326e1ba4949ee_normal.jpeg","created_at":"Fri, 25 Feb 2011 17:39:25 +0000","from_user":"takotako726","id_str":"41190545439207424","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u9b54\u6cd5\u5c11\u5973\u307e\u3069\u304b\u30de\u30ae\u30ab\u306e\u53cd\u97ff\u304ctwitter\u3067\u306f\u3093\u3071\u306d\u3048\u4ef6\u3002","id":41190545439207424,"from_user_id":119070802,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://z.twipple.jp/&quot; rel=&quot;nofollow&quot;&gt;\u3064\u3044\u3063\u3077\u308b/twipple&lt;/a&gt;"},{"from_user_id_str":"165695316","profile_image_url":"http://a1.twimg.com/profile_images/681748782/ring_normal.jpg","created_at":"Fri, 25 Feb 2011 17:39:21 +0000","from_user":"pandora_shotbar","id_str":"41190526447390720","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u300e\u30b7\u30e7\u30c3\u30c8\u30d0\u30fc\u3000\u30d1\u30f3\u30c9\u30e9\u3000\u30c4\u30a4\u30c3\u30bf\u30fc\u306e\u3064\u3076\u3084\u304d\u300f\u30b7\u30e7\u30c3\u30c8\u30d0\u30fc\u3000\u30d1\u30f3\u30c9\u30e9\u3000\u30c4\u30a4\u30c3\u30bf\u30fc\u306e\u3064\u2026\uff5chttp://pandora-twitter.seesaa.net/article/187809936.html","id":41190526447390720,"from_user_id":165695316,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://blog.seesaa.jp/&quot; rel=&quot;nofollow&quot;&gt;SeesaaBlog&lt;/a&gt;"},{"from_user_id_str":"88862311","profile_image_url":"http://a2.twimg.com/profile_images/1182243698/161113_100001897885617_169366_q_normal.jpg","created_at":"Fri, 25 Feb 2011 17:39:16 +0000","from_user":"amebaguide","id_str":"41190504926416896","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u300e\u30a2\u30e1\u30d6\u30ed\u653b\u7565\u30ac\u30a4\u30c9\u306e\u30c4\u30a4\u30c3\u30bf\u30fc\u306e\u3064\u3076\u3084\u304d\u300f\u30d6\u30ed\u30b0\u306e\u653b\u7565\u3000\u30c4\u30a4\u30c3\u30bf\u30fc\u306e\u3064\u3076\u3084\u304d\u96c6\uff5chttp://accessup-twitter.seesaa.net/article/187809931.html","id":41190504926416896,"from_user_id":88862311,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://blog.seesaa.jp/&quot; rel=&quot;nofollow&quot;&gt;SeesaaBlog&lt;/a&gt;"},{"from_user_id_str":"186895007","profile_image_url":"http://a2.twimg.com/profile_images/1229610799/image_normal.jpg","created_at":"Fri, 25 Feb 2011 17:39:11 +0000","from_user":"zizikt","id_str":"41190486123356161","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3053\u308c\u306f\u500b\u4eba\u7684\u306b\u306f\u91cd\u5b9d\u3067\u3059\u3002\n\u25c6iPhone&amp;iPad\u5411\u3051Twitter\u30a2\u30d7\u30ea\u300c\u3064\u3044\u3063\u3077\u308b\u300d\u306bEvernote\u3068\u306e\u9023\u643a\u6a5f\u80fd\u3092\u8ffd\u52a0 \nhttp://bit.ly/hPf44u","id":41190486123356161,"from_user_id":186895007,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"132320738","profile_image_url":"http://a3.twimg.com/profile_images/1229760475/image_normal.jpg","created_at":"Fri, 25 Feb 2011 17:39:04 +0000","from_user":"faina_","id_str":"41190453592334336","metadata":{"result_type":"recent"},"to_user_id":167894537,"text":"@gjmorley \u30e2\u30fc\u30ea\u30fc\u3055\u3093\u306e\u7ffb\u8a33\u306e\u8a00\u8449\u306e\u30bb\u30f3\u30b9\u304c\u3059\u304d\u3067\u3059\u3002\u305d\u3057\u3066\u3001Twitter\u3067\u77e5\u308b\u3001\u73fe\u5730\u306e\u4eba\u306e\u76ee\u306e\u529b\u3084\u3001\u60c5\u5831\u3092\u4f1d\u3048\u3066\u304f\u308c\u308b\u7686\u3055\u3093\u306e\u60c5\u71b1\u306b\u611f\u52d5\u3057\u3066\u3044\u307e\u3059\u3002\u611f\u52d5\u3059\u308b\u3063\u3066\u3059\u3054\u3044\u30a8\u30cd\u30eb\u30ae\u30fc\u3067\u3059\uff01\uff01","id":41190453592334336,"from_user_id":132320738,"to_user":"gjmorley","geo":null,"iso_language_code":"ja","to_user_id_str":"167894537","source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"24870552","profile_image_url":"http://a3.twimg.com/profile_images/907130634/4_normal.jpg","created_at":"Fri, 25 Feb 2011 17:39:03 +0000","from_user":"tana1192","id_str":"41190450480021504","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u500b\u4eba\u7684\u306b\u306f\u3001\u30bf\u30b0\u5f3e\u304d\u3059\u308c\u3070\u3044\u3044\uff08\u5f3e\u3051\u308b\u30c4\u30fc\u30eb\u3092\u4f7f\u3063\u3066Twitter\u3092\u3059\u308c\u3070\u3044\u3044\uff09\u3068\u601d\u3046\u3093\u3060\u3051\u3069\u306a\u3042\u3002\u307f\u3093\u306a\u305d\u308c\u306a\u308a\u306bTwitter\u3084\u308b\u4eba\u3060\u3057\u3001\u30c4\u30fc\u30eb\u9078\u3073\u304f\u3089\u3044\u5e45\u3092\u6301\u3063\u3066\u3084\u3063\u3066\u3082\u3002 \u307e\u3042\u3001\u4ffa\u30a2\u30cb\u30e1\u306f\u89b3\u308b\u89b3\u308b\u8a50\u6b3a\u3059\u308b\u3060\u3051\u306e\u4eba\u3060\u304b\u3089\u95a2\u4fc2\u306a\u3044\u3093\u3060\u3051\u3069\u3082\uff57\uff57\u5b9f\u6cc1\u306f\u697d\u3057\u305d\u3046\u306b\u898b\u3048\u308b\u3088\u3002","id":41190450480021504,"from_user_id":24870552,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://sourceforge.jp/projects/tween/wiki/FrontPage&quot; rel=&quot;nofollow&quot;&gt;Tween&lt;/a&gt;"},{"from_user_id_str":"58509646","profile_image_url":"http://a3.twimg.com/sticky/default_profile_images/default_profile_2_normal.png","created_at":"Fri, 25 Feb 2011 17:39:02 +0000","from_user":"kakuyas","id_str":"41190446663344128","metadata":{"result_type":"recent"},"to_user_id":107076877,"text":"@Dayspool \u6df1\u591c\uff12\uff19\u6642\u304f\u3089\u3044\u307e\u3067\u306f\u6bce\u65e5\u55b6\u696d\u3057\u3066\u308b\u306e\u3067\u3001twitter\u3001\u30e1\u30c3\u30bb\u3001PS3\u306a\u3069\u3067\u3088\u3093\u3067\u3051\u308c\u3002\u3053\u3063\u3061\u304b\u3089\u58f0\u304b\u3051\u308b\u3053\u3068\u3082\u3042\u308b\u304b\u3082\u3060\u304c\uff57","id":41190446663344128,"from_user_id":58509646,"to_user":"Dayspool","geo":null,"iso_language_code":"ja","to_user_id_str":"107076877","source":"&lt;a href=&quot;http://cheebow.info/chemt/archives/2007/04/twitterwindowst.html&quot; rel=&quot;nofollow&quot;&gt;Twit for Windows&lt;/a&gt;"},{"from_user_id_str":"149128527","profile_image_url":"http://a2.twimg.com/profile_images/1254922702/image_normal.jpg","created_at":"Fri, 25 Feb 2011 17:39:00 +0000","from_user":"uni13yoki","id_str":"41190437087748096","metadata":{"result_type":"recent"},"to_user_id":119468594,"text":"@kuro_wr84 \u304a\u308c\u3068\u304a\u524d\u3067Twitter\u3067\u4f1a\u8a71\u3057\u305f\u3089\u3001\u5927\u5909\u306a\u3053\u3068\u306b\u306a\u308b\u306a","id":41190437087748096,"from_user_id":149128527,"to_user":"kuro_wr84","geo":null,"iso_language_code":"ja","to_user_id_str":"119468594","source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"18670595","profile_image_url":"http://a2.twimg.com/profile_images/1250674062/ProfilePhoto_normal.png","created_at":"Fri, 25 Feb 2011 17:38:59 +0000","from_user":"nyuuuuun","id_str":"41190436450222080","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3078\u30fc\u3053\u3093\u306a\u306b\u3088\u304f\u4f3c\u308b\u3053\u3068\u3082\u3042\u308b\u3093\u3060\u30fc\nhttp://twitter.com/Re_44/status/35943233016168448\nhttp://twitter.com/3510_misaka/status/36122114821988352","id":41190436450222080,"from_user_id":18670595,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"96267603","profile_image_url":"http://a3.twimg.com/profile_images/1245253473/DSiLL3_normal.jpg","created_at":"Fri, 25 Feb 2011 17:38:59 +0000","from_user":"arivis","id_str":"41190433119940608","metadata":{"result_type":"recent"},"to_user_id":null,"text":"http://twitter.com/#!/arivis/status/40636755380142080 \u306a\u3093\u3064\u3046\u304b\u3053\u308c\u3067\u8d64\u3063\u3066\u306e\u3082\u3061\u3087\u3063\u3068\u3042\u308c\u3063\u3059\u306d\u3002\u305d\u3057\u3066\u4e88\u671f\u3057\u3066\u3044\u305f\u304b\u306e\u3088\u3046\u3060","id":41190433119940608,"from_user_id":96267603,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"148097776","profile_image_url":"http://a3.twimg.com/profile_images/1166904064/broken-heart_normal.png","created_at":"Fri, 25 Feb 2011 17:38:56 +0000","from_user":"ReajuBreaker_A","id_str":"41190422135058432","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u672c\u57a2\u30d5\u30a9\u30ed\u30fc\u3088\u308d\u3057\u304f\u3067\u3059\u2192 http://twitter.com/ReajuBreaker \uff08\uff20\u3060\u3068\u30ea\u30d7\u30e9\u30a4\u304c\u57cb\u307e\u308b\u305f\u3081\u3001URL\u306b\u3057\u3066\u3042\u308a\u307e\u3059\uff09","id":41190422135058432,"from_user_id":148097776,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.twitter.com/ReajuBreaker&quot; rel=&quot;nofollow&quot;&gt;\u73fe\u5145\u6bba\u3057\u306e\u7121\u4eba\u9023\u545f\uff1c\u30aa\u30fc\u30c8\u30c4\u30a4\u30fc\u30c8\uff1e&lt;/a&gt;"},{"from_user_id_str":"59711654","profile_image_url":"http://a2.twimg.com/profile_images/416212928/flowers-06-1_normal.jpg","created_at":"Fri, 25 Feb 2011 17:38:56 +0000","from_user":"agamo45","id_str":"41190421522546688","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @ebizo66: \u30ea\u30d3\u30a2\u30fb\u30c8\u30ea\u30dd\u30ea\u306eTw\uff1a\u6551\u6025\u8eca\u304c\u6765\u305f\u304c\u3001\u8ca0\u50b7\u8005\u3092\u8eca\u5185\u3067\u6bba\u5bb3\u3057\u3066\u3044\u305f\u3001\u3068\u3002\uff08\u6ec5\u8336\u82e6\u8336\u3060\uff01\uff09http://ow.ly/43pQ2 #libjp","id":41190421522546688,"from_user_id":59711654,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.hootsuite.com&quot; rel=&quot;nofollow&quot;&gt;HootSuite&lt;/a&gt;"},{"from_user_id_str":"145311373","profile_image_url":"http://a3.twimg.com/profile_images/1187802576/a_gam_02_normal.png","created_at":"Fri, 25 Feb 2011 17:38:55 +0000","from_user":"nogic1008","id_str":"41190418141937664","metadata":{"result_type":"recent"},"to_user_id":88117317,"text":"@runasoru \u307e\u3042\u5acc\u306a\u3089\u6df1\u591c\u5e2f\u306bTwitter\u898b\u306a\u304d\u3083\u3044\u3044\u3060\u3051\u3067\u3059\u304b\u3089\u306d\u30fc \u30103/19BDM\u30aa\u30d5http://twvt.us/bdoff_kansai\u3011","id":41190418141937664,"from_user_id":145311373,"to_user":"runasoru","geo":null,"iso_language_code":"ja","to_user_id_str":"88117317","source":"&lt;a href=&quot;http://sourceforge.jp/projects/tween/wiki/FrontPage&quot; rel=&quot;nofollow&quot;&gt;Tween&lt;/a&gt;"},{"from_user_id_str":"195851300","profile_image_url":"http://a2.twimg.com/profile_images/1124572815/be7b4c0a06cb60e8_normal.jpg","created_at":"Fri, 25 Feb 2011 17:38:49 +0000","from_user":"LoveLAscrewDoll","id_str":"41190391147540480","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @jp_mjp: SCREW TV SHOW Vol.6\u306e\u653e\u9001\u304c\u7121\u4e8b\u306b\u7d42\u4e86\u3044\u305f\u3057\u307e\u3057\u305f\u3002\u3054\u89a7\u9802\u304d\u3042\u308a\u304c\u3068\u3046\u3054\u3056\u3044\u307e\u3057\u305f\uff01\u6b21\u56de\u653e\u9001\u306f3\u670818\u65e5(\u91d1)\u3067\u3059\u3002\u8996\u8074\u8005\u30d7\u30ec\u30bc\u30f3\u30c8\u306e\u8a73\u7d30\u306f\u5f8c\u65e5MJP\u3067\u304a\u77e5\u3089\u305b\u3044\u305f\u3057\u307e\u3059\u3002\u305d\u306e\u969b\u306b\u306f\u3001\u3053\u306eTwitter\u3067\u3082\u304a\u77e5\u3089\u305b\u3044\u305f\u3057\u307e\u3059\u306e\u3067\u3001\u304a\u697d\u3057\u307f\u306b\uff01#SCREWTV","id":41190391147540480,"from_user_id":195851300,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://z.twipple.jp/&quot; rel=&quot;nofollow&quot;&gt;\u3064\u3044\u3063\u3077\u308b/twipple&lt;/a&gt;"},{"from_user_id_str":"178045354","profile_image_url":"http://a0.twimg.com/profile_images/1214479381/154722_10100141954893059_808622_55276626_7445050_n_normal.jpg","created_at":"Fri, 25 Feb 2011 17:38:48 +0000","from_user":"ChuriSta_gt","id_str":"41190389549510656","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3053\u3053\u4e00\u9031\u9593Twitter\u304c\u3084\u305f\u3089\u697d\u3057\u3044\u306e\u3067\u3059\u3051\u3069\u30fc\u30fc\u30fc\uff01\u306b\u3072\u3072\u3063\u7b11","id":41190389549510656,"from_user_id":178045354,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twipple.jp/&quot; rel=&quot;nofollow&quot;&gt;\u3064\u3044\u3063\u3077\u308b for iPhone&lt;/a&gt;"},{"from_user_id_str":"50592111","profile_image_url":"http://a0.twimg.com/profile_images/1252176582/lFjpi_normal.jpg","created_at":"Fri, 25 Feb 2011 17:38:48 +0000","from_user":"crowNeko","id_str":"41190387271864320","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u30a8\u30ed\u30b2\u30d7\u30ec\u30a4\u3057\u306a\u304c\u3089\u307e\u3069\u30de\u30aeTL\u3092\u898b\u306a\u3044\u3088\u3046\u306b\u534a\u76ee\u306b\u306a\u308a\u306a\u304c\u3089Twitter\u3057\u3066\u308b\u6df1\u591c2\u6642\u534a\u3002","id":41190387271864320,"from_user_id":50592111,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://stone.com/Twittelator&quot; rel=&quot;nofollow&quot;&gt;Twittelator&lt;/a&gt;"},{"from_user_id_str":"7141467","profile_image_url":"http://a3.twimg.com/profile_images/1198540741/icon12912579345276_normal.jpg","created_at":"Fri, 25 Feb 2011 17:38:40 +0000","from_user":"hina_geshi","id_str":"41190355961380864","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u7d50\u5c40\u30cd\u30bf\u30d0\u30ec\u3059\u3093\u306a\u3063\u3066\u8a00\u3046\u65b9\u304c\u30a2\u30ec\u3060\u3088\u306d\u3001\u3057\u306a\u3044\u308f\u3051\u7121\u3044\u3058\u3083\u306a\u3044\u8133\u5185\u5782\u308c\u6d41\u3057\u304cTwitter\u306a\u3093\u3060\u304b\u3089\u3055","id":41190355961380864,"from_user_id":7141467,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://projects.playwell.jp/go/Saezuri&quot; rel=&quot;nofollow&quot;&gt;Saezuri&lt;/a&gt;"},{"from_user_id_str":"149608984","profile_image_url":"http://a0.twimg.com/profile_images/1205950885/090702_normal.jpg","created_at":"Fri, 25 Feb 2011 17:38:39 +0000","from_user":"Mr_Tsubaki","id_str":"41190349447774208","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u307e\u3069\u304b\u306fTwitter\u5408\u308f\u305b\u3066\uff11\u6642\u9593\u306f\u697d\u3057\u3044","id":41190349447774208,"from_user_id":149608984,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://z.twipple.jp/&quot; rel=&quot;nofollow&quot;&gt;\u3064\u3044\u3063\u3077\u308b/twipple&lt;/a&gt;"},{"from_user_id_str":"122271550","profile_image_url":"http://a0.twimg.com/profile_images/961936499/neoneko_bot5jpg_____normal.jpg","created_at":"Fri, 25 Feb 2011 17:38:39 +0000","from_user":"neoneko_bot5","id_str":"41190348726345728","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3010\u30c6\u30b9\u30c8\uff1a23\u3011\u4eca\u65e5\u304b\u3089\u5ba3\u4f1d\u958b\u59cb\u2606\u306d\u304a\u306d\u3053\u306eTwitter \u3067 EasyBottex\u3000\u3067\u304d\u308b\u307e\u3067\uff01\u2192http://neoneko.blog31.fc2.com/","id":41190348726345728,"from_user_id":122271550,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www20.atpages.jp/neoneko/&quot; rel=&quot;nofollow&quot;&gt;neoneko_bot5&lt;/a&gt;"},{"from_user_id_str":"127069188","profile_image_url":"http://a3.twimg.com/sticky/default_profile_images/default_profile_6_normal.png","created_at":"Fri, 25 Feb 2011 17:38:37 +0000","from_user":"MYCHEBOT","id_str":"41190340908163074","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u30eb\u30d5\u3055\u3093\u304c\u914d\u4fe1\u3092\u7d42\u4e86\u3057\u307e\u3057\u305f\uff01/ http://777labo.com/mychecker/view/745.php / \u30c8\u30d4\u30c3\u30af:XSplit\u30c6\u30b9\u30c8\u3000twitter\u2192http://twitter.com/rukh01","id":41190340908163074,"from_user_id":127069188,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://777labo.com/mychecker/&quot; rel=&quot;nofollow&quot;&gt;MYCHEBOT&lt;/a&gt;"},{"from_user_id_str":"107626142","profile_image_url":"http://a1.twimg.com/profile_images/1104968421/SuperMaika1_normal.jpg","created_at":"Fri, 25 Feb 2011 17:38:34 +0000","from_user":"MaikaPaPa","id_str":"41190328614666240","metadata":{"result_type":"recent"},"to_user_id":null,"text":"75\u5e74\u524d\u306e\u4eca\u65e52\u670826\u65e5\u672a\u660e\u3001\u82e5\u304d\u9752\u5e74\u5c06\u6821\u3089\u304c\u653f\u6cbb\u8150\u6557\u3068\u8fb2\u6751\u306e\u56f0\u7aae\u306b\u5bfe\u3057\u3066\u6c7a\u8d77\u3057\u307e\u3057\u305f\u3002\u3082\u3061\u308d\u3093\u5f53\u6642\u306fTwitter\u3082FB\u3082\u3001\u307e\u305f\u5f53\u7136\u306a\u304c\u3089Internet\u3082\u3042\u308a\u307e\u305b\u3093\u3067\u3057\u305f\u3002\u4e00\u65b9\u3001\u30c1\u30e5\u30cb\u30b8\u30a2\u3001\u30a8\u30b8\u30d7\u30c8\u3001\u4e2d\u6771\u306b\u5e83\u304c\u308b\u53cd\u653f\u5e9c\u30c7\u30e2\u3068\u5f37\u6a29\u4f53\u5236\u306e\u5d29\u58ca\u3002\u73fe\u5728\u306e\u65e5\u672c\u3067\u306f\u8003\u3048\u3089\u308c\u306a\u3044\u3053\u3068\u3067\u3059\u3002","id":41190328614666240,"from_user_id":107626142,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"11111695","profile_image_url":"http://a1.twimg.com/sticky/default_profile_images/default_profile_0_normal.png","created_at":"Fri, 25 Feb 2011 17:38:28 +0000","from_user":"kumatchipooh","id_str":"41190306145775617","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @inosenaoki: \u306a\u308b\u307b\u3069\u306d\u3002 RT @dansrmz @inosenaoki \u3053\u3061\u3089\u304c\u30bd\u30d5\u30c8\u30d0\u30f3\u30af\u526f\u793e\u9577\u306e\u677e\u672c\u5fb9\u4e09\u3055\u3093\u306e\u3001Twitter\u306b\u95a2\u3059\u308b\u8ad6\u8003\u3067\u3059\u3002 \u25b6 &quot;Twitter\u306e2\u30c1\u30e3\u30f3\u30cd\u30eb\u5316\u306f\u9632\u6b62\u51fa\u6765\u308b\u304b&quot; http://t.co/Mwzb8Zf","id":41190306145775617,"from_user_id":11111695,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"212161909","profile_image_url":"http://a1.twimg.com/profile_images/1252895790/natm01_normal.gif","created_at":"Fri, 25 Feb 2011 17:38:28 +0000","from_user":"n34hitman","id_str":"41190303830511616","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Twitter\u30fb\u30d6\u30ed\u30b0\u30a2\u30d5\u30a3\u30ea\u30a8\u30a4\u30c8\u81ea\u52d5\u6295.... http://goo.gl/a4RHB 4054","id":41190303830511616,"from_user_id":212161909,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twibow.net/&quot; rel=&quot;nofollow&quot;&gt;Twibow&lt;/a&gt;"},{"from_user_id_str":"105945593","profile_image_url":"http://a2.twimg.com/sticky/default_profile_images/default_profile_5_normal.png","created_at":"Fri, 25 Feb 2011 17:38:24 +0000","from_user":"nakano_bot","id_str":"41190285710983168","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3053\u306ebot\u306f\u4e0d\u52d5\u7523\u4f1a\u793e\u69d8\u5411\u3051\u306e\u4e0d\u52d5\u7523\u30dd\u30fc\u30bf\u30eb\u30b5\u30a4\u30c8\u3078\u306e\u4e00\u62ec\u8ee2\u9001\uff0bTwitter\u7121\u6599\u8ee2\u9001\u30b5\u30fc\u30d3\u30b9\u306b\u3088\u308a\u3064\u3076\u3084\u304d\u307e\u3059\u3002\u3054\u5229\u7528\u306b\u306a\u308a\u305f\u3044\u5834\u5408\u306f http://bit.ly/demey0 \u306b\u304a\u6c17\u8efd\u306b\u304a\u554f\u3044\u5408\u308f\u305b\u4e0b\u3055\u3044\u3002","id":41190285710983168,"from_user_id":105945593,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.teramax.jp/aboutus.html&quot; rel=&quot;nofollow&quot;&gt;tmxbot&lt;/a&gt;"},{"from_user_id_str":"170904226","profile_image_url":"http://a2.twimg.com/profile_images/1249020397/1789kb_normal.jpg","created_at":"Fri, 25 Feb 2011 17:38:21 +0000","from_user":"1789kb","id_str":"41190274428305408","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3068\u308a\u3042\u3048\u305a\u4eca\u56de\u521d\u3081\u3066\u30ea\u30a2\u30eb\u30bf\u30a4\u30e0\u3067\u898b\u3066\u308f\u304b\u3063\u305f\u306e\u306f\u3001QB\u306f\u5168\u8eab\u304c\u30a2\u30f3\u30d1\u30f3\u30bf\u30a4\u30d7\u3060\u3068\u3044\u3046\u3053\u3068\u3068\u3001\u307e\u3069\u30de\u30ae\u7d42\u4e86\u5f8c\u306eTwitter\u306e\u3056\u308f\u3064\u304d\u304c\u3059\u3054\u3044\u3068\u3044\u3046\u3053\u3068","id":41190274428305408,"from_user_id":170904226,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.echofon.com/&quot; rel=&quot;nofollow&quot;&gt;Echofon&lt;/a&gt;"},{"from_user_id_str":"166169644","profile_image_url":"http://a1.twimg.com/profile_images/1217017679/image_normal.jpg","created_at":"Fri, 25 Feb 2011 17:38:18 +0000","from_user":"Okkkkkkkkkkun","id_str":"41190262420017152","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3063\u3066Twitter\u3067\u3064\u3076\u3084\u304f\u81ea\u5206\u3082\u76f8\u5f53\u5c0f\u3055\u3044\u306a\u3002","id":41190262420017152,"from_user_id":166169644,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"196623456","profile_image_url":"http://a3.twimg.com/profile_images/1219076661/image_normal.jpg","created_at":"Fri, 25 Feb 2011 17:38:06 +0000","from_user":"NoMoneyClub","id_str":"41190213342601216","metadata":{"result_type":"recent"},"to_user_id":195462431,"text":"@yosal15 \nTwitter\u3084\u3063\u3066\u308b\u3089\u3057\u3044\u3002\u3051\u3069\u3001\u898b\u3064\u304b\u3089\u306a\u3044\u3002","id":41190213342601216,"from_user_id":196623456,"to_user":"yosal15","geo":null,"iso_language_code":"ja","to_user_id_str":"195462431","source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"126984048","profile_image_url":"http://a3.twimg.com/profile_images/1254579571/zipyaru-20090829-23-0012_normal.png","created_at":"Fri, 25 Feb 2011 17:38:02 +0000","from_user":"minaduki_naduki","id_str":"41190196418584576","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u203b\u30e1\u30fc\u30eb\u3067\u5973\u306e\u5b50\u53e3\u8aac\u304f\u306e\u306b\u5fd9\u3057\u3044\u3093\u3060\u305d\u3046\u3067\u3059\u3000\u307e\u3058\u3058\u3054\u308d RT @yowano_k: \u5fd9\u3057\u304f\u3066\u3082Twitter\u306b\u9854\u3092\u51fa\u3057\u305f\u304f\u306a\u308b\u50d5\u30a7\u2026\u2026","id":41190196418584576,"from_user_id":126984048,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://seesmic.com/seesmic_desktop/sd2&quot; rel=&quot;nofollow&quot;&gt;Seesmic Desktop&lt;/a&gt;"},{"from_user_id_str":"200568705","profile_image_url":"http://a3.twimg.com/profile_images/1242179765/101230_1355_01_normal.jpg","created_at":"Fri, 25 Feb 2011 17:38:01 +0000","from_user":"hammerstrap","id_str":"41190190428979200","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u6628\u65e5\u91d1\u66dc\u65e5\u306f\u732e\u8840\u306b\u5f80\u304f\u3002\u4eca\u306e\u50d5\u306e\u4eba\u9593\u3068\u3057\u3066\u306e\u4fa1\u5024\u306f\u3001\u7cbe\u3005\u3053\u306e\u7a0b\u5ea6\u3002\u8179\u304c\u6e1b\u3063\u305f\u3002\u5374\u8aac\u3002twitter\u306e\u767e\u56db\u5341\u6587\u5b57\u306b\u82db\u3005\u3068\u3057\u3066\u3001\u4e00\u3064\u306e\u4eee\u8aac\u306b\u4fe1\u6191\u6027\u3092\u5f97\u308b\u3002\u6226\u6642\u4e0b\u306e\u7d19\u306e\u7d71\u5236\u3068\u3001\u4e2d\u5cf6\u6566\u306e\u6587\u7ae0\u306e\u95a2\u4fc2\u6027\u3002\u73fe\u5728\u30a6\u30a7\u30d6\u30ed\u30b0\u306b\u3001\u7e8f\u3081\u3066\u3044\u308b\u6700\u4e2d\u3002\u8fd1\u65e5\u516c\u958b\u4e88\u5b9a\u3002","id":41190190428979200,"from_user_id":200568705,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"164970427","profile_image_url":"http://a0.twimg.com/profile_images/1227176662/9192b021ef85ce9902c28955f86e604b_normal.jpg","created_at":"Fri, 25 Feb 2011 17:37:59 +0000","from_user":"syuigetsuIT","id_str":"41190184041197569","metadata":{"result_type":"recent"},"to_user_id":141926331,"text":"@iliad_tga \u30a4\u30ea\u30a2\u30b9\u3055\u3093\u304c\u305d\u306e\u8fba\u7406\u89e3\u306e\u3042\u308b\u3053\u3068\u306f\u5206\u304b\u3063\u3066\u307e\u3059\uff57\u3000\u30cd\u30bf\u30d0\u30ec\u4e91\u3005\u306ftwitter\u306e\u6c7a\u5b9a\u7684\u306a\u6b20\u70b9\u3060\u3068\u601d\u3044\u307e\u3059\u306d\u3047\u3002","id":41190184041197569,"from_user_id":164970427,"to_user":"iliad_tga","geo":null,"iso_language_code":"ja","to_user_id_str":"141926331","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"94526795","profile_image_url":"http://a0.twimg.com/profile_images/679411954/akb48_in_normal.jpg","created_at":"Fri, 25 Feb 2011 17:37:56 +0000","from_user":"akb48_in","id_str":"41190171248431104","metadata":{"result_type":"recent"},"to_user_id":null,"text":"AKB48\u67cf\u6728\u7531\u7d00 \u304a\u75b2\u308c\u69d8\u3002: \n\u3053\u3093\u3070\u3093\u306f(^O^)\uff0f\u266a\n\u3000\n\u3000\n\u3000\n\u4eca\u65e5\u306e\u516c\u6f14\u697d\u3057\u304b\u3063\u305f\u301c\n\u3000\n\u3000\n\u4e45\u3057\u3076\u308a\u3067\u7dca\u5f35\u3057\u305f\u3051\u3069\u3001\u306f\u3058\u3051\u307e\u304f\u3063\u305f\u305c\u3043\uff01\uff01\n\u3000\n\u3000\n\u3000\nMC\u306f\u565b\u307f\u307e\u304f\u308a\u306e\u30c6\u30f3\u30d1\u308a\u307e\u304f... http://bit.ly/ie8bEa akb48 twitter","id":41190171248431104,"from_user_id":94526795,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"222270374","profile_image_url":"http://a3.twimg.com/profile_images/1250946143/P1040062_normal.jpg","created_at":"Fri, 25 Feb 2011 17:37:53 +0000","from_user":"chrxpac","id_str":"41190158455943168","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3010\u5b9a\u671f\u3011Twitter\u306f\uff8a\uff9f\uff7f\uff7a\uff9d\u304b\u3089\u3057\u304b\u3067\u304d\u306a\u3044\u306e\u3067\uff98\uff8c\uff9f\u8fd4\u3057\u304c\u9045\u304f\u306a\u308a\u307e\u3059(\u00b4\u30fb\u03c9\u30fb\uff40)\u3054\u4e86\u627f\u4e0b\u3055\u3044!!","id":41190158455943168,"from_user_id":222270374,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twittbot.net/&quot; rel=&quot;nofollow&quot;&gt;twittbot.net&lt;/a&gt;"},{"from_user_id_str":"64009258","profile_image_url":"http://a2.twimg.com/profile_images/1154025023/Mixi___normal.jpg","created_at":"Fri, 25 Feb 2011 17:37:52 +0000","from_user":"Tatsuyuko","id_str":"41190153447944192","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u4f01\u696d\u304c\u5c31\u6d3b\u751f\u306bFacebook\u3092\u4f7f\u3063\u3066\u7533\u8acb\u305b\u3088\u3068\u3044\u3044\u3001\u4f01\u696d\u304cFacebook\u3092\u4f7f\u3048\u3068\u4f01\u696d\u304c\u8a00\u3063\u3066\u304d\u305f\u308a\u3059\u308c\u3070\u305d\u308c\u3069\u3053\u308d\u3058\u3083\u306a\u3044\u304b\u3068\u3002\u5c11\u306a\u304f\u3068\u3082\u5c31\u6d3b\u3067Twitter\u306e\u8a00\u52d5\u3084\u30d5\u30a9\u30ed\u30ef\u30fc\u3092\u8abf\u67fb\u3059\u308b\u4f01\u696d\u306f\u304b\u306a\u308a\u591a\u3044\u3067\u3059 RT @Isshee: \u4f01\u696d\u3067\u3082\u540c\u3058\u3067\u3057\u3087 RT","id":41190153447944192,"from_user_id":64009258,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://sourceforge.jp/projects/tween/wiki/FrontPage&quot; rel=&quot;nofollow&quot;&gt;Tween&lt;/a&gt;"},{"from_user_id_str":"105145175","profile_image_url":"http://static.twitter.com/images/default_profile_normal.png","created_at":"Fri, 25 Feb 2011 17:37:49 +0000","from_user":"snao813","id_str":"41190141703753728","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @yumisaiki: \u795e\u69d8\u306f\u672c\u5f53\u306b\u4eba\u9593\u3092\u3059\u3070\u3089\u3057\u3044\u30d0\u30e9\u30f3\u30b9\u3067\u914d\u7f6e\u3057\u3066\u304a\u3089\u308c\u308b\u3002\u795d\u5cf6\u307f\u305f\u3044\u306a\u5c0f\u3055\u3044\u3068\u3053\u308d\u306b\u306a\u3093\u3067\u3053\u3093\u306a\u306b\u7acb\u6d3e\u306a\u4eba\u304c\u305f\u304f\u3055\u3093\u3044\u308b\u3093\u3060\u308d\u3046\u3002\u795e\u69d8\u3042\u308a\u304c\u3068\u3046\u3002\u672c\u5f53\u306b\u3042\u308a\u304c\u3068\u3046\u3002\u4eba\u9593\u3063\u3066\u3059\u3070\u3089\u3057\u3044\u3068\u601d\u3048\u305f\u3002twitter\u3082\u3042\u308a\u304c\u3068\u3046\u3002\u3000#kaminoseki","id":41190141703753728,"from_user_id":105145175,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://seesmic.com/seesmic_desktop/sd2&quot; rel=&quot;nofollow&quot;&gt;Seesmic Desktop&lt;/a&gt;"},{"from_user_id_str":"203667204","profile_image_url":"http://a2.twimg.com/profile_images/1254664000/eve_blackcat_normal.jpg","created_at":"Fri, 25 Feb 2011 17:37:46 +0000","from_user":"eve_blackcat","id_str":"41190129292943361","metadata":{"result_type":"recent"},"to_user_id":146894340,"text":"@kuroiso02 \u3057\u308a\u3068\u308a\u3068\u304b\uff1f\n\u2026\u3067\u3082Twitter\u3060\u3068\u7d42\u308f\u3089\u306a\u304f\u306a\u308b\u30b1\u30c9\u2026","id":41190129292943361,"from_user_id":203667204,"to_user":"kuroiso02","geo":null,"iso_language_code":"ja","to_user_id_str":"146894340","source":"&lt;a href=&quot;http://twipple.jp/&quot; rel=&quot;nofollow&quot;&gt;\u3064\u3044\u3063\u3077\u308b for iPhone&lt;/a&gt;"},{"from_user_id_str":"6528403","profile_image_url":"http://a0.twimg.com/profile_images/1240591244/image_normal.jpg","created_at":"Fri, 25 Feb 2011 17:37:45 +0000","from_user":"sortiee","id_str":"41190125924917248","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u30a2\u30cb\u30e1\u5b9f\u6cc1\u306ftwitter\u306e\u764c","id":41190125924917248,"from_user_id":6528403,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://sites.google.com/site/peraperaprv/Home&quot; rel=&quot;nofollow&quot;&gt;P3:PeraPeraPrv&lt;/a&gt;"},{"from_user_id_str":"186058304","profile_image_url":"http://a0.twimg.com/profile_images/1250454564/IMG_0210_normal.JPG","created_at":"Fri, 25 Feb 2011 17:37:37 +0000","from_user":"00o8o00","id_str":"41190090386448384","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @fuefukioyasumi: \u3082\u3046\u3044\u3044\u3002\u300c\u671d\u751f\u300d\u306a\u3093\u304b\u3044\u3044\u3002BBC\u3082CNN\u3082\u82f1\u8a9e\u653e\u9001\u3060\u3002\u307f\u3093\u306a\u3001\u30c6\u30ec\u30d3\u3092\u3076\u3061\u3063\u3068\u5207\u3063\u3066Twitter\u3092\u898b\u3088\u3046\u3002\u3053\u3053\u306b\u300c\u751f\u304d\u305f\u60c5\u5831\u300d\u304c\u6d41\u308c\u3066\u3044\u308b\u3002\u300c\u751f\u304d\u305f\u53eb\u3073\u300d\u304c\u3042\u308b\u3002\u3053\u3053\u304b\u3089\u3067\u3082\u6b74\u53f2\u306e\u8ee2\u63db\u70b9\u3092\u611f\u3058\u308b\u4e8b\u304c\u3067\u304d\u308b\u306e\u3060\u3002 @gjmorley #libjp","id":41190090386448384,"from_user_id":186058304,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"49219631","profile_image_url":"http://a2.twimg.com/profile_images/1231873117/__2-colornow__2__normal.jpg","created_at":"Fri, 25 Feb 2011 17:37:33 +0000","from_user":"irisgazer","id_str":"41190073227550720","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3067\u3059\u3088\u306d\u3047 RT @minamitaiheiyou: \u6545\u306b\u30cd\u30bf\u30d0\u30ec\u3092\u3059\u308b\u306e\u3082\u81ea\u7531\u3002\u30cd\u30bf\u3070\u308c\u3057\u305f\u4eba\u3092\u30c7\u30a3\u30b9\u308b\u306e\u3082\u81ea\u7531\u3002\u3042\u3068\u306f\u5404\u3005\u306e\u88c1\u91cf\u3067\u4e57\u308a\u5207\u3063\u3066\u304f\u3060\u3055\u3044\u3088\u3081\u3093\u3069\u304f\u3055\u3044\u306a RT @kihirokiro: Twitter\u3067\u30cd\u30bf\u30d0\u30ec\u4e91\u3005\u3044\u3063\u3066\u3082\u5143\u3005Twitter\u3063\u3066\u300c\u500b\u4eba\u306e\u72ec\u308a\u8a00\u300d\u3060\u308d","id":41190073227550720,"from_user_id":49219631,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://sourceforge.jp/projects/tween/wiki/FrontPage&quot; rel=&quot;nofollow&quot;&gt;Tween&lt;/a&gt;"},{"from_user_id_str":"98560114","profile_image_url":"http://a0.twimg.com/profile_images/1252332545/IMGP8170_normal.jpg","created_at":"Fri, 25 Feb 2011 17:37:32 +0000","from_user":"qess0093","id_str":"41190070706905088","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u30b7\u30e5\u30fc\u30c6\u30a3\u304f\u305d\u3046\u305c\u3048\uff57 RT @syu_thi_bot: \u3044\u3064\u307e\u3067Twitter\u3084\u3063\u3066\u308b\u3093\u3060\u3044\uff1f\u3044\u3044\u52a0\u6e1b\u73fe\u5b9f\u306b\u623b\u308a\u306a\u3088\u3002\u3053\u3053\u306f\u30ad\u30df\u305f\u3061\u4e09\u6b21\u5143\u306e\u4eba\u9593\u304c\u3044\u308b\u3079\u304d\u5834\u6240\u3058\u3083\u306a\u3044\u3093\u3060\u3088\u3002\u305d\u3093\u306a\u306e\u57fa\u672c\u3060\u308d\uff01\uff01","id":41190070706905088,"from_user_id":98560114,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://sourceforge.jp/projects/tween/wiki/FrontPage&quot; rel=&quot;nofollow&quot;&gt;Tween&lt;/a&gt;"},{"from_user_id_str":"197459334","profile_image_url":"http://a3.twimg.com/profile_images/1210698414/shiratorishoko_normal.png","created_at":"Fri, 25 Feb 2011 17:37:31 +0000","from_user":"SyokoShiratori","id_str":"41190064243478528","metadata":{"result_type":"recent"},"to_user_id":null,"text":"+0.50kg \u540c\u3058\u304f\u30c0\u30a4\u30a8\u30c3\u30c8\u4e2d\u3067\u3059\u3002\u3088\u304f\u3053\u306e\u30b5\u30a4\u30c8\u3067\u4f53\u91cd\u5831\u544a\u3057\u3066\u307e\u3059\u266a http://bit.ly/fhN2fM RT @msophiah \u3046\u3046\u3046\u30fb\u30fb\u30fb\u304a\u8179\u3059\u3044\u305f\u301c\u30fb\u30fb\u30fb\u6211\u6162\u3001\u6211\u6162\u3001\u6211\u6162\u3002\u30c0\u30a4\u30a8\u30c3\u30c8\u3001\u30c0\u30a4\u30a8\u30c3\u30c8\u3001\u30c0\u30a4\u30a8\u30c3\u30c8\u3002","id":41190064243478528,"from_user_id":197459334,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://mob-mc.com&quot; rel=&quot;nofollow&quot;&gt;\uff08\u4eee\u79f0\uff09\u30c4\u30a4\u30af\u30ea\u30c3\u30af twiclick&lt;/a&gt;"},{"from_user_id_str":"180410237","profile_image_url":"http://a3.twimg.com/profile_images/1254473979/icon_normal.jpg","created_at":"Fri, 25 Feb 2011 17:37:30 +0000","from_user":"ka_ph","id_str":"41190062184079360","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3010\u5b9a\u671fpost\u3011\u30d5\u30a7\u30eb\u30c7\u30a3\u30ca\u30f3\u30c8bot( http://twitter.com/ferdinand_bot )\u4f5c\u308a\u307e\u3057\u305f\u3002\u304a\u5b50\u69d8\u306e\u540d\u524d\u304a\u501f\u308a\u3055\u305b\u3066\u304f\u308c\u308b\u65b9\u3044\u307e\u3057\u305f\u3089@ka_ph\u307e\u3067\u304a\u9858\u3044\u3057\u307e\u3059\u3002","id":41190062184079360,"from_user_id":180410237,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twittbot.net/&quot; rel=&quot;nofollow&quot;&gt;twittbot.net&lt;/a&gt;"},{"from_user_id_str":"52283906","profile_image_url":"http://a3.twimg.com/profile_images/387644016/10100654519_s_normal.jpg","created_at":"Fri, 25 Feb 2011 17:37:26 +0000","from_user":"rolling_bean","id_str":"41190043313913856","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3081\u307e\u3044\u304c\u3057\u307e\u3059\u306d\u301cRT @yurikalin:\u30b3\u30a4\u30c4\u30e9\u5168\u54e1\u3044\u306a\u304f\u306a\u3063\u305f\u3089\u3001\u660e\u308b\u304f\u306a\u308b\u3060\u308d\u3046\u306a\u3041\uff5e\u266a\uff1e\u65e5\u672c\u306e\u30d3\u30b8\u30e7\u30f3 RT roll \u65e5\u7d4c\uff06CSIS\u30b7\u30f3\u30dd\u30b8\u30a6\u30e0\u300c\u5b89\u4fdd\u6539\u5b9a50\u5468\u5e74\u3001\u3069\u3046\u306a\u308b\u65e5\u7c73\u95a2\u4fc2\u300d http://bit.ly/dES8PY\u3000http://bit.ly/ihg0GT","id":41190043313913856,"from_user_id":52283906,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://tabtter.jp&quot; rel=&quot;nofollow&quot;&gt;\u30bf\u30d6\u30c3\u30bf\u30fc&lt;/a&gt;"},{"from_user_id_str":"351896","profile_image_url":"http://a3.twimg.com/profile_images/1179865336/icon12911887173020_normal.jpg","created_at":"Fri, 25 Feb 2011 17:37:26 +0000","from_user":"cicada","id_str":"41190043292925952","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u4e2d\u5b66\u53d7\u9a13\u7a0b\u5ea6\u306e\u7b97\u6570\u306e\u554f\u984c\u3092\u51fa\u3059BOT http://twitter.com/arithmetic_bot \u6c17\u306b\u306f\u306a\u308b\u304c\u3001\u3061\u3083\u3093\u3068\u898b\u308b\u65e5\u304c\u6765\u308b\u3060\u308d\u3046\u304b\u30fb\u30fb\u3000#tearai\uff1a\u30ed\u30b3\u30e9\u30dc\u5bae\u5d0e\u770c http://locolabo.com/mz/ #mzlf","id":41190043292925952,"from_user_id":351896,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://locolabo.com/mz/&quot; rel=&quot;nofollow&quot;&gt;\u30ed\u30b3\u30e9\u30dc\u5bae\u5d0e\u770c&lt;/a&gt;"},{"from_user_id_str":"744554","profile_image_url":"http://a1.twimg.com/profile_images/1088753125/11868894_normal.gif","created_at":"Fri, 25 Feb 2011 17:37:20 +0000","from_user":"Febreze","id_str":"41190019020505088","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u30cd\u30bf\u30d0\u30ec\u3042\u307e\u308a\u6c17\u306b\u3057\u306a\u3044\u30bf\u30a4\u30d7\u3060\u3051\u3069\u306a\u3093\u304b\u3053\u3046Twitter\u958b\u304f\u3060\u3051\u3067\u30ac\u30f3\u30ac\u30f3\u30cd\u30bf\u30d0\u30ec\u5165\u3063\u3066\u304f\u308b\u306e\u306f\u306a\u3093\u3068\u3082\u8a00\u3048\u306a\u3044\u306a\u3002","id":41190019020505088,"from_user_id":744554,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"203371794","profile_image_url":"http://a1.twimg.com/profile_images/1226537594/___normal.png","created_at":"Fri, 25 Feb 2011 17:37:16 +0000","from_user":"himeko24","id_str":"41190004139114496","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u6b21\u3044\u3063\u3066\u307f\u3088\u30fc\u3000\u306f\u3044\u3053\u308c\u3000 \u6fc0\u5b89\u26052010\u5e74\u590f\u65b0\u30c7\u30b6\u30a4\u30f3\u2605\u30bb\u30af\u30b7\u30fc\u306a\u9023\u4f53\u5f0f\u7121\u5730\u6c34\u7740 \u80f8\u30d1\u30c3\u30c9\u4ed8\u304dQ122 http://bit.ly/h72C4i","id":41190004139114496,"from_user_id":203371794,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.google.co.jp&quot; rel=&quot;nofollow&quot;&gt;himeko24&lt;/a&gt;"},{"from_user_id_str":"119988932","profile_image_url":"http://a3.twimg.com/profile_images/1214344633/image_normal.jpg","created_at":"Fri, 25 Feb 2011 17:37:16 +0000","from_user":"7na_love_6sa","id_str":"41190002000007169","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u30d6\u30ed\u30b0\u66f4\u65b0\u3057\u307e\u3057\u305f\uff01Twitter\uff06mixi\u304b\u3089\u3082\u30b3\u30e1\u30f3\u30c8\u5b9c\u3057\u304f\u306d\u266a\n\u300c\u30cd\u30a4\u30eb\u30c1\u30a7\u30f3\u30b8\u266a\u300d http://amba.to/hy0Do2","id":41190002000007169,"from_user_id":119988932,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"217408835","profile_image_url":"http://a1.twimg.com/profile_images/1215428655/____4.0157_normal.jpg","created_at":"Fri, 25 Feb 2011 17:37:12 +0000","from_user":"nikubenki1123","id_str":"41189985424125952","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @x68k: \u57fa\u672c\u7684\u306bTwitter\u4e0a\u3067\u306f&quot;\u597d\u304d\u306b\u3084\u308c\u3070\u3044\u3044&quot;\u3060\u3051\u3069\u3001\u540d\u524d\u3082\u30a2\u30a4\u30b3\u30f3\u3082\u30a2\u30f3\u30bf\u3058\u3083\u306a\u3044\u305f\u304f\u3055\u3093\u306e\u4eba\u305f\u3061\u306e\u9b42\u304c\u3053\u3082\u3063\u305f\u3082\u306e\u306a\u306e\u3060\u304b\u3089\u3001\u305d\u308c\u3060\u3051\u306f&quot;\u80cc\u8ca0\u3048&quot;\u3068\u601d\u3046\uff1e\u30ad\u30e3\u30e9\u30af\u30bf\u30fc\u30a2\u30ab\u30a6\u30f3\u30c8","id":41189985424125952,"from_user_id":217408835,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://tweetlogix.com&quot; rel=&quot;nofollow&quot;&gt;Tweetlogix&lt;/a&gt;"},{"from_user_id_str":"139137996","profile_image_url":"http://a0.twimg.com/profile_images/1087408006/cut_work_18_normal.jpg","created_at":"Fri, 25 Feb 2011 17:37:12 +0000","from_user":"fujiokayouko","id_str":"41189984354566144","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u591c\u4e2d\u306bTwitter\u3092\u306a\u3093\u3068\u306a\u304f\u8997\u3044\u305f\u3089\u3082\u306e\u3059\u3054\u3044\u307e\u3069\u30de\u30aeTL\u3067","id":41189984354566144,"from_user_id":139137996,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://mobile.twitter.com&quot; rel=&quot;nofollow&quot;&gt;Mobile Web&lt;/a&gt;"},{"from_user_id_str":"61221002","profile_image_url":"http://a3.twimg.com/profile_images/554916301/_1259757374_61_normal.png","created_at":"Fri, 25 Feb 2011 17:37:08 +0000","from_user":"hiromk63","id_str":"41189970613903360","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @kenji_kohashi \u7121\u4e8b\u6620\u753b\u88fd\u4f5c\u306e\u5831\u544a\u306f\u3067\u304d\u305f\u3051\u3069\u4eca\u3060\u7de8\u96c6\u306f\u7d9a\u3044\u3066\u307e\u3059w \u305d\u3093\u306a\u3068\u3053\u3067 \u6620\u753b\u300cDON'T STOP!\u300d\u306eTwitter \u30a2\u30ab\u30a6\u30f3\u30c8 @DONTSTOPMOVIE \u3082\u958b\u59cb\u3001\u3082\u3057\u826f\u304b\u3063\u305f\u3089\u30d5\u30a9\u30ed\u30fc\u3057\u3066\u304f\u3060\u3055\u3044\uff01\u50d5\u3082\u542b\u3081\u6620\u753b\u88fd\u4f5c\u95a2\u4fc2\u8005\u304c\u6c17\u9577\u306b\u3064\u3076\u3084\u304d\u307e\u3059","id":41189970613903360,"from_user_id":61221002,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.hootsuite.com&quot; rel=&quot;nofollow&quot;&gt;HootSuite&lt;/a&gt;"},{"from_user_id_str":"147393812","profile_image_url":"http://a1.twimg.com/profile_images/1114001122/hana_10_normal.jpg","created_at":"Fri, 25 Feb 2011 17:37:07 +0000","from_user":"tubasa_uki","id_str":"41189965924667392","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\uff10\uff10\uff17\u3082\u3073\u3063\u304f\u308a\u3000\u5927\u56fd\u306e\u5927\u7d71\u9818\u9078\u304b\u3089\u3000\u5cf6\u56fd\u306e\u5730\u65b9\u9078\u306e\u9078\u6319\u307e\u3067\u306b\u3082\u3000\u6697\u8e8d\u3057\u3066\u3044\u308b\uff3e\uff3e\u3000\u3053\u306eTwitter \u30b9\u30ad\u30e3\u30f3\u30c0\u30eb\u3084\u60aa\u8cea\u306a\u4e8b\u4ef6\u306b\u3082\u7d61\u3080\u304c\u3000Twitter\u304b\u3089\u767a\u4fe1\u3055\u308c\u305f\u3000\u5e73\u548c\u3078\u306e\u8ca2\u732e\u306f\u3000\u307e\u3055\u306b\u30ce\u30fc\u3079\u30eb\u5e73\u548c\u8cde\u3082\u306e http://bit.ly/esjWDG #dotubo_ss","id":41189965924667392,"from_user_id":147393812,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twittbot.net/&quot; rel=&quot;nofollow&quot;&gt;twittbot.net&lt;/a&gt;"},{"from_user_id_str":"96081746","profile_image_url":"http://a0.twimg.com/profile_images/1244505419/illust832_normal.png","created_at":"Fri, 25 Feb 2011 17:37:07 +0000","from_user":"kazukt","id_str":"41189963131387904","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3046\u308b\u304a\u307c\u7d75\u3001\u4ed6\u306e\u4eba\u306e\u3082\u898b\u3066\u3044\u305f\u3089\u3084\u305f\u3089\u30de\u30f3\u30ac\u306e\u30ad\u30e3\u30e9\u30af\u30bf\u30fc\u3067\u3080\u3061\u3083\u304f\u3061\u3083\u4e0a\u624b\u3044\u4eba\u304c\uff01\u2026\u3068\u3001\u30d7\u30ed\u30d5\u30a3\u30fc\u30eb\u898b\u305f\u3089\u3001\u306a\u3093\u3068\u3054\u672c\u4eba\u304c\u66f8\u3044\u3066\u3044\u3089\u3063\u3057\u3083\u3063\u305f\u3002Twitter\u3063\u3066\u30b9\u30b4\u30a4\u308f\u3002","id":41189963131387904,"from_user_id":96081746,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://janetter.net/&quot; rel=&quot;nofollow&quot;&gt;Janetter&lt;/a&gt;"},{"from_user_id_str":"86306230","profile_image_url":"http://a1.twimg.com/profile_images/593004766/j2j_normal.jpg","created_at":"Fri, 25 Feb 2011 17:37:03 +0000","from_user":"excite_j2j","id_str":"41189949927596032","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u79c1\u306f\u3001\u65e9\u7a32\u7530\u5927\u5b66\u30aa\u30fc\u30d7\u30f3\u30ab\u30ec\u30c3\u30b8\u306e\u5b66\u751f\u306e\u8003\u3048\u3066\u3044\u308b\u3001\u5352\u696d\u751fSoudai /\u65e9\u7a32\u7530\u30ab\u30fc\u30c9\u4f1a\u54e1/ Soudai\u5b66\u751f\u89aa/\u3001\u8ab0\u304b\u304c\u30aa\u30fc\u30d7\u30f3\u30ab\u30ec\u30c3\u30b8\u65e9\u7a32\u7530\u5927\u5b662000\u5186\u306e\u5165\u5834\u6599\u306e\u30e1\u30f3\u30d0\u30fc\u3092\u7d39\u4ecb\u3057\u3066\u304f\u308c\u305f\u65b9\u304c\u305a\u3063\u3068\u5b89\u4e0a\u304c\u308a\u3060\u3002 (\u5143\u767a\u8a00 http://bit.ly/esxiwT )","id":41189949927596032,"from_user_id":86306230,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://d.hatena.ne.jp/fn7&quot; rel=&quot;nofollow&quot;&gt;\u65e5\u672c\u8a9e\u65e5\u672c\u8a9e\u7ffb\u8a33\u30b8\u30a7\u30cd\u30ec\u30fc\u30bf&lt;/a&gt;"},{"from_user_id_str":"120927161","profile_image_url":"http://a0.twimg.com/profile_images/1230006483/20110131_13022_26776_normal.jpg","created_at":"Fri, 25 Feb 2011 17:37:00 +0000","from_user":"FRISKFOSSILFANG","id_str":"41189933855158272","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @syu_thi_bot: \u3044\u3064\u307e\u3067Twitter\u3084\u3063\u3066\u308b\u3093\u3060\u3044\uff1f\u3044\u3044\u52a0\u6e1b\u73fe\u5b9f\u306b\u623b\u308a\u306a\u3088\u3002\u3053\u3053\u306f\u30ad\u30df\u305f\u3061\u4e09\u6b21\u5143\u306e\u4eba\u9593\u304c\u3044\u308b\u3079\u304d\u5834\u6240\u3058\u3083\u306a\u3044\u3093\u3060\u3088\u3002\u305d\u3093\u306a\u306e\u57fa\u672c\u3060\u308d\uff01\uff01","id":41189933855158272,"from_user_id":120927161,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twittbot.net/&quot; rel=&quot;nofollow&quot;&gt;twittbot.net&lt;/a&gt;"},{"from_user_id_str":"228973151","profile_image_url":"http://a1.twimg.com/sticky/default_profile_images/default_profile_0_normal.png","created_at":"Fri, 25 Feb 2011 17:36:59 +0000","from_user":"daisuke1589","id_str":"41189931887890432","metadata":{"result_type":"recent"},"to_user_id":null,"text":"twitter\u3063\u3066\u52dd\u624b\u306b\u30d5\u30a9\u30ed\u30fc\u3057\u3066\u3082\u3044\u3044\u3093\u3060\u3063\u3051\uff1f","id":41189931887890432,"from_user_id":228973151,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"54314110","profile_image_url":"http://a2.twimg.com/profile_images/1193541240/image_normal.jpg","created_at":"Fri, 25 Feb 2011 17:36:57 +0000","from_user":"Alohazuki","id_str":"41189922668953600","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Twitter\u306e\u5e83\u5cf6\u5f01\u3082\u3042\u3063\u305f\u3093\u3060\u306d\u3002","id":41189922668953600,"from_user_id":54314110,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.flight.co.jp/iPhone/TweetMe/&quot; rel=&quot;nofollow&quot;&gt;TweetMe for iPhone&lt;/a&gt;"},{"from_user_id_str":"72594681","profile_image_url":"http://a3.twimg.com/profile_images/1227240916/____normal.jpg","created_at":"Fri, 25 Feb 2011 17:36:56 +0000","from_user":"uri4ichi","id_str":"41189916922744832","metadata":{"result_type":"recent"},"to_user_id":226852303,"text":"@7_fuka Twitter\u304b\u3076\u308c\u306f\u3001\u3059\u3050\u306bD\u306b\u8d70\u308b\u306e\u3067\u3002\u306a\u3093\u3060\u304b\u5fae\u7b11\u307e\u3057\u3044\u306e\u3067\u3059( \u2579\u25e1\u2579)","id":41189916922744832,"from_user_id":72594681,"to_user":"7_fuka","geo":null,"iso_language_code":"ja","to_user_id_str":"226852303","source":"&lt;a href=&quot;http://sites.google.com/site/yorufukurou/&quot; rel=&quot;nofollow&quot;&gt;YoruFukurou&lt;/a&gt;"},{"from_user_id_str":"168393854","profile_image_url":"http://a3.twimg.com/profile_images/1253554518/GuNp3xVS_normal","created_at":"Fri, 25 Feb 2011 17:36:55 +0000","from_user":"makonyanhime","id_str":"41189913701515264","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u6589\u85e4\u3055\u3093\u3082\u30c0\u30e1\u3060...\u4eca\u591c\u306fTwitter\u5909\u3060\u306a\u3041(;_;)","id":41189913701515264,"from_user_id":168393854,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://mobile.twitter.com&quot; rel=&quot;nofollow&quot;&gt;Twitter for Android&lt;/a&gt;"},{"from_user_id_str":"122636787","profile_image_url":"http://a2.twimg.com/profile_images/1189607563/DSC01987_normal.JPG","created_at":"Fri, 25 Feb 2011 17:36:54 +0000","from_user":"enpy1217","id_str":"41189908500594688","metadata":{"result_type":"recent"},"to_user_id":null,"text":"twitter\u4e45\u3057\u3076\u308a\u306b\u958b\u3044\u305f\u3002\u3068\u3066\u3082\u591a\u5fd9\u3060\u3063\u305f\u3002\u75b2\u308c\u305f\u3002\u304a\u98a8\u5442\u306b\u3082\u5165\u308c\u306a\u304b\u3063\u305f\u3002\u30ad\u30bf\u30cd\u2026","id":41189908500594688,"from_user_id":122636787,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.flight.co.jp/iPhone/TweetMe/&quot; rel=&quot;nofollow&quot;&gt;TweetMe for iPhone&lt;/a&gt;"},{"from_user_id_str":"81663694","profile_image_url":"http://a3.twimg.com/profile_images/1177576126/__normal.png","created_at":"Fri, 25 Feb 2011 17:36:51 +0000","from_user":"progmiya","id_str":"41189895494049792","metadata":{"result_type":"recent"},"to_user_id":94050844,"text":"@hirasai_skyhigh \u6674\u308c\u541b\u3002\u30cd\u30bf\u30d0\u30ec\u306f\u898b\u305f\u304f\u306a\u3044\u3051\u3069\u30012ch\u3082twitter\u3082\u3084\u308a\u305f\u3044\u306e\u304c\u4eba\u3068\u8a00\u3046\u3082\u306e\u3088","id":41189895494049792,"from_user_id":81663694,"to_user":"hirasai_skyhigh","geo":null,"iso_language_code":"ja","to_user_id_str":"94050844","source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"159237469","profile_image_url":"http://a3.twimg.com/profile_images/1140433484/______2_normal.png","created_at":"Fri, 25 Feb 2011 17:36:50 +0000","from_user":"hikari_juku","id_str":"41189892096532480","metadata":{"result_type":"recent"},"to_user_id":135634241,"text":"@sssukimasuky \n\u4f55\u304b\u3042\u3063\u305f\u98a8\u3067\u3059\u306d\uff08\u7b11\uff09\u3000\u78ba\u304b\u306bTwitter\u306f\u6c17\u8efd\u3067\u3059\u3057\u306d\u3002\u30e1\u30fc\u30eb\u306b\u306a\u308b\u3068\u30d5\u30c3\u30c8\u30ef\u30fc\u30af\u304c\u91cd\u304f\u306a\u308b\u5834\u5408\u3082\u3042\u308b\u304b\u3082\u3057\u308c\u307e\u305b\u3093\u306d\u3002\u305d\u3046\u8003\u3048\u308b\u3068\u3059\u3054\u3044\u6642\u4ee3\u3060\u3002","id":41189892096532480,"from_user_id":159237469,"to_user":"sssukimasuky","geo":null,"iso_language_code":"ja","to_user_id_str":"135634241","source":"&lt;a href=&quot;http://www.hootsuite.com&quot; rel=&quot;nofollow&quot;&gt;HootSuite&lt;/a&gt;"},{"from_user_id_str":"141915990","profile_image_url":"http://a0.twimg.com/profile_images/1248969898/icon679566266564378764images_normal.jpg","created_at":"Fri, 25 Feb 2011 17:36:48 +0000","from_user":"adashino_","id_str":"41189886878949376","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @fuefukioyasumi: \u3082\u3046\u3044\u3044\u3002\u300c\u671d\u751f\u300d\u306a\u3093\u304b\u3044\u3044\u3002BBC\u3082CNN\u3082\u82f1\u8a9e\u653e\u9001\u3060\u3002\u307f\u3093\u306a\u3001\u30c6\u30ec\u30d3\u3092\u3076\u3061\u3063\u3068\u5207\u3063\u3066Twitter\u3092\u898b\u3088\u3046\u3002\u3053\u3053\u306b\u300c\u751f\u304d\u305f\u60c5\u5831\u300d\u304c\u6d41\u308c\u3066\u3044\u308b\u3002\u300c\u751f\u304d\u305f\u53eb\u3073\u300d\u304c\u3042\u308b\u3002\u3053\u3053\u304b\u3089\u3067\u3082\u6b74\u53f2\u306e\u8ee2\u63db\u70b9\u3092\u611f\u3058\u308b\u4e8b\u304c\u3067\u304d\u308b\u306e\u3060\u3002 @gjmorley #libjp","id":41189886878949376,"from_user_id":141915990,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"111308629","profile_image_url":"http://a1.twimg.com/profile_images/1137421845/mmooton_normal.png","created_at":"Fri, 25 Feb 2011 17:36:46 +0000","from_user":"mmooton","id_str":"41189877940748288","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @minponjp: \u3010\u3064\u3076\u3084\u304f\u3060\u3051\u306710000\u5186\u5546\u54c1\u5238GET\u3011&lt;&lt;visa\u30ae\u30d5\u30c8\u30ab\u30fc\u30c910000\u5186\u5206\u3092\u6bce\u6708\u62bd\u9078\u3067\u30d7\u30ec\u30bc\u30f3\u30c8&gt;&gt; \u21d2\u8a73\u3057\u304f\u306f\u4e0b\u306e\uff35\uff32\uff2c\u3088\u308a\u2193\u2193\u2193\u2193\u2193 http://minpon.jp/user_data/twitter_campaign.php","id":41189877940748288,"from_user_id":111308629,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twittbot.net/&quot; rel=&quot;nofollow&quot;&gt;twittbot.net&lt;/a&gt;"},{"from_user_id_str":"140945098","profile_image_url":"http://a0.twimg.com/profile_images/1198948281/b7664c71-87bc-4187-9d46-a61ab8d41b96_normal.jpg","created_at":"Fri, 25 Feb 2011 17:36:46 +0000","from_user":"waruimayuko","id_str":"41189877122867200","metadata":{"result_type":"recent"},"to_user_id":113371008,"text":"@toumeisyoujyo \u3042\u3053\u3061\u3083\u3093Twitter\u3084\u3063\u3066\u305f\u306e\u306d\u3002\u307e\u3060\u304a\u5e2d\u3042\u308b\u305d\u3046\u306a\u306e\u3067\u662f\u975e\uff01","id":41189877122867200,"from_user_id":140945098,"to_user":"toumeisyoujyo","geo":null,"iso_language_code":"ja","to_user_id_str":"113371008","source":"&lt;a href=&quot;http://twimi.jp/?r=via&quot; rel=&quot;nofollow&quot;&gt;twimi\u2606new&lt;/a&gt;"},{"from_user_id_str":"167512527","profile_image_url":"http://a1.twimg.com/profile_images/1172286365/newspaper_normal.jpg","created_at":"Fri, 25 Feb 2011 17:36:45 +0000","from_user":"KoranKaget","id_str":"41189871775252480","metadata":{"result_type":"recent"},"to_user_id":null,"text":"http://bit.ly/93Eeud RT @motocentrism \u30d6\u30ed\u30b0\u8a18\u4e8b\u66f8\u304d\u307e\u3057\u305f\u30fc\uff1a MotoGP\u3000\u30d6\u30c3\u30af\u30e1\u30fc\u30ab\u30fc\u306b\u898b\u308b\u5404\u30e9\u30a4\u30c0\u30fc\u306e\u4e0b\u99ac\u8a55 - http://goo.gl/xVe6... http://bit.ly/hDYxyx @motogpudpate","id":41189871775252480,"from_user_id":167512527,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"160251772","profile_image_url":"http://a3.twimg.com/profile_images/1150692471/_____normal.jpg","created_at":"Fri, 25 Feb 2011 17:36:45 +0000","from_user":"keikochaki","id_str":"41189870781075456","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u300c\u305a\u3063\u3068twitter\u3084\u3063\u3066\u308b\u3088\u306d\u300d\u3068\u6012\u3089\u308c\u3066\u3057\u307e\u3063\u305f(\u82e6\u7b11)","id":41189870781075456,"from_user_id":160251772,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twtr.jp&quot; rel=&quot;nofollow&quot;&gt;Keitai Web&lt;/a&gt;"},{"from_user_id_str":"211565766","profile_image_url":"http://a2.twimg.com/sticky/default_profile_images/default_profile_5_normal.png","created_at":"Fri, 25 Feb 2011 17:36:42 +0000","from_user":"sayap1yo","id_str":"41189858236043264","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u304a\u98df\u4e8b\u4f1a\u884c\u304d\u305f\u304b\u3063\u305f\u3051\u3069\n\u53cb\u9054\u3068\u904a\u3093\u3067\u307e\u3093\u305f\ue056\ue326\n\nTwitter\u898b\u3066\u307e\u3057\u305f\u3051\u3069\n\u3064\u3076\u3084\u304f\u30bf\u30a4\u30df\u30f3\u30b0\n\u5931\u3063\u3066\u305f\u3060\u3051\u3067\u3059( \u00b4 \u25bd ` )\uff89\u7b11","id":41189858236043264,"from_user_id":211565766,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.nibirutech.com&quot; rel=&quot;nofollow&quot;&gt;TwitBird&lt;/a&gt;"},{"from_user_id_str":"19603191","profile_image_url":"http://a1.twimg.com/profile_images/1254077264/116_normal.gif","created_at":"Fri, 25 Feb 2011 17:36:40 +0000","from_user":"Purple_Flash","id_str":"41189851873157120","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @syu_thi_bot: \u3044\u3064\u307e\u3067Twitter\u3084\u3063\u3066\u308b\u3093\u3060\u3044\uff1f\u3044\u3044\u52a0\u6e1b\u73fe\u5b9f\u306b\u623b\u308a\u306a\u3088\u3002\u3053\u3053\u306f\u30ad\u30df\u305f\u3061\u4e09\u6b21\u5143\u306e\u4eba\u9593\u304c\u3044\u308b\u3079\u304d\u5834\u6240\u3058\u3083\u306a\u3044\u3093\u3060\u3088\u3002\u305d\u3093\u306a\u306e\u57fa\u672c\u3060\u308d\uff01\uff01","id":41189851873157120,"from_user_id":19603191,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twittbot.net/&quot; rel=&quot;nofollow&quot;&gt;twittbot.net&lt;/a&gt;"},{"from_user_id_str":"215930291","profile_image_url":"http://a0.twimg.com/profile_images/1247906106/image_normal.jpg","created_at":"Fri, 25 Feb 2011 17:36:30 +0000","from_user":"minori_millie","id_str":"41189810055938048","metadata":{"result_type":"recent"},"to_user_id":212972774,"text":"@c_c_chika \u7b11\u3063\u3066\u305d\u3046\u3060\u306a\u3063\u3066\u601d\u3063\u3066\u305f(o^^o)\u30c1\u30ab\u306e\u7b11\u3044\u58f0\u304c\u805e\u3053\u3048\u3066\u304d\u305f\u3082\u3093\u3002mail\u306bTwitter\u3067\u5927\u5fd9\u3057\u3084\u3002","id":41189810055938048,"from_user_id":215930291,"to_user":"c_c_chika","geo":null,"iso_language_code":"ja","to_user_id_str":"212972774","source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"197459334","profile_image_url":"http://a3.twimg.com/profile_images/1210698414/shiratorishoko_normal.png","created_at":"Fri, 25 Feb 2011 17:36:30 +0000","from_user":"SyokoShiratori","id_str":"41189809586311168","metadata":{"result_type":"recent"},"to_user_id":null,"text":"+0.90kg \u30c0\u30a4\u30a8\u30c3\u30c8\u5fdc\u63f4\u3057\u3066\u307e\u3059\u3002(*^^*)\u30c0\u30a4\u30a8\u30c3\u30c8\u4f53\u91cd\u5831\u544a\u306e\u3064\u3076\u3084\u304d\u3067\u3059\u3002 http://bit.ly/fhN2fM RT @hayayumi \u3053\u3093\u306a\u6642\u9593\u306b\u3084\u304d\u306b\u304f\u30fc\u266b\u30c0\u30a4\u30a8\u30c3\u30c8\u671f\u9593\u306a\u306e\u306b\u306d....","id":41189809586311168,"from_user_id":197459334,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://mob-mc.com&quot; rel=&quot;nofollow&quot;&gt;\uff08\u4eee\u79f0\uff09\u30c4\u30a4\u30af\u30ea\u30c3\u30af twiclick&lt;/a&gt;"},{"from_user_id_str":"12337665","profile_image_url":"http://a0.twimg.com/profile_images/1146194926/pixiv-icon_normal.png","created_at":"Fri, 25 Feb 2011 17:36:27 +0000","from_user":"t_a_k_i","id_str":"41189797364121600","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Google\u30ea\u30fc\u30c0\u30fc\u3067\u30b5\u30a4\u30c8\u306e\u66f4\u65b0\u30c1\u30a7\u30c3\u30af\u3059\u308b\u3088\u308a\u3001Twitter\u30a2\u30ab\u30a6\u30f3\u30c8\u3092\u30d5\u30a9\u30ed\u30fc\u3057\u3066\u66f4\u65b0\u3092\u77e5\u308b\u307b\u3046\u304c\u4fbf\u5229\u3060\u306a\u3053\u308c","id":41189797364121600,"from_user_id":12337665,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://sites.google.com/site/yorufukurou/&quot; rel=&quot;nofollow&quot;&gt;YoruFukurou&lt;/a&gt;"},{"from_user_id_str":"104862453","profile_image_url":"http://a3.twimg.com/profile_images/1248609864/Image014_normal.jpg","created_at":"Fri, 25 Feb 2011 17:36:25 +0000","from_user":"yuz_ume","id_str":"41189787943714816","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @fuefukioyasumi: \u3082\u3046\u3044\u3044\u3002\u300c\u671d\u751f\u300d\u306a\u3093\u304b\u3044\u3044\u3002BBC\u3082CNN\u3082\u82f1\u8a9e\u653e\u9001\u3060\u3002\u307f\u3093\u306a\u3001\u30c6\u30ec\u30d3\u3092\u3076\u3061\u3063\u3068\u5207\u3063\u3066Twitter\u3092\u898b\u3088\u3046\u3002\u3053\u3053\u306b\u300c\u751f\u304d\u305f\u60c5\u5831\u300d\u304c\u6d41\u308c\u3066\u3044\u308b\u3002\u300c\u751f\u304d\u305f\u53eb\u3073\u300d\u304c\u3042\u308b\u3002\u3053\u3053\u304b\u3089\u3067\u3082\u6b74\u53f2\u306e\u8ee2\u63db\u70b9\u3092\u611f\u3058\u308b\u4e8b\u304c\u3067\u304d\u308b\u306e\u3060\u3002 @gjmorley #libjp","id":41189787943714816,"from_user_id":104862453,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"213846746","profile_image_url":"http://a1.twimg.com/profile_images/1242263342/haruhi1_normal.png","created_at":"Fri, 25 Feb 2011 17:36:23 +0000","from_user":"sloth888jpgame","id_str":"41189778409922560","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u643a\u5e2f\u96fb\u8a71\u7528\u306eTwitter\u3092\u5229\u7528\u3057\u305f\u30b2\u30fc\u30e0\u3092\u77e5\u3063\u3066\u3044\u308b\u4eba\u306f\u3001\u7d39\u4ecb\u3057\u3066\u304f\u3060\u3055\u3044\u3002 #TwitterGame","id":41189778409922560,"from_user_id":213846746,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twittbot.net/&quot; rel=&quot;nofollow&quot;&gt;twittbot.net&lt;/a&gt;"},{"from_user_id_str":"17484724","profile_image_url":"http://a2.twimg.com/profile_images/1138677235/iconue_normal.jpg","created_at":"Fri, 25 Feb 2011 17:36:22 +0000","from_user":"tsutcho","id_str":"41189777831231490","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u30a2\u30aa\u30b7\u30de\u3055\u3093twitter\u306b\u7acb\u3064\u30fb\u30fb\u30fb\u3060\u3068\u30fb\u30fb\u30fb\uff1f\uff12\u756a\u76ee\u306e\u30d5\u30a9\u30ed\u30ef\u30fc\u306e\u5ea7\u3092\u3044\u305f\u3060\u3044\u3066\u304a\u3053\u3046","id":41189777831231490,"from_user_id":17484724,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"220041064","profile_image_url":"http://a1.twimg.com/sticky/default_profile_images/default_profile_0_normal.png","created_at":"Fri, 25 Feb 2011 17:36:21 +0000","from_user":"sloth888jp_bot5","id_str":"41189772521254914","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u6642\u3005\u3001TwiAll\uff08\u30c4\u30a4\u30aa\u30fc\u30eb\uff09\u3067Twitter\u306e\u81ea\u52d5\u30d5\u30a9\u30ed\u30fc\u30fb\u30d5\u30a9\u30ed\u30fc\u8fd4\u3057\u3092\u3057\u3066\u3044\u307e\u3059\u3002","id":41189772521254914,"from_user_id":220041064,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twittbot.net/&quot; rel=&quot;nofollow&quot;&gt;twittbot.net&lt;/a&gt;"},{"from_user_id_str":"177693537","profile_image_url":"http://a0.twimg.com/profile_images/1240130924/20110207213206_normal.jpg","created_at":"Fri, 25 Feb 2011 17:36:21 +0000","from_user":"Na_Okinawa","id_str":"41189769912397824","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @ebizo66: \u30ea\u30d3\u30a2\u30fb\u30c8\u30ea\u30dd\u30ea\u306eTw\uff1a\u6551\u6025\u8eca\u304c\u6765\u305f\u304c\u3001\u8ca0\u50b7\u8005\u3092\u8eca\u5185\u3067\u6bba\u5bb3\u3057\u3066\u3044\u305f\u3001\u3068\u3002\uff08\u6ec5\u8336\u82e6\u8336\u3060\uff01\uff09http://ow.ly/43pQ2 #libjp","id":41189769912397824,"from_user_id":177693537,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.hootsuite.com&quot; rel=&quot;nofollow&quot;&gt;HootSuite&lt;/a&gt;"},{"from_user_id_str":"147006592","profile_image_url":"http://a2.twimg.com/profile_images/1251306448/image_normal.jpg","created_at":"Fri, 25 Feb 2011 17:36:19 +0000","from_user":"takasu_rika","id_str":"41189763532865536","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @kihirokiro: Twitter\u3067\u30cd\u30bf\u30d0\u30ec\u4e91\u3005\u3044\u3063\u3066\u3082\u5143\u3005Twitter\u3063\u3066\u300c\u500b\u4eba\u306e\u72ec\u308a\u8a00\u300d\u3060\u308d","id":41189763532865536,"from_user_id":147006592,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"100239985","profile_image_url":"http://a1.twimg.com/profile_images/733461294/CIMG0207_normal.JPG","created_at":"Fri, 25 Feb 2011 17:36:19 +0000","from_user":"strangebarjun","id_str":"41189762182152192","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Twitter\u3092\u59cb\u3081\u3066\u3001\u305d\u308d\u305d\u308d\u4e00\u5e74\u306b\u306a\u308a\u307e\u3059\u3002\u632f\u308a\u8fd4\u308b\u3068\u3001\u307c\u304f\u306e\u4eba\u9593\u6027\u3092\u305d\u3063\u304f\u308a\u53cd\u6620\u3059\u308b\u304c\u5982\u304f\u3001\u534a\u7aef\u3067\u3059\u306d\u3002\u60c5\u5831\u53ce\u96c6\u30c4\u30fc\u30eb\u3001\u60c5\u5831\u767a\u4fe1\u30c4\u30fc\u30eb\u3001\u30b3\u30df\u30e5\u30cb\u30b1\u30fc\u30b7\u30e7\u30f3\u30c4\u30fc\u30eb\u3001\u3069\u308c\u3082\u6a5f\u80fd\u3057\u5207\u308c\u3066\u3044\u306a\u3044\u306a\u3042\u3001\u3068\u3002\u305d\u3057\u3066\u3042\u308b\u306e\u306f\u300c\u3069\u3053\u304b\u3089\u3082\u76f8\u624b\u306b\u3055\u308c\u3066\u3044\u306a\u3044\u300d\u3068\u3044\u3046\u3001\u65e2\u77e5\u306e\u73fe\u5b9f\u3067\u3059\u3002","id":41189762182152192,"from_user_id":100239985,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.echofon.com/&quot; rel=&quot;nofollow&quot;&gt;Echofon&lt;/a&gt;"},{"from_user_id_str":"126390384","profile_image_url":"http://a2.twimg.com/profile_images/1176065038/nemunemu_normal.jpg","created_at":"Fri, 25 Feb 2011 17:36:18 +0000","from_user":"gesukapper","id_str":"41189757476286464","metadata":{"result_type":"recent"},"to_user_id":80935865,"text":"@tatsugorou \u306a\u3093\u304b\u4e16\u306e\u4e2d\u306b\u306f\u611a\u75f4\u3082\u4e0b\u30cd\u30bf\u3082\u8a00\u3044\u653e\u984c\u306etwitter\u3068\u3044\u3046\u3082\u306e\u304c\u3042\u308b\u305d\u3046\u3067\u3059\u3002","id":41189757476286464,"from_user_id":126390384,"to_user":"tatsugorou","geo":null,"iso_language_code":"ja","to_user_id_str":"80935865","source":"&lt;a href=&quot;http://janetter.net/&quot; rel=&quot;nofollow&quot;&gt;Janetter&lt;/a&gt;"},{"from_user_id_str":"196059029","profile_image_url":"http://a1.twimg.com/profile_images/1208831726/ruka2_normal.jpg","created_at":"Fri, 25 Feb 2011 17:36:17 +0000","from_user":"luka_m_bot","id_str":"41189756666777600","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u308f\u305f\u3057\u3082twitter\u306f\u3058\u3081\u307e\u3057\u305f","id":41189756666777600,"from_user_id":196059029,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www24.atpages.jp/aoi2/bot.php&quot; rel=&quot;nofollow&quot;&gt;\u5de1\u308b\u97f3&lt;/a&gt;"},{"from_user_id_str":"88135613","profile_image_url":"http://a3.twimg.com/profile_images/1088552877/P9280150_normal.JPG","created_at":"Fri, 25 Feb 2011 17:36:14 +0000","from_user":"Roko38","id_str":"41189740321587200","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\uff46\uff42\u306b\u30ed\u30b0\u30a4\u30f3\u3059\u308b\u6a5f\u4f1a\u304c\u65e5\u306b\u65e5\u306b\u5897\u3048\u3066\u304d\u305f\uff3e\uff3e \u6163\u308c\u3066\u304f\u308b\u3068\u3042\u3063\u3061\u306e\u304c\u9762\u767d\u3044\uff06\u4f7f\u3044\u52dd\u624b\u304c\u3044\u3044\u3088\u3046\u306a\u6c17\u304c\u3059\u308b\u3002\u8907\u5408\u7684\u306b\u8272\u3005\u51fa\u6765\u307e\u3059\u3088\u306d\u2026\u3063\u3066\u3001\u601d\u3063\u305f\u3053\u3068\u3092\u545f\u304f\u306e\u306fTwitter\u3060\u3063\u305f\u308a\u3067\u3059\u304c\u2026(^_^; \u305d\u3057\u3066\u81ea\u5206\u306e\u5834\u5408\u306f\u30c4\u30a4\u3068\u9023\u52d5\u3057\u3065\u3089\u3044\u72b6\u6cc1\u3060\u3063\u305f\u308a\u3067\u2026\u3002","id":41189740321587200,"from_user_id":88135613,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"110825211","profile_image_url":"http://a2.twimg.com/profile_images/1108977866/o_t_normal.jpg","created_at":"Fri, 25 Feb 2011 17:36:12 +0000","from_user":"kou_nanjyo","id_str":"41189731941363712","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @x68k: \u57fa\u672c\u7684\u306bTwitter\u4e0a\u3067\u306f&quot;\u597d\u304d\u306b\u3084\u308c\u3070\u3044\u3044&quot;\u3060\u3051\u3069\u3001\u540d\u524d\u3082\u30a2\u30a4\u30b3\u30f3\u3082\u30a2\u30f3\u30bf\u3058\u3083\u306a\u3044\u305f\u304f\u3055\u3093\u306e\u4eba\u305f\u3061\u306e\u9b42\u304c\u3053\u3082\u3063\u305f\u3082\u306e\u306a\u306e\u3060\u304b\u3089\u3001\u305d\u308c\u3060\u3051\u306f&quot;\u80cc\u8ca0\u3048&quot;\u3068\u601d\u3046\uff1e\u30ad\u30e3\u30e9\u30af\u30bf\u30fc\u30a2\u30ab\u30a6\u30f3\u30c8","id":41189731941363712,"from_user_id":110825211,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://tweetlogix.com&quot; rel=&quot;nofollow&quot;&gt;Tweetlogix&lt;/a&gt;"},{"from_user_id_str":"2095960","profile_image_url":"http://a2.twimg.com/profile_images/1248999075/majiresu2_normal.jpg","created_at":"Fri, 25 Feb 2011 17:36:10 +0000","from_user":"guldeen","id_str":"41189726945947648","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3042\u308a\u3083\u307e\u3041\u3002\u25bchttp://bit.ly/et4vVa \uff3b\u89d2\u5ddd\u66f8\u5e97\uff3d\u300c\u30b6\u30fb\u30b9\u30cb\u30fc\u30ab\u30fc\u300d\u4f11\u520a\u3078\u3000\u300c\u6dbc\u5bae\u30cf\u30eb\u30d2\u300d\u751f\u3093\u3060\u30e9\u30ce\u30d9\u96d1\u8a8c18\u5e74\u3067\u5e55 via http://twitter.com/lkj777","id":41189726945947648,"from_user_id":2095960,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"164121549","profile_image_url":"http://a1.twimg.com/profile_images/1251758789/m_108-07ae3_normal.jpg","created_at":"Fri, 25 Feb 2011 17:36:09 +0000","from_user":"hachi_touhi","id_str":"41189719299727360","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u30cd\u30bf\u30d0\u30ec\u6c17\u306b\u3057\u3066\u305f\u3089Twitter\u3084\u3063\u3066\u3089\u308c\u306a\u3044ww","id":41189719299727360,"from_user_id":164121549,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twicca.r246.jp/&quot; rel=&quot;nofollow&quot;&gt;twicca&lt;/a&gt;"},{"from_user_id_str":"194494659","profile_image_url":"http://a3.twimg.com/profile_images/1249717822/image_normal.jpg","created_at":"Fri, 25 Feb 2011 17:36:08 +0000","from_user":"tomonattomo","id_str":"41189715415801856","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3046\u308f\u3001\u660e\u65e5\u671d\u304b\u3089\u30d0\u30a4\u30c8\u3084\u306e\u306b\u306a\u3093\u3060\u3053\u306e\u306d\u3075\u304b\u3057\u3002\u3042\u3001\u591c\u66f4\u304b\u3057\u3002\u30d1\u30d4\u30eb\u30b9\u3068BUMP\u3001\u3048\u307f\u3068Twitter\u306eDM\u3057\u3059\u304e\u305f\u306a\u2026","id":41189715415801856,"from_user_id":194494659,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://mixi.jp/promotion.pl?id=voice_twitter&quot; rel=&quot;nofollow&quot;&gt; mixi \u30dc\u30a4\u30b9 &lt;/a&gt;"},{"from_user_id_str":"97224364","profile_image_url":"http://a3.twimg.com/profile_images/1150074355/fb8bcca60d340862c053a756377bfae8_normal.jpeg","created_at":"Fri, 25 Feb 2011 17:36:06 +0000","from_user":"xxxheat","id_str":"41189709174677504","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Twitter\u5b8c\u5168\u306b\u30d0\u30b0\u3063\u3066\u308borz","id":41189709174677504,"from_user_id":97224364,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"}],"max_id":41190705623732224,"since_id":38643906774044672,"refresh_url":"?since_id=41190705623732224&q=twitter","next_page":"?page=2&max_id=41190705623732224&rpp=100&lang=ja&q=twitter","results_per_page":100,"page":1,"completed_in":0.093336,"warning":"adjusted since_id to 38643906774044672 (), requested since_id was older than allowed -- since_id removed for pagination.","since_id_str":"38643906774044672","max_id_str":"41190705623732224","query":"twitter"}
benchmarks/json-data/jp50.jsondeleted−1
@@ -1 +0,0 @@
1−{"results":[{"from_user_id_str":"2458313","profile_image_url":"http://a2.twimg.com/profile_images/1203653060/fure091226_normal.png","created_at":"Thu, 27 Jan 2011 20:30:04 +0000","from_user":"19princess","id_str":"30724239224995840","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u6d77\u6674\u300c\u672c\u65e5\u306e\u6771\u4eac\u306e\u304a\u5929\u6c17\u306f\u6674\u6642\u3005\u66c7\u3067\u3057\u3087\u3046\u3002\u6700\u9ad8\u6c17\u6e29\u306f8\u5ea6\u3001\u6700\u4f4e\u6c17\u6e29\u306f1\u5ea6\u3067\u3059\u3002\u3042\u306a\u305f\u306e\u4eca\u65e5\u306e\u4eba\u751f\u306b\u3068\u3073\u3063\u304d\u308a\u306e\u304a\u5929\u6c17\u3092\u2665\u300d","id":30724239224995840,"from_user_id":2458313,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://babyprincess.sakura.ne.jp/about/&quot; rel=&quot;nofollow&quot;&gt;\u5929\u4f7f\u5bb6\u306e\u88cf\u5c71&lt;/a&gt;"},{"from_user_id_str":"66578965","profile_image_url":"http://a0.twimg.com/profile_images/1183763267/fossetta_normal.png","created_at":"Thu, 27 Jan 2011 20:00:04 +0000","from_user":"Fossetta_Tokyo","id_str":"30716689779785729","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u304a\u306f\u3088\u3046\u3054\u3056\u3044\u307e\u3059!!\u6771\u4eac\u90fd\u3001\u672c\u65e5\u306e\u304a\u5929\u6c17\u306f\u6674\u6642\u3005\u66c7\u3002\u6700\u9ad8\u6c17\u6e298\u5ea6\u3001\u6700\u4f4e\u6c17\u6e291\u5ea6\u3002\u6771\u4eac\u5730\u65b9\u3067\u306f\u3001\u7a7a\u6c17\u306e\u4e7e\u71e5\u3057\u305f\u72b6\u614b\u304c\u7d9a\u3044\u3066\u3044\u307e\u3059\u3002\u706b\u306e\u53d6\u308a\u6271\u3044\u306b\u6ce8\u610f\u3057\u3066\u4e0b\u3055\u3044\u3002\u4f0a\u8c46\u8af8\u5cf6\u3068\u5c0f\u7b20\u539f\u8af8\u5cf6\u306b\u306f\u3001\u5f37\u98a8\u3001\u6ce2\u6d6a\u3001\u4e7e\u71e5\u3001\u971c\u306e\u6ce8\u610f\u5831\u3092\u767a\u8868\u4e2d\u3067\u3059\u3002","id":30716689779785729,"from_user_id":66578965,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://bit.ly/Fossetta&quot; rel=&quot;nofollow&quot;&gt;\u30d5\u30a9\u30bb\u30c3\u30bf ver.3.1.1&lt;/a&gt;"},{"from_user_id_str":"104041146","profile_image_url":"http://a2.twimg.com/profile_images/863965118/001jwatokyo_normal.jpg","created_at":"Thu, 27 Jan 2011 19:44:33 +0000","from_user":"jwa_tokyo","id_str":"30712787537756160","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u6c17\u8c61\u5e81\u304b\u3089\u6771\u4eac\u306e\u5929\u6c17\u4e88\u5831\u304c\u767a\u8868\u3055\u308c\u307e\u3057\u305f\u3000\u305d\u306e\u5929\u6c17\u4e88\u5831\u3092\u3053\u3053\u3067\u3064\u3076\u3084\u3053\u3046\u304b\u306a\u3041\uff5e\uff1f\u3000\u8003\u3048\u4e2d\u3000\u307e\u3066\u6b21\u53f7\uff08\u7b11","id":30712787537756160,"from_user_id":104041146,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.docodemo.jp/twil/&quot; rel=&quot;nofollow&quot;&gt;Twil2 (Tweet Anytime, Anywhere by Mail)&lt;/a&gt;"},{"from_user_id_str":"144500192","profile_image_url":"http://a3.twimg.com/a/1294874399/images/default_profile_3_normal.png","created_at":"Thu, 27 Jan 2011 18:59:33 +0000","from_user":"kyo4to4","id_str":"30701462774358016","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u6771\u4eac\u90fd \u516b\u4e08\u5cf6 - \u4eca\u65e5\u306e\u5929\u6c17\u306f\u30fb\u30fb\u30fb\u66c7\u306e\u3061\u6674\u3067\u3059\u306e\uff01","id":30701462774358016,"from_user_id":144500192,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/kyo4to4&quot; rel=&quot;nofollow&quot;&gt;lost-sheep-bot&lt;/a&gt;"},{"from_user_id_str":"165724582","profile_image_url":"http://a0.twimg.com/profile_images/1222842347/163087_1256281064506_1753997852_484926_2761052_n_normal.jpg","created_at":"Thu, 27 Jan 2011 17:39:06 +0000","from_user":"Rifqi_19931020","id_str":"30681213748387840","metadata":{"result_type":"recent"},"to_user_id":113796067,"text":"@CHLionRagbaby \u30b1\u30f3\u3061\u3083\u3093\u3001\u671d\u4eca\u307e\u3067\u306e\u81ea\u5206\u306e\u30db\u30fc\u30e0\u30a8\u30ea\u30a2\u304b\u3089\u307e\u3060\u975e\u5e38\u306b\u5bd2\u3044\u3068\u96e8\u304c\u964d\u3063\u3066\u3044\u305f..\u3069\u306e\u3088\u3046\u306b\u73fe\u5728\u306e\u6771\u4eac\u306e\u5929\u6c17\uff1f","id":30681213748387840,"from_user_id":165724582,"to_user":"CHLionRagbaby","geo":null,"iso_language_code":"ja","to_user_id_str":"113796067","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"120911929","profile_image_url":"http://a0.twimg.com/profile_images/772435076/20100312___capture2_normal.png","created_at":"Thu, 27 Jan 2011 17:28:30 +0000","from_user":"Cirno_fan","id_str":"30678546020040705","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u4eca\u65e5\u306e\u6771\u4eac\u306e\u5929\u6c17\u306f\u3001\u66c7\u6642\u3005\u6674\u3067\u6700\u9ad8\u6c17\u6e29\u306f8\u2103\uff01 \u6700\u4f4e\u6c17\u6e29\u306f2\u2103\u3060\u3063\u305f\u3088\uff01 RT @mimi22999 \uff08\uff65\u2200\uff65\uff09\uff4c\u3001\u865a\u5f31\u306a\u8005\u306b\u3068\u3063\u3066\u3001\u6717\u3089\u304b\u306a\u9854\u306f\u4e0a\u5929\u6c17\u3068\u540c\u3058\u304f\u3089\u3044\u3046\u308c\u3057\u3044\u3082\u306e\u3060\u3002\u30d5\u30e9\u30f3\u30af\u30ea\u30f3 #tenki #bot","id":30678546020040705,"from_user_id":120911929,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://blog.livedoor.jp/fairycirno/archives/34686.html&quot; rel=&quot;nofollow&quot;&gt;\u5e7b\u60f3\u90f7 \u9727\u306e\u6e56&lt;/a&gt;"},{"from_user_id_str":"65976527","profile_image_url":"http://a0.twimg.com/profile_images/452810990/little_italies_____normal.jpg","created_at":"Thu, 27 Jan 2011 17:00:03 +0000","from_user":"heta_weather01","id_str":"30671388754845696","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3010\u30d8\u30bf\u5929\u3011Tere hommikust.\u30a8\u30b9\u30c8\u30cb\u30a2\u3067\u3059\u3002\u4eca\u65e5\u306e\u6771\u4eac\u306e\u5929\u6c17\u306f\u6674\u6642\u3005\u66c7\u3067\u660e\u65e5\u306f\u66c7\u308a\u3067\u3059\u3002\u3061\u306a\u307f\u306b\u50d5\u306e\u3068\u3053\u308d\u3067\u306f\u66c7\u308a\u3067\u6c17\u6e29-7\u2103\u3067\u3059\u3002\u3061\u306a\u307f\u306b\u30b9\u30ab\u30a4\u30d7\u306e\u958b\u767a\u672c\u90e8\u306f\u50d5\u306e\u5bb6\u306b\u3042\u308b\u3093\u3067\u3059\u3002","id":30671388754845696,"from_user_id":65976527,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www15.atpages.jp/~kageyanma/&quot; rel=&quot;nofollow&quot;&gt;\u5730\u7403\u306e\u4e2d&lt;/a&gt;"},{"from_user_id_str":"7278433","profile_image_url":"http://a3.twimg.com/profile_images/1218965303/michael-1_normal.png","created_at":"Thu, 27 Jan 2011 16:50:16 +0000","from_user":"shimohiko","id_str":"30668926035689472","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3042\u308a\u3002\n\u3010\u7f8e\u4eba\u5929\u6c17/\u6771\u4eac\u3011\u7f8e\u4eba\u5929\u6c17\u30ad\u30e3\u30b9\u30bf\u30fc\u306e&quot;\u3055\u3042\u3084\u3093\u3055\u3093&quot;\u306b\u3088\u308b\u3068\u300c1/29(\u571f)\u306f\u304f\u3082\u308a\u3067\u3001\u964d\u6c34\u78ba\u738740%\u3001\u6700\u9ad8\u6c17\u6e29\u306f6\u2103\u3067\u6700\u4f4e\u6c17\u6e29\u306f1\u2103\u3067\u3059\u300d\u7f8e\u4eba\u5929\u6c17\u21d2http://bit.ly/djB8th http://twitpic.com/3twnl0 #bt_tenki","id":30668926035689472,"from_user_id":7278433,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://bijintenki.jp&quot; rel=&quot;nofollow&quot;&gt;bijintenki.jp&lt;/a&gt;"},{"from_user_id_str":"61770","profile_image_url":"http://a3.twimg.com/profile_images/1206955079/tw172a_normal.png","created_at":"Thu, 27 Jan 2011 16:40:52 +0000","from_user":"rsky","id_str":"30666561853333504","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3075\u3068\u591c\u7a7a\u3092\u898b\u4e0a\u3052\u3066\u30aa\u30ea\u30aa\u30f3\u304c\u898b\u3048\u306a\u304f\u3066\u300c\u6771\u4eac\u306b\u306f\u7a7a\u304c\u306a\u3044\u300d\u3068\u667a\u6075\u5b50\u306e\u3088\u3046\u306a\u3053\u3068\u3092\u601d\u3063\u305f\u308f\u3051\u3060\u304c\u3001\u305f\u3076\u3093\u534a\u5206\u3050\u3089\u3044\u306f\u5929\u6c17\u306e\u305b\u3044\u3067\u3059","id":30666561853333504,"from_user_id":61770,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.hootsuite.com&quot; rel=&quot;nofollow&quot;&gt;HootSuite&lt;/a&gt;"},{"from_user_id_str":"103259265","profile_image_url":"http://a0.twimg.com/profile_images/767857973/anime_icon_normal.gif","created_at":"Thu, 27 Jan 2011 16:37:42 +0000","from_user":"liveshowonly","id_str":"30665765698928640","metadata":{"result_type":"recent"},"to_user_id":null,"text":"iPhone\u5929\u6c17\u3002\u6771\u4eac4\u2103\u3063\u3066\u7d50\u69cb\u5bd2\u304f\u306a\u3044\u3058\u3083\u3093\u3002\uff08\u78ba\u304b\u306b\u3082\u306e\u51c4\u304f\u5bd2\u3044\u8a33\u3067\u306f\u7121\u3044\uff09\u3002\u798f\u5ca1\u5e02\u306f1\u2103\u3060\u3002\u52dd\u3061\u3060\u305c\u3002Rock'n'roll","id":30665765698928640,"from_user_id":103259265,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"165242761","profile_image_url":"http://a1.twimg.com/profile_images/1147334744/SN3E00600001_normal.jpg","created_at":"Thu, 27 Jan 2011 16:37:35 +0000","from_user":"deuxavril0502","id_str":"30665736556912640","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u6b8b\u5ff5\u3001\u79c1\u306f\u6c96\u7e04\u3067\u3059(&gt;_&lt;)\u3067\u3082\u304a\u5929\u6c17\u826f\u3055\u305d\u3046\u3067\u826f\u304b\u3063\u305f\u306d\u3002\u3053\u3061\u3089\u306f\u96e8\u3088\uff5eRT @rinandy2010: \u305d\u3046\u3067\u3059\u3063\u266a\u51fa\u5f35\u3067(^^)\u304a\u306d\u3048\u3055\u307e\u306f\u6771\u4eac\u3067\u3059\u304b\uff1f\u3081\u3063\u3061\u3083\u5929\u6c17\u826f\u304f\u3066\u3073\u3063\u304f\u308a\u3067\u3059\u3002\u624b\u888b\u3068\u304b\u5168\u7136\u3044\u3089\u306a\u3044\u3067\u3059\u306d\u30fc RT @deuxavril0502 \u6771\u4eac\u306a\u306e\u30fc\uff1f","id":30665736556912640,"from_user_id":165242761,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.echofon.com/&quot; rel=&quot;nofollow&quot;&gt;Echofon&lt;/a&gt;"},{"from_user_id_str":"163900288","profile_image_url":"http://a1.twimg.com/profile_images/1210224823/icon12945064955238_normal.jpg","created_at":"Thu, 27 Jan 2011 16:24:37 +0000","from_user":"nyao_yurichan","id_str":"30662472734089216","metadata":{"result_type":"recent"},"to_user_id":100985873,"text":"@ray_ko302 \u767a\u898b\u3042\u308a\u304c\u3068\u3067\u3059\u3045\u3002\u3053\u3061\u3089\u3067\u3082\u3088\u308d\u3057\u304f\u306d\u3002\u6771\u4eac\u306f\u4eca\u65e5\u3082\u4e7e\u71e5\u3067\u5927\u5909\u3088\u3002\u305d\u3063\u3061\u3068\u771f\u9006\u306e\u5929\u6c17\u3060\u306d\u3002\u30a2\u30a4\u30b9\u30d0\u30fc\u30f3\u304d\u3092\u3064\u3051\u3066\u3088\u306d\u3002","id":30662472734089216,"from_user_id":163900288,"to_user":"ray_ko302","geo":null,"iso_language_code":"ja","to_user_id_str":"100985873","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"49227098","profile_image_url":"http://a3.twimg.com/profile_images/965007882/____normal.jpg","created_at":"Thu, 27 Jan 2011 15:52:26 +0000","from_user":"dosannko6","id_str":"30654371016478720","metadata":{"result_type":"recent"},"to_user_id":108570870,"text":"@peke_hajiP \u4ffa\u304c\u6771\u4eac \u6765\u3066\u6700\u521d\u306b\u9a5a\u3044\u305f\u306e\u304c\u3001\u5929\u6c17\u4e88\u5831\u3067\u82b1\u7c89\u60c5\u5831\u304c\u6d41\u308c\u308b\u3053\u3068\u3067\u3001\u6700\u521d\u306b\u8a66\u3057\u305f\u306e\u304c \u30b4\u30ad\u69d8 \u53ec\u559a\u306e\u5100\u5f0f\u3067\u3059\u304a\uff1f","id":30654371016478720,"from_user_id":49227098,"to_user":"peke_hajip","geo":null,"iso_language_code":"ja","to_user_id_str":"108570870","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"71148934","profile_image_url":"http://a0.twimg.com/profile_images/1209223630/image_normal.jpg","created_at":"Thu, 27 Jan 2011 15:46:49 +0000","from_user":"123keiko","id_str":"30652958311981058","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u9727\u5cf6\u306e\u964d\u7070\u306e\u30cb\u30e5\u30fc\u30b9\u3092\u898b\u3066\u601d\u3044\u51fa\u3057\u307e\u3057\u305f\u3002\u4e0a\u4eac\u3057\u305f\u59cb\u3081\u306e\u9803\u3001\u6771\u4eac\u306f1\u5e74\u4e2d\u3001\u7070\u304c\u964d\u3089\u306a\u3044\u304b\u3089\u7a7a\u6c17\u304c\u6f84\u3093\u3067\u3066\u904e\u3054\u3057\u3084\u3059\u3044\u306a\u3041\u3001\u3068\u601d\u3063\u305f\u306a\u3041\u3001\u3063\u3066\u3002\n\u5b9f\u5bb6\u306f\u51ac\u306e\u5b63\u7bc0\u98a8\u3067\u685c\u5cf6\u306e\u7070\u304c\u964d\u308b\u5730\u533a\u3067\u3057\u305f\u3002\u9e7f\u5150\u5cf6\u306e\u5929\u6c17\u4e88\u5831\u3067\u306f\u3001\u6bce\u65e5\u3001\u685c\u5cf6\u4e0a\u7a7a\u306e\u98a8\u5411\u304d\u4e88\u5831\u304c\u3067\u307e\u3059\u3002\u3053\u308c\u304b\u3089\u306f\u9727\u5cf6\u3082\u304b\u306a\uff1f","id":30652958311981058,"from_user_id":71148934,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"91124773","profile_image_url":"http://a3.twimg.com/profile_images/1139308356/prof101007_3-1_normal.jpg","created_at":"Thu, 27 Jan 2011 15:43:35 +0000","from_user":"sanposuruhito","id_str":"30652146277945345","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u4eca\u5bb5\u306e\u90fd\u5fc3\u306f\u3001\u8eab\u3082\u5f15\u304d\u7de0\u307e\u308b\u3068\u3044\u3046\u3088\u308a\u306f\u51cd\u3048\u308b\u7a0b\u306e\u51b7\u6c17\u3092\u611f\u3058\u308b\u5bd2\u3044\u591c\u3067\u3059\u3002\u660e\u65e5\u65e5\u4e2d\u306e\u6771\u4eac\u306e\u5929\u6c17\u306f\u3001\u5915\u65b9\u306b\u591a\u5c11\u96f2\u304c\u51fa\u308b\u5834\u6240\u304c\u3042\u308a\u305d\u3046\u306a\u3082\u306e\u306e\u6982\u306d\u6674\u308c\u7a7a\u304c\u5e83\u304c\u308a\u7d9a\u3051\u305d\u3046\u3067\u3059\u3002\u6700\u9ad8\u6c17\u6e29\u306f\u30015-6\u5ea6\u4f4d\u3068\u306a\u308a\u305d\u3046\u3067\u3059\u3002#weather_tokyo","id":30652146277945345,"from_user_id":91124773,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://projects.playwell.jp/go/Saezuri&quot; rel=&quot;nofollow&quot;&gt;Saezuri&lt;/a&gt;"},{"from_user_id_str":"104712480","profile_image_url":"http://a3.twimg.com/profile_images/1204016928/icon5087697006727791368kuro2_normal.jpg","created_at":"Thu, 27 Jan 2011 15:31:51 +0000","from_user":"asongfor_xx","id_str":"30649192296751104","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u7f8e\u4eba\u5929\u6c17\u304b\u3089tweet\u3059\u308b\u3068\u3053\u3093\u306a\u611f\u3058\u306a\u3093\u3060\u306a\u3002 RT asongfor_xx: \u3010\u7f8e\u4eba\u5929\u6c17/\u6771\u4eac\u3011\u7f8e\u4eba\u5929\u6c17\u30ad\u30e3\u30b9\u30bf\u30fc\u306e&quot;\u304b\u306a\u3053\u3055\u3093&quot;\u306b\u3088\u308b\u3068\u300c1/28(\u91d1)\u306f\u6674\u6642\u3005\u304f\u3082\u308a\u3067\u3001\u964d\u6c34\u78ba\u73870%\u3001\u6700\u9ad8\u6c17\u6e29\u306f8\u2103\u3067\u6700\u4f4e\u6c17\u6e29\u306f1\u2103\u3067\u3059\u300d\u7f8e\u4eba\u5929\u6c17\u21d2http://bit.ly/djB8th","id":30649192296751104,"from_user_id":104712480,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twipple.jp/&quot; rel=&quot;nofollow&quot;&gt;\u3064\u3044\u3063\u3077\u308b for iPhone&lt;/a&gt;"},{"from_user_id_str":"165965113","profile_image_url":"http://a0.twimg.com/profile_images/1200885316/shogomeguro_normal.jpg","created_at":"Thu, 27 Jan 2011 15:24:35 +0000","from_user":"shogomeguro","id_str":"30647362477105152","metadata":{"result_type":"recent"},"to_user_id":null,"text":"2011.1.26 \u793e\u7a93\u304b\u3089\u3002\u4e0d\u601d\u8b70\u306a\u5929\u6c17\u3067\u3053\u306e\u5f8c\u96ea\u304c\u3061\u3089\u3064\u3044\u305f\u3093\u3060\u3088\u306d\u3002\u6771\u4eac\u306e\u521d\u96ea\u3067\u3057\u305f\u3002 http://instagr.am/p/BO_xn/","id":30647362477105152,"from_user_id":165965113,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://instagr.am&quot; rel=&quot;nofollow&quot;&gt;instagram&lt;/a&gt;"},{"from_user_id_str":"166018520","profile_image_url":"http://a0.twimg.com/profile_images/1207460953/100-40030_normal.jpg","created_at":"Thu, 27 Jan 2011 15:18:17 +0000","from_user":"115nayume","id_str":"30645776254238722","metadata":{"result_type":"recent"},"to_user_id":118384679,"text":"@dancinpea09 \u6771\u4eac\u3001\u660e\u65e5\u3082\u5929\u6c17\u826f\u3044\u307f\u305f\u3044\u3067\u3001\u3088\u304b\u3063\u305f\u3067\u3059\u306d\u30fc\u266a \u30ca\u30a4\u30b9\u30c8\u30ea\u30c3\u30d7\uff01\u304a\u3084\u3059\u307f\u306a\u3055\u3044\u3002 http://twitpic.com/3tvun3","id":30645776254238722,"from_user_id":166018520,"to_user":"dancinpea09","geo":null,"iso_language_code":"ja","to_user_id_str":"118384679","source":"&lt;a href=&quot;http://tweetli.st/&quot; rel=&quot;nofollow&quot;&gt;TweetList!&lt;/a&gt;"},{"from_user_id_str":"202937674","profile_image_url":"http://a1.twimg.com/profile_images/1218797578/______2_normal.jpg","created_at":"Thu, 27 Jan 2011 15:11:48 +0000","from_user":"ryuusisan","id_str":"30644146498699264","metadata":{"result_type":"recent"},"to_user_id":203058384,"text":"@manaasutakshi \u6771\u4eac\u306f\u964d\u3063\u3066\u306a\u3044\u3093\u3067\u3059\u304b\u30fb\u30fb\u30fb\u5929\u6c17\u4e88\u5831\u306b\u3088\u308b\u3068\u660e\u65e5\u3082\u6771\u4eac\u306f\u964d\u3089\u306a\u3044\u305d\u3046\u3067\u3059\u306d\uff01\uff01\u79c1\u306e\u4f4f\u3093\u3067\u3044\u308b\u3068\u3053\u308d\u306f\u5fae\u5999\u306b\u964d\u308a\u305d\u3046\u3067\u51fa\u52e4\u6642\u306b\u964d\u3063\u3066\u305f\u3089\u3061\u3087\u3063\u3068\u5acc\u3060\u306a\u3041\u3000\u306a\u3093\u3066\u601d\u3044\u307e\u3059","id":30644146498699264,"from_user_id":202937674,"to_user":"manaasutakshi","geo":null,"iso_language_code":"ja","to_user_id_str":"203058384","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"3222182","profile_image_url":"http://a0.twimg.com/profile_images/1199090957/ProfilePhoto_normal.png","created_at":"Thu, 27 Jan 2011 15:09:35 +0000","from_user":"44mune","id_str":"30643589545459713","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3010\u7f8e\u4eba\u5929\u6c17/\u6771\u4eac\u3011\u7f8e\u4eba\u5929\u6c17\u30ad\u30e3\u30b9\u30bf\u30fc\u306e&quot;\u306e\u308a\u3055\u3093&quot;\u306b\u3088\u308b\u3068\u300c1/28(\u91d1)\u306f\u304f\u3082\u308a\u306e\u3061\u6674\u3067\u3001\u964d\u6c34\u78ba\u738710%\u3001\u6700\u9ad8\u6c17\u6e29\u306f9\u2103\u3067\u6700\u4f4e\u6c17\u6e29\u306f2\u2103\u3067\u3059\u300d http://twitpic.com/3tvruh","id":30643589545459713,"from_user_id":3222182,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://bijintenki.jp&quot; rel=&quot;nofollow&quot;&gt;bijintenki.jp&lt;/a&gt;"},{"from_user_id_str":"154341982","profile_image_url":"http://a0.twimg.com/profile_images/1155496864/_____normal.jpg","created_at":"Thu, 27 Jan 2011 15:02:39 +0000","from_user":"slave_420_bot","id_str":"30641845490946049","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u4eca\u30f3\u3068\u3053\u899a\u3048\u3066\u308b\u306e\u306f\u300c\u672d\u5e4c\u300d\u300c\u4ed9\u53f0\u300d\u300c\u6771\u4eac\u300d\u300c\u5927\u962a\u300d\u300c\u540d\u53e4\u5c4b\u300d\u300c\u798f\u5ca1\u300d\u306e\u4eca\u65e5\u3068\u660e\u65e5\u306e\u5929\u6c17\u3060\u306a\u3002\u5929\u6c17\u304c\u77e5\u308a\u305f\u3044\u6642\u306f\u300c\u5834\u6240\u300d\u3068\u300c\u4eca\u65e5\u306e\u5929\u6c17\u300d\u304b\u300c\u660e\u65e5\u306e\u5929\u6c17\u300d\u3092\u304a\u7533\u3057\u4ed8\u3051\u304f\u3060\u3055\u3044\u3001\u304a\u5b22\u69d8\uff1f","id":30641845490946049,"from_user_id":154341982,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://bot.syoyu.net/&quot; rel=&quot;nofollow&quot;&gt;\u7adc\u30f6\u5cf0\u90b8\u306e\u3069\u3053\u304b&lt;/a&gt;"},{"from_user_id_str":"72042678","profile_image_url":"http://a3.twimg.com/profile_images/1198771027/larxene_normal.jpg","created_at":"Thu, 27 Jan 2011 15:01:57 +0000","from_user":"larxene_bot","id_str":"30641668772339712","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u4eca\u65e5\u306e\u5929\u6c17\u306f \u672d\u5e4c\u304c\u6674\u308c \u4ed9\u53f0\u304c\u66c7\u6642\u3005\u96ea \u6771\u4eac\u304c\u6674\u306e\u3061\u66c7 \u540d\u53e4\u5c4b\u304c\u6674\u6642\u3005\u66c7 \u5927\u962a\u304c\u6674\u6642\u3005\u66c7 \u798f\u5ca1\u304c\u6674\u308c \u3089\u3057\u3044\u308f\u3088 \u6ce8\u610f\u3057\u306a\u3055\u3044","id":30641668772339712,"from_user_id":72042678,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www4.kiwi-us.com/~yuuna/larxene_bot_manual/index.html&quot; rel=&quot;nofollow&quot;&gt;\u5fd8\u5374\u306e\u57ce \u5730\u4e0a\u306e12\u968e&lt;/a&gt;"},{"from_user_id_str":"101331893","profile_image_url":"http://a1.twimg.com/sticky/default_profile_images/default_profile_0_normal.png","created_at":"Thu, 27 Jan 2011 15:01:34 +0000","from_user":"yoshiftan","id_str":"30641572240424961","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u6771\u4eac\u306e\u5929\u6c17\u4e88\u5831\u3092\u898b\u3066\u3073\u3063\u304f\u308a\uff01\u6691\u305d\u3046\u3060\u306a\u3053\u308a\u3083\u3002","id":30641572240424961,"from_user_id":101331893,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"Keitai Mail"},{"from_user_id_str":"65207550","profile_image_url":"http://a3.twimg.com/profile_images/448731969/_________R_normal.jpg","created_at":"Thu, 27 Jan 2011 15:01:33 +0000","from_user":"kabuyo","id_str":"30641566469066752","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u5929\u6c17\u4e88\u5831\u3067\u306f\u6771\u4eac\u3067\u306f\u4e7e\u71e5\u6ce8\u610f\u5831\u304c\u7d9a\u3044\u3066\u3044\u308b\u3089\u3057\u3044\u306e\u306b\u3001\u306a\u305c\u79c1\u304c\u5e72\u3057\u305f\u6d17\u6fef\u7269\u306f\u96e8\u306b\u6fe1\u308c\u3066\u3057\u307e\u3063\u305f\u306e\u3060\u308d\u3046\u304b\u2025\u3000\u3088\u3063\u307d\u3069\u904b\u304c\u60aa\u3044\u3089\u3057\u3044\u2025","id":30641566469066752,"from_user_id":65207550,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"80309352","profile_image_url":"http://a1.twimg.com/profile_images/1223620418/image_normal.jpg","created_at":"Thu, 27 Jan 2011 14:54:30 +0000","from_user":"mikutyan","id_str":"30639792026812416","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u6771\u4eac\u306e\u660e\u65e5\u306e\u5929\u6c17\u6559\u3048\u3066","id":30639792026812416,"from_user_id":80309352,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"80309352","profile_image_url":"http://a1.twimg.com/profile_images/1223620418/image_normal.jpg","created_at":"Thu, 27 Jan 2011 14:53:06 +0000","from_user":"mikutyan","id_str":"30639439847890944","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u660e\u65e5\u306e\u6771\u4eac\u306e\u5929\u6c17\u306a\u3093\u3060\u308d\u3046 \u96e8\u964d\u3063\u305f\u3089\u56f0\u308b\u3002","id":30639439847890944,"from_user_id":80309352,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"120911929","profile_image_url":"http://a0.twimg.com/profile_images/772435076/20100312___capture2_normal.png","created_at":"Thu, 27 Jan 2011 14:47:19 +0000","from_user":"Cirno_fan","id_str":"30637984684449792","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3042\u305f\u3044\u30c1\u30eb\u30ce\uff01\u30dc\u30c3\u30c8\u3060\u3051\u3069\u5929\u6c17\u4e88\u5831\u3082\u3067\u304d\u308b\u3088\uff01\u300c\u6771\u4eac\u306e\u4eca\u65e5\u306e\u5929\u6c17\u6559\u3048\u3066\u300d\u307f\u305f\u3044\u306bTL\u767a\u8a00\u3057\u3066\u304f\u308c\u308c\u3070\u8abf\u3079\u3066\u3042\u3052\u308b\uff01 #followme #followmejp #followmevip #tenki","id":30637984684449792,"from_user_id":120911929,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://blog.livedoor.jp/fairycirno/archives/34686.html&quot; rel=&quot;nofollow&quot;&gt;\u5e7b\u60f3\u90f7 \u9727\u306e\u6e56&lt;/a&gt;"},{"from_user_id_str":"33858777","profile_image_url":"http://a0.twimg.com/profile_images/352864695/muga_normal.jpg","created_at":"Thu, 27 Jan 2011 14:46:12 +0000","from_user":"collonist","id_str":"30637702105796610","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u6771\u4eac\u3063\u3066\u51ac\u306f\u57fa\u672c\u7684\u306b\u6674\u308c\u3066\u308b\u304b\u3089\u3001\u5929\u6c17\u4e88\u5831\u898b\u306a\u304f\u3066\u3082\u5168\u7136\u554f\u984c\u306a\u3044\u3002\u5c71\u5f62\u3060\u3068\u660e\u65e5\u306f\u3069\u3093\u3060\u3051\u96ea\u304c\u964d\u308b\u306e\u304b\u3001\u3069\u3093\u3060\u3051\u5bd2\u3044\u306e\u304b\u628a\u63e1\u3057\u3066\u3068\u304d\u305f\u3044\u306e\u3067\u3001\u5929\u6c17\u4e88\u5831\u306f\u5fc5\u305a\u30c1\u30a7\u30c3\u30af\u3057\u3066\u305f\u306e\u3060\u304c\u3002","id":30637702105796610,"from_user_id":33858777,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.hootsuite.com&quot; rel=&quot;nofollow&quot;&gt;HootSuite&lt;/a&gt;"},{"from_user_id_str":"79336228","profile_image_url":"http://a0.twimg.com/profile_images/1130029876/zmanmu_normal.png","created_at":"Thu, 27 Jan 2011 14:30:23 +0000","from_user":"atsuki777","id_str":"30633725041573890","metadata":{"result_type":"recent"},"to_user_id":null,"text":"MXTV\u306e\u5929\u6c17\u4e88\u5831\u521d\u3081\u3066\u898b\u305f\u3051\u3069\u6771\u4eac\u753a\u7530\u516b\u738b\u5b50\u3063\u3066\u5730\u57df\u8868\u793a\u304c\u2026w\u516b\u738b\u5b50\u3068\u753a\u7530\u306f\u6771\u4eac\u3058\u3083\u306a\u3044\u306e\u304bwww","id":30633725041573890,"from_user_id":79336228,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.echofon.com/&quot; rel=&quot;nofollow&quot;&gt;Echofon&lt;/a&gt;"},{"from_user_id_str":"90576097","profile_image_url":"http://a0.twimg.com/profile_images/1203320254/nanami1_normal.png","created_at":"Thu, 27 Jan 2011 14:28:26 +0000","from_user":"dycroft","id_str":"30633234245099521","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u6771\u4eac\u306e\u660e\u65e5\u306e\u304a\u5929\u6c17\u3067\u3059","id":30633234245099521,"from_user_id":90576097,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://sourceforge.jp/projects/tween/wiki/FrontPage&quot; rel=&quot;nofollow&quot;&gt;Tween&lt;/a&gt;"},{"from_user_id_str":"147215268","profile_image_url":"http://a2.twimg.com/profile_images/1198555202/ichika-7.4.0-3P_normal.gif","created_at":"Thu, 27 Jan 2011 14:28:23 +0000","from_user":"kiaran5032","id_str":"30633222211637248","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u6771\u4eac\u306e\u660e\u65e5\u306e\u304a\u5929\u6c17\u3067\u3059\u3002\u6674\u308c\u6642\u3005\u304f\u3082\u308a #MX","id":30633222211637248,"from_user_id":147215268,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://sourceforge.jp/projects/tween/wiki/FrontPage&quot; rel=&quot;nofollow&quot;&gt;Tween&lt;/a&gt;"},{"from_user_id_str":"1741599","profile_image_url":"http://a0.twimg.com/profile_images/1205744888/950637_normal.jpg","created_at":"Thu, 27 Jan 2011 14:28:21 +0000","from_user":"dasaitama","id_str":"30633212535382016","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u6771\u4eac\u306e\u3001\u660e\u65e5\u306e\u304a\u5929\u6c17\u3067\u3059","id":30633212535382016,"from_user_id":1741599,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://sourceforge.jp/projects/tween/wiki/FrontPage&quot; rel=&quot;nofollow&quot;&gt;Tween&lt;/a&gt;"},{"from_user_id_str":"34140879","profile_image_url":"http://a3.twimg.com/profile_images/1186413535/__6_normal.jpg","created_at":"Thu, 27 Jan 2011 14:28:17 +0000","from_user":"ryuji_chaos","id_str":"30633197016449024","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u6771\u4eac\u306e\u660e\u65e5\u306e\u304a\u5929\u6c17\u3067\u3059\u3002","id":30633197016449024,"from_user_id":34140879,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"1400","profile_image_url":"http://a0.twimg.com/profile_images/1198556839/westerndog_20090104_320x320_normal.jpg","created_at":"Thu, 27 Jan 2011 14:28:16 +0000","from_user":"westerndog","id_str":"30633191232503808","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u6771\u4eac\u306e\u660e\u65e5\u306e\u304a\u5929\u6c17\u3067\u3059","id":30633191232503808,"from_user_id":1400,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://sourceforge.jp/projects/tween/wiki/FrontPage&quot; rel=&quot;nofollow&quot;&gt;Tween&lt;/a&gt;"},{"from_user_id_str":"89239832","profile_image_url":"http://a3.twimg.com/profile_images/519522846/noriko_normal.jpg","created_at":"Thu, 27 Jan 2011 14:15:01 +0000","from_user":"Noriko_Fujimoto","id_str":"30629857234788352","metadata":{"result_type":"recent"},"to_user_id":115645219,"text":"@nossa430402 \u5bcc\u5c71\u306f\u3059\u3054\u3044\u96ea\u307f\u305f\u3044\u3067\u3059\u306d\uff5e\uff08\u5bd2\u3063\uff09\u3000\u6771\u4eac\u306f\u305d\u306e\u5206\u6bce\u65e5\u826f\u3044\u5929\u6c17\u3067\u3059\u3002\u5bd2\u3044\u3051\u3069\u30fb\u30fb\u30fb\u3002","id":30629857234788352,"from_user_id":89239832,"to_user":"nossa430402","geo":null,"iso_language_code":"ja","to_user_id_str":"115645219","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"107265539","profile_image_url":"http://a0.twimg.com/sticky/default_profile_images/default_profile_3_normal.png","created_at":"Thu, 27 Jan 2011 14:01:10 +0000","from_user":"kurumasuki330","id_str":"30626371826884608","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u4eca\u9031\u571f\u66dc\u65e5\u3001\u8eca\u3067\u6771\u4eac\u304b\u3089\u6771\u540d\u3001\u7c73\u539f\u7d4c\u7531\u3067\u91d1\u6ca2\u306e\u5b9f\u5bb6\u3078\u3002\u305d\u3057\u3066\u3001\u6708\u66dc\u65e5\u306b\u6771\u4eac\u3078\u5e30\u308b\u30b9\u30b1\u30b8\u30e5\u30fc\u30eb\u3002\u5929\u6c17\u4e88\u5831\u3060\u3068\u4eca\u9031\u672b\u3001\u5317\u9678\u5730\u65b9\u306f\u5927\u96ea\uff01\u5e30\u308c\u308b\u304b\u81ea\u4fe1\u304c\u306a\u304f\u306a\u3063\u3066\u304d\u305f\u3002\u307e\u305f\u3001\u305d\u306e\u6642\u5b9f\u6cc1\u4e2d\u7d99\u3057\u307e\u3059\u3002","id":30626371826884608,"from_user_id":107265539,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twtr.jp&quot; rel=&quot;nofollow&quot;&gt;Keitai Web&lt;/a&gt;"},{"from_user_id_str":"155313166","profile_image_url":"http://a3.twimg.com/profile_images/1167554721/73931_1408370184003_1674923704_920888_5686998_n_normal.jpg","created_at":"Thu, 27 Jan 2011 14:00:50 +0000","from_user":"takuya_aoki","id_str":"30626287127105536","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u6771\u4eac\u306f\u3081\u3063\u3061\u3083\u3044\u3044\u5929\u6c17\u3067\u904e\u3054\u3057\u3084\u3059\u3044\u3051\u3069\u30c9\u30e9\u30a4\u30a2\u30a4\u306b\u306f\u3061\u3087\u3063\u3068\u304d\u3064\u3044\u306a\u30fb\u30fb\u30fb\u76ee\u85ac\u304c\u624b\u653e\u305b\u306a\u3044","id":30626287127105536,"from_user_id":155313166,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"179984398","profile_image_url":"http://a1.twimg.com/profile_images/1182382310/g4350_normal.jpg","created_at":"Thu, 27 Jan 2011 13:52:50 +0000","from_user":"aiilabo","id_str":"30624271902449664","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u30d6\u30ed\u30b0\u66f4\u65b0 \u25c6\u611f\u60c5\u3092\u307f\u3064\u3081\u308b\u65b9\u6cd5 - \u3053\u3053\u6570\u65e5\u3001\u6642\u6298\u96e8\u304c\u30d1\u30e9\u30d1\u30e9\u3000\u5fae\u5999\u306a\u5929\u6c17\u306e\u6771\u4eac\u304b\u3089\u3042\u308b\u304c\u307e\u307e\u3067\u3059\u3002 \n\n \u4eca\u65e5\u306f\u3001\u6628\u65e5\u306e\u300c\u30de\u30a4\u30ca\u30b9\u611f\u60c5\u306f\u60aa\u3067\u3059\u304b\uff1f\n.. \u27aa http://am6.jp/e3e9tS","id":30624271902449664,"from_user_id":179984398,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://feedtweet.am6.jp/&quot; rel=&quot;nofollow&quot;&gt;\u261e feedtweet.jp \u261c&lt;/a&gt;"},{"from_user_id_str":"185992391","profile_image_url":"http://a2.twimg.com/profile_images/1192695844/otenki_normal.png","created_at":"Thu, 27 Jan 2011 13:00:37 +0000","from_user":"otenki_luci_bot","id_str":"30611130938298368","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u767a\u58f2\u65e5\u304b\u2026\u2026\u541b\u305f\u3061\u306b\u3068\u3063\u3066\u306f\u591a\u5206\u300190\u65e5\u5f8c\u306e\u3053\u3068\u3060\u3002\u3055\u3066\u660e\u65e5\u306e\u6771\u4eac\u90fd\u306e\u5929\u6c17\u306f\u6674\u306e\u3061\u66c7\u3001\u6700\u9ad8\u6c17\u6e29\u306f8\u5ea6\u3060\u305d\u3046\u3060\u3002\u3055\u3059\u304c\u306b\u4f55\u304b\u7740\u305f\u65b9\u304c\u3044\u3044\u305e\u3001\u30a4\u30fc\u30ce\u30c3\u30af\u3002","id":30611130938298368,"from_user_id":185992391,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/otenki_luci_bot&quot; rel=&quot;nofollow&quot;&gt;\u304a\u3066\u3093\u304d\u308b\u3057\u3075\u3047\u308b&lt;/a&gt;"},{"from_user_id_str":"65976527","profile_image_url":"http://a0.twimg.com/profile_images/452810990/little_italies_____normal.jpg","created_at":"Thu, 27 Jan 2011 13:00:04 +0000","from_user":"heta_weather01","id_str":"30610995843964928","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3010\u30d8\u30bf\u5929\u3011Jo napot.\u30cf\u30f3\u30ac\u30ea\u30fc\u3067\u3059\u3002\u6771\u4eac\u306e\u5929\u6c17\u306f\u6674\u306e\u3061\u66c7\u3067\u660e\u65e5\u306f\u6674\u6642\u3005\u66c7\u3001\u79c1\u306e\u3068\u3053\u308d\u3067\u306f\u66c7\u308a\u3067-2\u2103\u3067\u3059\u3002\u3048\u3001\u3053\u306e\u30d5\u30e9\u30a4\u30d1\u30f3\u3067\u3059\u304b\uff1f\u2026\u3061\u3087\u3063\u3068\u500b\u4eba\u7684\u306b\u6bb4\u308a\u305f\u3044\u4eba\u304c\u3044\u308b\u3093\u3067\u3059\u266a","id":30610995843964928,"from_user_id":65976527,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www15.atpages.jp/~kageyanma/&quot; rel=&quot;nofollow&quot;&gt;\u5730\u7403\u306e\u4e2d&lt;/a&gt;"},{"from_user_id_str":"109740077","profile_image_url":"http://a0.twimg.com/profile_images/1212763349/1d3d3821-6b3a-449f-a636-05b95ce3d5d8_normal.png","created_at":"Thu, 27 Jan 2011 12:59:41 +0000","from_user":"snow_arai","id_str":"30610896141156354","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u6771\u4eac\u306f\u3001\u30ab\u30e9\u30ab\u30e9\u9023\u7d9a\u3000\uff13\u4f4d\u30bf\u30a4 - \u65e9\u8d77\u304d\u2606\u304a\u5929\u6c17\u2606ONAIR\u65e5\u8a18\uff1a\u65e5\u7d4c\u30a6\u30fc\u30de\u30f3\u30aa\u30f3\u30e9\u30a4\u30f3 http://j.mp/hxP3Di","id":30610896141156354,"from_user_id":109740077,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"53407951","profile_image_url":"http://a1.twimg.com/profile_images/397960795/airman_normal.jpg","created_at":"Thu, 27 Jan 2011 12:57:32 +0000","from_user":"Airman2009","id_str":"30610355541508096","metadata":{"result_type":"recent"},"to_user_id":null,"text":". @04mmy22 @qsk1 \u98a8\u3068\u96f2\u30fb\u30fb\u30fb\u98db\u884c\u6a5f\u306e\u5927\u5c0f\u554f\u308f\u305a\u3001\u3053\u308c\u3070\u304b\u308a\u306f\u3069\u3046\u3057\u3088\u3046\u3082\u7121\u3044\u3067\u3059\u3088\u306d\u3002 \u6700\u8fd1\u306e\u5357\u6771\u4eac\u306e\u5929\u6c17\u306f\u5909\u3067\u3059\u306d\u3002\u3002\u3002","id":30610355541508096,"from_user_id":53407951,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://sourceforge.jp/projects/tween/wiki/FrontPage&quot; rel=&quot;nofollow&quot;&gt;Tween&lt;/a&gt;"},{"from_user_id_str":"111826019","profile_image_url":"http://a1.twimg.com/profile_images/1121742732/DVC00052_normal.jpg","created_at":"Thu, 27 Jan 2011 12:51:12 +0000","from_user":"nijiks","id_str":"30608762859421696","metadata":{"result_type":"recent"},"to_user_id":100014282,"text":"@sanaeru \u79c1\u3053\u3093\u306a\u5929\u6c17\u306e\u4e2d\uff64\u4e8c\u6cca\u4e09\u65e5\u3067\u660e\u65e5\u304b\u3089\u6771\u4eac\u884c\u304f\u3093\u3067\u3059\u3051\u3069\u2026\uff61\u65e5\u66dc\u65e5\u98db\u884c\u6a5f\u98db\u3076\u304b\u3057\u3089\u2026\uff1f","id":30608762859421696,"from_user_id":111826019,"to_user":"sanaeru","geo":null,"iso_language_code":"ja","to_user_id_str":"100014282","source":"&lt;a href=&quot;http://z.twipple.jp/&quot; rel=&quot;nofollow&quot;&gt;\u3064\u3044\u3063\u3077\u308b/twipple&lt;/a&gt;"},{"from_user_id_str":"164951488","profile_image_url":"http://a3.twimg.com/profile_images/799082230/twitter_normal.jpg","created_at":"Thu, 27 Jan 2011 12:47:49 +0000","from_user":"minorif_jp","id_str":"30607912309096448","metadata":{"result_type":"recent"},"to_user_id":105078670,"text":"@ecco_HIRADO \u5e73\u6238\u725b\u3063\u3066\u5143\u306f\u30aa\u30e9\u30f3\u30c0\u304b\u3089\u304d\u305f\u725b\u306a\u3093\u3060\u306d\u3002\u304a\u3044\u3057\u305d\u3046\u2026\u3002\u5e73\u6238\u306f\u3088\u304b\u6240\u305f\u3043\u3002\u3042\u305f\u3044\u3052\u3047\u3093\u5b9f\u5bb6\u3093\u65b9\u306f\u30c0\u30d6\u30eb\u706b\u5c71\u3084\u9ce5\u30a4\u30f3\u30d5\u30eb\u3067\u5927\u5909\u3084\u3063\u3069\u3002\u6771\u4eac\u3093\u826f\u304b\u3068\u3053\u306f\u5929\u6c17\u306e\u5fc3\u914d\u305b\u305a\u66ae\u3089\u305b\u308b\u3068\u3053\u3058\u3083\u3063\u3069\u3093\u3002","id":30607912309096448,"from_user_id":164951488,"to_user":"ecco_HIRADO","geo":null,"iso_language_code":"ja","to_user_id_str":"105078670","source":"&lt;a href=&quot;http://z.twipple.jp/&quot; rel=&quot;nofollow&quot;&gt;\u3064\u3044\u3063\u3077\u308b/twipple&lt;/a&gt;"},{"from_user_id_str":"10456803","profile_image_url":"http://a1.twimg.com/profile_images/145280215/vot_icon_normal.png","created_at":"Thu, 27 Jan 2011 12:43:37 +0000","from_user":"vot_","id_str":"30606853377363968","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3086\u3063\u304f\u308a\u5929\u6c17\u4e88\u5831\u3067\u3059\u3002\u6771\u4eac\u90fd,\u5927\u5cf6\u5730\u65b9\u300228\u65e5\uff08\u91d1\u66dc\u65e5\u306e\u5929\u6c17\u306f\u6674\u308c\u306e\u3061\u66c7\u308a\u3001\u6700\u9ad8\u6c17\u6e29\u306f7\u5ea6 \u6700\u4f4e\u6c17\u6e29\u306f1\u5ea6\u3067\u3057\u3087\u3046\u3002","id":30606853377363968,"from_user_id":10456803,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://voiceoftwitter.com&quot; rel=&quot;nofollow&quot;&gt;\uff56\uff4f\uff49\uff43\uff45 \uff4f\uff46 \uff54\uff57\uff49\uff54\uff54\uff45\uff52&lt;/a&gt;"},{"from_user_id_str":"23900716","profile_image_url":"http://a3.twimg.com/profile_images/1092646332/twitter_icon_normal.png","created_at":"Thu, 27 Jan 2011 12:38:00 +0000","from_user":"keiyama","id_str":"30605442639990784","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3010\u7f8e\u4eba\u5929\u6c17/\u6771\u4eac\u3011\u7f8e\u4eba\u5929\u6c17\u30ad\u30e3\u30b9\u30bf\u30fc\u306e&quot;\u30c8\u30e2\u30b3\u3055\u3093&quot;\u306b\u3088\u308b\u3068\u300c1/27(\u6728)\u306f\u304f\u3082\u308a\u306e\u3061\u6674\u3067\u3001\u964d\u6c34\u78ba\u738710%\u3001\u6700\u9ad8\u6c17\u6e29\u306f9\u2103\u3067\u6700\u4f4e\u6c17\u6e29\u306f2\u2103\u3067\u3059\u300d\u7f8e\u4eba\u5929\u6c17\u21d2http://bit.ly/djB8th http://twitpic.com/3tuekm #bt_tenki","id":30605442639990784,"from_user_id":23900716,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://bijintenki.jp&quot; rel=&quot;nofollow&quot;&gt;bijintenki.jp&lt;/a&gt;"},{"from_user_id_str":"32018516","profile_image_url":"http://a0.twimg.com/profile_images/1089472069/237_normal.jpg","created_at":"Thu, 27 Jan 2011 12:36:28 +0000","from_user":"DigJandG","id_str":"30605057460281344","metadata":{"result_type":"recent"},"to_user_id":196050661,"text":"@kosumoworld55 \u5929\u6c17\u4e88\u5831\u3092\u898b\u3066\u3044\u3064\u3082\u601d\u3046\u3093\u3060\u3002\u4f55\u3067\u6a2a\u6d5c\u3042\u305f\u308a\u306f\u3044\u3064\u3082\u597d\u3044\u5929\u6c17\u306a\u3093\u3060\u3002\u6771\u4eac\u3082\u3002\u3061\u306a\u307f\u306b\u516c\u9b5a\u306f\u3042\u3093\u307e\u308a\u597d\u304d\u3067\u306f\u3042\u308a\u307e\u305b\u3093\u3002\u306a\u3093\u304b\u81ed\u304f\u3063\u3066\u3002\u3067\u3082\u3001\u7435\u7436\u6e56\u3067\u516c\u9b5a\u3063\u3066\u3042\u307e\u308a\u805e\u304b\u306a\u3044\u69d8\u306a\u30fb\u30fb\u30fb\u3002\u4ffa\u304c\u91e3\u308a\u3092\u3057\u306a\u3044\u304b\u3089\u304b\u306a\uff1f","id":30605057460281344,"from_user_id":32018516,"to_user":"kosumoworld55","geo":null,"iso_language_code":"ja","to_user_id_str":"196050661","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"90935348","profile_image_url":"http://a1.twimg.com/sticky/default_profile_images/default_profile_0_normal.png","created_at":"Thu, 27 Jan 2011 12:34:34 +0000","from_user":"sorakeiko","id_str":"30604575937396737","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u95a2\u6771\u5730\u65b9\u306e\u660e\u65e5\u306e\u5929\u6c17\u2015\u7d9a\u304d\u3002\u660e\u65e5\u671d\u6700\u4f4e\u6c17\u6e29\u30fb\u8ed2\u4e26\u307f\u6c37\u70b9\u4e0b\u30fb\u5b87\u90fd\u5bae\u3001\u6c34\u6238\u30de\u30a4\u30ca\u30b95\u5ea6\u30fb\u6771\u4eac\u3001\u6a2a\u6d5c1\u5ea6\u3002\u6700\u9ad8\u6c17\u6e29\u30fb\u4eca\u65e5\u3088\u308a3\u5ea6\u524d\u5f8c\u4f4e\u304f5\uff5e8\u5ea6\u30fb\u6771\u4eac\u3001\u5343\u84498\u5ea6\u3002\u5411\u3053\u3046\u4e00\u9031\u9593\u30fb\u4e7e\u71e5\u3057\u305f\u6674\u308c\u7d9a\u304f\u30fb\uff08\u571f\uff09\u4f0a\u8c46\u8af8\u5cf6\u306b\u51b7\u305f\u3044\u96e8\u3084\u96ea\u304c\u898b\u3089\u308c\u305d\u3046\u3060\u304c\u3001\u95a2\u6771\u306e\u4e7e\u3044\u305f\u72b6\u614b\u7d9a\u304f\u3002","id":30604575937396737,"from_user_id":90935348,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"6113557","profile_image_url":"http://a3.twimg.com/profile_images/1227080026/profile_red_herencia_normal.png","created_at":"Thu, 27 Jan 2011 12:33:57 +0000","from_user":"fmoto7","id_str":"30604423327653888","metadata":{"result_type":"recent"},"to_user_id":null,"text":"&quot;\u6771\u4eac\u6c34\u904b\u7528\u30bb\u30f3\u30bf\u30fc\u306f\u3001\u524d\u534a\u6226\u304c\u7d42\u308f\u3063\u305f\u3068\u3053\u308d\u3067\u4e00\u6c17\u306b\u6c34\u5727\u9ad8\u3081\u3001\u5f8c\u534a\u6226\u59cb\u307e\u308b\u3068\u6c34\u5727\u4e0b\u3052\u3001\u7d42\u308f\u308b\u3068\u307e\u305f\u3059\u3050\u4e0a\u3052\u308b\u3002\u30c6\u30ec\u30d3\u306e\u8996\u8074\u3001\u305d\u306e\u65e5\u306e\u5929\u6c17\u306a\u3069\u30e9\u30a4...&quot; http://tumblr.com/xjy1cwiwrm","id":30604423327653888,"from_user_id":6113557,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.tumblr.com/&quot; rel=&quot;nofollow&quot;&gt;Tumblr&lt;/a&gt;"},{"from_user_id_str":"118092912","profile_image_url":"http://a3.twimg.com/profile_images/1225330653/____normal.PNG","created_at":"Thu, 27 Jan 2011 12:29:13 +0000","from_user":"saechuchun","id_str":"30603231042207744","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u3067\u3082\u5730\u9707\u306e\u8a71\u984c\u306e\u3068\u304d\u306e\u300c\u3082\u3057\u6771\u4eac\u3067\u76f4\u4e0b\u578b\u5730\u9707\u304c\u8d77\u304d\u305f\u3089\u300d\u3068\u304b\u5929\u6c17\u4e88\u5831\u306e\u3068\u304d\u306f\u897f\u3067\u96e8\u3060\u308d\u3046\u3068\u300c\u6771\u4eac\u3067\u306f\u301c\u65e5\u9593\u4e7e\u71e5\u3057\u3066\u307e\u3059\u306d\u30fc\u300d\u3068\u304b\u305d\u3046\u3044\u3046\u30ad\u30fc\u5c40\u306e\u95a2\u6771\u4e2d\u5fc3\u4e3b\u7fa9\u306f\u597d\u304d\u3067\u306f\u306a\u3044","id":30603231042207744,"from_user_id":118092912,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twtr.jp&quot; rel=&quot;nofollow&quot;&gt;Keitai Web&lt;/a&gt;"}],"max_id":30724239224995840,"since_id":28179956995457024,"refresh_url":"?since_id=30724239224995840&q=%E6%9D%B1%E4%BA%AC%E3%80%80%E5%A4%A9%E6%B0%97","next_page":"?page=2&max_id=30724239224995840&rpp=50&lang=ja&q=%E6%9D%B1%E4%BA%AC%E3%80%80%E5%A4%A9%E6%B0%97","results_per_page":50,"page":1,"completed_in":0.170202,"warning":"adjusted since_id to 28179956995457024 (), requested since_id was older than allowed -- since_id removed for pagination.","since_id_str":"28179956995457024","max_id_str":"30724239224995840","query":"%E6%9D%B1%E4%BA%AC%E3%80%80%E5%A4%A9%E6%B0%97"}
benchmarks/json-data/numbers.jsondeleted−1
@@ -1 +0,0 @@
1−[1.15, 1.3224999999999998, 1.5208749999999998, 1.7490062499999994, 2.0113571874999994, 2.313060765624999, 2.6600198804687487, 3.0590228625390607, 3.5178762919199196, 4.045557735707907, 4.652391396064092, 5.350250105473706, 6.152787621294761, 7.075705764488975, 8.137061629162321, 9.357620873536668, 10.761264004567169, 12.375453605252241, 14.231771646040077, 16.36653739294609, 18.821518001888, 21.644745702171196, 24.891457557496874, 28.625176191121405, 32.918952619789614, 37.856795512758055, 43.535314839671756, 50.06561206562252, 57.57545387546589, 66.21177195678577, 76.14353775030362, 87.56506841284916, 100.69982867477653, 115.804802975993, 133.17552342239193, 153.15185193575073, 176.1246297261133, 202.5433241850303, 232.9248228127848, 267.86354623470254, 308.04307816990786, 354.24953989539404, 407.3869708797031, 468.49501651165855, 538.7692689884072, 619.5846593366683, 712.5223582371685, 819.4007119727437, 942.3108187686552, 1083.6574415839534, 1246.2060578215462, 1433.136966494778, 1648.1075114689947, 1895.323638189344, 2179.622183917745, 2506.565511505407, 2882.5503382312177, 3314.9328889659, 3812.172822310785, 4383.998745657402, 5041.598557506012, 5797.838341131914, 6667.5140923017, 7667.641206146955, 8817.787387068996, 10140.455495129345, 11661.523819398746, 13410.752392308557, 15422.365251154839, 17735.720038828065, 20396.078044652273, 23455.489751350113, 26973.813214052625, 31019.885196160518, 35672.867975584595, 41023.79817192228, 47177.36789771062, 54253.97308236721, 62392.06904472228, 71750.87940143062, 82513.5113116452, 94890.53800839197, 109124.11870965076, 125492.73651609836, 144316.6469935131, 165964.14404254008, 190858.76564892105, 219487.5804962592, 252410.71757069806, 290272.32520630275, 333813.17398724816, 383885.1500853353, 441467.9225981356, 507688.1109878559, 583841.3276360342, 671417.5267814393, 772130.1557986551, 887949.6791684533, 1021142.1310437213, 1174313.4507002793, 1350460.4683053212, 1553029.5385511192, 1785983.969333787, 2053881.564733855, 2361963.7994439327, 2716258.369360523, 3123697.124764601, 3592251.6934792907, 4131089.447501184, 4750752.864626361, 5463365.794320315, 6282870.663468362, 7225301.262988616, 8309096.452436907, 9555460.920302443, 10988780.058347808, 12637097.067099977, 14532661.627164973, 16712560.871239718, 19219445.001925673, 22102361.752214525, 25417716.0150467, 29230373.417303704, 33614929.42989926, 38657168.84438414, 44455744.17104176, 51124105.79669802, 58792721.66620272, 67611629.91613312, 77753374.40355308, 89416380.56408603, 102828837.64869894, 118253163.29600377, 135991137.79040432, 156389808.45896497, 179848279.7278097, 206825521.68698114, 237849349.94002828, 273526752.4310325, 314555765.2956874, 361739130.09004045, 415999999.60354644, 478399999.5440784, 550159999.4756901, 632683999.3970436, 727586599.3066001, 836724589.20259, 962233277.5829784, 1106568269.2204251, 1272553509.6034887, 1463436536.044012, 1682952016.4506137, 1935394818.9182055, 2225704041.755936, 2559559648.019326, 2943493595.222225, 3385017634.5055585, 3892770279.681392, 4476685821.6336, 5148188694.87864, 5920416999.1104355, 6808479548.977001, 7829751481.32355, 9004214203.522081, 10354846334.050394, 11908073284.157951, 13694284276.781643, 15748426918.29889, 18110690956.04372, 20827294599.450275, 23951388789.367817, 27544097107.772987, 31675711673.938934, 36427068425.02977, 41891128688.78423, 48174797992.10186, 55401017690.91714, 63711170344.5547, 73267845896.2379, 84258022780.67358, 96896726197.77461, 111431235127.4408, 128145920396.5569, 147367808456.04044, 169472979724.44647, 194893926683.11343, 224128015685.58044, 257747218038.41748, 296409300744.1801, 340870695855.80707, 392001300234.1781, 450801495269.3048, 518421719559.70044, 596184977493.6555, 685612724117.7037, 788454632735.3593, 906722827645.6631, 1042731251792.5125, 1199140939561.3892, 1379012080495.5974, 1585863892569.937, 1823743476455.4275, 2097304997923.7415, 2411900747612.3022, 2773685859754.1475, 3189738738717.2695, 3668199549524.8594, 4218429481953.5884, 4851193904246.626, 5578872989883.619, 6415703938366.162, 7378059529121.086, 8484768458489.248, 9757483727262.635, 11221106286352.03, 12904272229304.832, 14839913063700.555, 17065900023255.637, 19625785026743.98, 22569652780755.58, 25955100697868.91, 29848365802549.246, 34325620672931.63, 39474463773871.375, 45395633339952.07, 52204978340944.88, 60035725092086.61, 69041083855899.59, 79397246434284.53, 91306833399427.2, 105002858409341.27, 120753287170742.45, 138866280246353.81, 159696222283306.88, 183650655625802.88, 211198253969673.3, 242877992065124.28, 279309690874892.9, 321206144506126.8, 369387066182045.8, 424795126109352.6, 488514395025755.5, 561791554279618.75, 646060287421561.5, 742969330534795.8, 854414730115015.0, 982576939632267.1, 1129963480577107.2, 1299458002663673.2, 1494376703063224.0, 1718533208522707.5, 1976313189801113.5, 2272760168271280.5, 2613674193511972.0, 3005725322538767.5, 3456584120919582.5, 3975071739057519.5, 4571332499916147.0, 5257032374903569.0, 6045587231139104.0, 6952425315809969.0, 7995289113181464.0, 9194582480158682.0, 1.0573769852182484e+16, 1.2159835330009856e+16, 1.3983810629511332e+16, 1.6081382223938032e+16, 1.8493589557528736e+16, 2.1267627991158044e+16, 2.4457772189831748e+16, 2.8126438018306508e+16, 3.234540372105248e+16, 3.719721427921035e+16, 4.27767964210919e+16, 4.919331588425568e+16, 5.657231326689403e+16, 6.505816025692813e+16, 7.481688429546734e+16, 8.603941693978744e+16, 9.894532948075555e+16, 1.1378712890286886e+17, 1.3085519823829918e+17, 1.5048347797404406e+17, 1.7305599967015066e+17, 1.9901439962067325e+17, 2.288665595637742e+17, 2.6319654349834032e+17, 3.026760250230913e+17, 3.48077428776555e+17, 4.002890430930382e+17, 4.603323995569939e+17, 5.29382259490543e+17, 6.087895984141244e+17, 7.00108038176243e+17, 8.051242439026793e+17, 9.258928804880812e+17, 1.0647768125612933e+18, 1.224493334445487e+18, 1.4081673346123103e+18, 1.6193924348041567e+18, 1.8623013000247798e+18, 2.1416464950284966e+18, 2.462893469282771e+18, 2.8323274896751867e+18, 3.257176613126464e+18, 3.7457531050954337e+18, 4.3076160708597484e+18, 4.95375848148871e+18, 5.696822253712016e+18, 6.551345591768818e+18, 7.53404743053414e+18, 8.66415454511426e+18, 9.963777726881399e+18, 1.1458344385913608e+19, 1.3177096043800648e+19, 1.5153660450370744e+19, 1.7426709517926355e+19, 2.0040715945615307e+19, 2.30468233374576e+19, 2.650384683807624e+19, 3.047942386378767e+19, 3.505133744335582e+19, 4.030903805985919e+19, 4.635539376883806e+19, 5.330870283416377e+19, 6.130500825928833e+19, 7.0500759498181575e+19, 8.10758734229088e+19, 9.323725443634512e+19, 1.0722284260179688e+20, 1.233062689920664e+20, 1.4180220934087634e+20, 1.6307254074200778e+20, 1.8753342185330894e+20, 2.1566343513130526e+20, 2.4801295040100103e+20, 2.8521489296115116e+20, 3.2799712690532385e+20, 3.7719669594112236e+20, 4.337762003322907e+20, 4.988426303821342e+20, 5.7366902493945437e+20, 6.597193786803724e+20, 7.586772854824282e+20, 8.724788783047925e+20, 1.0033507100505113e+21, 1.1538533165580878e+21, 1.326931314041801e+21, 1.5259710111480708e+21, 1.7548666628202813e+21, 2.0180966622433234e+21, 2.3208111615798217e+21, 2.668932835816795e+21, 3.0692727611893135e+21, 3.529663675367711e+21, 4.059113226672867e+21, 4.667980210673796e+21, 5.368177242274866e+21, 6.173403828616095e+21, 7.099414402908508e+21, 8.164326563344784e+21, 9.388975547846502e+21, 1.0797321880023475e+22, 1.2416920162026996e+22, 1.4279458186331043e+22, 1.64213769142807e+22, 1.8884583451422802e+22, 2.171727096913622e+22, 2.497486161450665e+22, 2.872109085668265e+22, 3.3029254485185042e+22, 3.798364265796279e+22, 4.368118905665721e+22, 5.0233367415155795e+22, 5.7768372527429155e+22, 6.643362840654352e+22, 7.639867266752504e+22, 8.78584735676538e+22, 1.0103724460280185e+23, 1.1619283129322213e+23, 1.3362175598720545e+23, 1.5366501938528623e+23, 1.7671477229307915e+23, 2.0322198813704103e+23, 2.3370528635759717e+23, 2.687610793112367e+23, 3.090752412079222e+23, 3.554365273891105e+23, 4.0875200649747705e+23, 4.700648074720986e+23, 5.405745285929133e+23, 6.216607078818502e+23, 7.149098140641278e+23, 8.221462861737468e+23, 9.454682290998088e+23, 1.0872884634647801e+24, 1.250381732984497e+24, 1.4379389929321714e+24, 1.653629841871997e+24, 1.9016743181527962e+24, 2.1869254658757156e+24, 2.5149642857570727e+24, 2.8922089286206334e+24, 3.326040267913728e+24, 3.824946308100787e+24, 4.3986882543159046e+24, 5.05849149246329e+24, 5.817265216332783e+24, 6.6898549987827e+24, 7.693333248600105e+24, 8.84733323589012e+24, 1.0174433221273637e+25, 1.1700598204464681e+25, 1.3455687935134384e+25, 1.547404112540454e+25, 1.779514729421522e+25, 2.04644193883475e+25, 2.353408229659962e+25, 2.7064194641089563e+25, 3.1123823837253e+25, 3.5792397412840944e+25, 4.116125702476708e+25, 4.733544557848214e+25, 5.443576241525446e+25, 6.260112677754262e+25, 7.199129579417401e+25, 8.27899901633001e+25, 9.52084886877951e+25, 1.0948976199096437e+26, 1.25913226289609e+26, 1.4480021023305035e+26, 1.665202417680079e+26, 1.9149827803320907e+26, 2.202230197381904e+26, 2.5325647269891895e+26, 2.9124494360375676e+26, 3.349316851443203e+26, 3.8517143791596826e+26, 4.429471536033635e+26, 5.09389226643868e+26, 5.857976106404481e+26, 6.736672522365153e+26, 7.747173400719924e+26, 8.909249410827912e+26, 1.0245636822452099e+27, 1.1782482345819913e+27, 1.35498546976929e+27, 1.5582332902346833e+27, 1.7919682837698857e+27, 2.0607635263353683e+27, 2.3698780552856732e+27, 2.725359763578524e+27, 3.1341637281153025e+27, 3.6042882873325974e+27, 4.1449315304324867e+27, 4.7666712599973594e+27, 5.481671948996963e+27, 6.303922741346507e+27, 7.249511152548482e+27, 8.336937825430755e+27, 9.587478499245366e+27, 1.102560027413217e+28, 1.2679440315251995e+28, 1.4581356362539794e+28, 1.6768559816920761e+28, 1.9283843789458875e+28, 2.2176420357877703e+28, 2.5502883411559357e+28, 2.932831592329326e+28, 3.3727563311787245e+28, 3.8786697808555327e+28, 4.460470247983863e+28, 5.129540785181441e+28, 5.8989719029586575e+28, 6.783817688402455e+28, 7.801390341662823e+28, 8.971598892912247e+28, 1.0317338726849081e+29, 1.1864939535876443e+29, 1.3644680466257909e+29, 1.5691382536196593e+29, 1.8045089916626083e+29, 2.0751853404119993e+29, 2.3864631414737988e+29, 2.7444326126948684e+29, 3.1560975045990984e+29, 3.629512130288963e+29, 4.173938949832307e+29, 4.800029792307153e+29, 5.520034261153225e+29, 6.348039400326208e+29, 7.300245310375139e+29, 8.39528210693141e+29, 9.65457442297112e+29, 1.1102760586416787e+30, 1.2768174674379305e+30, 1.46834008755362e+30, 1.6885911006866628e+30, 1.941879765789662e+30, 2.2331617306581113e+30, 2.568135990256828e+30, 2.9533563887953516e+30, 3.396359847114654e+30, 3.905813824181852e+30, 4.491685897809129e+30, 5.165438782480498e+30, 5.940254599852573e+30, 6.831292789830458e+30, 7.855986708305026e+30, 9.034384714550779e+30, 1.0389542421733396e+31, 1.1947973784993405e+31, 1.3740169852742412e+31, 1.5801195330653773e+31, 1.817137463025184e+31, 2.0897080824789613e+31, 2.4031642948508052e+31, 2.7636389390784257e+31, 3.1781847799401893e+31, 3.6549124969312175e+31, 4.2031493714709e+31, 4.833621777191535e+31, 5.558665043770264e+31, 6.392464800335803e+31, 7.3513345203861735e+31, 8.454034698444098e+31, 9.722139903210713e+31, 1.1180460888692319e+32, 1.2857530021996165e+32, 1.478615952529559e+32, 1.7004083454089925e+32, 1.9554695972203414e+32, 2.2487900368033926e+32, 2.586108542323901e+32, 2.974024823672486e+32, 3.420128547223359e+32, 3.933147829306862e+32, 4.523120003702891e+32, 5.2015880042583246e+32, 5.981826204897073e+32, 6.879100135631634e+32, 7.910965155976377e+32, 9.097609929372833e+32, 1.0462251418778757e+33, 1.2031589131595571e+33, 1.3836327501334904e+33, 1.591177662653514e+33, 1.8298543120515409e+33, 2.104332458859272e+33, 2.4199823276881623e+33, 2.7829796768413863e+33, 3.200426628367594e+33, 3.6804906226227334e+33, 4.232564216016143e+33, 4.867448848418564e+33, 5.597566175681348e+33, 6.437201102033549e+33, 7.402781267338582e+33, 8.513198457439368e+33, 9.790178226055273e+33, 1.1258704959963564e+34, 1.2947510703958096e+34, 1.488963730955181e+34, 1.712308290598458e+34, 1.9691545341882266e+34, 2.2645277143164603e+34, 2.604206871463929e+34, 2.994837902183518e+34, 3.4440635875110457e+34, 3.960673125637702e+34, 4.554774094483357e+34, 5.237990208655861e+34, 6.023688739954239e+34, 6.927242050947375e+34, 7.96632835858948e+34, 9.161277612377902e+34, 1.0535469254234585e+35, 1.2115789642369772e+35, 1.3933158088725236e+35, 1.6023131802034022e+35, 1.8426601572339122e+35, 2.119059180818999e+35, 2.4369180579418488e+35, 2.8024557666331258e+35, 3.2228241316280944e+35, 3.706247751372308e+35, 4.262184914078154e+35, 4.901512651189877e+35, 5.636739548868358e+35, 6.482250481198611e+35, 7.454588053378403e+35, 8.572776261385162e+35, 9.858692700592935e+35, 1.1337496605681875e+36, 1.3038121096534156e+36, 1.499383926101428e+36, 1.7242915150166418e+36, 1.982935242269138e+36, 2.2803755286095084e+36]
benchmarks/json-data/twitter1.jsondeleted−1
@@ -1 +0,0 @@
1−{"results":[{"from_user_id_str":"80430860","profile_image_url":"http://a2.twimg.com/profile_images/536455139/icon32_normal.png","created_at":"Wed, 26 Jan 2011 07:07:02 +0000","from_user":"kazu_yamamoto","id_str":"30159761706061824","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Haskell Server Pages \u3063\u3066\u3001\u307e\u3060\u7d9a\u3044\u3066\u3044\u305f\u306e\u304b\uff01","id":30159761706061824,"from_user_id":80430860,"geo":null,"iso_language_code":"no","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"}],"max_id":30159761706061824,"since_id":0,"refresh_url":"?since_id=30159761706061824&q=haskell","next_page":"?page=2&max_id=30159761706061824&rpp=1&q=haskell","results_per_page":1,"page":1,"completed_in":0.012606,"since_id_str":"0","max_id_str":"30159761706061824","query":"haskell"}
benchmarks/json-data/twitter10.jsondeleted−1
@@ -1 +0,0 @@
1−{"results":[{"from_user_id_str":"207858021","profile_image_url":"http://a3.twimg.com/sticky/default_profile_images/default_profile_2_normal.png","created_at":"Wed, 26 Jan 2011 04:30:38 +0000","from_user":"pboudarga","id_str":"30120402839666689","metadata":{"result_type":"recent"},"to_user_id":null,"text":"I'm at Rolla Sushi Grill (27737 Bouquet Canyon Road, #106, Btw Haskell Canyon and Rosedell Drive, Saugus) http://4sq.com/gqqdhs","id":30120402839666689,"from_user_id":207858021,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://foursquare.com&quot; rel=&quot;nofollow&quot;&gt;foursquare&lt;/a&gt;"},{"from_user_id_str":"69988683","profile_image_url":"http://a0.twimg.com/profile_images/1211955817/avatar_7888_normal.gif","created_at":"Wed, 26 Jan 2011 04:25:23 +0000","from_user":"YNK33","id_str":"30119083059978240","metadata":{"result_type":"recent"},"to_user_id":null,"text":"hsndfile 0.5.0: Free and open source Haskell bindings for libsndfile http://bit.ly/gHaBWG Mac Os","id":30119083059978240,"from_user_id":69988683,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"81492","profile_image_url":"http://a1.twimg.com/profile_images/423894208/Picture_7_normal.jpg","created_at":"Wed, 26 Jan 2011 04:24:28 +0000","from_user":"satzz","id_str":"30118851488251904","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Emacs\u306e\u30e2\u30fc\u30c9\u8868\u793a\u304c\u4eca(Ruby Controller Outputz RoR Flymake REl hs)\u3068\u306a\u3063\u3066\u3066\u3088\u304f\u308f\u304b\u3089\u306a\u3044\u3093\u3060\u3051\u3069\u6700\u5f8c\u306eREl\u3068\u304bhs\u3063\u3066\u4f55\u3060\u308d\u3046\u2026haskell\u3068\u304b2\u5e74\u4ee5\u4e0a\u66f8\u3044\u3066\u306a\u3044\u3051\u3069\u2026","id":30118851488251904,"from_user_id":81492,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.hootsuite.com&quot; rel=&quot;nofollow&quot;&gt;HootSuite&lt;/a&gt;"},{"from_user_id_str":"9518356","profile_image_url":"http://a2.twimg.com/profile_images/119165723/ocaml-icon_normal.png","created_at":"Wed, 26 Jan 2011 04:19:19 +0000","from_user":"planet_ocaml","id_str":"30117557788741632","metadata":{"result_type":"recent"},"to_user_id":null,"text":"I so miss #haskell type classes in #ocaml - i want to do something like refinement. Also why does ocaml not have... http://bit.ly/geYRwt","id":30117557788741632,"from_user_id":9518356,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"218059","profile_image_url":"http://a1.twimg.com/profile_images/1053837723/twitter-icon9_normal.jpg","created_at":"Wed, 26 Jan 2011 04:16:32 +0000","from_user":"aprikip","id_str":"30116854940835840","metadata":{"result_type":"recent"},"to_user_id":null,"text":"yatex-mode\u3084haskell-mode\u306e\u3053\u3068\u3067\u3059\u306d\u3001\u308f\u304b\u308a\u307e\u3059\u3002","id":30116854940835840,"from_user_id":218059,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://sites.google.com/site/yorufukurou/&quot; rel=&quot;nofollow&quot;&gt;YoruFukurou&lt;/a&gt;"},{"from_user_id_str":"216363","profile_image_url":"http://a1.twimg.com/profile_images/72454310/Tim-Avatar_normal.png","created_at":"Wed, 26 Jan 2011 04:15:30 +0000","from_user":"dysinger","id_str":"30116594684264448","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Haskell in Hawaii tonight for me... #fun","id":30116594684264448,"from_user_id":216363,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.nambu.com/&quot; rel=&quot;nofollow&quot;&gt;Nambu&lt;/a&gt;"},{"from_user_id_str":"1774820","profile_image_url":"http://a2.twimg.com/profile_images/61169291/dan_desert_thumb_normal.jpg","created_at":"Wed, 26 Jan 2011 04:13:36 +0000","from_user":"DanMil","id_str":"30116117682851840","metadata":{"result_type":"recent"},"to_user_id":1594784,"text":"@ojrac @chewedwire @tomheon Haskell isn't a language, it's a belief system. A seductive one...","id":30116117682851840,"from_user_id":1774820,"to_user":"ojrac","geo":null,"iso_language_code":"en","to_user_id_str":"1594784","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"659256","profile_image_url":"http://a0.twimg.com/profile_images/746976711/angular-final_normal.jpg","created_at":"Wed, 26 Jan 2011 04:11:06 +0000","from_user":"djspiewak","id_str":"30115488931520512","metadata":{"result_type":"recent"},"to_user_id":null,"text":"One of the very nice things about Haskell as opposed to SML is the reduced proliferation of identifiers (e.g. andb, orb, etc). #typeclasses","id":30115488931520512,"from_user_id":659256,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://itunes.apple.com/us/app/twitter/id409789998?mt=12&quot; rel=&quot;nofollow&quot;&gt;Twitter for Mac&lt;/a&gt;"},{"from_user_id_str":"144546280","profile_image_url":"http://a1.twimg.com/a/1295051201/images/default_profile_1_normal.png","created_at":"Wed, 26 Jan 2011 04:06:12 +0000","from_user":"listwarenet","id_str":"30114255890026496","metadata":{"result_type":"recent"},"to_user_id":null,"text":"http://www.listware.net/201101/haskell-cafe/84752-re-haskell-cafe-gpl-license-of-h-matrix-and-prelude-numeric.html Re: Haskell-c","id":30114255890026496,"from_user_id":144546280,"geo":null,"iso_language_code":"no","to_user_id_str":null,"source":"&lt;a href=&quot;http://1e10.org/cloud/&quot; rel=&quot;nofollow&quot;&gt;1e10&lt;/a&gt;"},{"from_user_id_str":"1594784","profile_image_url":"http://a2.twimg.com/profile_images/378515773/square-profile_normal.jpg","created_at":"Wed, 26 Jan 2011 04:01:29 +0000","from_user":"ojrac","id_str":"30113067333324800","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @tomheon: @ojrac @chewedwire Don't worry, learning Haskell will not give you any clear idea what monad means.","id":30113067333324800,"from_user_id":1594784,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"}],"max_id":30120402839666689,"since_id":0,"refresh_url":"?since_id=30120402839666689&q=haskell","next_page":"?page=2&max_id=30120402839666689&rpp=10&q=haskell","results_per_page":10,"page":1,"completed_in":0.012714,"since_id_str":"0","max_id_str":"30120402839666689","query":"haskell"}
benchmarks/json-data/twitter100.jsondeleted−1
@@ -1 +0,0 @@
1−{"results":[{"from_user_id_str":"3646730","profile_image_url":"http://a3.twimg.com/profile_images/404973767/avatar_normal.jpg","created_at":"Wed, 26 Jan 2011 04:35:07 +0000","from_user":"nicolaslara","id_str":"30121530767708160","metadata":{"result_type":"recent"},"to_user_id":18616016,"text":"@josej30 Python y Clojure. Obviamente son diferentes, y cada uno tiene sus ventajas y desventajas. De Haskell faltar\u00eda pattern matching","id":30121530767708160,"from_user_id":3646730,"to_user":"josej30","geo":null,"iso_language_code":"es","to_user_id_str":"18616016","source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"207858021","profile_image_url":"http://a3.twimg.com/sticky/default_profile_images/default_profile_2_normal.png","created_at":"Wed, 26 Jan 2011 04:30:38 +0000","from_user":"pboudarga","id_str":"30120402839666689","metadata":{"result_type":"recent"},"to_user_id":null,"text":"I'm at Rolla Sushi Grill (27737 Bouquet Canyon Road, #106, Btw Haskell Canyon and Rosedell Drive, Saugus) http://4sq.com/gqqdhs","id":30120402839666689,"from_user_id":207858021,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://foursquare.com&quot; rel=&quot;nofollow&quot;&gt;foursquare&lt;/a&gt;"},{"from_user_id_str":"69988683","profile_image_url":"http://a0.twimg.com/profile_images/1211955817/avatar_7888_normal.gif","created_at":"Wed, 26 Jan 2011 04:25:23 +0000","from_user":"YNK33","id_str":"30119083059978240","metadata":{"result_type":"recent"},"to_user_id":null,"text":"hsndfile 0.5.0: Free and open source Haskell bindings for libsndfile http://bit.ly/gHaBWG Mac Os","id":30119083059978240,"from_user_id":69988683,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"81492","profile_image_url":"http://a1.twimg.com/profile_images/423894208/Picture_7_normal.jpg","created_at":"Wed, 26 Jan 2011 04:24:28 +0000","from_user":"satzz","id_str":"30118851488251904","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Emacs\u306e\u30e2\u30fc\u30c9\u8868\u793a\u304c\u4eca(Ruby Controller Outputz RoR Flymake REl hs)\u3068\u306a\u3063\u3066\u3066\u3088\u304f\u308f\u304b\u3089\u306a\u3044\u3093\u3060\u3051\u3069\u6700\u5f8c\u306eREl\u3068\u304bhs\u3063\u3066\u4f55\u3060\u308d\u3046\u2026haskell\u3068\u304b2\u5e74\u4ee5\u4e0a\u66f8\u3044\u3066\u306a\u3044\u3051\u3069\u2026","id":30118851488251904,"from_user_id":81492,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.hootsuite.com&quot; rel=&quot;nofollow&quot;&gt;HootSuite&lt;/a&gt;"},{"from_user_id_str":"9518356","profile_image_url":"http://a2.twimg.com/profile_images/119165723/ocaml-icon_normal.png","created_at":"Wed, 26 Jan 2011 04:19:19 +0000","from_user":"planet_ocaml","id_str":"30117557788741632","metadata":{"result_type":"recent"},"to_user_id":null,"text":"I so miss #haskell type classes in #ocaml - i want to do something like refinement. Also why does ocaml not have... http://bit.ly/geYRwt","id":30117557788741632,"from_user_id":9518356,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"218059","profile_image_url":"http://a1.twimg.com/profile_images/1053837723/twitter-icon9_normal.jpg","created_at":"Wed, 26 Jan 2011 04:16:32 +0000","from_user":"aprikip","id_str":"30116854940835840","metadata":{"result_type":"recent"},"to_user_id":null,"text":"yatex-mode\u3084haskell-mode\u306e\u3053\u3068\u3067\u3059\u306d\u3001\u308f\u304b\u308a\u307e\u3059\u3002","id":30116854940835840,"from_user_id":218059,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://sites.google.com/site/yorufukurou/&quot; rel=&quot;nofollow&quot;&gt;YoruFukurou&lt;/a&gt;"},{"from_user_id_str":"216363","profile_image_url":"http://a1.twimg.com/profile_images/72454310/Tim-Avatar_normal.png","created_at":"Wed, 26 Jan 2011 04:15:30 +0000","from_user":"dysinger","id_str":"30116594684264448","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Haskell in Hawaii tonight for me... #fun","id":30116594684264448,"from_user_id":216363,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.nambu.com/&quot; rel=&quot;nofollow&quot;&gt;Nambu&lt;/a&gt;"},{"from_user_id_str":"1774820","profile_image_url":"http://a2.twimg.com/profile_images/61169291/dan_desert_thumb_normal.jpg","created_at":"Wed, 26 Jan 2011 04:13:36 +0000","from_user":"DanMil","id_str":"30116117682851840","metadata":{"result_type":"recent"},"to_user_id":1594784,"text":"@ojrac @chewedwire @tomheon Haskell isn't a language, it's a belief system. A seductive one...","id":30116117682851840,"from_user_id":1774820,"to_user":"ojrac","geo":null,"iso_language_code":"en","to_user_id_str":"1594784","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"659256","profile_image_url":"http://a0.twimg.com/profile_images/746976711/angular-final_normal.jpg","created_at":"Wed, 26 Jan 2011 04:11:06 +0000","from_user":"djspiewak","id_str":"30115488931520512","metadata":{"result_type":"recent"},"to_user_id":null,"text":"One of the very nice things about Haskell as opposed to SML is the reduced proliferation of identifiers (e.g. andb, orb, etc). #typeclasses","id":30115488931520512,"from_user_id":659256,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://itunes.apple.com/us/app/twitter/id409789998?mt=12&quot; rel=&quot;nofollow&quot;&gt;Twitter for Mac&lt;/a&gt;"},{"from_user_id_str":"144546280","profile_image_url":"http://a1.twimg.com/a/1295051201/images/default_profile_1_normal.png","created_at":"Wed, 26 Jan 2011 04:06:12 +0000","from_user":"listwarenet","id_str":"30114255890026496","metadata":{"result_type":"recent"},"to_user_id":null,"text":"http://www.listware.net/201101/haskell-cafe/84752-re-haskell-cafe-gpl-license-of-h-matrix-and-prelude-numeric.html Re: Haskell-c","id":30114255890026496,"from_user_id":144546280,"geo":null,"iso_language_code":"no","to_user_id_str":null,"source":"&lt;a href=&quot;http://1e10.org/cloud/&quot; rel=&quot;nofollow&quot;&gt;1e10&lt;/a&gt;"},{"from_user_id_str":"1594784","profile_image_url":"http://a2.twimg.com/profile_images/378515773/square-profile_normal.jpg","created_at":"Wed, 26 Jan 2011 04:01:29 +0000","from_user":"ojrac","id_str":"30113067333324800","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @tomheon: @ojrac @chewedwire Don't worry, learning Haskell will not give you any clear idea what monad means.","id":30113067333324800,"from_user_id":1594784,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"207589736","profile_image_url":"http://a3.twimg.com/profile_images/1225527428/headshot_1_normal.jpg","created_at":"Wed, 26 Jan 2011 04:00:13 +0000","from_user":"ashleevelazq101","id_str":"30112747555397632","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Federal investigation finds safety violations at The Acadia Hospital: By Meg Haskell, BDN Staff The investigatio... http://bit.ly/dONnpn","id":30112747555397632,"from_user_id":207589736,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"17671137","profile_image_url":"http://a2.twimg.com/profile_images/290264834/Haskell-logo-outer-glow_normal.png","created_at":"Wed, 26 Jan 2011 03:58:00 +0000","from_user":"Hackage","id_str":"30112192346984448","metadata":{"result_type":"recent"},"to_user_id":null,"text":"streams 0.4, added by EdwardKmett: Various Haskell 2010 stream comonads http://bit.ly/idBkPe","id":30112192346984448,"from_user_id":17671137,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"17489366","profile_image_url":"http://a3.twimg.com/sticky/default_profile_images/default_profile_2_normal.png","created_at":"Wed, 26 Jan 2011 03:58:00 +0000","from_user":"aapnoot","id_str":"30112191881420800","metadata":{"result_type":"recent"},"to_user_id":null,"text":"streams 0.4, added by EdwardKmett: Various Haskell 2010 stream comonads http://bit.ly/idBkPe","id":30112191881420800,"from_user_id":17489366,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"8530482","profile_image_url":"http://a2.twimg.com/profile_images/137867266/n608671563_7396_normal.jpg","created_at":"Wed, 26 Jan 2011 03:50:12 +0000","from_user":"jeffmclamb","id_str":"30110229207187456","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Angel - daemon to run and monitor processes like daemontools or god, written in Haskell http://ff.im/-wNyLk","id":30110229207187456,"from_user_id":8530482,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://friendfeed.com&quot; rel=&quot;nofollow&quot;&gt;FriendFeed&lt;/a&gt;"},{"from_user_id_str":"177539201","profile_image_url":"http://a0.twimg.com/profile_images/1178368800/img_normal.jpeg","created_at":"Wed, 26 Jan 2011 03:46:01 +0000","from_user":"tomheon","id_str":"30109174645919744","metadata":{"result_type":"recent"},"to_user_id":1594784,"text":"@ojrac @chewedwire Don't worry, learning Haskell will not give you any clear idea what monad means.","id":30109174645919744,"from_user_id":177539201,"to_user":"ojrac","geo":null,"iso_language_code":"en","to_user_id_str":"1594784","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"1594784","profile_image_url":"http://a2.twimg.com/profile_images/378515773/square-profile_normal.jpg","created_at":"Wed, 26 Jan 2011 03:44:34 +0000","from_user":"ojrac","id_str":"30108808684503040","metadata":{"result_type":"recent"},"to_user_id":128028225,"text":"@chewedwire @tomheon Why are you making me curious about Haskell? I LIKE not knowing what monad means!!","id":30108808684503040,"from_user_id":1594784,"to_user":"chewedwire","geo":null,"iso_language_code":"en","to_user_id_str":"128028225","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"23750094","profile_image_url":"http://a0.twimg.com/profile_images/951373780/Moeinthecar_normal.jpg","created_at":"Wed, 26 Jan 2011 03:41:54 +0000","from_user":"shokalshab","id_str":"30108140443795456","metadata":{"result_type":"recent"},"to_user_id":null,"text":"I'm at Magnitude Cheer @ Gymnastics Olympica USA (7735 Haskell Ave., btw Saticoy &amp; Strathern, Van Nuys) http://4sq.com/gmXfaL","id":30108140443795456,"from_user_id":23750094,"geo":null,"iso_language_code":"en","place":{"id":"4e4a2a2f86cb2946","type":"poi","full_name":"Gymnastics Olympica USA, Van Nuys"},"to_user_id_str":null,"source":"&lt;a href=&quot;http://foursquare.com&quot; rel=&quot;nofollow&quot;&gt;foursquare&lt;/a&gt;"},{"from_user_id_str":"8135112","profile_image_url":"http://a0.twimg.com/profile_images/1165240350/LIMITED_normal.jpg","created_at":"Wed, 26 Jan 2011 03:41:35 +0000","from_user":"Claricei","id_str":"30108059208515584","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @kristenmchugh22: @KeithOlbermann Ryan looks like Jughead w/o the hat. And sounds as mealy-mouthed as Eddie Haskell.","id":30108059208515584,"from_user_id":8135112,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"128028225","profile_image_url":"http://a1.twimg.com/profile_images/1224994593/Coding_Drunk_normal.jpg","created_at":"Wed, 26 Jan 2011 03:40:02 +0000","from_user":"chewedwire","id_str":"30107670367182848","metadata":{"result_type":"recent"},"to_user_id":177539201,"text":"@tomheon Cool, I'll take a look. I feel like I should mention this: http://bit.ly/hVstDM","id":30107670367182848,"from_user_id":128028225,"to_user":"tomheon","geo":null,"iso_language_code":"en","to_user_id_str":"177539201","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"8679778","profile_image_url":"http://a3.twimg.com/profile_images/1195318056/me_nyc_12_18_10_icon_normal.jpg","created_at":"Wed, 26 Jan 2011 03:38:42 +0000","from_user":"kristenmchugh22","id_str":"30107332381777920","metadata":{"result_type":"recent"},"to_user_id":756269,"text":"@KeithOlbermann Ryan looks like Jughead w/o the hat. And sounds as mealy-mouthed as Eddie Haskell.","id":30107332381777920,"from_user_id":8679778,"to_user":"KeithOlbermann","geo":null,"iso_language_code":"en","to_user_id_str":"756269","source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"103316559","profile_image_url":"http://a1.twimg.com/profile_images/1179458751/bc3beab4-d59d-4e78-b13b-50747986cfa2_normal.png","created_at":"Wed, 26 Jan 2011 03:36:15 +0000","from_user":"cityslikr","id_str":"30106719153557504","metadata":{"result_type":"recent"},"to_user_id":null,"text":"&quot;Social safety net into a hammock.&quot; So says Eddie Haskell with the GOP response. #SOTU","id":30106719153557504,"from_user_id":103316559,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://blackberry.com/twitter&quot; rel=&quot;nofollow&quot;&gt;Twitter for BlackBerry\u00ae&lt;/a&gt;"},{"from_user_id_str":"169063143","profile_image_url":"http://a0.twimg.com/profile_images/1160506212/9697_1_normal.gif","created_at":"Wed, 26 Jan 2011 03:31:52 +0000","from_user":"wrkforce_safety","id_str":"30105614919143424","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Federal investigation finds safety violations at The Acadia Hospital: By Meg Haskell, BDN Staff The investigatio... http://bit.ly/gA60C1","id":30105614919143424,"from_user_id":169063143,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"177539201","profile_image_url":"http://a0.twimg.com/profile_images/1178368800/img_normal.jpeg","created_at":"Wed, 26 Jan 2011 03:29:40 +0000","from_user":"tomheon","id_str":"30105060960632832","metadata":{"result_type":"recent"},"to_user_id":128028225,"text":"@chewedwire Great book on Haskell: http://oreilly.com/catalog/9780596514983","id":30105060960632832,"from_user_id":177539201,"to_user":"chewedwire","geo":null,"iso_language_code":"en","to_user_id_str":"128028225","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"782692","profile_image_url":"http://a0.twimg.com/profile_images/1031304589/Profile.2007.1_normal.jpg","created_at":"Wed, 26 Jan 2011 03:29:19 +0000","from_user":"turnageb","id_str":"30104974591533057","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @ovillalon: Paul Ryan solves the mystery of whatever happened to Eddie Haskell. #sotu","id":30104974591533057,"from_user_id":782692,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"128028225","profile_image_url":"http://a1.twimg.com/profile_images/1224994593/Coding_Drunk_normal.jpg","created_at":"Wed, 26 Jan 2011 03:28:04 +0000","from_user":"chewedwire","id_str":"30104657267265536","metadata":{"result_type":"recent"},"to_user_id":177539201,"text":"@tomheon I always loved the pattern matching in SML and it looks like Haskell is MUCH better at it. I'm messing around now at tryhaskell.org","id":30104657267265536,"from_user_id":128028225,"to_user":"tomheon","geo":null,"iso_language_code":"en","to_user_id_str":"177539201","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"12834082","profile_image_url":"http://a3.twimg.com/profile_images/1083036140/mugshot_normal.png","created_at":"Wed, 26 Jan 2011 03:28:01 +0000","from_user":"ovillalon","id_str":"30104647213518848","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Paul Ryan solves the mystery of whatever happened to Eddie Haskell. #sotu","id":30104647213518848,"from_user_id":12834082,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"13540930","profile_image_url":"http://a1.twimg.com/profile_images/1205312219/23467_350321383101_821143101_5114147_3010041_n_normal.jpg","created_at":"Wed, 26 Jan 2011 03:26:02 +0000","from_user":"goodfox","id_str":"30104146455560192","metadata":{"result_type":"recent"},"to_user_id":10226179,"text":"@billykeene22 Bordeaux is one of my heroes. I was so excited when he accepted the invitation to campus. He's been a great friend to Haskell.","id":30104146455560192,"from_user_id":13540930,"to_user":"billykeene22","geo":null,"iso_language_code":"en","to_user_id_str":"10226179","source":"&lt;a href=&quot;http://www.ubertwitter.com/bb/download.php&quot; rel=&quot;nofollow&quot;&gt;\u00dcberTwitter&lt;/a&gt;"},{"from_user_id_str":"18616016","profile_image_url":"http://a2.twimg.com/profile_images/1173522726/214397343_normal.jpg","created_at":"Wed, 26 Jan 2011 03:25:18 +0000","from_user":"josej30","id_str":"30103962313031681","metadata":{"result_type":"recent"},"to_user_id":14870909,"text":"@cris7ian Ahh bueno multiparadigma ya es respetable :) Empezar\u00e9 a explotar la parte funcional de los lenguajes ahora #Haskell","id":30103962313031681,"from_user_id":18616016,"to_user":"Cris7ian","geo":null,"iso_language_code":"es","to_user_id_str":"14870909","source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"14870909","profile_image_url":"http://a2.twimg.com/profile_images/1176930429/oso_yo_normal.png","created_at":"Wed, 26 Jan 2011 03:23:43 +0000","from_user":"Cris7ian","id_str":"30103562360983553","metadata":{"result_type":"recent"},"to_user_id":18616016,"text":"@josej30 hahaha no, es multiparadigma y es bastante lazy. Nothing like haskell, pero s\u00ed, el de Flash","id":30103562360983553,"from_user_id":14870909,"to_user":"josej30","geo":null,"iso_language_code":"es","to_user_id_str":"18616016","source":"&lt;a href=&quot;http://www.echofon.com/&quot; rel=&quot;nofollow&quot;&gt;Echofon&lt;/a&gt;"},{"from_user_id_str":"2421643","profile_image_url":"http://a0.twimg.com/profile_images/1190361665/ernestgrumbles-17_normal.jpg","created_at":"Wed, 26 Jan 2011 03:20:24 +0000","from_user":"ernestgrumbles","id_str":"30102730756333568","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Wow... WolframAlpha did not know who Eddie Haskell is. Guess I'll never use that &quot;knowledge engine&quot; again.","id":30102730756333568,"from_user_id":2421643,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"128028225","profile_image_url":"http://a1.twimg.com/profile_images/1224994593/Coding_Drunk_normal.jpg","created_at":"Wed, 26 Jan 2011 03:14:21 +0000","from_user":"chewedwire","id_str":"30101204428132352","metadata":{"result_type":"recent"},"to_user_id":177539201,"text":"@tomheon How is Haskell better/different from CL or Scheme? I honestly don't know, although I'm becoming more curious.","id":30101204428132352,"from_user_id":128028225,"to_user":"tomheon","geo":null,"iso_language_code":"en","to_user_id_str":"177539201","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"13540930","profile_image_url":"http://a1.twimg.com/profile_images/1205312219/23467_350321383101_821143101_5114147_3010041_n_normal.jpg","created_at":"Wed, 26 Jan 2011 03:06:54 +0000","from_user":"goodfox","id_str":"30099329809129473","metadata":{"result_type":"recent"},"to_user_id":null,"text":"A day of vision &amp; speeches. #SOTU now. And a wonderful Haskell Convocation address earlier today by Sinte Gleske President Lionel Bordeaux.","id":30099329809129473,"from_user_id":13540930,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.ubertwitter.com/bb/download.php&quot; rel=&quot;nofollow&quot;&gt;\u00dcberTwitter&lt;/a&gt;"},{"from_user_id_str":"119185220","profile_image_url":"http://a0.twimg.com/profile_images/1089027228/dfg_normal.jpg","created_at":"Wed, 26 Jan 2011 03:03:38 +0000","from_user":"LaLiciouz_03","id_str":"30098510623805440","metadata":{"result_type":"recent"},"to_user_id":null,"text":"The Game with the girl room 330 Haskell follow us...","id":30098510623805440,"from_user_id":119185220,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"18616016","profile_image_url":"http://a2.twimg.com/profile_images/1173522726/214397343_normal.jpg","created_at":"Wed, 26 Jan 2011 02:57:25 +0000","from_user":"josej30","id_str":"30096946144215040","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Voy a extra\u00f1ar Haskell cuando regrese al mundo imperativo. Hay alg\u00fan lenguaje imperativo que tenga este poder funcional? #ci3661","id":30096946144215040,"from_user_id":18616016,"geo":null,"iso_language_code":"es","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"17671137","profile_image_url":"http://a2.twimg.com/profile_images/290264834/Haskell-logo-outer-glow_normal.png","created_at":"Wed, 26 Jan 2011 02:55:32 +0000","from_user":"Hackage","id_str":"30096471814574080","metadata":{"result_type":"recent"},"to_user_id":null,"text":"comonad-transformers 0.9.0, added by EdwardKmett: Haskell 98 comonad transformers http://bit.ly/h6xIsf","id":30096471814574080,"from_user_id":17671137,"geo":null,"iso_language_code":"no","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"177539201","profile_image_url":"http://a0.twimg.com/profile_images/1178368800/img_normal.jpeg","created_at":"Wed, 26 Jan 2011 02:48:12 +0000","from_user":"tomheon","id_str":"30094626920603649","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Every time I look at Haskell I love it more.","id":30094626920603649,"from_user_id":177539201,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"60792568","profile_image_url":"http://a0.twimg.com/profile_images/1203647517/glenda-flash_normal.jpg","created_at":"Wed, 26 Jan 2011 02:40:42 +0000","from_user":"r_takaishi","id_str":"30092735935422464","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Haskell\u3088\u308aD\u8a00\u8a9e\u304c\u4e0a\u3068\u306f\u601d\u308f\u306a\u304b\u3063\u305f\uff0e http://www.tiobe.com/index.php/content/paperinfo/tpci/index.html","id":30092735935422464,"from_user_id":60792568,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twmode.sf.net/&quot; rel=&quot;nofollow&quot;&gt;twmode&lt;/a&gt;"},{"from_user_id_str":"160145510","profile_image_url":"http://a0.twimg.com/profile_images/1218108166/going_galt_normal.jpg","created_at":"Wed, 26 Jan 2011 02:39:31 +0000","from_user":"wtp1787","id_str":"30092439653974018","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @KLSouth: Eddie Haskell Goes to Washington... &quot;You look really nice tonight, Ms Cleaver&quot;","id":30092439653974018,"from_user_id":160145510,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"96616016","profile_image_url":"http://a1.twimg.com/profile_images/1196978169/Picture0002_normal.jpg","created_at":"Wed, 26 Jan 2011 02:39:20 +0000","from_user":"MelissaRNMBA","id_str":"30092392203816960","metadata":{"result_type":"recent"},"to_user_id":14862975,"text":"@KLSouth At least Eddie Haskell was entertaining.","id":30092392203816960,"from_user_id":96616016,"to_user":"KLSouth","geo":null,"iso_language_code":"en","to_user_id_str":"14862975","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"14862975","profile_image_url":"http://a0.twimg.com/profile_images/421596393/kls_4_normal.JPG","created_at":"Wed, 26 Jan 2011 02:38:29 +0000","from_user":"KLSouth","id_str":"30092178327871489","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Eddie Haskell Goes to Washington... &quot;You look really nice tonight, Ms Cleaver&quot;","id":30092178327871489,"from_user_id":14862975,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"144546280","profile_image_url":"http://a1.twimg.com/a/1295051201/images/default_profile_1_normal.png","created_at":"Wed, 26 Jan 2011 02:36:17 +0000","from_user":"listwarenet","id_str":"30091626869161984","metadata":{"result_type":"recent"},"to_user_id":null,"text":"http://www.listware.net/201101/haskell-beginners/84641-haskell-beginners-wildcards-in-expressions.html Haskell-beginners - Wild","id":30091626869161984,"from_user_id":144546280,"geo":null,"iso_language_code":"no","to_user_id_str":null,"source":"&lt;a href=&quot;http://1e10.org/cloud/&quot; rel=&quot;nofollow&quot;&gt;1e10&lt;/a&gt;"},{"from_user_id_str":"24538048","profile_image_url":"http://a2.twimg.com/profile_images/1117267605/rope_normal.jpg","created_at":"Wed, 26 Jan 2011 02:23:14 +0000","from_user":"dbph","id_str":"30088341030440960","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @dnene: Skilled Calisthenics. Haskell code that outputs python which spits ruby which emits the haskell source. http://j.mp/YlQUL via @mfeathers","id":30088341030440960,"from_user_id":24538048,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"158951567","profile_image_url":"http://a3.twimg.com/profile_images/962721419/Logo_3_normal.jpg","created_at":"Wed, 26 Jan 2011 01:58:31 +0000","from_user":"YubaVetTech","id_str":"30082124207886336","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Dr. Haskell has just been awarded the prestigious Hayward Award for \u2018Excellence in Education\u2019. This award honors... http://fb.me/QgQCxd74","id":30082124207886336,"from_user_id":158951567,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.facebook.com/twitter&quot; rel=&quot;nofollow&quot;&gt;Facebook&lt;/a&gt;"},{"from_user_id_str":"158951567","profile_image_url":"http://a3.twimg.com/profile_images/962721419/Logo_3_normal.jpg","created_at":"Wed, 26 Jan 2011 01:56:04 +0000","from_user":"YubaVetTech","id_str":"30081505476743168","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Dr. Haskell has just been awarded the prestigous Haward Award for Excellence in Education. This award honors... http://fb.me/PC9mYmCR","id":30081505476743168,"from_user_id":158951567,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.facebook.com/twitter&quot; rel=&quot;nofollow&quot;&gt;Facebook&lt;/a&gt;"},{"from_user_id_str":"2331498","profile_image_url":"http://a3.twimg.com/profile_images/494632120/me_normal.jpg","created_at":"Wed, 26 Jan 2011 01:43:50 +0000","from_user":"Verus","id_str":"30078427155406848","metadata":{"result_type":"recent"},"to_user_id":79273052,"text":"@kami_joe \u3044\u3084\uff0c\u8ab2\u984c\u306f\u89e3\u6c7a\u5bfe\u8c61(\u30d1\u30ba\u30eb\u3068\u304b)\u3092\u4e0e\u3048\u3089\u308c\u3066\uff0c\u554f\u984c\u5b9a\u7fa9\u3068\u30d7\u30ed\u30b0\u30e9\u30df\u30f3\u30b0(\u6307\u5b9a\u8a00\u8a9e\u306fC++\u3082\u3057\u304f\u306fJava)\u3068\u3044\u3046\u3044\u308f\u3070\u666e\u901a\u306a\u8ab2\u984c\u3067\u306f\u3042\u308b\u3093\u3060\u3051\u3069\uff0e\u95a2\u6570\u578b\u8a00\u8a9e\u306fHaskell\u306e\u6388\u696d\u304c\u307e\u305f\u5225\u306b\u3042\u308b\u306e\uff0e","id":30078427155406848,"from_user_id":2331498,"to_user":"kami_joe","geo":null,"iso_language_code":"ja","to_user_id_str":"79273052","source":"&lt;a href=&quot;http://itunes.apple.com/us/app/twitter/id409789998?mt=12&quot; rel=&quot;nofollow&quot;&gt;Twitter for Mac&lt;/a&gt;"},{"from_user_id_str":"79151233","profile_image_url":"http://a2.twimg.com/a/1295051201/images/default_profile_2_normal.png","created_at":"Wed, 26 Jan 2011 01:40:37 +0000","from_user":"cz_newdrafts","id_str":"30077617361125376","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Haskell programming language http://bit.ly/gpPAwB","id":30077617361125376,"from_user_id":79151233,"geo":null,"iso_language_code":"no","to_user_id_str":null,"source":"&lt;a href=&quot;http://tommorris.org/&quot; rel=&quot;nofollow&quot;&gt;tommorris' hacksample&lt;/a&gt;"},{"from_user_id_str":"2331498","profile_image_url":"http://a3.twimg.com/profile_images/494632120/me_normal.jpg","created_at":"Wed, 26 Jan 2011 01:02:57 +0000","from_user":"Verus","id_str":"30068139416879104","metadata":{"result_type":"recent"},"to_user_id":9252720,"text":"@shukukei Java\u3068C\u306f\u3042\u308b\u7a0b\u5ea6\u66f8\u3051\u3066\u3042\u305f\u308a\u307e\u3048\u306a\u3068\u3053\u308d\u304c\u3042\u308b\u304b\u3089\u306a\u30fc\uff0ePython\u306f\u500b\u4eba\u7684\u306b\u611f\u899a\u304c\u5408\u308f\u306a\u3044\uff0e\u611f\u899a\u306a\u306e\u3067\uff0c\u3082\u3046\u3069\u3046\u3057\u3088\u3046\u3082\u306a\u3044\uff57 \u3044\u307e\u306fScala\u3068Haskell\u3092\u3082\u3063\u3068\u6975\u3081\u305f\u3044\u3068\u3053\u308d\uff0e","id":30068139416879104,"from_user_id":2331498,"to_user":"shukukei","geo":null,"iso_language_code":"ja","to_user_id_str":"9252720","source":"&lt;a href=&quot;http://itunes.apple.com/us/app/twitter/id409789998?mt=12&quot; rel=&quot;nofollow&quot;&gt;Twitter for Mac&lt;/a&gt;"},{"from_user_id_str":"2781460","profile_image_url":"http://a0.twimg.com/profile_images/82526625/.joeyicon_normal.jpg","created_at":"Wed, 26 Jan 2011 01:02:35 +0000","from_user":"joeyhess","id_str":"30068046538219520","metadata":{"result_type":"recent"},"to_user_id":null,"text":"just figured out that I can use parameterized types to remove a dependency loop in git-annex's type definitions. whee #haskell","id":30068046538219520,"from_user_id":2781460,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://identi.ca&quot; rel=&quot;nofollow&quot;&gt;identica&lt;/a&gt;"},{"from_user_id_str":"144546280","profile_image_url":"http://a1.twimg.com/a/1295051201/images/default_profile_1_normal.png","created_at":"Wed, 26 Jan 2011 00:54:22 +0000","from_user":"listwarenet","id_str":"30065977920061440","metadata":{"result_type":"recent"},"to_user_id":null,"text":"http://www.listware.net/201101/haskell-beginners/84466-haskell-beginners-bytestring-question.html Haskell-beginners - Bytestrin","id":30065977920061440,"from_user_id":144546280,"geo":null,"iso_language_code":"no","to_user_id_str":null,"source":"&lt;a href=&quot;http://1e10.org/cloud/&quot; rel=&quot;nofollow&quot;&gt;1e10&lt;/a&gt;"},{"from_user_id_str":"1291845","profile_image_url":"http://a0.twimg.com/profile_images/1225743404/ThinOxygen-small-opaque-solidarity_normal.png","created_at":"Wed, 26 Jan 2011 00:52:07 +0000","from_user":"_aaron_","id_str":"30065412242669568","metadata":{"result_type":"recent"},"to_user_id":null,"text":"wanted: librly licensed high level native compiled lang with min runtime (otherwise cobra/mono would be perfect) for win. lua? haskell? ooc?","id":30065412242669568,"from_user_id":1291845,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"5912444","profile_image_url":"http://a2.twimg.com/profile_images/546261026/ssf0xg11_normal.jpg","created_at":"Wed, 26 Jan 2011 00:45:45 +0000","from_user":"shelarcy","id_str":"30063810773516288","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @Hackage: download 0.3.1.1, added by MagnusTherning: High-level file download based on URLs http://bit.ly/eHfiJB","id":30063810773516288,"from_user_id":5912444,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"135993","profile_image_url":"http://a2.twimg.com/profile_images/1190667086/myface2010small_normal.jpg","created_at":"Wed, 26 Jan 2011 00:41:00 +0000","from_user":"kudzu_naoki","id_str":"30062613287141376","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @tanakh: \u9b54\u6cd5Haskell\u5c11\u5973\u5019\u88dc\u3092\u63a2\u3059\u306e\u3082\u5927\u5909\u306a\u3093\u3060","id":30062613287141376,"from_user_id":135993,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.hootsuite.com&quot; rel=&quot;nofollow&quot;&gt;HootSuite&lt;/a&gt;"},{"from_user_id_str":"52620546","profile_image_url":"http://a1.twimg.com/profile_images/434693356/twitter-icon_normal.png","created_at":"Wed, 26 Jan 2011 00:40:25 +0000","from_user":"omasanori","id_str":"30062465656033280","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u9b54\u6cd5Haskell\u5c11\u5973\u306e\u4e00\u65e5\u306fGHC HEAD\u306e\u30d3\u30eb\u30c9\u304b\u3089\u59cb\u307e\u308b","id":30062465656033280,"from_user_id":52620546,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.movatwi.jp&quot; rel=&quot;nofollow&quot;&gt;www.movatwi.jp&lt;/a&gt;"},{"from_user_id_str":"52620546","profile_image_url":"http://a1.twimg.com/profile_images/434693356/twitter-icon_normal.png","created_at":"Wed, 26 Jan 2011 00:37:12 +0000","from_user":"omasanori","id_str":"30061656331526144","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @tanakh: \u50d5\u3068\u5951\u7d04\u3057\u3066\u9b54\u6cd5Haskell\u5c11\u5973\u306b\u306a\u308d\u3046\u3088\uff01","id":30061656331526144,"from_user_id":52620546,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.hootsuite.com&quot; rel=&quot;nofollow&quot;&gt;HootSuite&lt;/a&gt;"},{"from_user_id_str":"135993","profile_image_url":"http://a2.twimg.com/profile_images/1190667086/myface2010small_normal.jpg","created_at":"Wed, 26 Jan 2011 00:35:42 +0000","from_user":"kudzu_naoki","id_str":"30061282665168896","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @tanakh: \u50d5\u3068\u5951\u7d04\u3057\u3066\u9b54\u6cd5Haskell\u5c11\u5973\u306b\u306a\u308d\u3046\u3088\uff01","id":30061282665168896,"from_user_id":135993,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.hootsuite.com&quot; rel=&quot;nofollow&quot;&gt;HootSuite&lt;/a&gt;"},{"from_user_id_str":"1631333","profile_image_url":"http://a1.twimg.com/profile_images/81268862/profile300_normal.jpg","created_at":"Wed, 26 Jan 2011 00:30:02 +0000","from_user":"qnighy","id_str":"30059855884582913","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @tanakh: \u50d5\u3068\u5951\u7d04\u3057\u3066\u9b54\u6cd5Haskell\u5c11\u5973\u306b\u306a\u308d\u3046\u3088\uff01","id":30059855884582913,"from_user_id":1631333,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.hootsuite.com&quot; rel=&quot;nofollow&quot;&gt;HootSuite&lt;/a&gt;"},{"from_user_id_str":"9093754","profile_image_url":"http://a1.twimg.com/profile_images/99435906/PHD_3d_col_blk_normal.jpg","created_at":"Wed, 26 Jan 2011 00:26:20 +0000","from_user":"phdwine","id_str":"30058925516656640","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Last weekend of Tri Nations Tasting with PHD wines at Haskell Vineyards. Hope you didn't miss the Pinot Noir tasting last week !","id":30058925516656640,"from_user_id":9093754,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"2119923","profile_image_url":"http://a2.twimg.com/profile_images/1096701078/djayprofile_normal.jpg","created_at":"Wed, 26 Jan 2011 00:21:14 +0000","from_user":"djay75","id_str":"30057639543050240","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @dnene: Skilled Calisthenics. Haskell code that outputs python which spits ruby which emits the haskell source. http://j.mp/YlQUL via @mfeathers","id":30057639543050240,"from_user_id":2119923,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"134323731","profile_image_url":"http://a2.twimg.com/profile_images/1225818824/IMG00518-20110125-1547_normal.jpg","created_at":"Wed, 26 Jan 2011 00:19:30 +0000","from_user":"PrinceOfBrkeley","id_str":"30057205554216960","metadata":{"result_type":"recent"},"to_user_id":167093027,"text":"@PayThaPrince go to haskell.","id":30057205554216960,"from_user_id":134323731,"to_user":"PayThaPrince","geo":null,"iso_language_code":"en","to_user_id_str":"167093027","source":"&lt;a href=&quot;http://blackberry.com/twitter&quot; rel=&quot;nofollow&quot;&gt;Twitter for BlackBerry\u00ae&lt;/a&gt;"},{"from_user_id_str":"705857","profile_image_url":"http://a1.twimg.com/profile_images/429483912/ben_twitter_normal.jpg","created_at":"Wed, 26 Jan 2011 00:03:28 +0000","from_user":"bennadel","id_str":"30053166972141569","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Using #Homebrew to install Haskell - the last of the Seven Languages (in Seven Weeks) http://bit.ly/eA9Cv1 This has been some journey.","id":30053166972141569,"from_user_id":705857,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"251466","profile_image_url":"http://a2.twimg.com/profile_images/1194100934/pass_normal.jpg","created_at":"Wed, 26 Jan 2011 00:02:54 +0000","from_user":"simonszu","id_str":"30053025502466048","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Ouh yeah! Ich werde doch produktiv sein, diese Semesterferien. Ich werde funktional Programmieren lernen. #haskell, Baby.","id":30053025502466048,"from_user_id":251466,"geo":null,"iso_language_code":"de","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.echofon.com/&quot; rel=&quot;nofollow&quot;&gt;Echofon&lt;/a&gt;"},{"from_user_id_str":"357786","profile_image_url":"http://a0.twimg.com/profile_images/612044841/FM_2010_normal.jpg","created_at":"Tue, 25 Jan 2011 23:59:13 +0000","from_user":"diligiant","id_str":"30052100973006848","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @paulrbrown: &quot;...we only discovered a single bug after compilation.&quot; (http://t.co/K0wlEYz) #haskell","id":30052100973006848,"from_user_id":357786,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://itunes.apple.com/us/app/twitter/id409789998?mt=12&quot; rel=&quot;nofollow&quot;&gt;Twitter for Mac&lt;/a&gt;"},{"from_user_id_str":"101597523","profile_image_url":"http://a1.twimg.com/profile_images/1206183256/2010-12-12-204902_normal.jpg","created_at":"Tue, 25 Jan 2011 23:54:46 +0000","from_user":"wlad_kent","id_str":"30050977964892160","metadata":{"result_type":"recent"},"to_user_id":86297184,"text":"@Nilson_Neto Isso eh bem basico. quando vc estiver estudando recurs\u00e3o em Haskell, ai vc vai ver oq eh papo de nerd - kkk - 1\u00ba periodo isso.","id":30050977964892160,"from_user_id":101597523,"to_user":"Nilson_Neto","geo":null,"iso_language_code":"pt","to_user_id_str":"86297184","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"144546280","profile_image_url":"http://a1.twimg.com/a/1295051201/images/default_profile_1_normal.png","created_at":"Tue, 25 Jan 2011 23:51:22 +0000","from_user":"listwarenet","id_str":"30050123383832577","metadata":{"result_type":"recent"},"to_user_id":null,"text":"http://www.listware.net/201101/haskell-cafe/84336-haskell-cafe-monomorphic-let-bindings-and-darcs.html Haskell-cafe - Monomorph","id":30050123383832577,"from_user_id":144546280,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://1e10.org/cloud/&quot; rel=&quot;nofollow&quot;&gt;1e10&lt;/a&gt;"},{"from_user_id_str":"5776901","profile_image_url":"http://a0.twimg.com/profile_images/472682157/lucabw_normal.JPG","created_at":"Tue, 25 Jan 2011 23:48:40 +0000","from_user":"lsbardel","id_str":"30049446469312512","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Very interesting technology stack these guys use http://bit.ly/ghAjS7 #python #redis #haskell","id":30049446469312512,"from_user_id":5776901,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"3005901","profile_image_url":"http://a0.twimg.com/profile_images/278943006/Lone_Pine_Peak_-_Peter_200x200_normal.jpg","created_at":"Tue, 25 Jan 2011 23:45:48 +0000","from_user":"pmonks","id_str":"30048721110573056","metadata":{"result_type":"recent"},"to_user_id":203834278,"text":"@techielicous Haskell: http://bit.ly/gy3oFi ;-)","id":30048721110573056,"from_user_id":3005901,"to_user":"techielicous","geo":null,"iso_language_code":"en","to_user_id_str":"203834278","source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"162697074","profile_image_url":"http://a2.twimg.com/profile_images/826205838/ryan3_normal.jpg","created_at":"Tue, 25 Jan 2011 23:44:47 +0000","from_user":"TheRonaldMCD","id_str":"30048468781244416","metadata":{"result_type":"recent"},"to_user_id":null,"text":"I'm at Aldi Food Market (4122 Gaston Ave, Haskell, Dallas) http://4sq.com/ekqRY7","id":30048468781244416,"from_user_id":162697074,"geo":null,"iso_language_code":"no","to_user_id_str":null,"source":"&lt;a href=&quot;http://foursquare.com&quot; rel=&quot;nofollow&quot;&gt;foursquare&lt;/a&gt;"},{"from_user_id_str":"203834278","profile_image_url":"http://a0.twimg.com/profile_images/1223375080/me_normal.jpg","created_at":"Tue, 25 Jan 2011 23:44:04 +0000","from_user":"techielicous","id_str":"30048286589067264","metadata":{"result_type":"recent"},"to_user_id":3005901,"text":"@pmonks I was thinking Haskell or Scheme","id":30048286589067264,"from_user_id":203834278,"to_user":"pmonks","geo":null,"iso_language_code":"en","to_user_id_str":"3005901","source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"537690","profile_image_url":"http://a3.twimg.com/profile_images/45665122/nushiostamp_normal.jpg","created_at":"Tue, 25 Jan 2011 23:38:14 +0000","from_user":"nushio","id_str":"30046818658164737","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u305d\u3046\u3044\u3084\u5951\u7d04\u306b\u3088\u308b\u30d7\u30ed\u30b0\u30e9\u30df\u30f3\u30b0\u3068\u304b\u3042\u3063\u305f\u306a\u3002Haskell\u306a\u3093\u304b\u3088\u308a\u3042\u3063\u3061\u306e\u65b9\u304c\u9b54\u6cd5\u5c11\u5973\u547c\u3070\u308f\u308a\u306b\u3075\u3055\u308f\u3057\u3044\u3002","id":30046818658164737,"from_user_id":537690,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"181192","profile_image_url":"http://a2.twimg.com/profile_images/1089890701/q530888600_9828_normal.jpg","created_at":"Tue, 25 Jan 2011 23:38:03 +0000","from_user":"aodag","id_str":"30046772223016960","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @omasanori: \u300c\u3082\u3046\u4f55\u5e74\u3082Haskell\u306e\u3053\u3068\u3057\u304b\u8003\u3048\u3066\u306a\u304b\u3063\u305f\u304b\u3089\u306a\u3001\u30eb\u30fc\u30d7\u306e\u4f7f\u3044\u65b9\u5fd8\u308c\u3066\u305f\u300d","id":30046772223016960,"from_user_id":181192,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.movatwi.jp&quot; rel=&quot;nofollow&quot;&gt;www.movatwi.jp&lt;/a&gt;"},{"from_user_id_str":"5886055","profile_image_url":"http://a3.twimg.com/profile_images/85531669/ichi_normal.jpg","created_at":"Tue, 25 Jan 2011 23:37:53 +0000","from_user":"kanaya","id_str":"30046729243983873","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u9e97\u3057\u3044\u3002\u201c@omasanori: \u300c\u3082\u3046\u4f55\u5e74\u3082Haskell\u306e\u3053\u3068\u3057\u304b\u8003\u3048\u3066\u306a\u304b\u3063\u305f\u304b\u3089\u306a\u3001\u30eb\u30fc\u30d7\u306e\u4f7f\u3044\u65b9\u5fd8\u308c\u3066\u305f\u300d\u201d","id":30046729243983873,"from_user_id":5886055,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://itunes.apple.com/app/twitter/id333903271?mt=8&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPad&lt;/a&gt;"},{"from_user_id_str":"52620546","profile_image_url":"http://a1.twimg.com/profile_images/434693356/twitter-icon_normal.png","created_at":"Tue, 25 Jan 2011 23:36:26 +0000","from_user":"omasanori","id_str":"30046367187476481","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u300c\u3082\u3046\u4f55\u5e74\u3082Haskell\u306e\u3053\u3068\u3057\u304b\u8003\u3048\u3066\u306a\u304b\u3063\u305f\u304b\u3089\u306a\u3001\u30eb\u30fc\u30d7\u306e\u4f7f\u3044\u65b9\u5fd8\u308c\u3066\u305f\u300d","id":30046367187476481,"from_user_id":52620546,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.movatwi.jp&quot; rel=&quot;nofollow&quot;&gt;www.movatwi.jp&lt;/a&gt;"},{"from_user_id_str":"1659992","profile_image_url":"http://a1.twimg.com/profile_images/504488750/1_normal.jpg","created_at":"Tue, 25 Jan 2011 23:16:13 +0000","from_user":"finalfusion","id_str":"30041278544609280","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @necocen: Haskell\u306e\u30df\u30b5\u30ef\u3001\u3068\u3044\u3046\u3082\u306e\u3092\u8003\u3048\u3066\u307f\u3066\u3071\u3063\u3068\u3057\u306a\u3044","id":30041278544609280,"from_user_id":1659992,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"272513","profile_image_url":"http://a2.twimg.com/profile_images/320244078/Mike_Painting2_normal.png","created_at":"Tue, 25 Jan 2011 23:05:09 +0000","from_user":"mikehadlow","id_str":"30038492373319680","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Just written the same simple program in C#, F# and Haskell: 18, 12 and 9 LoC respectively. And I'm much better at C# than F# or Haskell.","id":30038492373319680,"from_user_id":272513,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"89393264","profile_image_url":"http://a0.twimg.com/profile_images/1169486472/020_portland_me_normal.jpg","created_at":"Tue, 25 Jan 2011 23:01:28 +0000","from_user":"newsportlandme","id_str":"30037564589084673","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Governor's Choice to Run Maine DOC Under Scrutiny - MPBN: State Rep. Anne Haskell, a Portland Democrat, says Mai... http://bit.ly/fO30gC","id":30037564589084673,"from_user_id":89393264,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"38138","profile_image_url":"http://a3.twimg.com/profile_images/1212565885/Screen_shot_2011-01-11_at_5.28.47_PM_normal.png","created_at":"Tue, 25 Jan 2011 22:59:55 +0000","from_user":"michaelneale","id_str":"30037174615281664","metadata":{"result_type":"recent"},"to_user_id":null,"text":"The haskell EvilMangler http://t.co/P2Tls7J","id":30037174615281664,"from_user_id":38138,"geo":null,"iso_language_code":"no","to_user_id_str":null,"source":"&lt;a href=&quot;http://itunes.apple.com/us/app/twitter/id409789998?mt=12&quot; rel=&quot;nofollow&quot;&gt;Twitter for Mac&lt;/a&gt;"},{"from_user_id_str":"45692","profile_image_url":"http://a3.twimg.com/profile_images/1177741507/dogkarno_r_normal.jpg","created_at":"Tue, 25 Jan 2011 22:45:06 +0000","from_user":"karno","id_str":"30033448286552064","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Haskell\u3063\u3066\u95a2\u6570\u306b\u30ab\u30ec\u30fc\u7c89\u3076\u3061\u8fbc\u3080\u3068\u304b\u306a\u3093\u3068\u304b","id":30033448286552064,"from_user_id":45692,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://yubitter.com/&quot; rel=&quot;nofollow&quot;&gt;yubitter&lt;/a&gt;"},{"from_user_id_str":"27605","profile_image_url":"http://a2.twimg.com/profile_images/15826632/meron_normal.jpg","created_at":"Tue, 25 Jan 2011 22:44:23 +0000","from_user":"celeron1ghz","id_str":"30033268761956352","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @necocen: Haskell\u306e\u30df\u30b5\u30ef\u3001\u3068\u3044\u3046\u3082\u306e\u3092\u8003\u3048\u3066\u307f\u3066\u3071\u3063\u3068\u3057\u306a\u3044","id":30033268761956352,"from_user_id":27605,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"12901","profile_image_url":"http://a1.twimg.com/profile_images/56091349/haruhi_nagato-Y_normal.jpg","created_at":"Tue, 25 Jan 2011 22:43:30 +0000","from_user":"necocen","id_str":"30033044035346432","metadata":{"result_type":"recent"},"to_user_id":null,"text":"\u307e\u3042Haskell\u77e5\u3089\u3093\u3057\u306d","id":30033044035346432,"from_user_id":12901,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"12901","profile_image_url":"http://a1.twimg.com/profile_images/56091349/haruhi_nagato-Y_normal.jpg","created_at":"Tue, 25 Jan 2011 22:42:54 +0000","from_user":"necocen","id_str":"30032894856531968","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Haskell\u306e\u30df\u30b5\u30ef\u3001\u3068\u3044\u3046\u3082\u306e\u3092\u8003\u3048\u3066\u307f\u3066\u3071\u3063\u3068\u3057\u306a\u3044","id":30032894856531968,"from_user_id":12901,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"10821270","profile_image_url":"http://a0.twimg.com/profile_images/1195474259/Salto_Marlon_normal.jpg","created_at":"Tue, 25 Jan 2011 22:35:09 +0000","from_user":"jjedMoriAnktah","id_str":"30030942106025984","metadata":{"result_type":"recent"},"to_user_id":null,"text":"&quot;A Haskell program that outputs a Python program that outputs a Ruby program that outputs the original Haskell program&quot; http://is.gd/E6Julu","id":30030942106025984,"from_user_id":10821270,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"7554762","profile_image_url":"http://a0.twimg.com/profile_images/100515212/ajay-photo_normal.jpg","created_at":"Tue, 25 Jan 2011 22:34:30 +0000","from_user":"comatose_kid","id_str":"30030780205899776","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @bumptech: Bump Dev Blog - Why we use Haskell at Bump http://devblog.bu.mp/haskell-at-bump","id":30030780205899776,"from_user_id":7554762,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"148474705","profile_image_url":"http://a0.twimg.com/profile_images/1119234716/fur_hat_-_gilbeys_vodka_-_life_-_11-30-1962_normal.JPG","created_at":"Tue, 25 Jan 2011 22:29:19 +0000","from_user":"landmvintage","id_str":"30029476003840000","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @faerymoongodess: Magnificent Miriam Haskell Baroque Pearl Necklace by @MercyMadge http://etsy.me/hqRl51","id":30029476003840000,"from_user_id":148474705,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"37715508","profile_image_url":"http://a1.twimg.com/profile_images/1207891411/ballerina_normal.jpg","created_at":"Tue, 25 Jan 2011 22:24:52 +0000","from_user":"faerymoongodess","id_str":"30028356326002688","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Magnificent Miriam Haskell Baroque Pearl Necklace by @MercyMadge http://etsy.me/hqRl51","id":30028356326002688,"from_user_id":37715508,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"17671137","profile_image_url":"http://a2.twimg.com/profile_images/290264834/Haskell-logo-outer-glow_normal.png","created_at":"Tue, 25 Jan 2011 22:17:16 +0000","from_user":"Hackage","id_str":"30026442456694784","metadata":{"result_type":"recent"},"to_user_id":null,"text":"base16-bytestring 0.1.0.0, added by BryanOSullivan: Fast base16 (hex) encoding and deconding for ByteStrings http://bit.ly/eu75TN","id":30026442456694784,"from_user_id":17671137,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"199750997","profile_image_url":"http://a3.twimg.com/sticky/default_profile_images/default_profile_2_normal.png","created_at":"Tue, 25 Jan 2011 22:12:07 +0000","from_user":"benreads","id_str":"30025146991382528","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Writing Systems Software in a Functional Language -- brief, but fun. I want to see how well they can make Systems Haskell perform at scale.","id":30025146991382528,"from_user_id":199750997,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"35359797","profile_image_url":"http://a1.twimg.com/profile_images/1173453785/48893_521140819_1896062_q_normal.jpg","created_at":"Tue, 25 Jan 2011 22:09:45 +0000","from_user":"jcawthorne1","id_str":"30024549265309696","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Just saw Jeff Haskell give the middle finger!! Lol awesome","id":30024549265309696,"from_user_id":35359797,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"13540930","profile_image_url":"http://a1.twimg.com/profile_images/1205312219/23467_350321383101_821143101_5114147_3010041_n_normal.jpg","created_at":"Tue, 25 Jan 2011 22:06:44 +0000","from_user":"goodfox","id_str":"30023790381498369","metadata":{"result_type":"recent"},"to_user_id":null,"text":"At the Haskell Convocation. (@ Haskell Indian Nations U Auditorium) http://4sq.com/eKKXyn","id":30023790381498369,"from_user_id":13540930,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://foursquare.com&quot; rel=&quot;nofollow&quot;&gt;foursquare&lt;/a&gt;"},{"from_user_id_str":"14674418","profile_image_url":"http://a2.twimg.com/profile_images/238230125/IMG_1030-1_normal.jpg","created_at":"Tue, 25 Jan 2011 22:02:31 +0000","from_user":"sanityinc","id_str":"30022731919523840","metadata":{"result_type":"recent"},"to_user_id":371289,"text":"@xshay Haskell's great, but Clojure's similarly lazy in all the ways that matter, and is more practical for day-to-day use.","id":30022731919523840,"from_user_id":14674418,"to_user":"xshay","geo":null,"iso_language_code":"en","to_user_id_str":"371289","source":"&lt;a href=&quot;http://www.echofon.com/&quot; rel=&quot;nofollow&quot;&gt;Echofon&lt;/a&gt;"},{"from_user_id_str":"371289","profile_image_url":"http://a2.twimg.com/profile_images/1113482439/me-brisbane_normal.jpg","created_at":"Tue, 25 Jan 2011 21:58:29 +0000","from_user":"xshay","id_str":"30021714444292096","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Just made a lazy sequence of prime numbers in haskell. I'm smitten.","id":30021714444292096,"from_user_id":371289,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://itunes.apple.com/us/app/twitter/id409789998?mt=12&quot; rel=&quot;nofollow&quot;&gt;Twitter for Mac&lt;/a&gt;"},{"from_user_id_str":"199453873","profile_image_url":"http://a3.twimg.com/a/1294785484/images/default_profile_3_normal.png","created_at":"Tue, 25 Jan 2011 21:48:40 +0000","from_user":"stackfeed","id_str":"30019243982454784","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Practical Scala reference manual, for searching things like method names: Hello, \n\nInspired by\nHaskell API Searc... http://bit.ly/g4zWZQ","id":30019243982454784,"from_user_id":199453873,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"17489366","profile_image_url":"http://a3.twimg.com/sticky/default_profile_images/default_profile_2_normal.png","created_at":"Tue, 25 Jan 2011 21:45:32 +0000","from_user":"aapnoot","id_str":"30018455189065728","metadata":{"result_type":"recent"},"to_user_id":null,"text":"download 0.3.1, added by MagnusTherning: High-level file download based on URLs http://bit.ly/i8mYvi","id":30018455189065728,"from_user_id":17489366,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"17489366","profile_image_url":"http://a3.twimg.com/sticky/default_profile_images/default_profile_2_normal.png","created_at":"Tue, 25 Jan 2011 21:45:31 +0000","from_user":"aapnoot","id_str":"30018452601180160","metadata":{"result_type":"recent"},"to_user_id":null,"text":"download 0.3.1.1, added by MagnusTherning: High-level file download based on URLs http://bit.ly/eHfiJB","id":30018452601180160,"from_user_id":17489366,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"17671137","profile_image_url":"http://a2.twimg.com/profile_images/290264834/Haskell-logo-outer-glow_normal.png","created_at":"Tue, 25 Jan 2011 21:45:31 +0000","from_user":"Hackage","id_str":"30018451867176960","metadata":{"result_type":"recent"},"to_user_id":null,"text":"download 0.3.1, added by MagnusTherning: High-level file download based on URLs http://bit.ly/i8mYvi","id":30018451867176960,"from_user_id":17671137,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"138502705","profile_image_url":"http://a1.twimg.com/profile_images/1083845614/yclogo_normal.gif","created_at":"Tue, 25 Jan 2011 21:45:04 +0000","from_user":"newsyc100","id_str":"30018340839755777","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Haskell improves log processing 4x over Python http://devblog.bu.mp/haskell-at-bump (http://bit.ly/gQxxR8)","id":30018340839755777,"from_user_id":138502705,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://news.ycombinator.com&quot; rel=&quot;nofollow&quot;&gt;newsyc&lt;/a&gt;"},{"from_user_id_str":"1578246","profile_image_url":"http://a0.twimg.com/profile_images/59312315/avatar_simpson_small_normal.jpg","created_at":"Tue, 25 Jan 2011 21:43:32 +0000","from_user":"magthe","id_str":"30017953801969665","metadata":{"result_type":"recent"},"to_user_id":null,"text":"New version of download uploaded to #hackage #haskell","id":30017953801969665,"from_user_id":1578246,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://api.supertweet.net&quot; rel=&quot;nofollow&quot;&gt;MyAuth API Proxy&lt;/a&gt;"},{"from_user_id_str":"135838970","profile_image_url":"http://a2.twimg.com/profile_images/1079929891/logo_normal.png","created_at":"Tue, 25 Jan 2011 21:37:51 +0000","from_user":"reward999","id_str":"30016525180084224","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Found Great Dane (Main &amp; Haskell- Dallas): We found a great dane. 214-712-0000 http://bit.ly/fQ8iBw","id":30016525180084224,"from_user_id":135838970,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"137719265","profile_image_url":"http://a2.twimg.com/profile_images/1092224079/8__4__normal.jpg","created_at":"Tue, 25 Jan 2011 21:34:22 +0000","from_user":"WeiMatas","id_str":"30015646020411392","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Fourth day Rez party Eddie Haskell County in second life \u2013 which took place in cabaret Tadd","id":30015646020411392,"from_user_id":137719265,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://dlvr.it&quot; rel=&quot;nofollow&quot;&gt;dlvr.it&lt;/a&gt;"},{"from_user_id_str":"144546280","profile_image_url":"http://a1.twimg.com/a/1295051201/images/default_profile_1_normal.png","created_at":"Tue, 25 Jan 2011 21:33:21 +0000","from_user":"listwarenet","id_str":"30015392571195392","metadata":{"result_type":"recent"},"to_user_id":null,"text":"http://www.listware.net/201101/haskell-cafe/83889-haskell-cafe-gpl-license-of-h-matrix-and-prelude-numeric.html Haskell-cafe -","id":30015392571195392,"from_user_id":144546280,"geo":null,"iso_language_code":"no","to_user_id_str":null,"source":"&lt;a href=&quot;http://1e10.org/cloud/&quot; rel=&quot;nofollow&quot;&gt;1e10&lt;/a&gt;"}],"max_id":30121530767708160,"since_id":0,"refresh_url":"?since_id=30121530767708160&q=haskell","next_page":"?page=2&max_id=30121530767708160&rpp=100&q=haskell","results_per_page":100,"page":1,"completed_in":1.195569,"since_id_str":"0","max_id_str":"30121530767708160","query":"haskell"}
benchmarks/json-data/twitter20.jsondeleted−1
@@ -1 +0,0 @@
1−{"results":[{"from_user_id_str":"166199691","profile_image_url":"http://a2.twimg.com/profile_images/1252958188/38_normal.jpg","created_at":"Fri, 25 Feb 2011 17:41:26 +0000","from_user":"_classicc","id_str":"41191052790603776","metadata":{"result_type":"recent"},"to_user_id":null,"text":"my twitter is actin slow today.","id":41191052790603776,"from_user_id":166199691,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"138835410","profile_image_url":"http://a1.twimg.com/profile_images/1250985094/243321801_normal.jpg","created_at":"Fri, 25 Feb 2011 17:41:26 +0000","from_user":"amereronday","id_str":"41191050307567616","metadata":{"result_type":"recent"},"to_user_id":null,"text":"twitter jail, here i come.","id":41191050307567616,"from_user_id":138835410,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"359548","profile_image_url":"http://a2.twimg.com/profile_images/53612334/don_otvos_normal.jpg","created_at":"Fri, 25 Feb 2011 17:41:26 +0000","from_user":"donnyo","id_str":"41191050110451712","metadata":{"result_type":"recent"},"to_user_id":7074534,"text":"@stlsmallbiz I see there is currently a Twitter promo too....tempting....","id":41191050110451712,"from_user_id":359548,"to_user":"stlsmallbiz","geo":null,"iso_language_code":"en","place":{"id":"82b7b2f97b12261d","type":"poi","full_name":"Yammer Inc, San Francisco"},"to_user_id_str":"7074534","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"122523770","profile_image_url":"http://a0.twimg.com/profile_images/1073533262/11646_1076222405045_1810798478_156114_3663737_n_normal.jpg","created_at":"Fri, 25 Feb 2011 17:41:26 +0000","from_user":"msBreChan","id_str":"41191049720238080","metadata":{"result_type":"recent"},"to_user_id":null,"text":"so twitter gt spam now -_-","id":41191049720238080,"from_user_id":122523770,"geo":{"type":"Point","coordinates":[35.2213,-80.8276]},"iso_language_code":"en","place":{"id":"4d5ed95f830e9b41","type":"neighborhood","full_name":"Elizabeth, Charlotte"},"to_user_id_str":null,"source":"&lt;a href=&quot;http://mobile.twitter.com&quot; rel=&quot;nofollow&quot;&gt;Twitter for Android&lt;/a&gt;"},{"from_user_id_str":"229024950","profile_image_url":"http://a3.twimg.com/sticky/default_profile_images/default_profile_6_normal.png","created_at":"Fri, 25 Feb 2011 17:41:25 +0000","from_user":"NinaMaechik","id_str":"41191047853912064","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Glad I can remember my twitter password! LOL! Hugs to Nick from his aunties...","id":41191047853912064,"from_user_id":229024950,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"215545822","profile_image_url":"http://a2.twimg.com/profile_images/1239909540/RTL_normal.png","created_at":"Fri, 25 Feb 2011 17:41:25 +0000","from_user":"RightToLaugh","id_str":"41191047371558912","metadata":{"result_type":"recent"},"to_user_id":null,"text":"#Bacon wrapped dates http://bit.ly/hUxVC9 Just like my grandma used to make http://twitter.com/#","id":41191047371558912,"from_user_id":215545822,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"217845526","profile_image_url":"http://a0.twimg.com/sticky/default_profile_images/default_profile_3_normal.png","created_at":"Fri, 25 Feb 2011 17:41:25 +0000","from_user":"TheShoeLooker","id_str":"41191047052804096","metadata":{"result_type":"recent"},"to_user_id":38033240,"text":"@ShoeDazzle love love love to twitter or blog about your deals and shoes!\ntheshoelooker.blogspot.com","id":41191047052804096,"from_user_id":217845526,"to_user":"shoedazzle","geo":null,"iso_language_code":"en","to_user_id_str":"38033240","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"24953438","profile_image_url":"http://a3.twimg.com/profile_images/1181252763/76820_10150100014748783_677998782_7386695_4377006_n_normal.jpg","created_at":"Fri, 25 Feb 2011 17:41:25 +0000","from_user":"liljermaine32","id_str":"41191046025056256","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Twitter fam I gotta question 4 ya is texas south or midwest #arguments","id":41191046025056256,"from_user_id":24953438,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://mobile.twitter.com&quot; rel=&quot;nofollow&quot;&gt;Twitter for Android&lt;/a&gt;"},{"from_user_id_str":"122451024","profile_image_url":"http://a2.twimg.com/profile_images/1143400129/100706-ETCanada_201134_1__normal.jpg","created_at":"Fri, 25 Feb 2011 17:41:25 +0000","from_user":"Kim_DEon","id_str":"41191045161164801","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Help @CARE @EvaLongoria and ME use Twitter to change the lives of girls in poverty across the world! Ready? Go to http://TwitChange.com NOW!","id":41191045161164801,"from_user_id":122451024,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"128351479","profile_image_url":"http://a3.twimg.com/profile_images/1150198829/Kirby_Photo__edit__normal.JPG","created_at":"Fri, 25 Feb 2011 17:41:24 +0000","from_user":"TheDaveKirby","id_str":"41191043894493184","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Maybe its time to clean house...MY HOUSE http://bit.ly/ejG22P","id":41191043894493184,"from_user_id":128351479,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"87512773","profile_image_url":"http://a0.twimg.com/profile_images/1252511106/image_normal.jpg","created_at":"Fri, 25 Feb 2011 17:41:24 +0000","from_user":"supportthehood","id_str":"41191043206610946","metadata":{"result_type":"recent"},"to_user_id":2467330,"text":"@eastcoastmp3 #FF it's the way twitter works !!!","id":41191043206610946,"from_user_id":87512773,"to_user":"eastcoastmp3","geo":null,"iso_language_code":"en","to_user_id_str":"2467330","source":"&lt;a href=&quot;http://twitter.com/&quot; rel=&quot;nofollow&quot;&gt;Twitter for iPhone&lt;/a&gt;"},{"from_user_id_str":"149894545","profile_image_url":"http://a0.twimg.com/profile_images/1219334400/patrick_camo_normal.jpg","created_at":"Fri, 25 Feb 2011 17:41:24 +0000","from_user":"suburbpat","id_str":"41191040912330752","metadata":{"result_type":"recent"},"to_user_id":null,"text":"I havent had a rib session on twitter in a while.......I wanna Rib with a nigga with alot followers lol","id":41191040912330752,"from_user_id":149894545,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"97749622","profile_image_url":"http://a0.twimg.com/profile_images/1254640781/IMG1633A_normal.jpg","created_at":"Fri, 25 Feb 2011 17:41:24 +0000","from_user":"jrricardosantos","id_str":"41191040547430400","metadata":{"result_type":"recent"},"to_user_id":101017476,"text":"@yofzs pq tirou o CAPS LOCK? kkkk tava bem legal...hehehe eu estou no t\u00e9dio...kkk tbm estou no twitter e msn..aff!!","id":41191040547430400,"from_user_id":97749622,"to_user":"yofzs","geo":null,"iso_language_code":"en","to_user_id_str":"101017476","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"94381536","profile_image_url":"http://a1.twimg.com/profile_images/1174777929/41509_100001699300415_3521888_n_normal.jpg","created_at":"Fri, 25 Feb 2011 17:41:23 +0000","from_user":"DonNieves","id_str":"41191038978752512","metadata":{"result_type":"recent"},"to_user_id":151926400,"text":"@TiiH13 cheira meu ovo, no email, no orkut, no msn, no facebook, no twitter, no skype, no spark, no ICQ e no google talk","id":41191038978752512,"from_user_id":94381536,"to_user":"TiiH13","geo":null,"iso_language_code":"en","to_user_id_str":"151926400","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"211858432","profile_image_url":"http://a3.twimg.com/profile_images/1231906180/JonasBrothers_normal.jpg","created_at":"Fri, 25 Feb 2011 17:41:23 +0000","from_user":"OriginalJBfans","id_str":"41191038328651776","metadata":{"result_type":"recent"},"to_user_id":null,"text":"I literally forgot about this twitter... so whats occuring followers?","id":41191038328651776,"from_user_id":211858432,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"90317132","profile_image_url":"http://a3.twimg.com/profile_images/1230085056/254101635_normal.jpg","created_at":"Fri, 25 Feb 2011 17:41:23 +0000","from_user":"Just2smooth","id_str":"41191036936126464","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Wassup twitter","id":41191036936126464,"from_user_id":90317132,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://ubersocial.com&quot; rel=&quot;nofollow&quot;&gt;\u00dcberSocial&lt;/a&gt;"},{"from_user_id_str":"144771504","profile_image_url":"http://a1.twimg.com/profile_images/1243343836/image_normal.jpg","created_at":"Fri, 25 Feb 2011 17:41:23 +0000","from_user":"ima_b_b_badman","id_str":"41191036638339072","metadata":{"result_type":"recent"},"to_user_id":null,"text":"i been M.I.A. all day twitter my bad","id":41191036638339072,"from_user_id":144771504,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"207922664","profile_image_url":"http://a2.twimg.com/profile_images/1237106108/258356167_normal.jpg","created_at":"Fri, 25 Feb 2011 17:41:22 +0000","from_user":"itsthecarter_","id_str":"41191036013391873","metadata":{"result_type":"recent"},"to_user_id":null,"text":"twitter is a stupid addiction.","id":41191036013391873,"from_user_id":207922664,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://ubersocial.com&quot; rel=&quot;nofollow&quot;&gt;\u00dcberSocial&lt;/a&gt;"},{"from_user_id_str":"150000649","profile_image_url":"http://a0.twimg.com/profile_images/1237789059/belllaa_normal.jpg","created_at":"Fri, 25 Feb 2011 17:41:22 +0000","from_user":"angelicabrvo","id_str":"41191035707207680","metadata":{"result_type":"recent"},"to_user_id":null,"text":"que hubo twitter? huy que feoxd","id":41191035707207680,"from_user_id":150000649,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://blackberry.com/twitter&quot; rel=&quot;nofollow&quot;&gt;Twitter for BlackBerry\u00ae&lt;/a&gt;"},{"from_user_id_str":"185713003","profile_image_url":"http://a2.twimg.com/profile_images/1191421540/163229_177015295661467_154687431227587_492170_2147500_n_normal.jpg","created_at":"Fri, 25 Feb 2011 17:41:22 +0000","from_user":"downbytheshores","id_str":"41191033945595905","metadata":{"result_type":"recent"},"to_user_id":null,"text":"follow us on twitter\nwww.twitter.com/downbytheshores http://fb.me/DhDS915e","id":41191033945595905,"from_user_id":185713003,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.facebook.com/twitter&quot; rel=&quot;nofollow&quot;&gt;Facebook&lt;/a&gt;"}],"max_id":41191052790603776,"since_id":38643906774044672,"refresh_url":"?since_id=41191052790603776&q=twitter","next_page":"?page=2&max_id=41191052790603776&rpp=20&lang=en&q=twitter","results_per_page":20,"page":1,"completed_in":0.128719,"warning":"adjusted since_id to 38643906774044672 (), requested since_id was older than allowed -- since_id removed for pagination.","since_id_str":"38643906774044672","max_id_str":"41191052790603776","query":"twitter"}
benchmarks/json-data/twitter50.jsondeleted−1
@@ -1 +0,0 @@
1−{"results":[{"from_user_id_str":"207858021","profile_image_url":"http://a3.twimg.com/sticky/default_profile_images/default_profile_2_normal.png","created_at":"Wed, 26 Jan 2011 04:30:38 +0000","from_user":"pboudarga","id_str":"30120402839666689","metadata":{"result_type":"recent"},"to_user_id":null,"text":"I'm at Rolla Sushi Grill (27737 Bouquet Canyon Road, #106, Btw Haskell Canyon and Rosedell Drive, Saugus) http://4sq.com/gqqdhs","id":30120402839666689,"from_user_id":207858021,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://foursquare.com&quot; rel=&quot;nofollow&quot;&gt;foursquare&lt;/a&gt;"},{"from_user_id_str":"69988683","profile_image_url":"http://a0.twimg.com/profile_images/1211955817/avatar_7888_normal.gif","created_at":"Wed, 26 Jan 2011 04:25:23 +0000","from_user":"YNK33","id_str":"30119083059978240","metadata":{"result_type":"recent"},"to_user_id":null,"text":"hsndfile 0.5.0: Free and open source Haskell bindings for libsndfile http://bit.ly/gHaBWG Mac Os","id":30119083059978240,"from_user_id":69988683,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"81492","profile_image_url":"http://a1.twimg.com/profile_images/423894208/Picture_7_normal.jpg","created_at":"Wed, 26 Jan 2011 04:24:28 +0000","from_user":"satzz","id_str":"30118851488251904","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Emacs\u306e\u30e2\u30fc\u30c9\u8868\u793a\u304c\u4eca(Ruby Controller Outputz RoR Flymake REl hs)\u3068\u306a\u3063\u3066\u3066\u3088\u304f\u308f\u304b\u3089\u306a\u3044\u3093\u3060\u3051\u3069\u6700\u5f8c\u306eREl\u3068\u304bhs\u3063\u3066\u4f55\u3060\u308d\u3046\u2026haskell\u3068\u304b2\u5e74\u4ee5\u4e0a\u66f8\u3044\u3066\u306a\u3044\u3051\u3069\u2026","id":30118851488251904,"from_user_id":81492,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.hootsuite.com&quot; rel=&quot;nofollow&quot;&gt;HootSuite&lt;/a&gt;"},{"from_user_id_str":"9518356","profile_image_url":"http://a2.twimg.com/profile_images/119165723/ocaml-icon_normal.png","created_at":"Wed, 26 Jan 2011 04:19:19 +0000","from_user":"planet_ocaml","id_str":"30117557788741632","metadata":{"result_type":"recent"},"to_user_id":null,"text":"I so miss #haskell type classes in #ocaml - i want to do something like refinement. Also why does ocaml not have... http://bit.ly/geYRwt","id":30117557788741632,"from_user_id":9518356,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"218059","profile_image_url":"http://a1.twimg.com/profile_images/1053837723/twitter-icon9_normal.jpg","created_at":"Wed, 26 Jan 2011 04:16:32 +0000","from_user":"aprikip","id_str":"30116854940835840","metadata":{"result_type":"recent"},"to_user_id":null,"text":"yatex-mode\u3084haskell-mode\u306e\u3053\u3068\u3067\u3059\u306d\u3001\u308f\u304b\u308a\u307e\u3059\u3002","id":30116854940835840,"from_user_id":218059,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://sites.google.com/site/yorufukurou/&quot; rel=&quot;nofollow&quot;&gt;YoruFukurou&lt;/a&gt;"},{"from_user_id_str":"216363","profile_image_url":"http://a1.twimg.com/profile_images/72454310/Tim-Avatar_normal.png","created_at":"Wed, 26 Jan 2011 04:15:30 +0000","from_user":"dysinger","id_str":"30116594684264448","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Haskell in Hawaii tonight for me... #fun","id":30116594684264448,"from_user_id":216363,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.nambu.com/&quot; rel=&quot;nofollow&quot;&gt;Nambu&lt;/a&gt;"},{"from_user_id_str":"1774820","profile_image_url":"http://a2.twimg.com/profile_images/61169291/dan_desert_thumb_normal.jpg","created_at":"Wed, 26 Jan 2011 04:13:36 +0000","from_user":"DanMil","id_str":"30116117682851840","metadata":{"result_type":"recent"},"to_user_id":1594784,"text":"@ojrac @chewedwire @tomheon Haskell isn't a language, it's a belief system. A seductive one...","id":30116117682851840,"from_user_id":1774820,"to_user":"ojrac","geo":null,"iso_language_code":"en","to_user_id_str":"1594784","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"659256","profile_image_url":"http://a0.twimg.com/profile_images/746976711/angular-final_normal.jpg","created_at":"Wed, 26 Jan 2011 04:11:06 +0000","from_user":"djspiewak","id_str":"30115488931520512","metadata":{"result_type":"recent"},"to_user_id":null,"text":"One of the very nice things about Haskell as opposed to SML is the reduced proliferation of identifiers (e.g. andb, orb, etc). #typeclasses","id":30115488931520512,"from_user_id":659256,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://itunes.apple.com/us/app/twitter/id409789998?mt=12&quot; rel=&quot;nofollow&quot;&gt;Twitter for Mac&lt;/a&gt;"},{"from_user_id_str":"144546280","profile_image_url":"http://a1.twimg.com/a/1295051201/images/default_profile_1_normal.png","created_at":"Wed, 26 Jan 2011 04:06:12 +0000","from_user":"listwarenet","id_str":"30114255890026496","metadata":{"result_type":"recent"},"to_user_id":null,"text":"http://www.listware.net/201101/haskell-cafe/84752-re-haskell-cafe-gpl-license-of-h-matrix-and-prelude-numeric.html Re: Haskell-c","id":30114255890026496,"from_user_id":144546280,"geo":null,"iso_language_code":"no","to_user_id_str":null,"source":"&lt;a href=&quot;http://1e10.org/cloud/&quot; rel=&quot;nofollow&quot;&gt;1e10&lt;/a&gt;"},{"from_user_id_str":"1594784","profile_image_url":"http://a2.twimg.com/profile_images/378515773/square-profile_normal.jpg","created_at":"Wed, 26 Jan 2011 04:01:29 +0000","from_user":"ojrac","id_str":"30113067333324800","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @tomheon: @ojrac @chewedwire Don't worry, learning Haskell will not give you any clear idea what monad means.","id":30113067333324800,"from_user_id":1594784,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"207589736","profile_image_url":"http://a3.twimg.com/profile_images/1225527428/headshot_1_normal.jpg","created_at":"Wed, 26 Jan 2011 04:00:13 +0000","from_user":"ashleevelazq101","id_str":"30112747555397632","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Federal investigation finds safety violations at The Acadia Hospital: By Meg Haskell, BDN Staff The investigatio... http://bit.ly/dONnpn","id":30112747555397632,"from_user_id":207589736,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"17671137","profile_image_url":"http://a2.twimg.com/profile_images/290264834/Haskell-logo-outer-glow_normal.png","created_at":"Wed, 26 Jan 2011 03:58:00 +0000","from_user":"Hackage","id_str":"30112192346984448","metadata":{"result_type":"recent"},"to_user_id":null,"text":"streams 0.4, added by EdwardKmett: Various Haskell 2010 stream comonads http://bit.ly/idBkPe","id":30112192346984448,"from_user_id":17671137,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"17489366","profile_image_url":"http://a3.twimg.com/sticky/default_profile_images/default_profile_2_normal.png","created_at":"Wed, 26 Jan 2011 03:58:00 +0000","from_user":"aapnoot","id_str":"30112191881420800","metadata":{"result_type":"recent"},"to_user_id":null,"text":"streams 0.4, added by EdwardKmett: Various Haskell 2010 stream comonads http://bit.ly/idBkPe","id":30112191881420800,"from_user_id":17489366,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"8530482","profile_image_url":"http://a2.twimg.com/profile_images/137867266/n608671563_7396_normal.jpg","created_at":"Wed, 26 Jan 2011 03:50:12 +0000","from_user":"jeffmclamb","id_str":"30110229207187456","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Angel - daemon to run and monitor processes like daemontools or god, written in Haskell http://ff.im/-wNyLk","id":30110229207187456,"from_user_id":8530482,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://friendfeed.com&quot; rel=&quot;nofollow&quot;&gt;FriendFeed&lt;/a&gt;"},{"from_user_id_str":"177539201","profile_image_url":"http://a0.twimg.com/profile_images/1178368800/img_normal.jpeg","created_at":"Wed, 26 Jan 2011 03:46:01 +0000","from_user":"tomheon","id_str":"30109174645919744","metadata":{"result_type":"recent"},"to_user_id":1594784,"text":"@ojrac @chewedwire Don't worry, learning Haskell will not give you any clear idea what monad means.","id":30109174645919744,"from_user_id":177539201,"to_user":"ojrac","geo":null,"iso_language_code":"en","to_user_id_str":"1594784","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"1594784","profile_image_url":"http://a2.twimg.com/profile_images/378515773/square-profile_normal.jpg","created_at":"Wed, 26 Jan 2011 03:44:34 +0000","from_user":"ojrac","id_str":"30108808684503040","metadata":{"result_type":"recent"},"to_user_id":128028225,"text":"@chewedwire @tomheon Why are you making me curious about Haskell? I LIKE not knowing what monad means!!","id":30108808684503040,"from_user_id":1594784,"to_user":"chewedwire","geo":null,"iso_language_code":"en","to_user_id_str":"128028225","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"23750094","profile_image_url":"http://a0.twimg.com/profile_images/951373780/Moeinthecar_normal.jpg","created_at":"Wed, 26 Jan 2011 03:41:54 +0000","from_user":"shokalshab","id_str":"30108140443795456","metadata":{"result_type":"recent"},"to_user_id":null,"text":"I'm at Magnitude Cheer @ Gymnastics Olympica USA (7735 Haskell Ave., btw Saticoy &amp; Strathern, Van Nuys) http://4sq.com/gmXfaL","id":30108140443795456,"from_user_id":23750094,"geo":null,"iso_language_code":"en","place":{"id":"4e4a2a2f86cb2946","type":"poi","full_name":"Gymnastics Olympica USA, Van Nuys"},"to_user_id_str":null,"source":"&lt;a href=&quot;http://foursquare.com&quot; rel=&quot;nofollow&quot;&gt;foursquare&lt;/a&gt;"},{"from_user_id_str":"8135112","profile_image_url":"http://a0.twimg.com/profile_images/1165240350/LIMITED_normal.jpg","created_at":"Wed, 26 Jan 2011 03:41:35 +0000","from_user":"Claricei","id_str":"30108059208515584","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @kristenmchugh22: @KeithOlbermann Ryan looks like Jughead w/o the hat. And sounds as mealy-mouthed as Eddie Haskell.","id":30108059208515584,"from_user_id":8135112,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"128028225","profile_image_url":"http://a1.twimg.com/profile_images/1224994593/Coding_Drunk_normal.jpg","created_at":"Wed, 26 Jan 2011 03:40:02 +0000","from_user":"chewedwire","id_str":"30107670367182848","metadata":{"result_type":"recent"},"to_user_id":177539201,"text":"@tomheon Cool, I'll take a look. I feel like I should mention this: http://bit.ly/hVstDM","id":30107670367182848,"from_user_id":128028225,"to_user":"tomheon","geo":null,"iso_language_code":"en","to_user_id_str":"177539201","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"8679778","profile_image_url":"http://a3.twimg.com/profile_images/1195318056/me_nyc_12_18_10_icon_normal.jpg","created_at":"Wed, 26 Jan 2011 03:38:42 +0000","from_user":"kristenmchugh22","id_str":"30107332381777920","metadata":{"result_type":"recent"},"to_user_id":756269,"text":"@KeithOlbermann Ryan looks like Jughead w/o the hat. And sounds as mealy-mouthed as Eddie Haskell.","id":30107332381777920,"from_user_id":8679778,"to_user":"KeithOlbermann","geo":null,"iso_language_code":"en","to_user_id_str":"756269","source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"103316559","profile_image_url":"http://a1.twimg.com/profile_images/1179458751/bc3beab4-d59d-4e78-b13b-50747986cfa2_normal.png","created_at":"Wed, 26 Jan 2011 03:36:15 +0000","from_user":"cityslikr","id_str":"30106719153557504","metadata":{"result_type":"recent"},"to_user_id":null,"text":"&quot;Social safety net into a hammock.&quot; So says Eddie Haskell with the GOP response. #SOTU","id":30106719153557504,"from_user_id":103316559,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://blackberry.com/twitter&quot; rel=&quot;nofollow&quot;&gt;Twitter for BlackBerry\u00ae&lt;/a&gt;"},{"from_user_id_str":"169063143","profile_image_url":"http://a0.twimg.com/profile_images/1160506212/9697_1_normal.gif","created_at":"Wed, 26 Jan 2011 03:31:52 +0000","from_user":"wrkforce_safety","id_str":"30105614919143424","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Federal investigation finds safety violations at The Acadia Hospital: By Meg Haskell, BDN Staff The investigatio... http://bit.ly/gA60C1","id":30105614919143424,"from_user_id":169063143,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"177539201","profile_image_url":"http://a0.twimg.com/profile_images/1178368800/img_normal.jpeg","created_at":"Wed, 26 Jan 2011 03:29:40 +0000","from_user":"tomheon","id_str":"30105060960632832","metadata":{"result_type":"recent"},"to_user_id":128028225,"text":"@chewedwire Great book on Haskell: http://oreilly.com/catalog/9780596514983","id":30105060960632832,"from_user_id":177539201,"to_user":"chewedwire","geo":null,"iso_language_code":"en","to_user_id_str":"128028225","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"782692","profile_image_url":"http://a0.twimg.com/profile_images/1031304589/Profile.2007.1_normal.jpg","created_at":"Wed, 26 Jan 2011 03:29:19 +0000","from_user":"turnageb","id_str":"30104974591533057","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @ovillalon: Paul Ryan solves the mystery of whatever happened to Eddie Haskell. #sotu","id":30104974591533057,"from_user_id":782692,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"128028225","profile_image_url":"http://a1.twimg.com/profile_images/1224994593/Coding_Drunk_normal.jpg","created_at":"Wed, 26 Jan 2011 03:28:04 +0000","from_user":"chewedwire","id_str":"30104657267265536","metadata":{"result_type":"recent"},"to_user_id":177539201,"text":"@tomheon I always loved the pattern matching in SML and it looks like Haskell is MUCH better at it. I'm messing around now at tryhaskell.org","id":30104657267265536,"from_user_id":128028225,"to_user":"tomheon","geo":null,"iso_language_code":"en","to_user_id_str":"177539201","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"12834082","profile_image_url":"http://a3.twimg.com/profile_images/1083036140/mugshot_normal.png","created_at":"Wed, 26 Jan 2011 03:28:01 +0000","from_user":"ovillalon","id_str":"30104647213518848","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Paul Ryan solves the mystery of whatever happened to Eddie Haskell. #sotu","id":30104647213518848,"from_user_id":12834082,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"13540930","profile_image_url":"http://a1.twimg.com/profile_images/1205312219/23467_350321383101_821143101_5114147_3010041_n_normal.jpg","created_at":"Wed, 26 Jan 2011 03:26:02 +0000","from_user":"goodfox","id_str":"30104146455560192","metadata":{"result_type":"recent"},"to_user_id":10226179,"text":"@billykeene22 Bordeaux is one of my heroes. I was so excited when he accepted the invitation to campus. He's been a great friend to Haskell.","id":30104146455560192,"from_user_id":13540930,"to_user":"billykeene22","geo":null,"iso_language_code":"en","to_user_id_str":"10226179","source":"&lt;a href=&quot;http://www.ubertwitter.com/bb/download.php&quot; rel=&quot;nofollow&quot;&gt;\u00dcberTwitter&lt;/a&gt;"},{"from_user_id_str":"18616016","profile_image_url":"http://a2.twimg.com/profile_images/1173522726/214397343_normal.jpg","created_at":"Wed, 26 Jan 2011 03:25:18 +0000","from_user":"josej30","id_str":"30103962313031681","metadata":{"result_type":"recent"},"to_user_id":14870909,"text":"@cris7ian Ahh bueno multiparadigma ya es respetable :) Empezar\u00e9 a explotar la parte funcional de los lenguajes ahora #Haskell","id":30103962313031681,"from_user_id":18616016,"to_user":"Cris7ian","geo":null,"iso_language_code":"es","to_user_id_str":"14870909","source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"14870909","profile_image_url":"http://a2.twimg.com/profile_images/1176930429/oso_yo_normal.png","created_at":"Wed, 26 Jan 2011 03:23:43 +0000","from_user":"Cris7ian","id_str":"30103562360983553","metadata":{"result_type":"recent"},"to_user_id":18616016,"text":"@josej30 hahaha no, es multiparadigma y es bastante lazy. Nothing like haskell, pero s\u00ed, el de Flash","id":30103562360983553,"from_user_id":14870909,"to_user":"josej30","geo":null,"iso_language_code":"es","to_user_id_str":"18616016","source":"&lt;a href=&quot;http://www.echofon.com/&quot; rel=&quot;nofollow&quot;&gt;Echofon&lt;/a&gt;"},{"from_user_id_str":"2421643","profile_image_url":"http://a0.twimg.com/profile_images/1190361665/ernestgrumbles-17_normal.jpg","created_at":"Wed, 26 Jan 2011 03:20:24 +0000","from_user":"ernestgrumbles","id_str":"30102730756333568","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Wow... WolframAlpha did not know who Eddie Haskell is. Guess I'll never use that &quot;knowledge engine&quot; again.","id":30102730756333568,"from_user_id":2421643,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"128028225","profile_image_url":"http://a1.twimg.com/profile_images/1224994593/Coding_Drunk_normal.jpg","created_at":"Wed, 26 Jan 2011 03:14:21 +0000","from_user":"chewedwire","id_str":"30101204428132352","metadata":{"result_type":"recent"},"to_user_id":177539201,"text":"@tomheon How is Haskell better/different from CL or Scheme? I honestly don't know, although I'm becoming more curious.","id":30101204428132352,"from_user_id":128028225,"to_user":"tomheon","geo":null,"iso_language_code":"en","to_user_id_str":"177539201","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"13540930","profile_image_url":"http://a1.twimg.com/profile_images/1205312219/23467_350321383101_821143101_5114147_3010041_n_normal.jpg","created_at":"Wed, 26 Jan 2011 03:06:54 +0000","from_user":"goodfox","id_str":"30099329809129473","metadata":{"result_type":"recent"},"to_user_id":null,"text":"A day of vision &amp; speeches. #SOTU now. And a wonderful Haskell Convocation address earlier today by Sinte Gleske President Lionel Bordeaux.","id":30099329809129473,"from_user_id":13540930,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.ubertwitter.com/bb/download.php&quot; rel=&quot;nofollow&quot;&gt;\u00dcberTwitter&lt;/a&gt;"},{"from_user_id_str":"119185220","profile_image_url":"http://a0.twimg.com/profile_images/1089027228/dfg_normal.jpg","created_at":"Wed, 26 Jan 2011 03:03:38 +0000","from_user":"LaLiciouz_03","id_str":"30098510623805440","metadata":{"result_type":"recent"},"to_user_id":null,"text":"The Game with the girl room 330 Haskell follow us...","id":30098510623805440,"from_user_id":119185220,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"18616016","profile_image_url":"http://a2.twimg.com/profile_images/1173522726/214397343_normal.jpg","created_at":"Wed, 26 Jan 2011 02:57:25 +0000","from_user":"josej30","id_str":"30096946144215040","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Voy a extra\u00f1ar Haskell cuando regrese al mundo imperativo. Hay alg\u00fan lenguaje imperativo que tenga este poder funcional? #ci3661","id":30096946144215040,"from_user_id":18616016,"geo":null,"iso_language_code":"es","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"17671137","profile_image_url":"http://a2.twimg.com/profile_images/290264834/Haskell-logo-outer-glow_normal.png","created_at":"Wed, 26 Jan 2011 02:55:32 +0000","from_user":"Hackage","id_str":"30096471814574080","metadata":{"result_type":"recent"},"to_user_id":null,"text":"comonad-transformers 0.9.0, added by EdwardKmett: Haskell 98 comonad transformers http://bit.ly/h6xIsf","id":30096471814574080,"from_user_id":17671137,"geo":null,"iso_language_code":"no","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitterfeed.com&quot; rel=&quot;nofollow&quot;&gt;twitterfeed&lt;/a&gt;"},{"from_user_id_str":"177539201","profile_image_url":"http://a0.twimg.com/profile_images/1178368800/img_normal.jpeg","created_at":"Wed, 26 Jan 2011 02:48:12 +0000","from_user":"tomheon","id_str":"30094626920603649","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Every time I look at Haskell I love it more.","id":30094626920603649,"from_user_id":177539201,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"60792568","profile_image_url":"http://a0.twimg.com/profile_images/1203647517/glenda-flash_normal.jpg","created_at":"Wed, 26 Jan 2011 02:40:42 +0000","from_user":"r_takaishi","id_str":"30092735935422464","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Haskell\u3088\u308aD\u8a00\u8a9e\u304c\u4e0a\u3068\u306f\u601d\u308f\u306a\u304b\u3063\u305f\uff0e http://www.tiobe.com/index.php/content/paperinfo/tpci/index.html","id":30092735935422464,"from_user_id":60792568,"geo":null,"iso_language_code":"ja","to_user_id_str":null,"source":"&lt;a href=&quot;http://twmode.sf.net/&quot; rel=&quot;nofollow&quot;&gt;twmode&lt;/a&gt;"},{"from_user_id_str":"160145510","profile_image_url":"http://a0.twimg.com/profile_images/1218108166/going_galt_normal.jpg","created_at":"Wed, 26 Jan 2011 02:39:31 +0000","from_user":"wtp1787","id_str":"30092439653974018","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @KLSouth: Eddie Haskell Goes to Washington... &quot;You look really nice tonight, Ms Cleaver&quot;","id":30092439653974018,"from_user_id":160145510,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"96616016","profile_image_url":"http://a1.twimg.com/profile_images/1196978169/Picture0002_normal.jpg","created_at":"Wed, 26 Jan 2011 02:39:20 +0000","from_user":"MelissaRNMBA","id_str":"30092392203816960","metadata":{"result_type":"recent"},"to_user_id":14862975,"text":"@KLSouth At least Eddie Haskell was entertaining.","id":30092392203816960,"from_user_id":96616016,"to_user":"KLSouth","geo":null,"iso_language_code":"en","to_user_id_str":"14862975","source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"14862975","profile_image_url":"http://a0.twimg.com/profile_images/421596393/kls_4_normal.JPG","created_at":"Wed, 26 Jan 2011 02:38:29 +0000","from_user":"KLSouth","id_str":"30092178327871489","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Eddie Haskell Goes to Washington... &quot;You look really nice tonight, Ms Cleaver&quot;","id":30092178327871489,"from_user_id":14862975,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.tweetdeck.com&quot; rel=&quot;nofollow&quot;&gt;TweetDeck&lt;/a&gt;"},{"from_user_id_str":"144546280","profile_image_url":"http://a1.twimg.com/a/1295051201/images/default_profile_1_normal.png","created_at":"Wed, 26 Jan 2011 02:36:17 +0000","from_user":"listwarenet","id_str":"30091626869161984","metadata":{"result_type":"recent"},"to_user_id":null,"text":"http://www.listware.net/201101/haskell-beginners/84641-haskell-beginners-wildcards-in-expressions.html Haskell-beginners - Wild","id":30091626869161984,"from_user_id":144546280,"geo":null,"iso_language_code":"no","to_user_id_str":null,"source":"&lt;a href=&quot;http://1e10.org/cloud/&quot; rel=&quot;nofollow&quot;&gt;1e10&lt;/a&gt;"},{"from_user_id_str":"24538048","profile_image_url":"http://a2.twimg.com/profile_images/1117267605/rope_normal.jpg","created_at":"Wed, 26 Jan 2011 02:23:14 +0000","from_user":"dbph","id_str":"30088341030440960","metadata":{"result_type":"recent"},"to_user_id":null,"text":"RT @dnene: Skilled Calisthenics. Haskell code that outputs python which spits ruby which emits the haskell source. http://j.mp/YlQUL via @mfeathers","id":30088341030440960,"from_user_id":24538048,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"},{"from_user_id_str":"158951567","profile_image_url":"http://a3.twimg.com/profile_images/962721419/Logo_3_normal.jpg","created_at":"Wed, 26 Jan 2011 01:58:31 +0000","from_user":"YubaVetTech","id_str":"30082124207886336","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Dr. Haskell has just been awarded the prestigious Hayward Award for \u2018Excellence in Education\u2019. This award honors... http://fb.me/QgQCxd74","id":30082124207886336,"from_user_id":158951567,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.facebook.com/twitter&quot; rel=&quot;nofollow&quot;&gt;Facebook&lt;/a&gt;"},{"from_user_id_str":"158951567","profile_image_url":"http://a3.twimg.com/profile_images/962721419/Logo_3_normal.jpg","created_at":"Wed, 26 Jan 2011 01:56:04 +0000","from_user":"YubaVetTech","id_str":"30081505476743168","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Dr. Haskell has just been awarded the prestigous Haward Award for Excellence in Education. This award honors... http://fb.me/PC9mYmCR","id":30081505476743168,"from_user_id":158951567,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://www.facebook.com/twitter&quot; rel=&quot;nofollow&quot;&gt;Facebook&lt;/a&gt;"},{"from_user_id_str":"2331498","profile_image_url":"http://a3.twimg.com/profile_images/494632120/me_normal.jpg","created_at":"Wed, 26 Jan 2011 01:43:50 +0000","from_user":"Verus","id_str":"30078427155406848","metadata":{"result_type":"recent"},"to_user_id":79273052,"text":"@kami_joe \u3044\u3084\uff0c\u8ab2\u984c\u306f\u89e3\u6c7a\u5bfe\u8c61(\u30d1\u30ba\u30eb\u3068\u304b)\u3092\u4e0e\u3048\u3089\u308c\u3066\uff0c\u554f\u984c\u5b9a\u7fa9\u3068\u30d7\u30ed\u30b0\u30e9\u30df\u30f3\u30b0(\u6307\u5b9a\u8a00\u8a9e\u306fC++\u3082\u3057\u304f\u306fJava)\u3068\u3044\u3046\u3044\u308f\u3070\u666e\u901a\u306a\u8ab2\u984c\u3067\u306f\u3042\u308b\u3093\u3060\u3051\u3069\uff0e\u95a2\u6570\u578b\u8a00\u8a9e\u306fHaskell\u306e\u6388\u696d\u304c\u307e\u305f\u5225\u306b\u3042\u308b\u306e\uff0e","id":30078427155406848,"from_user_id":2331498,"to_user":"kami_joe","geo":null,"iso_language_code":"ja","to_user_id_str":"79273052","source":"&lt;a href=&quot;http://itunes.apple.com/us/app/twitter/id409789998?mt=12&quot; rel=&quot;nofollow&quot;&gt;Twitter for Mac&lt;/a&gt;"},{"from_user_id_str":"79151233","profile_image_url":"http://a2.twimg.com/a/1295051201/images/default_profile_2_normal.png","created_at":"Wed, 26 Jan 2011 01:40:37 +0000","from_user":"cz_newdrafts","id_str":"30077617361125376","metadata":{"result_type":"recent"},"to_user_id":null,"text":"Haskell programming language http://bit.ly/gpPAwB","id":30077617361125376,"from_user_id":79151233,"geo":null,"iso_language_code":"no","to_user_id_str":null,"source":"&lt;a href=&quot;http://tommorris.org/&quot; rel=&quot;nofollow&quot;&gt;tommorris' hacksample&lt;/a&gt;"},{"from_user_id_str":"2331498","profile_image_url":"http://a3.twimg.com/profile_images/494632120/me_normal.jpg","created_at":"Wed, 26 Jan 2011 01:02:57 +0000","from_user":"Verus","id_str":"30068139416879104","metadata":{"result_type":"recent"},"to_user_id":9252720,"text":"@shukukei Java\u3068C\u306f\u3042\u308b\u7a0b\u5ea6\u66f8\u3051\u3066\u3042\u305f\u308a\u307e\u3048\u306a\u3068\u3053\u308d\u304c\u3042\u308b\u304b\u3089\u306a\u30fc\uff0ePython\u306f\u500b\u4eba\u7684\u306b\u611f\u899a\u304c\u5408\u308f\u306a\u3044\uff0e\u611f\u899a\u306a\u306e\u3067\uff0c\u3082\u3046\u3069\u3046\u3057\u3088\u3046\u3082\u306a\u3044\uff57 \u3044\u307e\u306fScala\u3068Haskell\u3092\u3082\u3063\u3068\u6975\u3081\u305f\u3044\u3068\u3053\u308d\uff0e","id":30068139416879104,"from_user_id":2331498,"to_user":"shukukei","geo":null,"iso_language_code":"ja","to_user_id_str":"9252720","source":"&lt;a href=&quot;http://itunes.apple.com/us/app/twitter/id409789998?mt=12&quot; rel=&quot;nofollow&quot;&gt;Twitter for Mac&lt;/a&gt;"},{"from_user_id_str":"2781460","profile_image_url":"http://a0.twimg.com/profile_images/82526625/.joeyicon_normal.jpg","created_at":"Wed, 26 Jan 2011 01:02:35 +0000","from_user":"joeyhess","id_str":"30068046538219520","metadata":{"result_type":"recent"},"to_user_id":null,"text":"just figured out that I can use parameterized types to remove a dependency loop in git-annex's type definitions. whee #haskell","id":30068046538219520,"from_user_id":2781460,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://identi.ca&quot; rel=&quot;nofollow&quot;&gt;identica&lt;/a&gt;"},{"from_user_id_str":"144546280","profile_image_url":"http://a1.twimg.com/a/1295051201/images/default_profile_1_normal.png","created_at":"Wed, 26 Jan 2011 00:54:22 +0000","from_user":"listwarenet","id_str":"30065977920061440","metadata":{"result_type":"recent"},"to_user_id":null,"text":"http://www.listware.net/201101/haskell-beginners/84466-haskell-beginners-bytestring-question.html Haskell-beginners - Bytestrin","id":30065977920061440,"from_user_id":144546280,"geo":null,"iso_language_code":"no","to_user_id_str":null,"source":"&lt;a href=&quot;http://1e10.org/cloud/&quot; rel=&quot;nofollow&quot;&gt;1e10&lt;/a&gt;"},{"from_user_id_str":"1291845","profile_image_url":"http://a0.twimg.com/profile_images/1225743404/ThinOxygen-small-opaque-solidarity_normal.png","created_at":"Wed, 26 Jan 2011 00:52:07 +0000","from_user":"_aaron_","id_str":"30065412242669568","metadata":{"result_type":"recent"},"to_user_id":null,"text":"wanted: librly licensed high level native compiled lang with min runtime (otherwise cobra/mono would be perfect) for win. lua? haskell? ooc?","id":30065412242669568,"from_user_id":1291845,"geo":null,"iso_language_code":"en","to_user_id_str":null,"source":"&lt;a href=&quot;http://twitter.com/&quot;&gt;web&lt;/a&gt;"}],"max_id":30120402839666689,"since_id":0,"refresh_url":"?since_id=30120402839666689&q=haskell","next_page":"?page=2&max_id=30120402839666689&rpp=50&q=haskell","results_per_page":50,"page":1,"completed_in":0.291696,"since_id_str":"0","max_id_str":"30120402839666689","query":"haskell"}
benchmarks/warp-3.0.1.1/LICENSEdeleted−20
@@ -1,20 +0,0 @@
1−Copyright (c) 2012 Michael Snoyman, http://www.yesodweb.com/
2−
3−Permission is hereby granted, free of charge, to any person obtaining
4−a copy of this software and associated documentation files (the
5−"Software"), to deal in the Software without restriction, including
6−without limitation the rights to use, copy, modify, merge, publish,
7−distribute, sublicense, and/or sell copies of the Software, and to
8−permit persons to whom the Software is furnished to do so, subject to
9−the following conditions:
10−
11−The above copyright notice and this permission notice shall be
12−included in all copies or substantial portions of the Software.
13−
14−THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
15−EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16−MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17−NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18−LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19−OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20−WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
benchmarks/warp-3.0.1.1/Network/Wai/Handler/Warp/ReadInt.hsdeleted−67
@@ -1,67 +0,0 @@
1−{-# LANGUAGE OverloadedStrings #-}
2−{-# LANGUAGE MagicHash #-}
3−{-# LANGUAGE BangPatterns #-}
4−
5−-- Copyright : Erik de Castro Lopo <erikd@mega-nerd.com>
6−-- License : BSD3
7−
8−module Network.Wai.Handler.Warp.ReadInt (
9− readInt
10− , readInt64
11− ) where
12−
13−-- This function lives in its own file because the MagicHash pragma interacts
14−-- poorly with the CPP pragma.
15−
16−import Data.ByteString (ByteString)
17−import qualified Data.ByteString as S
18−import Data.Int (Int64)
19−import GHC.Prim
20−import GHC.Types
21−import GHC.Word
22−
23−{-# INLINE readInt #-}
24−readInt :: Integral a => ByteString -> a
25−readInt bs = fromIntegral $ readInt64 bs
26−
27−-- This function is used to parse the Content-Length field of HTTP headers and
28−-- is a performance hot spot. It should only be replaced with something
29−-- significantly and provably faster.
30−--
31−-- It needs to be able work correctly on 32 bit CPUs for file sizes > 2G so we
32−-- use Int64 here and then make a generic 'readInt' that allows conversion to
33−-- Int and Integer.
34−
35−{-# NOINLINE readInt64 #-}
36−readInt64 :: ByteString -> Int64
37−readInt64 bs = S.foldl' (\ !i !c -> i * 10 + fromIntegral (mhDigitToInt c)) 0
38− $ S.takeWhile isDigit bs
39−
40−data Table = Table !Addr#
41−
42−{-# NOINLINE mhDigitToInt #-}
43−mhDigitToInt :: Word8 -> Int
44−mhDigitToInt (W8# i) = I# (word2Int# (indexWord8OffAddr# addr (word2Int# i)))
45− where
46− !(Table addr) = table
47− table :: Table
48− table = Table
49− "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
50− \\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
51− \\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
52− \\x00\x01\x02\x03\x04\x05\x06\x07\x08\x09\x00\x00\x00\x00\x00\x00\
53− \\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
54− \\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
55− \\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
56− \\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
57− \\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
58− \\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
59− \\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
60− \\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
61− \\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
62− \\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
63− \\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
64− \\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00"#
65−
66−isDigit :: Word8 -> Bool
67−isDigit w = w >= 48 && w <= 57
benchmarks/warp-3.0.1.1/Network/Wai/Handler/Warp/RequestHeader.hsdeleted−172
@@ -1,172 +0,0 @@
1−{-# LANGUAGE DeriveDataTypeable #-}
2−{-# LANGUAGE OverloadedStrings #-}
3−{-# LANGUAGE BangPatterns #-}
4−
5−module Network.Wai.Handler.Warp.RequestHeader (
6− parseHeaderLines
7− , parseByteRanges
8− ) where
9−
10−import Control.Exception (Exception, throwIO)
11−import Control.Monad (when)
12−import Data.Typeable (Typeable)
13−import qualified Data.ByteString as S
14−import qualified Data.ByteString.Char8 as B (unpack, readInteger)
15−import Data.ByteString.Internal (ByteString(..), memchr)
16−import qualified Data.CaseInsensitive as CI
17−import Data.Word (Word8)
18−import Foreign.ForeignPtr (withForeignPtr)
19−import Foreign.Ptr (Ptr, plusPtr, minusPtr, nullPtr)
20−import Foreign.Storable (peek)
21−import qualified Network.HTTP.Types as H
22−-- import Network.Wai.Handler.Warp.Types
23−import qualified Network.HTTP.Types.Header as HH
24−-- $setup
25−-- >>> :set -XOverloadedStrings
26−
27−data InvalidRequest = NotEnoughLines [String]
28− | BadFirstLine String
29− | NonHttp
30− | IncompleteHeaders
31− | ConnectionClosedByPeer
32− | OverLargeHeader
33− deriving (Eq, Typeable, Show)
34−
35−instance Exception InvalidRequest
36−
37−----------------------------------------------------------------
38−
39−parseHeaderLines :: [ByteString]
40− -> IO (H.Method
41− ,ByteString -- Path
42− ,ByteString -- Path, parsed
43− ,ByteString -- Query
44− ,H.HttpVersion
45− ,H.RequestHeaders
46− )
47−parseHeaderLines [] = throwIO $ NotEnoughLines []
48−parseHeaderLines (firstLine:otherLines) = do
49− (method, path', query, httpversion) <- parseRequestLine firstLine
50− let path = H.extractPath path'
51− hdr = map parseHeader otherLines
52− return (method, path', path, query, httpversion, hdr)
53−
54−----------------------------------------------------------------
55−
56−-- |
57−--
58−-- >>> parseRequestLine "GET / HTTP/1.1"
59−-- ("GET","/","",HTTP/1.1)
60−-- >>> parseRequestLine "POST /cgi/search.cgi?key=foo HTTP/1.0"
61−-- ("POST","/cgi/search.cgi","?key=foo",HTTP/1.0)
62−-- >>> parseRequestLine "GET "
63−-- *** Exception: Warp: Invalid first line of request: "GET "
64−-- >>> parseRequestLine "GET /NotHTTP UNKNOWN/1.1"
65−-- *** Exception: Warp: Request line specified a non-HTTP request
66−parseRequestLine :: ByteString
67− -> IO (H.Method
68− ,ByteString -- Path
69− ,ByteString -- Query
70− ,H.HttpVersion)
71−parseRequestLine requestLine@(PS fptr off len) = withForeignPtr fptr $ \ptr -> do
72− when (len < 14) $ throwIO baderr
73− let methodptr = ptr `plusPtr` off
74− limptr = methodptr `plusPtr` len
75− lim0 = fromIntegral len
76−
77− pathptr0 <- memchr methodptr 32 lim0 -- ' '
78− when (pathptr0 == nullPtr || (limptr `minusPtr` pathptr0) < 11) $
79− throwIO baderr
80− let pathptr = pathptr0 `plusPtr` 1
81− lim1 = fromIntegral (limptr `minusPtr` pathptr0)
82−
83− httpptr0 <- memchr pathptr 32 lim1 -- ' '
84− when (httpptr0 == nullPtr || (limptr `minusPtr` httpptr0) < 9) $
85− throwIO baderr
86− let httpptr = httpptr0 `plusPtr` 1
87− lim2 = fromIntegral (httpptr0 `minusPtr` pathptr)
88−
89− checkHTTP httpptr
90− !hv <- httpVersion httpptr
91− queryptr <- memchr pathptr 63 lim2 -- '?'
92−
93− let !method = bs ptr methodptr pathptr0
94− !path
95− | queryptr == nullPtr = bs ptr pathptr httpptr0
96− | otherwise = bs ptr pathptr queryptr
97− !query
98− | queryptr == nullPtr = S.empty
99− | otherwise = bs ptr queryptr httpptr0
100−
101− return (method,path,query,hv)
102− where
103− baderr = BadFirstLine $ B.unpack requestLine
104− check :: Ptr Word8 -> Int -> Word8 -> IO ()
105− check p n w = do
106− w0 <- peek $ p `plusPtr` n
107− when (w0 /= w) $ throwIO NonHttp
108− checkHTTP httpptr = do
109− check httpptr 0 72 -- 'H'
110− check httpptr 1 84 -- 'T'
111− check httpptr 2 84 -- 'T'
112− check httpptr 3 80 -- 'P'
113− check httpptr 4 47 -- '/'
114− check httpptr 6 46 -- '.'
115− httpVersion httpptr = do
116− major <- peek $ httpptr `plusPtr` 5
117− minor <- peek $ httpptr `plusPtr` 7
118− return $ if major == (49 :: Word8) && minor == (49 :: Word8) then
119− H.http11
120− else
121− H.http10
122− bs ptr p0 p1 = PS fptr o l
123− where
124− o = p0 `minusPtr` ptr
125− l = p1 `minusPtr` p0
126−
127−----------------------------------------------------------------
128−
129−-- |
130−--
131−-- >>> parseHeader "Content-Length:47"
132−-- ("Content-Length","47")
133−-- >>> parseHeader "Accept-Ranges: bytes"
134−-- ("Accept-Ranges","bytes")
135−-- >>> parseHeader "Host: example.com:8080"
136−-- ("Host","example.com:8080")
137−-- >>> parseHeader "NoSemiColon"
138−-- ("NoSemiColon","")
139−
140−parseHeader :: ByteString -> H.Header
141−parseHeader s =
142− let (k, rest) = S.break (== 58) s -- ':'
143− rest' = S.dropWhile (\c -> c == 32 || c == 9) $ S.drop 1 rest
144− in (CI.mk k, rest')
145−
146−parseByteRanges :: S.ByteString -> Maybe HH.ByteRanges
147−parseByteRanges bs1 = do
148− bs2 <- stripPrefix "bytes=" bs1
149− (r, bs3) <- range bs2
150− ranges (r:) bs3
151− where
152− range bs2 =
153− case stripPrefix "-" bs2 of
154− Just bs3 -> do
155− (i, bs4) <- B.readInteger bs3
156− Just (HH.ByteRangeSuffix i, bs4)
157− Nothing -> do
158− (i, bs3) <- B.readInteger bs2
159− bs4 <- stripPrefix "-" bs3
160− case B.readInteger bs4 of
161− Nothing -> Just (HH.ByteRangeFrom i, bs4)
162− Just (j, bs5) -> Just (HH.ByteRangeFromTo i j, bs5)
163− ranges front bs3 =
164− case stripPrefix "," bs3 of
165− Nothing -> Just (front [])
166− Just bs4 -> do
167− (r, bs5) <- range bs4
168− ranges (front . (r:)) bs5
169−
170− stripPrefix x y
171− | x `S.isPrefixOf` y = Just (S.drop (S.length x) y)
172− | otherwise = Nothing
changelog.mddeleted−114
@@ -1,114 +0,0 @@
1−0.13.2.1
2−
3−* Improved performance of `Data.Attoparsec.Text.asciiCI`
4−
5−0.13.2.0
6−
7−* `pure` is now strict in `Position`
8−
9−0.13.1.0
10−
11−* `runScanner` now correctly returns the final state
12− (https://github.com/bos/attoparsec/issues/105).
13−* `Parser`, `ZeptoT`, `Buffer`, and `More` now expose `Semigroup` instances.
14−* `Parser`, and `ZeptoT` now expose `MonadFail` instances.
15−
16−0.13.0.2
17−
18−* Restore the fast specialised character set implementation for Text
19−* Move testsuite from test-framework to tasty
20−* Performance optimization of takeWhile and takeWhile1
21−
22−0.13.0.1
23−
24−* Fixed a bug in the implementations of inClass and notInClass for
25− Text (https://github.com/bos/attoparsec/issues/103)
26−
27−0.13.0.0
28−
29−* Made the parser type in the Zepto module a monad transformer
30− (needed by aeson's string unescaping parser).
31−
32−0.12.1.6
33−
34−* Fixed a case folding bug in the ByteString version of stringCI.
35−
36−0.12.1.5
37−
38−* Fixed an indexing bug in the new Text implementation of string,
39− reported by Michel Boucey.
40−
41−0.12.1.4
42−
43−* Fixed a case where the string parser would consume an unnecessary
44− amount of input before failing a match, when it could bail much
45− earlier (https://github.com/bos/attoparsec/issues/97)
46−
47−* Added more context to error messages
48− (https://github.com/bos/attoparsec/pull/79)
49−
50−0.12.1.3
51−
52−* Fixed incorrect tracking of Text lengths
53− (https://github.com/bos/attoparsec/issues/80)
54−
55−0.12.1.2
56−
57−* Fixed the incorrect tracking of capacity if the initial buffer was
58− empty (https://github.com/bos/attoparsec/issues/75)
59−
60−0.12.1.1
61−
62−* Fixed a data corruption bug that occurred under some circumstances
63− if a buffer grew after prompting for more input
64− (https://github.com/bos/attoparsec/issues/74)
65−
66−0.12.1.0
67−
68−* Now compatible with GHC 7.9
69−
70−* Reintroduced the Chunk class, used by the parsers package
71−
72−0.12.0.0
73−
74−* A new internal representation makes almost all real-world parsers
75− faster, sometimes by big margins. For example, parsing JSON data
76− with aeson is now up to 70% faster. These performance improvements
77− also come with reduced memory consumption and some new capabilities.
78−
79−* The new match combinator gives both the result of a parse and the
80− input that it matched.
81−
82−* The test suite has doubled in size. This made it possible to switch
83− to the new internal representation with a decent degree of
84− confidence that everything was more or less working.
85−
86−* The benchmark suite now contains a small family of benchmarks taken
87− from real-world uses of attoparsec.
88−
89−* A few types that ought to have been private now are.
90−
91−* A few obsolete modules and functions have been marked as deprecated.
92− They will be removed from the next major release.
93−
94−0.11.3.0
95−
96−* New function scientific is compatible with rational, but parses
97− integers more efficiently (https://github.com/bos/aeson/issues/198)
98−
99−0.11.2.0
100−
101−* The new Chunk typeclass allows for some code sharing with Ed
102− Kmett's parsers package: http://hackage.haskell.org/package/parsers
103−
104−* New function runScanner generalises scan to return the final state
105− of the scanner as well as the input consumed.
106−
107−
108−0.11.1.0
109−
110−* New dependency: the scientific package. This allows us to parse
111− numbers much more efficiently.
112−
113−* peekWord8', peekChar': new primitive parsers that allow
114− single-character lookahead.
examples/Makefile+2−6
@@ -1,4 +1,4 @@
1−CC := cc
1+CC := gcc
2CFLAGS := -O3 -Wall
2CFLAGS := -O3 -Wall
3# To make the code about 6% faster:
3# To make the code about 6% faster:
4# CFLAGS += -fwhole-program --combine
4# CFLAGS += -fwhole-program --combine
@@ -12,8 +12,4 @@ c-http: rfc2616.c http_parser.c
12clean:
12clean:
13 rm -f *.hi *.o c-http
13 rm -f *.hi *.o c-http
14
14
15−http_parser.c: http_parser.h
15+vpath %.c $(HOME)/hg/http-parser
16− curl -O https://raw.githubusercontent.com/joyent/http-parser/master/http_parser.c
17−
18−http_parser.h:
19− curl -O https://raw.githubusercontent.com/joyent/http-parser/master/http_parser.h
examples/Parsec_RFC2616.hs+6−9
@@ -23,16 +23,15 @@ token :: Stream s m Char => ParsecT s u m Char
23token = satisfy $ \c -> S.notMember (fromEnum c) set
23token = satisfy $ \c -> S.notMember (fromEnum c) set
24 where set = S.fromList . map fromEnum $ ['\0'..'\31'] ++ "()<>@,;:\\\"/[]?={} \t" ++ ['\128'..'\255']
24 where set = S.fromList . map fromEnum $ ['\0'..'\31'] ++ "()<>@,;:\\\"/[]?={} \t" ++ ['\128'..'\255']
25
25
26−isHorizontalSpace :: Char -> Bool
27isHorizontalSpace c = c == ' ' || c == '\t'
26isHorizontalSpace c = c == ' ' || c == '\t'
28
27
29skipHSpaces :: Stream s m Char => ParsecT s u m ()
28skipHSpaces :: Stream s m Char => ParsecT s u m ()
30skipHSpaces = skipMany1 (satisfy isHorizontalSpace)
29skipHSpaces = skipMany1 (satisfy isHorizontalSpace)
31
30
32data Request = Request {
31data Request = Request {
33− _requestMethod :: String
32+ requestMethod :: String
34− , _requestUri :: String
33+ , requestUri :: String
35− , _requestProtocol :: String
34+ , requestProtocol :: String
36 } deriving (Eq, Ord, Show)
35 } deriving (Eq, Ord, Show)
37
36
38requestLine :: Stream s m Char => ParsecT s u m Request
37requestLine :: Stream s m Char => ParsecT s u m Request
@@ -48,8 +47,8 @@ endOfLine :: Stream s m Char => ParsecT s u m ()
48endOfLine = (string "\r\n" *> pure ()) <|> (char '\n' *> pure ())
47endOfLine = (string "\r\n" *> pure ()) <|> (char '\n' *> pure ())
49
48
50data Header = Header {
49data Header = Header {
51− _headerName :: String
50+ headerName :: String
52− , _headerValue :: [String]
51+ , headerValue :: [String]
53 } deriving (Eq, Ord, Show)
52 } deriving (Eq, Ord, Show)
54
53
55messageHeader :: Stream s m Char => ParsecT s u m Header
54messageHeader :: Stream s m Char => ParsecT s u m Header
@@ -62,16 +61,14 @@ messageHeader = do
62request :: Stream s m Char => ParsecT s u m (Request, [Header])
61request :: Stream s m Char => ParsecT s u m (Request, [Header])
63request = (,) <$> requestLine <*> many messageHeader <* endOfLine
62request = (,) <$> requestLine <*> many messageHeader <* endOfLine
64
63
65−listy :: FilePath -> IO ()
66listy arg = do
64listy arg = do
67 r <- parseFromFile (many request) arg
65 r <- parseFromFile (many request) arg
68 case r of
66 case r of
69 Left err -> putStrLn $ arg ++ ": " ++ show err
67 Left err -> putStrLn $ arg ++ ": " ++ show err
70 Right rs -> print (length rs)
68 Right rs -> print (length rs)
71
69
72−chunky :: FilePath -> IO ()
73chunky arg = bracket (openFile arg ReadMode) hClose $ \h ->
70chunky arg = bracket (openFile arg ReadMode) hClose $ \h ->
74− loop (0::Int) =<< B.hGetContents h
71+ loop 0 =<< B.hGetContents h
75 where
72 where
76 loop !n bs
73 loop !n bs
77 | B.null bs = print n
74 | B.null bs = print n
examples/RFC2616.hs+49−24
@@ -5,61 +5,86 @@ module RFC2616
5 Header(..)
5 Header(..)
6 , Request(..)
6 , Request(..)
7 , Response(..)
7 , Response(..)
8+ , isToken
9+ , messageHeader
8 , request
10 , request
11+ , requestLine
9 , response
12 , response
13+ , responseLine
14+ , lowerHeader
15+ , lookupHeader
10 ) where
16 ) where
11
17
12import Control.Applicative
18import Control.Applicative
13−import Data.Attoparsec.ByteString as P
19+import Data.Attoparsec as P
20+import qualified Data.Attoparsec.Char8 as P8
14−import Data.Attoparsec.ByteString.Char8 (char8, endOfLine, isDigit_w8)
21+import Data.Attoparsec.Char8 (char8, endOfLine, isDigit_w8)
15−import Data.ByteString (ByteString)
16import Data.Word (Word8)
22import Data.Word (Word8)
17−import Data.Attoparsec.ByteString.Char8 (isEndOfLine, isHorizontalSpace)
23+import qualified Data.ByteString.Char8 as B hiding (map)
24+import qualified Data.ByteString as B (map)
18
25
19isToken :: Word8 -> Bool
26isToken :: Word8 -> Bool
20isToken w = w <= 127 && notInClass "\0-\31()<>@,;:\\\"/[]?={} \t" w
27isToken w = w <= 127 && notInClass "\0-\31()<>@,;:\\\"/[]?={} \t" w
21
28
22skipSpaces :: Parser ()
29skipSpaces :: Parser ()
23−skipSpaces = satisfy isHorizontalSpace *> skipWhile isHorizontalSpace
30+skipSpaces = satisfy P8.isHorizontalSpace *> skipWhile P8.isHorizontalSpace
24
31
25data Request = Request {
32data Request = Request {
26− requestMethod :: ByteString
33+ requestMethod :: !B.ByteString
27− , requestUri :: ByteString
34+ , requestUri :: !B.ByteString
28− , requestVersion :: ByteString
35+ , requestVersion :: !B.ByteString
29 } deriving (Eq, Ord, Show)
36 } deriving (Eq, Ord, Show)
30
37
31−httpVersion :: Parser ByteString
38+httpVersion :: Parser B.ByteString
32httpVersion = "HTTP/" *> P.takeWhile (\c -> isDigit_w8 c || c == 46)
39httpVersion = "HTTP/" *> P.takeWhile (\c -> isDigit_w8 c || c == 46)
33
40
34requestLine :: Parser Request
41requestLine :: Parser Request
42+requestLine = do
35−requestLine = Request <$> (takeWhile1 isToken <* char8 ' ')
43+ method <- P.takeWhile1 isToken <* char8 ' '
36− <*> (takeWhile1 (/=32) <* char8 ' ')
44+ uri <- P.takeWhile1 (/=32) <* char8 ' '
37− <*> (httpVersion <* endOfLine)
45+ version <- httpVersion <* endOfLine
46+ return $! Request method uri version
38
47
39data Header = Header {
48data Header = Header {
40− headerName :: ByteString
49+ headerName :: !B.ByteString
41− , headerValue :: [ByteString]
50+ , headerValue :: [B.ByteString]
42 } deriving (Eq, Ord, Show)
51 } deriving (Eq, Ord, Show)
43
52
44messageHeader :: Parser Header
53messageHeader :: Parser Header
45−messageHeader = Header
54+messageHeader = do
46− <$> (P.takeWhile isToken <* char8 ':' <* skipWhile isHorizontalSpace)
55+ header <- P.takeWhile isToken <* char8 ':' <* skipWhile P8.isHorizontalSpace
47− <*> ((:) <$> (takeTill isEndOfLine <* endOfLine)
56+ body <- takeTill P8.isEndOfLine <* endOfLine
48− <*> (many $ skipSpaces *> takeTill isEndOfLine <* endOfLine))
57+ bodies <- many $ skipSpaces *> takeTill P8.isEndOfLine <* endOfLine
58+ return $! Header header (body:bodies)
49
59
50request :: Parser (Request, [Header])
60request :: Parser (Request, [Header])
51request = (,) <$> requestLine <*> many messageHeader <* endOfLine
61request = (,) <$> requestLine <*> many messageHeader <* endOfLine
52
62
53data Response = Response {
63data Response = Response {
54− responseVersion :: ByteString
64+ responseVersion :: !B.ByteString
55− , responseCode :: ByteString
65+ , responseCode :: !B.ByteString
56− , responseMsg :: ByteString
66+ , responseMsg :: !B.ByteString
57 } deriving (Eq, Ord, Show)
67 } deriving (Eq, Ord, Show)
58
68
59responseLine :: Parser Response
69responseLine :: Parser Response
70+responseLine = do
60−responseLine = Response <$> (httpVersion <* char8 ' ')
71+ version <- httpVersion <* char8 ' '
61− <*> (P.takeWhile isDigit_w8 <* char8 ' ')
72+ code <- P.takeWhile isDigit_w8 <* char8 ' '
62− <*> (takeTill isEndOfLine <* endOfLine)
73+ msg <- P.takeTill P8.isEndOfLine <* endOfLine
74+ return $! Response version code msg
63
75
64response :: Parser (Response, [Header])
76response :: Parser (Response, [Header])
65response = (,) <$> responseLine <*> many messageHeader <* endOfLine
77response = (,) <$> responseLine <*> many messageHeader <* endOfLine
78+
79+lowerHeader :: Header -> Header
80+lowerHeader (Header n v) = Header (B.map toLower n) (map (B.map toLower) v)
81+ where toLower w | w >= 65 && w <= 90 = w + 32
82+ | otherwise = w
83+
84+lookupHeader :: B.ByteString -> [Header] -> [B.ByteString]
85+lookupHeader k = go
86+ where
87+ go (Header n v:hs)
88+ | k == n = v
89+ | otherwise = go hs
90+ go _ = []
examples/Atto_RFC2616.hs → examples/TestRFC2616.hsrenamed+8−16
@@ -1,28 +1,21 @@
1{-# LANGUAGE BangPatterns #-}
1{-# LANGUAGE BangPatterns #-}
2−
3−module Main (main) where
4−
5−import Control.Applicative
6−import Control.Exception (bracket)
7−import Control.Monad (forM_)
8−import Data.Attoparsec.ByteString
9import RFC2616
2import RFC2616
10−import System.Environment
3+import Control.Monad (forM_)
11import System.IO
4import System.IO
5+import Control.Exception (bracket)
6+import System.Environment
12import qualified Data.ByteString.Char8 as B
7import qualified Data.ByteString.Char8 as B
8+import Data.Attoparsec
13
9
14−refill :: Handle -> IO B.ByteString
15−refill h = B.hGet h (80*1024)
10+refill h = B.hGet h (4*1024)
16
11
17−listy :: FilePath -> Handle -> IO ()
18listy file h = do
12listy file h = do
19 r <- parseWith (refill h) (many request) =<< refill h
13 r <- parseWith (refill h) (many request) =<< refill h
20 case r of
14 case r of
21 Fail _ _ msg -> hPutStrLn stderr $ file ++ ": " ++ msg
15 Fail _ _ msg -> hPutStrLn stderr $ file ++ ": " ++ msg
22 Done _ reqs -> print (length reqs)
16 Done _ reqs -> print (length reqs)
23−
17+
24−incrementy :: FilePath -> Handle -> IO ()
25−incrementy file h = go (0::Int) =<< refill h
18+incrementy file h = go 0 =<< refill h
26 where
19 where
27 go !n is = do
20 go !n is = do
28 r <- parseWith (refill h) request is
21 r <- parseWith (refill h) request is
@@ -35,8 +28,7 @@ incrementy file h = go (0::Int) =<< refill h
35 then print (n+1)
28 then print (n+1)
36 else go (n+1) s
29 else go (n+1) s
37 | otherwise -> go (n+1) bs
30 | otherwise -> go (n+1) bs
38−
31+
39−main :: IO ()
40main = do
32main = do
41 args <- getArgs
33 args <- getArgs
42 forM_ args $ \arg ->
34 forM_ args $ \arg ->
examples/attoparsec-examples.cabaldeleted−31
@@ -1,31 +0,0 @@
1−-- These examples are not intended to be installed.
2−-- So don't install 'em.
3−
4−name: attoparsec-examples
5−version: 0
6−cabal-version: >=1.6
7−build-type: Simple
8−
9−executable atto-rfc2616
10− main-is: Atto_RFC2616.hs
11− hs-source-dirs: .. .
12− ghc-options: -O2 -Wall -rtsopts
13− build-depends:
14− array,
15− base == 4.*,
16− bytestring >= 0.10.4.0,
17− deepseq >= 1.1,
18− scientific >= 0.3.1,
19− text >= 1.1.1.0
20−
21−executable parsec-rfc2616
22− main-is: Parsec_RFC2616.hs
23− hs-source-dirs: .
24− ghc-options: -O2 -Wall -rtsopts
25− build-depends:
26− array,
27− base == 4.*,
28− containers,
29− bytestring >= 0.10.4.0,
30− parsec,
31− text >= 1.1.1.0
examples/http-requests.txtdeleted−494
@@ -1,494 +0,0 @@
1−GET / HTTP/1.1
2−Host: www.reddit.com
3−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
4−Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
5−Accept-Language: en-us,en;q=0.5
6−Accept-Encoding: gzip, deflate
7−Connection: keep-alive
8−
9−GET /reddit.v_EZwRzV-Ns.css HTTP/1.1
10−Host: www.redditstatic.com
11−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
12−Accept: text/css,*/*;q=0.1
13−Accept-Language: en-us,en;q=0.5
14−Accept-Encoding: gzip, deflate
15−Connection: keep-alive
16−Referer: http://www.reddit.com/
17−
18−GET /reddit-init.en-us.O1zuMqOOQvY.js HTTP/1.1
19−Host: www.redditstatic.com
20−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
21−Accept: */*
22−Accept-Language: en-us,en;q=0.5
23−Accept-Encoding: gzip, deflate
24−Connection: keep-alive
25−Referer: http://www.reddit.com/
26−
27−GET /reddit.en-us.31yAfSoTsfo.js HTTP/1.1
28−Host: www.redditstatic.com
29−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
30−Accept: */*
31−Accept-Language: en-us,en;q=0.5
32−Accept-Encoding: gzip, deflate
33−Connection: keep-alive
34−Referer: http://www.reddit.com/
35−
36−GET /kill.png HTTP/1.1
37−Host: www.redditstatic.com
38−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
39−Accept: image/png,image/*;q=0.8,*/*;q=0.5
40−Accept-Language: en-us,en;q=0.5
41−Accept-Encoding: gzip, deflate
42−Connection: keep-alive
43−Referer: http://www.reddit.com/
44−
45−GET /icon.png HTTP/1.1
46−Host: www.redditstatic.com
47−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
48−Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
49−Accept-Language: en-us,en;q=0.5
50−Accept-Encoding: gzip, deflate
51−Connection: keep-alive
52−
53−GET /favicon.ico HTTP/1.1
54−Host: www.redditstatic.com
55−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
56−Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
57−Accept-Language: en-us,en;q=0.5
58−Accept-Encoding: gzip, deflate
59−Connection: keep-alive
60−
61−GET /AMZM4CWd6zstSC8y.jpg HTTP/1.1
62−Host: b.thumbs.redditmedia.com
63−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
64−Accept: image/png,image/*;q=0.8,*/*;q=0.5
65−Accept-Language: en-us,en;q=0.5
66−Accept-Encoding: gzip, deflate
67−Connection: keep-alive
68−Referer: http://www.reddit.com/
69−
70−GET /jz1d5Nm0w97-YyNm.jpg HTTP/1.1
71−Host: b.thumbs.redditmedia.com
72−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
73−Accept: image/png,image/*;q=0.8,*/*;q=0.5
74−Accept-Language: en-us,en;q=0.5
75−Accept-Encoding: gzip, deflate
76−Connection: keep-alive
77−Referer: http://www.reddit.com/
78−
79−GET /aWGO99I6yOcNUKXB.jpg HTTP/1.1
80−Host: a.thumbs.redditmedia.com
81−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
82−Accept: image/png,image/*;q=0.8,*/*;q=0.5
83−Accept-Language: en-us,en;q=0.5
84−Accept-Encoding: gzip, deflate
85−Connection: keep-alive
86−Referer: http://www.reddit.com/
87−
88−GET /rZ_rD5TjrJM0E9Aj.css HTTP/1.1
89−Host: e.thumbs.redditmedia.com
90−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
91−Accept: text/css,*/*;q=0.1
92−Accept-Language: en-us,en;q=0.5
93−Accept-Encoding: gzip, deflate
94−Connection: keep-alive
95−Referer: http://www.reddit.com/
96−
97−GET /tmsPwagFzyTvrGRx.jpg HTTP/1.1
98−Host: a.thumbs.redditmedia.com
99−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
100−Accept: image/png,image/*;q=0.8,*/*;q=0.5
101−Accept-Language: en-us,en;q=0.5
102−Accept-Encoding: gzip, deflate
103−Connection: keep-alive
104−Referer: http://www.reddit.com/
105−
106−GET /KYgUaLvXCK3TCEJx.jpg HTTP/1.1
107−Host: a.thumbs.redditmedia.com
108−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
109−Accept: image/png,image/*;q=0.8,*/*;q=0.5
110−Accept-Language: en-us,en;q=0.5
111−Accept-Encoding: gzip, deflate
112−Connection: keep-alive
113−Referer: http://www.reddit.com/
114−
115−GET /81pzxT5x2ozuEaxX.jpg HTTP/1.1
116−Host: e.thumbs.redditmedia.com
117−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
118−Accept: image/png,image/*;q=0.8,*/*;q=0.5
119−Accept-Language: en-us,en;q=0.5
120−Accept-Encoding: gzip, deflate
121−Connection: keep-alive
122−Referer: http://www.reddit.com/
123−
124−GET /MFqCUiUVPO5V8t6x.jpg HTTP/1.1
125−Host: a.thumbs.redditmedia.com
126−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
127−Accept: image/png,image/*;q=0.8,*/*;q=0.5
128−Accept-Language: en-us,en;q=0.5
129−Accept-Encoding: gzip, deflate
130−Connection: keep-alive
131−Referer: http://www.reddit.com/
132−
133−GET /TFpYTiAO5aEowokv.jpg HTTP/1.1
134−Host: e.thumbs.redditmedia.com
135−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
136−Accept: image/png,image/*;q=0.8,*/*;q=0.5
137−Accept-Language: en-us,en;q=0.5
138−Accept-Encoding: gzip, deflate
139−Connection: keep-alive
140−Referer: http://www.reddit.com/
141−
142−GET /eMWMpmm9APNeNqcF.jpg HTTP/1.1
143−Host: e.thumbs.redditmedia.com
144−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
145−Accept: image/png,image/*;q=0.8,*/*;q=0.5
146−Accept-Language: en-us,en;q=0.5
147−Accept-Encoding: gzip, deflate
148−Connection: keep-alive
149−Referer: http://www.reddit.com/
150−
151−GET /S-IpsJrOKuaK9GZ8.jpg HTTP/1.1
152−Host: c.thumbs.redditmedia.com
153−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
154−Accept: image/png,image/*;q=0.8,*/*;q=0.5
155−Accept-Language: en-us,en;q=0.5
156−Accept-Encoding: gzip, deflate
157−Connection: keep-alive
158−Referer: http://www.reddit.com/
159−
160−GET /3V6dj9PDsNnheDXn.jpg HTTP/1.1
161−Host: c.thumbs.redditmedia.com
162−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
163−Accept: image/png,image/*;q=0.8,*/*;q=0.5
164−Accept-Language: en-us,en;q=0.5
165−Accept-Encoding: gzip, deflate
166−Connection: keep-alive
167−Referer: http://www.reddit.com/
168−
169−GET /wQ3-VmNXhv8sg4SJ.jpg HTTP/1.1
170−Host: c.thumbs.redditmedia.com
171−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
172−Accept: image/png,image/*;q=0.8,*/*;q=0.5
173−Accept-Language: en-us,en;q=0.5
174−Accept-Encoding: gzip, deflate
175−Connection: keep-alive
176−Referer: http://www.reddit.com/
177−
178−GET /ixd1C1njpczEWC22.jpg HTTP/1.1
179−Host: c.thumbs.redditmedia.com
180−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
181−Accept: image/png,image/*;q=0.8,*/*;q=0.5
182−Accept-Language: en-us,en;q=0.5
183−Accept-Encoding: gzip, deflate
184−Connection: keep-alive
185−Referer: http://www.reddit.com/
186−
187−GET /nGsQj15VyOHMwmq8.jpg HTTP/1.1
188−Host: c.thumbs.redditmedia.com
189−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
190−Accept: image/png,image/*;q=0.8,*/*;q=0.5
191−Accept-Language: en-us,en;q=0.5
192−Accept-Encoding: gzip, deflate
193−Connection: keep-alive
194−Referer: http://www.reddit.com/
195−
196−GET /zT4yQmDxQLbIxK1b.jpg HTTP/1.1
197−Host: c.thumbs.redditmedia.com
198−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
199−Accept: image/png,image/*;q=0.8,*/*;q=0.5
200−Accept-Language: en-us,en;q=0.5
201−Accept-Encoding: gzip, deflate
202−Connection: keep-alive
203−Referer: http://www.reddit.com/
204−
205−GET /L5e1HcZLv1iu4nrG.jpg HTTP/1.1
206−Host: f.thumbs.redditmedia.com
207−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
208−Accept: image/png,image/*;q=0.8,*/*;q=0.5
209−Accept-Language: en-us,en;q=0.5
210−Accept-Encoding: gzip, deflate
211−Connection: keep-alive
212−Referer: http://www.reddit.com/
213−
214−GET /WJFFPxD8X4JO_lIG.jpg HTTP/1.1
215−Host: f.thumbs.redditmedia.com
216−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
217−Accept: image/png,image/*;q=0.8,*/*;q=0.5
218−Accept-Language: en-us,en;q=0.5
219−Accept-Encoding: gzip, deflate
220−Connection: keep-alive
221−Referer: http://www.reddit.com/
222−
223−GET /hVMVTDdjuY3bQox5.jpg HTTP/1.1
224−Host: f.thumbs.redditmedia.com
225−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
226−Accept: image/png,image/*;q=0.8,*/*;q=0.5
227−Accept-Language: en-us,en;q=0.5
228−Accept-Encoding: gzip, deflate
229−Connection: keep-alive
230−Referer: http://www.reddit.com/
231−
232−GET /rnWf8CjBcyPQs5y_.jpg HTTP/1.1
233−Host: f.thumbs.redditmedia.com
234−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
235−Accept: image/png,image/*;q=0.8,*/*;q=0.5
236−Accept-Language: en-us,en;q=0.5
237−Accept-Encoding: gzip, deflate
238−Connection: keep-alive
239−Referer: http://www.reddit.com/
240−
241−GET /gZJL1jNylKbGV4d-.jpg HTTP/1.1
242−Host: d.thumbs.redditmedia.com
243−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
244−Accept: image/png,image/*;q=0.8,*/*;q=0.5
245−Accept-Language: en-us,en;q=0.5
246−Accept-Encoding: gzip, deflate
247−Connection: keep-alive
248−Referer: http://www.reddit.com/
249−
250−GET /aNd2zNRLXiMnKUFh.jpg HTTP/1.1
251−Host: c.thumbs.redditmedia.com
252−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
253−Accept: image/png,image/*;q=0.8,*/*;q=0.5
254−Accept-Language: en-us,en;q=0.5
255−Accept-Encoding: gzip, deflate
256−Connection: keep-alive
257−Referer: http://www.reddit.com/
258−
259−GET /droparrowgray.gif HTTP/1.1
260−Host: www.redditstatic.com
261−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
262−Accept: image/png,image/*;q=0.8,*/*;q=0.5
263−Accept-Language: en-us,en;q=0.5
264−Accept-Encoding: gzip, deflate
265−Connection: keep-alive
266−Referer: http://www.redditstatic.com/reddit.v_EZwRzV-Ns.css
267−
268−GET /sprite-reddit.an0Lnf61Ap4.png HTTP/1.1
269−Host: www.redditstatic.com
270−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
271−Accept: image/png,image/*;q=0.8,*/*;q=0.5
272−Accept-Language: en-us,en;q=0.5
273−Accept-Encoding: gzip, deflate
274−Connection: keep-alive
275−Referer: http://www.redditstatic.com/reddit.v_EZwRzV-Ns.css
276−
277−GET /ga.js HTTP/1.1
278−Host: www.google-analytics.com
279−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
280−Accept: */*
281−Accept-Language: en-us,en;q=0.5
282−Accept-Encoding: gzip, deflate
283−Connection: keep-alive
284−Referer: http://www.reddit.com/
285−If-Modified-Since: Tue, 29 Oct 2013 19:33:51 GMT
286−
287−GET /reddit/ads.html?sr=-reddit.com&bust2 HTTP/1.1
288−Host: static.adzerk.net
289−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
290−Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
291−Accept-Language: en-us,en;q=0.5
292−Accept-Encoding: gzip, deflate
293−Connection: keep-alive
294−Referer: http://www.reddit.com/
295−
296−GET /pixel/of_destiny.png?v=hOlmDALJCWWdjzfBV4ZxJPmrdCLWB%2Ftq7Z%2Ffp4Q%2FxXbVPPREuMJMVGzKraTuhhNWxCCwi6yFEZg%3D&r=783333388 HTTP/1.1
297−Host: pixel.redditmedia.com
298−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
299−Accept: image/png,image/*;q=0.8,*/*;q=0.5
300−Accept-Language: en-us,en;q=0.5
301−Accept-Encoding: gzip, deflate
302−Connection: keep-alive
303−Referer: http://www.reddit.com/
304−
305−GET /UNcO-h_QcS9PD-Gn.jpg HTTP/1.1
306−Host: c.thumbs.redditmedia.com
307−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
308−Accept: image/png,image/*;q=0.8,*/*;q=0.5
309−Accept-Language: en-us,en;q=0.5
310−Accept-Encoding: gzip, deflate
311−Connection: keep-alive
312−Referer: http://e.thumbs.redditmedia.com/rZ_rD5TjrJM0E9Aj.css
313−
314−GET /welcome-lines.png HTTP/1.1
315−Host: www.redditstatic.com
316−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
317−Accept: image/png,image/*;q=0.8,*/*;q=0.5
318−Accept-Language: en-us,en;q=0.5
319−Accept-Encoding: gzip, deflate
320−Connection: keep-alive
321−Referer: http://www.redditstatic.com/reddit.v_EZwRzV-Ns.css
322−
323−GET /welcome-upvote.png HTTP/1.1
324−Host: www.redditstatic.com
325−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
326−Accept: image/png,image/*;q=0.8,*/*;q=0.5
327−Accept-Language: en-us,en;q=0.5
328−Accept-Encoding: gzip, deflate
329−Connection: keep-alive
330−Referer: http://www.redditstatic.com/reddit.v_EZwRzV-Ns.css
331−
332−GET /__utm.gif?utmwv=5.5.1&utms=1&utmn=720496082&utmhn=www.reddit.com&utme=8(site*srpath*usertype*uitype)9(%20reddit.com*%20reddit.com-GET_listing*guest*web)11(3!2)&utmcs=UTF-8&utmsr=2560x1600&utmvp=1288x792&utmsc=24-bit&utmul=en-us&utmje=1&utmfl=13.0%20r0&utmdt=reddit%3A%20the%20front%20page%20of%20the%20internet&utmhid=2129416330&utmr=-&utmp=%2F&utmht=1400862512705&utmac=UA-12131688-1&utmcc=__utma%3D55650728.585571751.1400862513.1400862513.1400862513.1%3B%2B__utmz%3D55650728.1400862513.1.1.utmcsr%3D(direct)%7Cutmccn%3D(direct)%7Cutmcmd%3D(none)%3B&utmu=qR~ HTTP/1.1
333−Host: www.google-analytics.com
334−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
335−Accept: image/png,image/*;q=0.8,*/*;q=0.5
336−Accept-Language: en-us,en;q=0.5
337−Accept-Encoding: gzip, deflate
338−Connection: keep-alive
339−Referer: http://www.reddit.com/
340−
341−GET /ImnpOQhbXUPkwceN.png HTTP/1.1
342−Host: a.thumbs.redditmedia.com
343−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
344−Accept: image/png,image/*;q=0.8,*/*;q=0.5
345−Accept-Language: en-us,en;q=0.5
346−Accept-Encoding: gzip, deflate
347−Connection: keep-alive
348−Referer: http://www.reddit.com/
349−
350−GET /ajax/libs/jquery/1.7.1/jquery.min.js HTTP/1.1
351−Host: ajax.googleapis.com
352−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
353−Accept: */*
354−Accept-Language: en-us,en;q=0.5
355−Accept-Encoding: gzip, deflate
356−Connection: keep-alive
357−Referer: http://static.adzerk.net/reddit/ads.html?sr=-reddit.com&bust2
358−
359−GET /__utm.gif?utmwv=5.5.1&utms=2&utmn=1493472678&utmhn=www.reddit.com&utmt=event&utme=5(AdBlock*enabled*false)(0)8(site*srpath*usertype*uitype)9(%20reddit.com*%20reddit.com-GET_listing*guest*web)11(3!2)&utmcs=UTF-8&utmsr=2560x1600&utmvp=1288x792&utmsc=24-bit&utmul=en-us&utmje=1&utmfl=13.0%20r0&utmdt=reddit%3A%20the%20front%20page%20of%20the%20internet&utmhid=2129416330&utmr=-&utmp=%2F&utmht=1400862512708&utmac=UA-12131688-1&utmni=1&utmcc=__utma%3D55650728.585571751.1400862513.1400862513.1400862513.1%3B%2B__utmz%3D55650728.1400862513.1.1.utmcsr%3D(direct)%7Cutmccn%3D(direct)%7Cutmcmd%3D(none)%3B&utmu=6R~ HTTP/1.1
360−Host: www.google-analytics.com
361−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
362−Accept: image/png,image/*;q=0.8,*/*;q=0.5
363−Accept-Language: en-us,en;q=0.5
364−Accept-Encoding: gzip, deflate
365−Connection: keep-alive
366−Referer: http://www.reddit.com/
367−
368−GET /ados.js?q=43 HTTP/1.1
369−Host: secure.adzerk.net
370−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
371−Accept: */*
372−Accept-Language: en-us,en;q=0.5
373−Accept-Encoding: gzip, deflate
374−Connection: keep-alive
375−Referer: http://static.adzerk.net/reddit/ads.html?sr=-reddit.com&bust2
376−
377−GET /fetch-trackers?callback=jQuery111005268222517967478_1400862512407&ids%5B%5D=t3_25jzeq-t8_k2ii&_=1400862512408 HTTP/1.1
378−Host: tracker.redditmedia.com
379−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
380−Accept: */*
381−Accept-Language: en-us,en;q=0.5
382−Accept-Encoding: gzip, deflate
383−Connection: keep-alive
384−Referer: http://www.reddit.com/
385−
386−GET /ados?t=1400862512892&request={%22Placements%22:[{%22A%22:5146,%22S%22:24950,%22D%22:%22main%22,%22AT%22:5},{%22A%22:5146,%22S%22:24950,%22D%22:%22sponsorship%22,%22AT%22:8}],%22Keywords%22:%22-reddit.com%22,%22Referrer%22:%22http%3A%2F%2Fwww.reddit.com%2F%22,%22IsAsync%22:true,%22WriteResults%22:true} HTTP/1.1
387−Host: engine.adzerk.net
388−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
389−Accept: */*
390−Accept-Language: en-us,en;q=0.5
391−Accept-Encoding: gzip, deflate
392−Connection: keep-alive
393−Referer: http://static.adzerk.net/reddit/ads.html?sr=-reddit.com&bust2
394−
395−GET /pixel/of_doom.png?id=t3_25jzeq-t8_k2ii&hash=da31d967485cdbd459ce1e9a5dde279fef7fc381&r=1738649500 HTTP/1.1
396−Host: pixel.redditmedia.com
397−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
398−Accept: image/png,image/*;q=0.8,*/*;q=0.5
399−Accept-Language: en-us,en;q=0.5
400−Accept-Encoding: gzip, deflate
401−Connection: keep-alive
402−Referer: http://www.reddit.com/
403−
404−GET /Extensions/adFeedback.js HTTP/1.1
405−Host: static.adzrk.net
406−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
407−Accept: */*
408−Accept-Language: en-us,en;q=0.5
409−Accept-Encoding: gzip, deflate
410−Connection: keep-alive
411−Referer: http://static.adzerk.net/reddit/ads.html?sr=-reddit.com&bust2
412−
413−GET /Extensions/adFeedback.css HTTP/1.1
414−Host: static.adzrk.net
415−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
416−Accept: text/css,*/*;q=0.1
417−Accept-Language: en-us,en;q=0.5
418−Accept-Encoding: gzip, deflate
419−Connection: keep-alive
420−Referer: http://static.adzerk.net/reddit/ads.html?sr=-reddit.com&bust2
421−
422−GET /reddit/ads-load.html?bust2 HTTP/1.1
423−Host: static.adzerk.net
424−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
425−Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
426−Accept-Language: en-us,en;q=0.5
427−Accept-Encoding: gzip, deflate
428−Connection: keep-alive
429−Referer: http://www.reddit.com/
430−
431−GET /Advertisers/a774d7d6148046efa89403a8db635a81.jpg HTTP/1.1
432−Host: static.adzerk.net
433−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
434−Accept: image/png,image/*;q=0.8,*/*;q=0.5
435−Accept-Language: en-us,en;q=0.5
436−Accept-Encoding: gzip, deflate
437−Connection: keep-alive
438−Referer: http://static.adzerk.net/reddit/ads.html?sr=-reddit.com&bust2
439−
440−GET /i.gif?e=eyJhdiI6NjIzNTcsImF0Ijo1LCJjbSI6MTE2MzUxLCJjaCI6Nzk4NCwiY3IiOjMzNzAxNSwiZGkiOiI4NmI2Y2UzYWM5NDM0MjhkOTk2ZTg4MjYwZDE5ZTE1YyIsImRtIjoxLCJmYyI6NDE2MTI4LCJmbCI6MjEwNDY0LCJrdyI6Ii1yZWRkaXQuY29tIiwibWsiOiItcmVkZGl0LmNvbSIsIm53Ijo1MTQ2LCJwYyI6MCwicHIiOjIwMzYyLCJydCI6MSwicmYiOiJodHRwOi8vd3d3LnJlZGRpdC5jb20vIiwic3QiOjI0OTUwLCJ1ayI6InVlMS01ZWIwOGFlZWQ5YTc0MDFjOTE5NWNiOTMzZWI3Yzk2NiIsInRzIjoxNDAwODYyNTkzNjQ1fQ&s=lwlbFf2Uywt7zVBFRj_qXXu7msY HTTP/1.1
441−Host: engine.adzerk.net
442−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
443−Accept: image/png,image/*;q=0.8,*/*;q=0.5
444−Accept-Language: en-us,en;q=0.5
445−Accept-Encoding: gzip, deflate
446−Connection: keep-alive
447−Referer: http://static.adzerk.net/reddit/ads.html?sr=-reddit.com&bust2
448−Cookie: azk=ue1-5eb08aeed9a7401c9195cb933eb7c966
449−
450−GET /BurstingPipe/adServer.bs?cn=tf&c=19&mc=imp&pli=9994987&PluID=0&ord=1400862593644&rtu=-1 HTTP/1.1
451−Host: bs.serving-sys.com
452−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
453−Accept: image/png,image/*;q=0.8,*/*;q=0.5
454−Accept-Language: en-us,en;q=0.5
455−Accept-Encoding: gzip, deflate
456−Connection: keep-alive
457−Referer: http://static.adzerk.net/reddit/ads.html?sr=-reddit.com&bust2
458−
459−GET /Advertisers/63cfd0044ffd49c0a71a6626f7a1d8f0.jpg HTTP/1.1
460−Host: static.adzerk.net
461−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
462−Accept: image/png,image/*;q=0.8,*/*;q=0.5
463−Accept-Language: en-us,en;q=0.5
464−Accept-Encoding: gzip, deflate
465−Connection: keep-alive
466−Referer: http://static.adzerk.net/reddit/ads-load.html?bust2
467−
468−GET /BurstingPipe/adServer.bs?cn=tf&c=19&mc=imp&pli=9962555&PluID=0&ord=1400862593645&rtu=-1 HTTP/1.1
469−Host: bs.serving-sys.com
470−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
471−Accept: image/png,image/*;q=0.8,*/*;q=0.5
472−Accept-Language: en-us,en;q=0.5
473−Accept-Encoding: gzip, deflate
474−Connection: keep-alive
475−Referer: http://static.adzerk.net/reddit/ads-load.html?bust2
476−Cookie: S_9994987=6754579095859875029; A4=01fmFvgRnI09SF00000; u2=d1263d39-874b-4a89-86cd-a2ab0860ed4e3Zl040
477−
478−GET /i.gif?e=eyJhdiI6NjIzNTcsImF0Ijo4LCJjbSI6MTE2MzUxLCJjaCI6Nzk4NCwiY3IiOjMzNzAxOCwiZGkiOiI3OTdlZjU3OWQ5NjE0ODdiODYyMGMyMGJkOTE4YzNiMSIsImRtIjoxLCJmYyI6NDE2MTMxLCJmbCI6MjEwNDY0LCJrdyI6Ii1yZWRkaXQuY29tIiwibWsiOiItcmVkZGl0LmNvbSIsIm53Ijo1MTQ2LCJwYyI6MCwicHIiOjIwMzYyLCJydCI6MSwicmYiOiJodHRwOi8vd3d3LnJlZGRpdC5jb20vIiwic3QiOjI0OTUwLCJ1ayI6InVlMS01ZWIwOGFlZWQ5YTc0MDFjOTE5NWNiOTMzZWI3Yzk2NiIsInRzIjoxNDAwODYyNTkzNjQ2fQ&s=OjzxzXAgQksbdQOHNm-bjZcnZPA HTTP/1.1
479−Host: engine.adzerk.net
480−User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1
481−Accept: image/png,image/*;q=0.8,*/*;q=0.5
482−Accept-Language: en-us,en;q=0.5
483−Accept-Encoding: gzip, deflate
484−Connection: keep-alive
485−Referer: http://static.adzerk.net/reddit/ads-load.html?bust2
486−Cookie: azk=ue1-5eb08aeed9a7401c9195cb933eb7c966
487−
488−GET /subscribe?host_int=1042356184&ns_map=571794054_374233948806,464381511_13349283399&user_id=245722467&nid=1399334269710011966&ts=1400862514 HTTP/1.1
489−Host: notify8.dropbox.com
490−Accept-Encoding: identity
491−Connection: keep-alive
492−X-Dropbox-Locale: en_US
493−User-Agent: DropboxDesktopClient/2.7.54 (Macintosh; 10.8; ('i32',); en_US)
494−
examples/rfc2616.c+21−27
@@ -1,22 +1,21 @@
1/*
1/*
2− * This is a simple driver for the http-parser package. It is
2+ * This is a simple driver for Ryan Dahl's hand-bummed C http-parser
3− * intended to read one HTTP request after another from a file,
3+ * package. It is intended to read one HTTP request after another
4− * nothing more.
4+ * from a file, nothing more.
5 *
5 *
6 * For "feature parity" with the Haskell code in RFC2616.hs, we
6 * For "feature parity" with the Haskell code in RFC2616.hs, we
7 * allocate and populate a simple structure describing each request,
7 * allocate and populate a simple structure describing each request,
8 * since that's the sort of thing that many real applications would
8 * since that's the sort of thing that many real applications would
9 * themselves do and the library doesn't do this for us.
9 * themselves do and the library doesn't do this for us.
10 *
10 *
11− * For the http-parser source, see
11+ * For the http-parser source, see http://github.com/ry/http-parser/
12− * https://github.com/joyent/http-parser/blob/master/http_parser.c
13 */
12 */
14
13
15/*
14/*
16 * Turn off this preprocessor symbol to have the callbacks do nothing
15 * Turn off this preprocessor symbol to have the callbacks do nothing
17 * at all, which "improves performance" by about 50%.
16 * at all, which "improves performance" by about 50%.
18 */
17 */
19−/*#define LOOK_BUSY*/
18+#define LOOK_BUSY
20
19
21#include <assert.h>
20#include <assert.h>
22#include <fcntl.h>
21#include <fcntl.h>
@@ -28,18 +27,18 @@
28#include <unistd.h>
27#include <unistd.h>
29
28
30#include "http_parser.h"
29#include "http_parser.h"
31−
30+
32struct http_string {
31struct http_string {
33 size_t len;
32 size_t len;
34 char value[0];
33 char value[0];
35};
34};
36−
35+
37struct http_header {
36struct http_header {
38 struct http_string *name;
37 struct http_string *name;
39 struct http_string *value;
38 struct http_string *value;
40 struct http_header *next;
39 struct http_header *next;
41};
40};
42−
41+
43struct http_request {
42struct http_request {
44 struct http_string *method;
43 struct http_string *method;
45 struct http_string *uri;
44 struct http_string *uri;
@@ -50,7 +49,7 @@ struct data {
50 size_t count;
49 size_t count;
51 struct http_request req;
50 struct http_request req;
52};
51};
53−
52+
54static void *xmalloc(size_t size)
53static void *xmalloc(size_t size)
55{
54{
56 void *ptr;
55 void *ptr;
@@ -79,7 +78,7 @@ static void xstrcat(struct http_string **dst, const char *src, size_t len)
79 *dst = xstrdup(src, len, 0);
78 *dst = xstrdup(src, len, 0);
80 return;
79 return;
81 }
80 }
82−
81+
83 p = xstrdup((*dst)->value, (*dst)->len, len);
82 p = xstrdup((*dst)->value, (*dst)->len, len);
84 memcpy(p->value + (*dst)->len, src, len);
83 memcpy(p->value + (*dst)->len, src, len);
85 p->len += len;
84 p->len += len;
@@ -99,7 +98,7 @@ static int begin(http_parser *p)
99static int url(http_parser *p, const char *at, size_t len)
98static int url(http_parser *p, const char *at, size_t len)
100{
99{
101#ifdef LOOK_BUSY
100#ifdef LOOK_BUSY
102− struct data *data = p->data;
101+ struct data *data = p->data;
103
102
104 xstrcat(&data->req.uri, at, len);
103 xstrcat(&data->req.uri, at, len);
105#endif
104#endif
@@ -120,7 +119,7 @@ static int header_field(http_parser *p, const char *at, size_t len)
120 hdr->name = xstrdup(at, len, 0);
119 hdr->name = xstrdup(at, len, 0);
121 hdr->value = NULL;
120 hdr->value = NULL;
122 hdr->next = NULL;
121 hdr->next = NULL;
123−
122+
124 if (data->req.last != NULL)
123 if (data->req.last != NULL)
125 data->req.last->next = hdr;
124 data->req.last->next = hdr;
126 data->req.last = hdr;
125 data->req.last = hdr;
@@ -151,7 +150,7 @@ static int complete(http_parser *p)
151
150
152 free(data->req.method);
151 free(data->req.method);
153 free(data->req.uri);
152 free(data->req.uri);
154−
153+
155 for (hdr = data->req.headers; hdr != NULL; hdr = next) {
154 for (hdr = data->req.headers; hdr != NULL; hdr = next) {
156 next = hdr->next;
155 next = hdr->next;
157 free(hdr->name);
156 free(hdr->name);
@@ -165,7 +164,7 @@ static int complete(http_parser *p)
165 data->req.headers = NULL;
164 data->req.headers = NULL;
166 data->req.last = NULL;
165 data->req.last = NULL;
167#endif
166#endif
168−
167+
169 /* Bludgeon http_parser into understanding that we really want to
168 /* Bludgeon http_parser into understanding that we really want to
170 * keep parsing after a request that in principle ought to close
169 * keep parsing after a request that in principle ought to close
171 * the "connection". */
170 * the "connection". */
@@ -181,21 +180,16 @@ static int complete(http_parser *p)
181static void parse(const char *path, int fd)
180static void parse(const char *path, int fd)
182{
181{
183 struct data data;
182 struct data data;
184− http_parser_settings s;
185 http_parser p;
183 http_parser p;
186 ssize_t nread;
184 ssize_t nread;
187
185
188− memset(&s, 0, sizeof(s));
189− s.on_message_begin = begin;
190− s.on_url = url;
191− s.on_header_field = header_field;
192− s.on_header_value = header_value;
193− s.on_message_complete = complete;
194−
195− p.data = &data;
196−
197 http_parser_init(&p, HTTP_REQUEST);
186 http_parser_init(&p, HTTP_REQUEST);
198−
187+ p.on_message_begin = begin;
188+ p.on_url = url;
189+ p.on_header_field = header_field;
190+ p.on_header_value = header_value;
191+ p.on_message_complete = complete;
192+ p.data = &data;
199 data.count = 0;
193 data.count = 0;
200 data.req.method = NULL;
194 data.req.method = NULL;
201 data.req.uri = NULL;
195 data.req.uri = NULL;
@@ -208,7 +202,7 @@ static void parse(const char *path, int fd)
208
202
209 nread = read(fd, buf, sizeof(buf));
203 nread = read(fd, buf, sizeof(buf));
210
204
211− np = http_parser_execute(&p, &s, buf, nread);
205+ np = http_parser_execute(&p, buf, nread);
212 if (np != nread) {
206 if (np != nread) {
213 fprintf(stderr, "%s: parse failed\n", path);
207 fprintf(stderr, "%s: parse failed\n", path);
214 break;
208 break;
tests/Makefilenew file+14
@@ -0,0 +1,14 @@
1+all: TestFastSet.out qc.out
2+
3+%.out: %.exe
4+ ./$< | tee $<.tmp
5+ mv $<.tmp $@
6+
7+qc.exe: QC.hs
8+ ghc -O -fno-warn-orphans --make -o $@ $<
9+
10+%.exe: %.hs
11+ ghc -O -fno-warn-orphans --make -o $@ $<
12+
13+clean:
14+ -rm -f *.hi *.o *.exe *.out
tests/QC.hs+2−8
@@ -1,19 +1,13 @@
1{-# OPTIONS_GHC -fno-warn-missing-signatures #-}
1{-# OPTIONS_GHC -fno-warn-missing-signatures #-}
2module Main (main) where
2module Main (main) where
3
3
4−import qualified QC.Buffer as Buffer
5import qualified QC.ByteString as ByteString
4import qualified QC.ByteString as ByteString
6−import qualified QC.Combinator as Combinator
7−import qualified QC.Simple as Simple
8import qualified QC.Text as Text
5import qualified QC.Text as Text
9−import Test.Tasty (defaultMain, testGroup)
6+import Test.Framework (defaultMain, testGroup)
10
7
11main = defaultMain tests
8main = defaultMain tests
12
9
13−tests = testGroup "tests" [
10+tests = [
14 testGroup "bs" ByteString.tests
11 testGroup "bs" ByteString.tests
15− , testGroup "buf" Buffer.tests
16− , testGroup "combinator" Combinator.tests
17− , testGroup "simple" Simple.tests
18 , testGroup "text" Text.tests
12 , testGroup "text" Text.tests
19 ]
13 ]
tests/QC/Buffer.hsdeleted−96
@@ -1,96 +0,0 @@
1−{-# LANGUAGE BangPatterns, CPP, FlexibleInstances, OverloadedStrings,
2− TypeSynonymInstances #-}
3−
4−module QC.Buffer (tests) where
5−
6−#if !MIN_VERSION_base(4,8,0)
7−import Control.Applicative ((<$>))
8−import Data.Monoid (Monoid(mconcat))
9−#endif
10−import QC.Common ()
11−import Test.Tasty (TestTree)
12−import Test.Tasty.QuickCheck (testProperty)
13−import Test.QuickCheck
14−import qualified Data.Attoparsec.ByteString.Buffer as BB
15−import qualified Data.Attoparsec.Text.Buffer as BT
16−import qualified Data.ByteString as B
17−import qualified Data.ByteString.Unsafe as B
18−import qualified Data.Text as T
19−import qualified Data.Text.Unsafe as T
20−
21−data BP t b = BP [t] !t !b
22− deriving (Eq, Show)
23−
24−type BPB = BP B.ByteString BB.Buffer
25−type BPT = BP T.Text BT.Buffer
26−
27−instance Arbitrary BPB where
28− arbitrary = do
29− bss <- arbitrary
30− return $! toBP BB.buffer bss
31−
32− shrink (BP bss _ _) = toBP BB.buffer <$> shrink bss
33−
34−instance Arbitrary BPT where
35− arbitrary = do
36− bss <- arbitrary
37− return $! toBP BT.buffer bss
38−
39− shrink (BP bss _ _) = toBP BT.buffer <$> shrink bss
40−
41−toBP :: (Monoid a, Monoid b) => (a -> b) -> [a] -> BP a b
42−toBP buf bss = BP bss (mconcat bss) (mconcat (map buf bss))
43−
44−b_unbuffer :: BPB -> Property
45−b_unbuffer (BP _ts t buf) = t === BB.unbuffer buf
46−
47−t_unbuffer :: BPT -> Property
48−t_unbuffer (BP _ts t buf) = t === BT.unbuffer buf
49−
50−b_length :: BPB -> Property
51−b_length (BP _ts t buf) = B.length t === BB.length buf
52−
53−t_length :: BPT -> Property
54−t_length (BP _ts t buf) = T.lengthWord16 t === BT.length buf
55−
56−b_unsafeIndex :: BPB -> Gen Property
57−b_unsafeIndex (BP _ts t buf) = do
58− let l = B.length t
59− i <- choose (0,l-1)
60− return $ l === 0 .||. B.unsafeIndex t i === BB.unsafeIndex buf i
61−
62−t_iter :: BPT -> Gen Property
63−t_iter (BP _ts t buf) = do
64− let l = T.lengthWord16 t
65− i <- choose (0,l-1)
66− let it (T.Iter c q) = (c,q)
67− return $ l === 0 .||. it (T.iter t i) === it (BT.iter buf i)
68−
69−t_iter_ :: BPT -> Gen Property
70−t_iter_ (BP _ts t buf) = do
71− let l = T.lengthWord16 t
72− i <- choose (0,l-1)
73− return $ l === 0 .||. T.iter_ t i === BT.iter_ buf i
74−
75−b_unsafeDrop :: BPB -> Gen Property
76−b_unsafeDrop (BP _ts t buf) = do
77− i <- choose (0, B.length t)
78− return $ B.unsafeDrop i t === BB.unsafeDrop i buf
79−
80−t_dropWord16 :: BPT -> Gen Property
81−t_dropWord16 (BP _ts t buf) = do
82− i <- choose (0, T.lengthWord16 t)
83− return $ T.dropWord16 i t === BT.dropWord16 i buf
84−
85−tests :: [TestTree]
86−tests = [
87− testProperty "b_unbuffer" b_unbuffer
88− , testProperty "t_unbuffer" t_unbuffer
89− , testProperty "b_length" b_length
90− , testProperty "t_length" t_length
91− , testProperty "b_unsafeIndex" b_unsafeIndex
92− , testProperty "t_iter" t_iter
93− , testProperty "t_iter_" t_iter_
94− , testProperty "b_unsafeDrop" b_unsafeDrop
95− , testProperty "t_dropWord16" t_dropWord16
96− ]
tests/QC/ByteString.hs+78−149
@@ -1,187 +1,116 @@
1−{-# LANGUAGE BangPatterns, CPP, OverloadedStrings #-}
1+{-# LANGUAGE BangPatterns, OverloadedStrings #-}
2+{-# OPTIONS_GHC -fno-warn-missing-signatures -fno-warn-orphans #-}
2module QC.ByteString (tests) where
3module QC.ByteString (tests) where
3
4
4−#if !MIN_VERSION_base(4,8,0)
5−import Control.Applicative ((<*>), (<$>))
5+import Control.Applicative ((<$>), (<*>))
6−#endif
7−import Data.Char (chr, ord, toUpper)
8−import Data.Int (Int64)
9−import Data.Word (Word8)
10−import Prelude hiding (take, takeWhile)
6+import Prelude hiding (takeWhile)
11−import QC.Common (ASCII(..), liftOp, parseBS, toStrictBS)
7+import Test.Framework.Providers.QuickCheck2 (testProperty)
12−import Test.Tasty (TestTree)
13−import Test.Tasty.QuickCheck (testProperty)
14import Test.QuickCheck
8import Test.QuickCheck
15import qualified Data.Attoparsec.ByteString as P
9import qualified Data.Attoparsec.ByteString as P
16−import qualified Data.Attoparsec.ByteString.Char8 as P8
17−import qualified Data.Attoparsec.ByteString.FastSet as S
18import qualified Data.Attoparsec.ByteString.Lazy as PL
10import qualified Data.Attoparsec.ByteString.Lazy as PL
19import qualified Data.ByteString as B
11import qualified Data.ByteString as B
20−import qualified Data.ByteString.Char8 as B8
21import qualified Data.ByteString.Lazy as L
12import qualified Data.ByteString.Lazy as L
22−import qualified Data.ByteString.Lazy.Char8 as L8
13+
14+instance Arbitrary B.ByteString where
15+ arbitrary = B.pack <$> arbitrary
16+
17+instance Arbitrary L.ByteString where
18+ arbitrary = sized $ \n -> resize (round (sqrt (toEnum n :: Double)))
19+ ((L.fromChunks . map (B.pack . nonEmpty)) <$> arbitrary)
20+ where nonEmpty (NonEmpty a) = a
21+
22+-- Naming.
23+
24+{-
25+label (NonEmpty s) = case parse (anyWord8 <?> s) B.empty of
26+ (_, Left err) -> s `isInfixOf` err
27+ _ -> False
28+-}
23
29
24-- Basic byte-level combinators.
30-- Basic byte-level combinators.
25
31
26−satisfy :: Word8 -> L.ByteString -> Property
32+maybeP p = PL.maybeResult . PL.parse p
27−satisfy w s = parseBS (P.satisfy (<=w)) (L.cons w s) === Just w
28
33
29−satisfyWith :: Word8 -> L.ByteString -> Property
34+defP p = PL.parse p
30−satisfyWith w s = parseBS (P.satisfyWith (chr . fromIntegral) (<=c))
31− (L.cons (fromIntegral (ord c)) s) === Just c
32− where
33− c = chr (fromIntegral w)
34
35
35−word8 :: Word8 -> L.ByteString -> Property
36−word8 w s = parseBS (P.word8 w) (L.cons w s) === Just w
36+satisfy w s = maybeP (P.satisfy (<=w)) (L.cons w s) == Just w
37
37
38−skip :: Word8 -> L.ByteString -> Property
38+word8 w s = maybeP (P.word8 w) (L.cons w s) == Just w
39−skip w s =
40− case (parseBS (P.skip (<w)) s, L.uncons s) of
41− (Nothing, mcs) -> maybe (property True) (expectFailure . it) mcs
42− (Just _, mcs) -> maybe (property False) it mcs
43− where it cs = liftOp "<" (<) (fst cs) w
44
39
45−anyWord8 :: L.ByteString -> Property
46anyWord8 s
40anyWord8 s
47− | L.null s = p === Nothing
41+ | L.null s = p == Nothing
48− | otherwise = p === Just (L.head s)
42+ | otherwise = p == Just (L.head s)
49− where p = parseBS P.anyWord8 s
43+ where p = maybeP P.anyWord8 s
50−
44+
51−notWord8 :: Word8 -> NonEmptyList Word8 -> Property
52−notWord8 w (NonEmpty s) = parseBS (P.notWord8 w) bs === if v == w
45+notWord8 w (NonEmpty s) = maybeP (P.notWord8 w) bs == if v == w
53− then Nothing
46+ then Nothing
54− else Just v
47+ else Just v
55 where v = L.head bs
48 where v = L.head bs
56 bs = L.pack s
49 bs = L.pack s
57
50
58−peekWord8 :: L.ByteString -> Property
59peekWord8 s
51peekWord8 s
60− | L.null s = p === Just (Nothing, s)
52+ | L.null s = p == Just (Nothing, s)
61− | otherwise = p === Just (Just (L.head s), s)
53+ | otherwise = p == Just (Just (L.head s), s)
62− where p = parseBS ((,) <$> P.peekWord8 <*> P.takeLazyByteString) s
54+ where p = maybeP ((,) <$> P.peekWord8 <*> P.takeLazyByteString) s
63−
55+
64−peekWord8' :: L.ByteString -> Property
65−peekWord8' s = parseBS P.peekWord8' s === (fst <$> L.uncons s)
66−
67−string :: L.ByteString -> L.ByteString -> Property
68−string s t = parseBS (P.string s') (s `L.append` t) === Just s'
56+string s t = maybeP (P.string s') (s `L.append` t) == Just s'
69− where s' = toStrictBS s
57+ where s' = toStrict s
70−
58+
71−stringCI :: ASCII L.ByteString -> ASCII L.ByteString -> Property
59+toStrict = B.concat . L.toChunks
72−stringCI (ASCII s) (ASCII t) =
60+
73− parseBS (P8.stringCI up) (s `L.append` t) === Just s'
74− where s' = toStrictBS s
75− up = B8.map toUpper s'
76−
77−strings :: L.ByteString -> L.ByteString -> L.ByteString -> Property
78−strings s t u =
79− parseBS (P.string (toStrictBS s) >> P.string t') (L.concat [s,t,u])
80− === Just t'
81− where t' = toStrictBS t
82−
83−skipWhile :: Word8 -> L.ByteString -> Property
84skipWhile w s =
61skipWhile w s =
85 let t = L.dropWhile (<=w) s
62 let t = L.dropWhile (<=w) s
86− in case PL.parse (P.skipWhile (<=w)) s of
63+ in case defP (P.skipWhile (<=w)) s of
87− PL.Done t' () -> t === t'
64+ PL.Done t' () -> t == t'
88− _ -> property False
65+ _ -> False
89
66
90−takeCount :: Positive Int -> L.ByteString -> Property
91takeCount (Positive k) s =
67takeCount (Positive k) s =
92− case parseBS (P.take k) s of
68+ case maybeP (P.take k) s of
93− Nothing -> liftOp ">" (>) (fromIntegral k) (L.length s)
69+ Nothing -> fromIntegral k > L.length s
94− Just _s -> liftOp "<=" (<=) (fromIntegral k) (L.length s)
70+ Just s' -> fromIntegral k <= L.length s
95
71
96−takeWhile :: Word8 -> L.ByteString -> Property
97takeWhile w s =
72takeWhile w s =
98 let (h,t) = L.span (==w) s
73 let (h,t) = L.span (==w) s
99− in case PL.parse (P.takeWhile (==w)) s of
74+ in case defP (P.takeWhile (==w)) s of
100− PL.Done t' h' -> t === t' .&&. toStrictBS h === h'
75+ PL.Done t' h' -> t == t' && toStrict h == h'
101− _ -> property False
76+ _ -> False
102
77
103−take :: Int -> L.ByteString -> Property
104−take n s = maybe (property $ L.length s < fromIntegral n)
105− (=== B.take n (toStrictBS s)) $
106− parseBS (P.take n) s
107−
108−takeByteString :: L.ByteString -> Property
109−takeByteString s = maybe (property False) (=== toStrictBS s) .
110− parseBS P.takeByteString $ s
111−
112−takeLazyByteString :: L.ByteString -> Property
113−takeLazyByteString s = maybe (property False) (=== s) .
114− parseBS P.takeLazyByteString $ s
115−
116−takeWhile1 :: Word8 -> L.ByteString -> Property
117takeWhile1 w s =
78takeWhile1 w s =
118 let s' = L.cons w s
79 let s' = L.cons w s
119 (h,t) = L.span (<=w) s'
80 (h,t) = L.span (<=w) s'
120− in case PL.parse (P.takeWhile1 (<=w)) s' of
81+ in case defP (P.takeWhile1 (<=w)) s' of
121− PL.Done t' h' -> t === t' .&&. toStrictBS h === h'
82+ PL.Done t' h' -> t == t' && toStrict h == h'
122− _ -> property False
83+ _ -> False
123
84
124−takeTill :: Word8 -> L.ByteString -> Property
125takeTill w s =
85takeTill w s =
126 let (h,t) = L.break (==w) s
86 let (h,t) = L.break (==w) s
127− in case PL.parse (P.takeTill (==w)) s of
87+ in case defP (P.takeTill (==w)) s of
128− PL.Done t' h' -> t === t' .&&. toStrictBS h === h'
88+ PL.Done t' h' -> t == t' && toStrict h == h'
129− _ -> property False
89+ _ -> False
130−
90+
131−takeWhile1_empty :: Property
132−takeWhile1_empty = parseBS (P.takeWhile1 undefined) L.empty === Nothing
91+takeWhile1_empty = maybeP (P.takeWhile1 undefined) L.empty == Nothing
133−
134−endOfInput :: L.ByteString -> Property
135−endOfInput s = parseBS P.endOfInput s === if L.null s
136− then Just ()
137− else Nothing
138−
139−endOfLine :: L.ByteString -> Property
140−endOfLine s =
141− case (parseBS P8.endOfLine s, L8.uncons s) of
142− (Nothing, mcs) -> maybe (property True) (expectFailure . eol) mcs
143− (Just _, mcs) -> maybe (property False) eol mcs
144− where eol (c,s') = c === '\n' .||.
145− (c, fst <$> L8.uncons s') === ('\r', Just '\n')
146−
147−scan :: L.ByteString -> Positive Int64 -> Property
148−scan s (Positive k) = parseBS p s === Just (toStrictBS $ L.take k s)
149− where p = P.scan k $ \ n _ ->
150− if n > 0 then let !n' = n - 1 in Just n' else Nothing
151
92
152−members :: [Word8] -> Property
93+endOfInput s = maybeP P.endOfInput s == if L.null s
153−members s = property $ all (`S.memberWord8` set) s
94+ then Just ()
154− where set = S.fromList s
95+ else Nothing
155
96
156−nonmembers :: [Word8] -> [Word8] -> Property
97+scan s (Positive k) = maybeP p s == (Just $ toStrict $ L.take k s)
157−nonmembers s s' = property . not . any (`S.memberWord8` set) $ filter (not . (`elem` s)) s'
98+ where p = P.scan k $ \ n _ ->
158− where set = S.fromList s
99+ if n > 0 then let !n' = n - 1 in Just n' else Nothing
159
100
160−tests :: [TestTree]
161tests = [
101tests = [
162− testProperty "anyWord8" anyWord8
163− , testProperty "endOfInput" endOfInput
102+ testProperty "satisfy" satisfy,
164− , testProperty "endOfLine" endOfLine
103+ testProperty "word8" word8,
165− , testProperty "notWord8" notWord8
104+ testProperty "notWord8" notWord8,
166− , testProperty "peekWord8" peekWord8
105+ testProperty "anyWord8" anyWord8,
167− , testProperty "peekWord8'" peekWord8'
106+ testProperty "peekWord8" peekWord8,
168− , testProperty "satisfy" satisfy
169− , testProperty "satisfyWith" satisfyWith
107+ testProperty "string" string,
170− , testProperty "scan" scan
171− , testProperty "skip" skip
172− , testProperty "skipWhile" skipWhile
108+ testProperty "skipWhile" skipWhile,
173− , testProperty "string" string
174− , testProperty "stringCI" stringCI
175− , testProperty "strings" strings
176− , testProperty "take" take
177− , testProperty "takeByteString" takeByteString
178− , testProperty "takeCount" takeCount
109+ testProperty "takeCount" takeCount,
179− , testProperty "takeLazyByteString" takeLazyByteString
180− , testProperty "takeTill" takeTill
181− , testProperty "takeWhile" takeWhile
110+ testProperty "takeWhile" takeWhile,
182− , testProperty "takeWhile1" takeWhile1
111+ testProperty "takeWhile1" takeWhile1,
183− , testProperty "takeWhile1_empty" takeWhile1_empty
112+ testProperty "takeWhile1_empty" takeWhile1_empty,
184− , testProperty "word8" word8
113+ testProperty "takeTill" takeTill,
185− , testProperty "members" members
114+ testProperty "endOfInput" endOfInput,
186− , testProperty "nonmembers" nonmembers
115+ testProperty "scan" scan
187 ]
116 ]
tests/QC/Combinator.hsdeleted−52
@@ -1,52 +0,0 @@
1−{-# LANGUAGE CPP, OverloadedStrings #-}
2−
3−module QC.Combinator where
4−
5−#if !MIN_VERSION_base(4,8,0)
6−import Control.Applicative ((<*>), (<$>), (<*), (*>))
7−#endif
8−import Data.Maybe (fromJust, isJust)
9−import Data.Word (Word8)
10−import QC.Common (Repack, parseBS, repackBS, toLazyBS)
11−import Test.Tasty (TestTree)
12−import Test.Tasty.QuickCheck (testProperty)
13−import Test.QuickCheck
14−import qualified Data.Attoparsec.ByteString.Char8 as P
15−import qualified Data.Attoparsec.Combinator as C
16−import qualified Data.ByteString as B
17−import qualified Data.ByteString.Char8 as B8
18−
19−choice :: NonEmptyList (NonEmptyList Word8) -> Gen Property
20−choice (NonEmpty xs) = do
21− let ys = map (B.pack . getNonEmpty) xs
22− return . forAll (repackBS <$> arbitrary <*> elements ys) $
23− maybe False (`elem` ys) . parseBS (C.choice (map P.string ys))
24−
25−count :: Positive (Small Int) -> Repack -> B.ByteString -> Bool
26−count (Positive (Small n)) rs s =
27− (length <$> parseBS (C.count n (P.string s)) input) == Just n
28− where input = repackBS rs (B.concat (replicate (n+1) s))
29−
30−lookAhead :: NonEmptyList Word8 -> Bool
31−lookAhead (NonEmpty xs) =
32− let ys = B.pack xs
33− withLookAheadThenConsume = (\x y -> (x, y)) <$> C.lookAhead (P.string ys) <*> P.string ys
34− mr = parseBS withLookAheadThenConsume $ toLazyBS ys
35− in isJust mr && fst (fromJust mr) == snd (fromJust mr)
36−
37−match :: Int -> NonNegative Int -> NonNegative Int -> Repack -> Bool
38−match n (NonNegative x) (NonNegative y) rs =
39− parseBS (P.match parser) (repackBS rs input) == Just (input, n)
40− where parser = P.skipWhile (=='x') *> P.signed P.decimal <*
41− P.skipWhile (=='y')
42− input = B.concat [
43− B8.replicate x 'x', B8.pack (show n), B8.replicate y 'y'
44− ]
45−
46−tests :: [TestTree]
47−tests = [
48− testProperty "choice" choice
49− , testProperty "count" count
50− , testProperty "lookAhead" lookAhead
51− , testProperty "match" match
52− ]
tests/QC/Common.hsdeleted−113
@@ -1,113 +0,0 @@
1−{-# LANGUAGE CPP, FlexibleInstances #-}
2−{-# OPTIONS_GHC -fno-warn-orphans #-}
3−module QC.Common
4− (
5− ASCII(..)
6− , parseBS
7− , parseT
8− , toLazyBS
9− , toStrictBS
10− , Repack
11− , repackBS
12− , repackBS_
13− , repackT
14− , repackT_
15− , liftOp
16− ) where
17−
18−#if !MIN_VERSION_base(4,8,0)
19−import Control.Applicative ((<*>), (<$>))
20−#endif
21−import Data.Char (isAlpha)
22−import Test.QuickCheck
23−import Test.QuickCheck.Unicode (shrinkChar, string)
24−import qualified Data.ByteString as B
25−import qualified Data.ByteString.Lazy as BL
26−import qualified Data.Text as T
27−import qualified Data.Text.Lazy as TL
28−import qualified Data.Attoparsec.ByteString.Lazy as BL
29−import qualified Data.Attoparsec.Text.Lazy as TL
30−
31−#if !MIN_VERSION_base(4,4,0)
32−-- This should really be a dependency on the random package :-(
33−instance Random Word8 where
34− randomR = integralRandomR
35− random = randomR (minBound,maxBound)
36−
37−instance Arbitrary Word8 where
38− arbitrary = choose (minBound, maxBound)
39−#endif
40−
41−parseBS :: BL.Parser r -> BL.ByteString -> Maybe r
42−parseBS p = BL.maybeResult . BL.parse p
43−
44−parseT :: TL.Parser r -> TL.Text -> Maybe r
45−parseT p = TL.maybeResult . TL.parse p
46−
47−toStrictBS :: BL.ByteString -> B.ByteString
48−toStrictBS = B.concat . BL.toChunks
49−
50−toLazyBS :: B.ByteString -> BL.ByteString
51−toLazyBS = BL.fromChunks . (:[])
52−
53−instance Arbitrary B.ByteString where
54− arbitrary = B.pack <$> arbitrary
55− shrink = map B.pack . shrink . B.unpack
56−
57−instance Arbitrary BL.ByteString where
58− arbitrary = repackBS <$> arbitrary <*> arbitrary
59− shrink = map BL.pack . shrink . BL.unpack
60−
61−newtype ASCII a = ASCII { fromASCII :: a }
62− deriving (Eq, Ord, Show)
63−
64−instance Arbitrary (ASCII B.ByteString) where
65− arbitrary = (ASCII . B.pack) <$> listOf (choose (0,127))
66− shrink = map (ASCII . B.pack) . shrink . B.unpack . fromASCII
67−
68−instance Arbitrary (ASCII BL.ByteString) where
69− arbitrary = ASCII <$> (repackBS <$> arbitrary <*> (fromASCII <$> arbitrary))
70− shrink = map (ASCII . BL.pack) . shrink . BL.unpack . fromASCII
71−
72−type Repack = NonEmptyList (Positive (Small Int))
73−
74−repackBS :: Repack -> B.ByteString -> BL.ByteString
75−repackBS (NonEmpty bs) =
76− BL.fromChunks . repackBS_ (map (getSmall . getPositive) bs)
77−
78−repackBS_ :: [Int] -> B.ByteString -> [B.ByteString]
79−repackBS_ = go . cycle
80− where go (b:bs) s
81− | B.null s = []
82− | otherwise = let (h,t) = B.splitAt b s
83− in h : go bs t
84− go _ _ = error "unpossible"
85−
86−instance Arbitrary T.Text where
87− arbitrary = T.pack <$> string
88− shrink = map T.pack . shrinkList shrinkChar . T.unpack
89−
90−instance Arbitrary TL.Text where
91− arbitrary = TL.pack <$> string
92− shrink = map TL.pack . shrinkList shrinkChar . TL.unpack
93−
94−repackT :: Repack -> T.Text -> TL.Text
95−repackT (NonEmpty bs) =
96− TL.fromChunks . repackT_ (map (getSmall . getPositive) bs)
97−
98−repackT_ :: [Int] -> T.Text -> [T.Text]
99−repackT_ = go . cycle
100− where go (b:bs) s
101− | T.null s = []
102− | otherwise = let (h,t) = T.splitAt b s
103− in h : go bs t
104− go _ _ = error "unpossible"
105−
106−liftOp :: (Show a, Testable prop) =>
107− String -> (a -> a -> prop) -> a -> a -> Property
108−liftOp name f x y = counterexample desc (f x y)
109− where op = case name of
110− (c:_) | isAlpha c -> " `" ++ name ++ "` "
111− | otherwise -> " " ++ name ++ " "
112− _ -> " ??? "
113− desc = "not (" ++ show x ++ op ++ show y ++ ")"
tests/QC/IPv6/Internal.hsdeleted−316
@@ -1,316 +0,0 @@
1−-- -----------------------------------------------------------------------------
2−
3−-- |
4−-- Module : Text.IPv6Addr
5−-- Copyright : Copyright © Michel Boucey 2011-2015
6−-- License : BSD-Style
7−-- Maintainer : michel.boucey@gmail.com
8−--
9−-- Dealing with IPv6 address text representations, canonization and manipulations.
10−--
11−
12−-- -----------------------------------------------------------------------------
13−
14−{-# LANGUAGE OverloadedStrings #-}
15−
16−module QC.IPv6.Internal where {-
17− ( expandTokens
18− , macAddr
19− , maybeIPv6AddrTokens
20− , ipv4AddrToIPv6AddrTokens
21− , ipv6TokensToText
22− , ipv6TokensToIPv6Addr
23− , isIPv6Addr
24− , maybeTokIPv6Addr
25− , maybeTokPureIPv6Addr
26− , fromDoubleColon
27− , fromIPv6Addr
28− , toDoubleColon
29− ) where -}
30−
31−import Debug.Trace
32−import Control.Monad (replicateM)
33−import Data.Attoparsec.Text
34−import Data.Char (isDigit,isHexDigit,toLower)
35−import Data.Monoid ((<>))
36−import Control.Applicative ((<|>),(<*))
37−import Data.List (group,isSuffixOf,elemIndex,elemIndices,intersperse)
38−import Data.Word (Word32)
39−import Numeric (showHex)
40−import qualified Data.Text as T
41−import qualified Data.Text.Read as R (decimal)
42−import Data.Maybe (fromJust)
43−
44−import QC.IPv6.Types
45−
46−tok0 = "0"
47−
48−-- | Returns the 'T.Text' of an IPv6 address.
49−fromIPv6Addr :: IPv6Addr -> T.Text
50−fromIPv6Addr (IPv6Addr t) = t
51−
52−-- | Given an arbitrary list of 'IPv6AddrToken', returns the corresponding 'T.Text'.
53−ipv6TokensToText :: [IPv6AddrToken] -> T.Text
54−ipv6TokensToText l = T.concat $ map ipv6TokenToText l
55−
56−-- | Returns the corresponding 'T.Text' of an IPv6 address token.
57−ipv6TokenToText :: IPv6AddrToken -> T.Text
58−ipv6TokenToText (SixteenBit s) = s
59−ipv6TokenToText Colon = ":"
60−ipv6TokenToText DoubleColon = "::"
61−ipv6TokenToText AllZeros = tok0 -- "A single 16-bit 0000 field MUST be represented as 0" (RFC 5952, 4.1)
62−ipv6TokenToText (IPv4Addr a) = a
63−
64−-- | Returns 'True' if a list of 'IPv6AddrToken' constitutes a valid IPv6 Address.
65−isIPv6Addr :: [IPv6AddrToken] -> Bool
66−isIPv6Addr [] = False
67−isIPv6Addr [DoubleColon] = True
68−isIPv6Addr [DoubleColon,SixteenBit tok1] = True
69−isIPv6Addr tks =
70− diffNext tks && (do
71− let cdctks = countDoubleColon tks
72− let lentks = length tks
73− let lasttk = last tks
74− let lenconst = (lentks == 15 && cdctks == 0) || (lentks < 15 && cdctks == 1)
75− firstValidToken tks &&
76− (case countIPv4Addr tks of
77− 0 -> case lasttk of
78− SixteenBit _ -> lenconst
79− DoubleColon -> lenconst
80− AllZeros -> lenconst
81− _ -> False
82− 1 -> case lasttk of
83− IPv4Addr _ -> (lentks == 13 && cdctks == 0) || (lentks < 12 && cdctks == 1)
84− _ -> False
85− otherwise -> False))
86− where diffNext [] = False
87− diffNext [_] = True
88− diffNext (t:ts) = do
89− let h = head ts
90− case t of
91− SixteenBit _ -> case h of
92− SixteenBit _ -> False
93− AllZeros -> False
94− _ -> diffNext ts
95− AllZeros -> case h of
96− SixteenBit _ -> False
97− AllZeros -> False
98− _ -> diffNext ts
99− _ -> diffNext ts
100− firstValidToken l =
101− case head l of
102− SixteenBit _ -> True
103− DoubleColon -> True
104− AllZeros -> True
105− _ -> False
106− countDoubleColon l = length $ elemIndices DoubleColon l
107− tok1 = "1"
108−
109−countIPv4Addr = foldr oneMoreIPv4Addr 0
110− where
111− oneMoreIPv4Addr t c = case t of
112− IPv4Addr _ -> c + 1
113− otherwise -> c
114−
115−-- | This is the main function which returns 'Just' the list of a tokenized IPv6
116−-- address text representation validated against RFC 4291 and canonized
117−-- in conformation with RFC 5952, or 'Nothing'.
118−maybeTokIPv6Addr :: T.Text -> Maybe [IPv6AddrToken]
119−maybeTokIPv6Addr t =
120− case maybeIPv6AddrTokens t of
121− Just ltks -> if isIPv6Addr ltks
122− then Just $ (ipv4AddrReplacement . toDoubleColon . fromDoubleColon) ltks
123− else Nothing
124− Nothing -> Nothing
125− where
126− ipv4AddrReplacement ltks =
127− if ipv4AddrRewrite ltks
128− then init ltks ++ ipv4AddrToIPv6AddrTokens (last ltks)
129− else ltks
130−
131−-- | Returns 'Just' the list of tokenized pure IPv6 address, always rewriting an
132−-- embedded IPv4 address if present.
133−maybeTokPureIPv6Addr :: T.Text -> Maybe [IPv6AddrToken]
134−maybeTokPureIPv6Addr t = do
135− ltks <- maybeIPv6AddrTokens t
136− if isIPv6Addr ltks
137− then Just $ (toDoubleColon . ipv4AddrReplacement . fromDoubleColon) ltks
138− else Nothing
139− where
140− ipv4AddrReplacement ltks' = init ltks' ++ ipv4AddrToIPv6AddrTokens (last ltks')
141−
142−-- | Tokenize a 'T.Text' into 'Just' a list of 'IPv6AddrToken', or 'Nothing'.
143−maybeIPv6AddrTokens :: T.Text -> Maybe [IPv6AddrToken]
144−maybeIPv6AddrTokens s =
145− case readText s of
146− Done r l -> traceShow (r,l) $ if r==T.empty then Just l else Nothing
147− Fail {} -> Nothing
148− where
149− readText s = feed (parse (many1 $ ipv4Addr <|> sixteenBit <|> doubleColon <|> colon) s) T.empty
150−
151−-- | An embedded IPv4 address have to be rewritten to output a pure IPv6 Address
152−-- text representation in hexadecimal digits. But some well-known prefixed IPv6
153−-- addresses have to keep visible in their text representation the fact that
154−-- they deals with IPv4 to IPv6 transition process (RFC 5952 Section 5):
155−--
156−-- IPv4-compatible IPv6 address like "::1.2.3.4"
157−--
158−-- IPv4-mapped IPv6 address like "::ffff:1.2.3.4"
159−--
160−-- IPv4-translated address like "::ffff:0:1.2.3.4"
161−--
162−-- IPv4-translatable address like "64:ff9b::1.2.3.4"
163−--
164−-- ISATAP address like "fe80::5efe:1.2.3.4"
165−--
166−ipv4AddrRewrite :: [IPv6AddrToken] -> Bool
167−ipv4AddrRewrite tks =
168− case last tks of
169− IPv4Addr _ -> do
170− let itks = init tks
171− not (itks == [DoubleColon]
172− || itks == [DoubleColon,SixteenBit tokffff,Colon]
173− || itks == [DoubleColon,SixteenBit tokffff,Colon,AllZeros,Colon]
174− || itks == [SixteenBit "64",Colon,SixteenBit "ff9b",DoubleColon]
175− || [SixteenBit "200",Colon,SixteenBit tok5efe,Colon] `isSuffixOf` itks
176− || [AllZeros,Colon,SixteenBit tok5efe,Colon] `isSuffixOf` itks
177− || [DoubleColon,SixteenBit tok5efe,Colon] `isSuffixOf` itks)
178− _ -> False
179− where
180− tokffff = "ffff"
181− tok5efe = "5efe"
182−
183−-- | Rewrites an embedded 'IPv4Addr' into the corresponding list of pure 'IPv6Addr' tokens.
184−--
185−-- > ipv4AddrToIPv6AddrTokens (IPv4Addr "127.0.0.1") == [SixteenBits "7f0",Colon,SixteenBits "1"]
186−--
187−ipv4AddrToIPv6AddrTokens :: IPv6AddrToken -> [IPv6AddrToken]
188−ipv4AddrToIPv6AddrTokens t =
189− case t of
190− IPv4Addr a -> do
191− let m = toHex a
192− [ SixteenBit ((!!) m 0 <> addZero ((!!) m 1))
193− , Colon
194− , SixteenBit ((!!) m 2 <> addZero ((!!) m 3)) ]
195− _ -> [t]
196− where
197− toHex a = map (\x -> T.pack $ showHex (read (T.unpack x)::Int) "") $ T.split (=='.') a
198− addZero d = if T.length d == 1 then tok0 <> d else d
199−
200−expandTokens :: [IPv6AddrToken] -> [IPv6AddrToken]
201−expandTokens = map expandToken
202− where expandToken (SixteenBit s) = SixteenBit $ T.justifyRight 4 '0' s
203− expandToken AllZeros = SixteenBit "0000"
204− expandToken t = t
205−
206−fromDoubleColon :: [IPv6AddrToken] -> [IPv6AddrToken]
207−fromDoubleColon tks =
208− if DoubleColon `notElem` tks
209− then tks
210− else do let s = splitAt (fromJust $ elemIndex DoubleColon tks) tks
211− let fsts = fst s
212− let snds = if not (null (snd s)) then tail(snd s) else []
213− let fste = if null fsts then [] else fsts ++ [Colon]
214− let snde = if null snds then [] else Colon : snds
215− fste ++ allZerosTokensReplacement(quantityOfAllZerosTokenToReplace tks) ++ snde
216− where
217− allZerosTokensReplacement x = intersperse Colon (replicate x AllZeros)
218− quantityOfAllZerosTokenToReplace x =
219− ntks tks - foldl (\c x -> if (x /= DoubleColon) && (x /= Colon) then c+1 else c) 0 x
220− where
221− ntks tks = if countIPv4Addr tks == 1 then 7 else 8
222−
223−toDoubleColon :: [IPv6AddrToken] -> [IPv6AddrToken]
224−toDoubleColon tks =
225− zerosToDoubleColon tks (zerosRunToReplace $ zerosRunsList tks)
226− where
227− zerosToDoubleColon :: [IPv6AddrToken] -> (Int,Int) -> [IPv6AddrToken]
228− -- No all zeros token, so no double colon replacement...
229− zerosToDoubleColon ls (_,0) = ls
230− -- "The symbol '::' MUST NOT be used to shorten just one 16-bit 0 field" (RFC 5952 4.2.2)
231− zerosToDoubleColon ls (_,1) = ls
232− zerosToDoubleColon ls (i,l) =
233− let ls' = filter (/= Colon) ls
234− in intersperse Colon (Prelude.take i ls') ++ [DoubleColon] ++ intersperse Colon (drop (i+l) ls')
235− zerosRunToReplace t =
236− let l = longestLengthZerosRun t
237− in (firstLongestZerosRunIndex t l,l)
238− where
239− firstLongestZerosRunIndex x y = sum . snd . unzip $ Prelude.takeWhile (/=(True,y)) x
240− longestLengthZerosRun x =
241− maximum $ map longest x
242− where longest t = case t of
243− (True,i) -> i
244− _ -> 0
245− zerosRunsList x = map helper $ groupZerosRuns x
246− where
247− helper h = (head h == AllZeros, lh) where lh = length h
248− groupZerosRuns = group . filter (/= Colon)
249−
250−ipv6TokensToIPv6Addr :: [IPv6AddrToken] -> Maybe IPv6Addr
251−ipv6TokensToIPv6Addr l = Just $ IPv6Addr $ ipv6TokensToText l
252−
253−fullSixteenBit :: T.Text -> Maybe IPv6AddrToken
254−fullSixteenBit t =
255− case parse ipv6AddrFullChunk t of
256− Done a b -> if a==T.empty then Just $ SixteenBit $ T.pack b else Nothing
257− _ -> Nothing
258−
259−macAddr :: Parser (Maybe [IPv6AddrToken])
260−macAddr = do
261− n1 <- count 2 hexaChar <* ":"
262− n2 <- count 2 hexaChar <* ":"
263− n3 <- count 2 hexaChar <* ":"
264− n4 <- count 2 hexaChar <* ":"
265− n5 <- count 2 hexaChar <* ":"
266− n6 <- count 2 hexaChar
267− return $ maybeIPv6AddrTokens $ T.pack $ concat [n1,n2,n3,n4,n5,n6]
268−
269−sixteenBit :: Parser IPv6AddrToken
270−sixteenBit = do
271− r <- ipv6AddrFullChunk <|> count 3 hexaChar <|> count 2 hexaChar <|> count 1 hexaChar
272− -- "Leading zeros MUST be suppressed" (RFC 5952, 4.1)
273− let r' = T.dropWhile (=='0') $ T.pack r
274− return $ if T.null r'
275− then AllZeros
276− -- Hexadecimal digits MUST be in lowercase (RFC 5952 4.3)
277− else SixteenBit $ T.toLower r'
278−
279−ipv4Addr :: Parser IPv6AddrToken
280−ipv4Addr = do
281− n1 <- manyDigits <* "."
282− if n1 /= T.empty
283− then do n2 <- manyDigits <* "."
284− if n2 /= T.empty
285− then do n3 <- manyDigits <* "."
286− if n3 /= T.empty
287− then do n4 <- manyDigits
288− if n4 /= T.empty
289− then return $ IPv4Addr $ T.intercalate "." [n1,n2,n3,n4]
290− else parserFailure
291− else parserFailure
292− else parserFailure
293− else parserFailure
294− where
295− parserFailure = fail "ipv4Addr parsing failure"
296− manyDigits = do
297− ds <- takeWhile1 isDigit
298− case R.decimal ds of
299− Right (n,_) -> return (if n < 256 then T.pack $ show n else T.empty)
300− Left _ -> return T.empty
301−
302−doubleColon :: Parser IPv6AddrToken
303−doubleColon = do
304− string "::"
305− return DoubleColon
306−
307−colon :: Parser IPv6AddrToken
308−colon = do
309− string ":"
310− return Colon
311−
312−ipv6AddrFullChunk :: Parser String
313−ipv6AddrFullChunk = count 4 hexaChar
314−
315−hexaChar :: Parser Char
316−hexaChar = satisfy (inClass "0-9a-fA-F")
tests/QC/IPv6/Types.hsdeleted−29
@@ -1,29 +0,0 @@
1−-- -----------------------------------------------------------------------------
2−
3−-- |
4−-- Module : Text.IPv6Addr
5−-- Copyright : Copyright © Michel Boucey 2011-2015
6−-- License : BSD-Style
7−-- Maintainer : michel.boucey@gmail.com
8−--
9−-- Dealing with IPv6 address text representations, canonization and manipulations.
10−--
11−
12−-- -----------------------------------------------------------------------------
13−
14−module QC.IPv6.Types where
15−
16−import qualified Data.Text as T
17−
18−data IPv6Addr = IPv6Addr T.Text
19−
20−instance Show IPv6Addr where
21− show (IPv6Addr addr) = T.unpack addr
22−
23−data IPv6AddrToken
24− = SixteenBit T.Text -- ^ A four hexadecimal digits group representing a 16-Bit chunk
25− | AllZeros -- ^ An all zeros 16-Bit chunk
26− | Colon -- ^ A separator between 16-Bit chunks
27− | DoubleColon -- ^ A double-colon stands for a unique compression of many consecutive 16-Bit chunks
28− | IPv4Addr T.Text -- ^ An embedded IPv4 address as representation of the last 32-Bit
29− deriving (Eq,Show)
tests/QC/Rechunked.hsdeleted−56
@@ -1,56 +0,0 @@
1−{-# LANGUAGE BangPatterns #-}
2−
3−module QC.Rechunked (
4− rechunkBS
5− , rechunkT
6− ) where
7−
8−import Control.Monad (forM, forM_)
9−import Control.Monad.ST (ST, runST)
10−import Data.List (unfoldr)
11−import Test.QuickCheck (Gen, choose)
12−import qualified Data.ByteString as B
13−import qualified Data.Text as T
14−import qualified Data.Vector as V
15−import qualified Data.Vector.Generic as G
16−import qualified Data.Vector.Generic.Mutable as M
17−
18−rechunkBS :: B.ByteString -> Gen [B.ByteString]
19−rechunkBS = fmap (map B.copy) . rechunk_ B.splitAt B.length
20−
21−rechunkT :: T.Text -> Gen [T.Text]
22−rechunkT = fmap (map T.copy) . rechunk_ T.splitAt T.length
23−
24−rechunk_ :: (Int -> a -> (a,a)) -> (a -> Int) -> a -> Gen [a]
25−rechunk_ split len xs = (unfoldr go . (,) xs) `fmap` rechunkSizes (len xs)
26− where go (b,r:rs) = Just (h, (t,rs))
27− where (h,t) = split r b
28− go (_,_) = Nothing
29−
30−rechunkSizes :: Int -> Gen [Int]
31−rechunkSizes n0 = shuffle =<< loop [] (0:repeat 1) n0
32− where loop _ [] _ = error "it's 2015, where's my Stream type?"
33− loop acc (lb:lbs) n
34− | n <= 0 = shuffle (reverse acc)
35− | otherwise = do
36− !i <- choose (lb,n)
37− loop (i:acc) lbs (n-i)
38−
39−shuffle :: [Int] -> Gen [Int]
40−shuffle (0:xs) = (0:) `fmap` shuffle xs
41−shuffle xs = fisherYates xs
42−
43−fisherYates :: [a] -> Gen [a]
44−fisherYates xs = (V.toList . V.backpermute v) `fmap` swapIndices (G.length v)
45− where
46− v = V.fromList xs
47− swapIndices n0 = do
48− swaps <- forM [0..n] $ \i -> ((,) i) `fmap` choose (i,n)
49− return (runST (swapAll swaps))
50− where
51− n = n0 - 1
52− swapAll :: [(Int,Int)] -> ST s (V.Vector Int)
53− swapAll ijs = do
54− mv <- G.unsafeThaw (G.enumFromTo 0 n :: V.Vector Int)
55− forM_ ijs $ uncurry (M.swap mv)
56− G.unsafeFreeze mv
tests/QC/Simple.hsdeleted−37
@@ -1,37 +0,0 @@
1−{-# LANGUAGE OverloadedStrings #-}
2−{-# OPTIONS_GHC -fno-warn-missing-signatures #-}
3−
4−module QC.Simple (
5− tests
6− ) where
7−
8−import Control.Applicative ((<|>))
9−import Data.ByteString (ByteString)
10−import Data.List (foldl')
11−import Data.Maybe (fromMaybe)
12−import QC.Rechunked (rechunkBS)
13−import Test.Tasty (TestTree)
14−import Test.Tasty.QuickCheck (testProperty)
15−import Test.QuickCheck (Property, counterexample, forAll)
16−import qualified Data.Attoparsec.ByteString.Char8 as A
17−
18−t_issue75 = expect issue75 "ab" (A.Done "" "b")
19−
20−issue75 :: A.Parser ByteString
21−issue75 = "a" >> ("b" <|> "")
22−
23−expect :: (Show r, Eq r) => A.Parser r -> ByteString -> A.Result r -> Property
24−expect p input wanted =
25− forAll (rechunkBS input) $ \in' ->
26− let result = parse p in'
27− in counterexample (show result ++ " /= " ++ show wanted) $
28− fromMaybe False (A.compareResults result wanted)
29−
30−parse :: A.Parser r -> [ByteString] -> A.Result r
31−parse p (x:xs) = foldl' A.feed (A.parse p x) xs
32−parse p [] = A.parse p ""
33−
34−tests :: [TestTree]
35−tests = [
36− testProperty "issue75" t_issue75
37− ]
tests/QC/Text.hs+74−151
@@ -1,86 +1,65 @@
1−{-# LANGUAGE BangPatterns, CPP, OverloadedStrings #-}
1+{-# LANGUAGE OverloadedStrings #-}
2−{-# OPTIONS_GHC -fno-warn-warnings-deprecations #-}
2+{-# OPTIONS_GHC -fno-warn-missing-signatures -fno-warn-orphans #-}
3module QC.Text (tests) where
3module QC.Text (tests) where
4
4
5−#if !MIN_VERSION_base(4,8,0)
6−import Control.Applicative ((<*>), (<$>))
5+import Control.Applicative ((<$>), (<*>))
7−#endif
8−import Data.Int (Int64)
9−import Data.Word (Word8)
10−import Prelude hiding (take, takeWhile)
6+import Prelude hiding (takeWhile)
11−import QC.Common (liftOp, parseT)
7+import Test.Framework.Providers.QuickCheck2 (testProperty)
12−import qualified QC.Text.FastSet as FastSet
13−import qualified QC.Text.Regressions as Regressions
14−import Test.Tasty (TestTree, testGroup)
15−import Test.Tasty.QuickCheck (testProperty)
16import Test.QuickCheck
8import Test.QuickCheck
9+import qualified Data.Char as Char
17import qualified Data.Attoparsec.Text as P
10import qualified Data.Attoparsec.Text as P
18import qualified Data.Attoparsec.Text.Lazy as PL
11import qualified Data.Attoparsec.Text.Lazy as PL
19−import qualified Data.Attoparsec.Text.FastSet as S
20−import qualified Data.ByteString as BS
21−import qualified Data.Char as Char
22import qualified Data.Text as T
12import qualified Data.Text as T
23−import qualified Data.Text.Encoding as TE
24import qualified Data.Text.Lazy as L
13import qualified Data.Text.Lazy as L
25
14
15+instance Arbitrary T.Text where
16+ arbitrary = T.pack <$> arbitrary
17+
18+instance Arbitrary L.Text where
19+ arbitrary = sized $ \n -> resize (round (sqrt (toEnum n :: Double)))
20+ ((L.fromChunks . map (T.pack . nonEmpty)) <$> arbitrary)
21+ where nonEmpty (NonEmpty a) = a
22+
23+-- Naming.
24+
25+{-
26+label (NonEmpty s) = case parse (anyChar <?> s) T.empty of
27+ (_, Left err) -> s `isInfixOf` err
28+ _ -> False
29+-}
30+
26-- Basic byte-level combinators.
31-- Basic byte-level combinators.
27
32
28−satisfy :: Char -> L.Text -> Property
33+maybeP p = PL.maybeResult . PL.parse p
29−satisfy w s = parseT (P.satisfy (<=w)) (L.cons w s) === Just w
30
34
31−satisfyWith :: Char -> L.Text -> Property
35+defP p = PL.parse p
32−satisfyWith c s = parseT (P.satisfyWith id (<=c)) (L.cons c s) === Just c
33
36
34−char :: Char -> L.Text -> Property
35−char w s = parseT (P.char w) (L.cons w s) === Just w
37+satisfy w s = maybeP (P.satisfy (<=w)) (L.cons w s) == Just w
36
38
37−skip :: Char -> L.Text -> Property
39+char w s = maybeP (P.char w) (L.cons w s) == Just w
38−skip w s =
39− case (parseT (P.skip (<w)) s, L.uncons s) of
40− (Nothing, mcs) -> maybe (property True) (expectFailure . it) mcs
41− (Just _, mcs) -> maybe (property False) it mcs
42− where it cs = liftOp "<" (<) (fst cs) w
43
40
44−anyChar :: L.Text -> Property
45anyChar s
41anyChar s
46− | L.null s = p === Nothing
42+ | L.null s = p == Nothing
47− | otherwise = p === Just (L.head s)
43+ | otherwise = p == Just (L.head s)
48− where p = parseT P.anyChar s
44+ where p = maybeP P.anyChar s
49
45
50−notChar :: Char -> NonEmptyList Char -> Property
51−notChar w (NonEmpty s) = parseT (P.notChar w) bs === if v == w
46+notChar w (NonEmpty s) = maybeP (P.notChar w) bs == if v == w
52 then Nothing
47 then Nothing
53 else Just v
48 else Just v
54 where v = L.head bs
49 where v = L.head bs
55 bs = L.pack s
50 bs = L.pack s
56
51
57−peekChar :: L.Text -> Property
58peekChar s
52peekChar s
59− | L.null s = p === Just (Nothing, s)
53+ | L.null s = p == Just (Nothing, s)
60− | otherwise = p === Just (Just (L.head s), s)
54+ | otherwise = p == Just (Just (L.head s), s)
61− where p = parseT ((,) <$> P.peekChar <*> P.takeLazyText) s
55+ where p = maybeP ((,) <$> P.peekChar <*> P.takeLazyText) s
62−
63−peekChar' :: L.Text -> Property
64−peekChar' s = parseT P.peekChar' s === (fst <$> L.uncons s)
65
56
66−string :: L.Text -> L.Text -> Property
67−string s t = parseT (P.string s') (s `L.append` t) === Just s'
57+string s t = maybeP (P.string s') (s `L.append` t) == Just s'
68 where s' = toStrict s
58 where s' = toStrict s
69
59
70−strings :: L.Text -> L.Text -> L.Text -> Property
71−strings s t u =
72− parseT (P.string (toStrict s) >> P.string t') (L.concat [s,t,u])
73− === Just t'
74− where t' = toStrict t
75−
76−-- | Note: "simple, and efficient" works for well formed input...
77−-- i.e. e.g. Latin1 texts
78−stringCI :: [Word8] -> Property
79−stringCI ws = P.parseOnly (P.stringCI fs) s === Right s
60+stringCI s = P.parseOnly (P.stringCI fs) s == Right s
80 where fs = T.toCaseFold s
61 where fs = T.toCaseFold s
81− s = TE.decodeLatin1 (BS.pack ws)
82
62
83−asciiCI :: T.Text -> Gen Bool
84asciiCI x =
63asciiCI x =
85 (\s i -> P.parseOnly (P.asciiCI s) i == Right i)
64 (\s i -> P.parseOnly (P.asciiCI s) i == Right i)
86 <$> maybeModifyCase x
65 <$> maybeModifyCase x
@@ -90,114 +69,58 @@ asciiCI x =
90 toLower = T.map (\c -> if c < Char.chr 127 then Char.toLower c else c)
69 toLower = T.map (\c -> if c < Char.chr 127 then Char.toLower c else c)
91 toUpper = T.map (\c -> if c < Char.chr 127 then Char.toUpper c else c)
70 toUpper = T.map (\c -> if c < Char.chr 127 then Char.toUpper c else c)
92
71
93−toStrict :: L.Text -> T.Text
94toStrict = T.concat . L.toChunks
72toStrict = T.concat . L.toChunks
95
73
96−skipWhile :: Char -> L.Text -> Property
97skipWhile w s =
74skipWhile w s =
98 let t = L.dropWhile (<=w) s
75 let t = L.dropWhile (<=w) s
99− in case PL.parse (P.skipWhile (<=w)) s of
76+ in case defP (P.skipWhile (<=w)) s of
100− PL.Done t' () -> t === t'
77+ PL.Done t' () -> t == t'
101− _ -> property False
78+ _ -> False
102−
103−take :: Int -> L.Text -> Property
104−take n s = maybe (liftOp "<" (<) (L.length s) (fromIntegral n))
105− (=== T.take n (toStrict s)) $
106− parseT (P.take n) s
107−
108−takeText :: L.Text -> Property
109−takeText s = maybe (property False) (=== toStrict s) . parseT P.takeText $ s
110−
111−takeLazyText :: L.Text -> Property
112−takeLazyText s = maybe (property False) (=== s) . parseT P.takeLazyText $ s
113
79
114−takeCount :: Positive Int -> L.Text -> Property
115takeCount (Positive k) s =
80takeCount (Positive k) s =
116− case parseT (P.take k) s of
81+ case maybeP (P.take k) s of
117− Nothing -> liftOp ">" (>) (fromIntegral k) (L.length s)
82+ Nothing -> fromIntegral k > L.length s
118− Just _s -> liftOp "<=" (<=) (fromIntegral k) (L.length s)
83+ Just s' -> fromIntegral k <= L.length s
119
84
120−takeWhile :: Char -> L.Text -> Property
121takeWhile w s =
85takeWhile w s =
122 let (h,t) = L.span (==w) s
86 let (h,t) = L.span (==w) s
123− in case PL.parse (P.takeWhile (==w)) s of
87+ in case defP (P.takeWhile (==w)) s of
124− PL.Done t' h' -> t === t' .&&. toStrict h === h'
88+ PL.Done t' h' -> t == t' && toStrict h == h'
125− _ -> property False
89+ _ -> False
126
90
127−takeWhile1 :: Char -> L.Text -> Property
128takeWhile1 w s =
91takeWhile1 w s =
129− let s' = L.cons w s
92+ let s' = L.cons w s
130− (h,t) = L.span (<=w) s'
93+ (h,t) = L.span (<=w) s'
131− in case PL.parse (P.takeWhile1 (<=w)) s' of
94+ in case defP (P.takeWhile1 (<=w)) s' of
132− PL.Done t' h' -> t === t' .&&. toStrict h === h'
95+ PL.Done t' h' -> t == t' && toStrict h == h'
133− _ -> property False
96+ _ -> False
134
97
135−takeTill :: Char -> L.Text -> Property
136takeTill w s =
98takeTill w s =
137 let (h,t) = L.break (==w) s
99 let (h,t) = L.break (==w) s
138− in case PL.parse (P.takeTill (==w)) s of
100+ in case defP (P.takeTill (==w)) s of
139− PL.Done t' h' -> t === t' .&&. toStrict h === h'
101+ PL.Done t' h' -> t == t' && toStrict h == h'
140− _ -> property False
102+ _ -> False
141−
103+
142−takeWhile1_empty :: Property
143−takeWhile1_empty = parseT (P.takeWhile1 undefined) L.empty === Nothing
104+takeWhile1_empty = maybeP (P.takeWhile1 undefined) L.empty == Nothing
144−
105+
145−endOfInput :: L.Text -> Property
146−endOfInput s = parseT P.endOfInput s === if L.null s
106+endOfInput s = maybeP P.endOfInput s == if L.null s
147− then Just ()
107+ then Just ()
148− else Nothing
149−
150−endOfLine :: L.Text -> Property
151−endOfLine s =
152− case (parseT P.endOfLine s, L.uncons s) of
153− (Nothing, mcs) -> maybe (property True) (expectFailure . eol) mcs
154− (Just _, mcs) -> maybe (property False) eol mcs
155− where eol (c,s') = c === '\n' .||.
156− (c, fst <$> L.uncons s') === ('\r', Just '\n')
157−
158−scan :: L.Text -> Positive Int64 -> Property
159−-- for some reason, if counterexample is removed, this test fails?
160−scan s (Positive k) = counterexample (show s)
161− $ parseT p s === Just (toStrict $ L.take k s)
162− where p = P.scan k $ \ n _ ->
163− if n > 0 then let !n' = n - 1 in Just n' else Nothing
108+ else Nothing
164−
109+
165−members :: String -> Property
166−members s = property $ all (`S.member` set) s
167− where set = S.fromList s
168−
169−nonmembers :: String -> String -> Property
170−nonmembers s s' = property . not . any (`S.member` set) $ filter (not . (`elem` s)) s'
171− where set = S.fromList s
172−
173−tests :: [TestTree]
174tests = [
110tests = [
175− testProperty "anyChar" anyChar
111+ testProperty "satisfy" satisfy,
176− , testProperty "asciiCI" asciiCI
177− , testProperty "char" char
112+ testProperty "char" char,
178− , testProperty "endOfInput" endOfInput
179− , testProperty "endOfLine" endOfLine
180− , testProperty "notChar" notChar
113+ testProperty "notChar" notChar,
181− , testProperty "peekChar" peekChar
182− , testProperty "peekChar'" peekChar'
114+ testProperty "anyChar" anyChar,
183− , testProperty "satisfy" satisfy
115+ testProperty "peekChar" peekChar,
184− , testProperty "satisfyWith" satisfyWith
185− , testProperty "scan" scan
186− , testProperty "skip" skip
187− , testProperty "skipWhile" skipWhile
188− , testProperty "string" string
116+ testProperty "string" string,
189− , testProperty "strings" strings
190− , testProperty "stringCI" stringCI
117+ testProperty "stringCI" stringCI,
191− , testProperty "take" take
118+ testProperty "asciiCI" asciiCI,
192− , testProperty "takeText" takeText
119+ testProperty "skipWhile" skipWhile,
193− , testProperty "takeCount" takeCount
120+ testProperty "takeCount" takeCount,
194− , testProperty "takeLazyText" takeLazyText
195− , testProperty "takeTill" takeTill
196− , testProperty "takeWhile" takeWhile
121+ testProperty "takeWhile" takeWhile,
197− , testProperty "takeWhile1" takeWhile1
122+ testProperty "takeWhile1" takeWhile1,
198− , testProperty "takeWhile1_empty" takeWhile1_empty
123+ testProperty "takeWhile1_empty" takeWhile1_empty,
199− , testProperty "members" members
200− , testProperty "nonmembers" nonmembers
124+ testProperty "takeTill" takeTill,
201− , testGroup "FastSet" FastSet.tests
125+ testProperty "endOfInput" endOfInput
202− , testGroup "Regressions" Regressions.tests
203 ]
126 ]
tests/QC/Text/FastSet.hsdeleted−15
@@ -1,15 +0,0 @@
1−module QC.Text.FastSet where
2−
3−import Test.Tasty (TestTree)
4−import Test.Tasty.QuickCheck (testProperty)
5−import Test.QuickCheck
6−import qualified Data.Attoparsec.Text.FastSet as FastSet
7−
8−membershipCorrect :: String -> String -> Property
9−membershipCorrect members others =
10− let fs = FastSet.fromList members
11− correct c = (c `FastSet.member` fs) == (c `elem` members)
12− in property $ all correct (members ++ others)
13−
14−tests :: [TestTree]
15−tests = [ testProperty "membership is correct" membershipCorrect ]
tests/QC/Text/Regressions.hsdeleted−54
@@ -1,54 +0,0 @@
1−{-# LANGUAGE OverloadedStrings #-}
2−
3−module QC.Text.Regressions (
4− tests
5− ) where
6−
7−import Data.Text (Text)
8−import qualified Data.Text as T
9−import Data.List (foldl')
10−import Data.Maybe (fromMaybe)
11−import Data.Char (isLower)
12−import Data.Monoid ((<>))
13−import QC.Rechunked (rechunkT)
14−import Test.Tasty (TestTree)
15−import Test.Tasty.QuickCheck (testProperty)
16−import Test.QuickCheck (Property, counterexample, forAll)
17−import qualified Data.Attoparsec.Text as A
18−
19−
20−--------------------------------------------------------------------------------
21−-- 105 was about runScanner not always returning the final state. The result
22−-- did depend on how the data was fed to the parser.
23−
24−t_issue105 :: Property
25−t_issue105 = expect issue105 "lowER" (A.Done "ER" "low")
26−
27−issue105 :: A.Parser Text
28−issue105 = do
29− (_, firstFourLowercaseLetters) <- A.runScanner "" f
30− return $ firstFourLowercaseLetters
31−
32− where
33− f :: Text -> Char -> Maybe Text
34− f acc c = if T.length acc < 4 && isLower c
35− then Just $ acc <> T.singleton c
36− else Nothing
37−
38−
39−expect :: (Show r, Eq r) => A.Parser r -> Text -> A.Result r -> Property
40−expect p input wanted =
41− forAll (rechunkT input) $ \in' ->
42− let result = parse p in'
43− in counterexample (show result ++ " /= " ++ show wanted) $
44− fromMaybe False (A.compareResults result wanted)
45−
46−parse :: A.Parser r -> [Text] -> A.Result r
47−parse p (x:xs) = foldl' A.feed (A.parse p x) xs
48−parse p [] = A.parse p ""
49−
50−
51−tests :: [TestTree]
52−tests = [
53− testProperty "issue105" t_issue105
54− ]
tests/TestFastSet.hsnew file+25
@@ -0,0 +1,25 @@
1+module Main (main) where
2+
3+import Data.Word (Word8)
4+import qualified Data.Attoparsec.FastSet as F
5+import System.Random (Random(..), RandomGen)
6+import Test.QuickCheck
7+
8+integralRandomR :: (Integral a, RandomGen g) => (a, a) -> g -> (a, g)
9+integralRandomR (a,b) g = case randomR (fromIntegral a :: Int,
10+ fromIntegral b :: Int) g
11+ of (x,g') -> (fromIntegral x, g')
12+
13+instance Random Word8 where
14+ randomR = integralRandomR
15+ random = randomR (minBound,maxBound)
16+
17+instance Arbitrary Word8 where
18+ arbitrary = choose (minBound, maxBound)
19+
20+prop_AllMembers s =
21+ let set = F.fromList s
22+ in all (`F.memberWord8` set) s
23+
24+main = do
25+ quickCheck prop_AllMembers