This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[("GCC extra via C opts", " -fwrapv"), | |
("C compiler command", "i386-apple-darwin11-clang"), | |
("C compiler flags", " -U__i686 -fno-stack-protector"), | |
("C compiler link flags", ""), | |
("ld command", "i386-apple-darwin11-ld"), | |
("ld flags", ""), | |
("ld supports compact unwind", "YES"), | |
("ld supports build-id", "NO"), | |
("ld supports filelist", "YES"), | |
("ld is GNU ld", "NO"), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/Applications/Xcode.app/Contents/Developer/usr/bin/make -r --no-print-directory -f ghc.mk install BINDIST=YES NO_INCLUDE_DEPS=YES | |
/usr/local/bin/ginstall -c -m 755 -d "/usr/local/lib/i386-apple-darwin11-ghc-7.8.20140130/include" | |
/usr/local/bin/ginstall -c -m 755 -d "/usr/local/lib/i386-apple-darwin11-ghc-7.8.20140130/include/." && /usr/local/bin/ginstall -c -m 644 includes/./*.h "/usr/local/lib/i386-apple-darwin11-ghc-7.8.20140130/include/./" && /usr/local/bin/ginstall -c -m 755 -d "/usr/local/lib/i386-apple-darwin11-ghc-7.8.20140130/include/rts" && /usr/local/bin/ginstall -c -m 644 includes/rts/*.h "/usr/local/lib/i386-apple-darwin11-ghc-7.8.20140130/include/rts/" && /usr/local/bin/ginstall -c -m 755 -d "/usr/local/lib/i386-apple-darwin11-ghc-7.8.20140130/include/rts/prof" && /usr/local/bin/ginstall -c -m 644 includes/rts/prof/*.h "/usr/local/lib/i386-apple-darwin11-ghc-7.8.20140130/include/rts/prof/" && /usr/local/bin/ginstall -c -m 755 -d "/usr/local/lib/i386-apple-darwin11-ghc-7.8.20140130/includ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{-# OPTIONS -Wall #-} | |
module Main where | |
import Control.Concurrent (threadDelay) | |
import System.Environment (getArgs) | |
import System.INotify | |
main :: IO () | |
main = do |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{-# OPTIONS_GHC -fno-warn-orphans #-} | |
----------------------------------------------------------------------------- | |
-- | | |
-- Module : Text.Regex.Posix.String | |
-- Copyright : (c) Chris Kuklewicz 2006 | |
-- License : BSD-style (see the file LICENSE) | |
-- | |
-- Maintainer : [email protected], [email protected] | |
-- Stability : experimental | |
-- Portability : non-portable (regex-base needs MPTC+FD) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
------------------------------------------------------------------------------ | |
getVideo :: T.Text -> T.Text -> ByteString -> Maybe Video | |
getVideo ep defaultThumbnail rawJson = | |
rawJson ^? _Value . to (\o -> Video ep <$> | |
(o ^? key "id" . _Integer) <*> | |
(getThumbnail defaultThumbnail o) <*> | |
(o ^? key "user_id" . _Integer) <*> | |
(o ^? key "user" . key "first_name" . _String) <*> | |
(o ^? key "user" . key "last_name" . _String) <*> | |
(o ^? key "organization_id" . _Integer) <*> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
req' = def { | |
host = "user:[email protected]", | |
port = 443, | |
method = "POST", | |
responseTimeout = Just timeout, | |
requestHeaders = headers, | |
path = twilioPath, | |
requestBody = RequestBodyBS (C8.pack body), | |
secure = True } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defconst hub-pkg-conf | |
(let* ((hub-env (hub-get-sandbox))) | |
(if (string= "nohub" hub-env) | |
'() | |
'("-g" (make-hub-pkg-conf hub-env))))) | |
(eval | |
`(flycheck-define-checker haskell-ghc-mod | |
"A Haskell syntax and type checker using ghc-mod." | |
:command ("ghc-mod" "check" "-g" "-Wall" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{-# LANGUAGE RankNTypes #-} | |
module PML where | |
import Data.Functor.Identity | |
-- Poor Man Lenses | |
-- Implementation of SPJ's talk | |
-------------------------------------------------------------------------------- | |
type Lens' s a = forall f. (Functor f) => (a -> f a) -> s -> f s |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Test | |
public void GetRequestAsScalaFutureImmediateReturn2() throws Exception { | |
HttpClient client = new NingHttpClient(); | |
String fakeUrl = "http://httpbin.org/delay/20"; | |
ActorSystem system = ActorSystem.create("ScalaInterop"); | |
ExecutionContext executionContext = system.dispatcher(); | |
Future<HttpResponse> f = Async.toScalaFuture(client.GET(fakeUrl), executionContext); | |
System.out.println("Waiting 20 sec to give the time to the future to complete"); | |
Thread.sleep(20000); | |
System.out.println("I should succeed straight away now..."); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package org.cakesolutions.spray.can.examples; | |
import akka.actor.*; | |
import akka.io.IO; | |
import spray.can.Http; | |
import java.net.InetSocketAddress; | |
/** | |
* This example is a mixture of the barebone server here: |