View gist:30c23cf0956637c99f5b8a0a58ea5a78
object JNumber {
def apply(value: BigDecimal): JNumber = JNumber(value.toString)
def apply(value: BigInt): JNumber = JNumber(value.toString)
def apply(value: Byte): JNumber = JNumber(value.toString)
def apply(value: Double): JNumber = JNumber(value.toString)
def apply(value: Float): JNumber = JNumber(value.toString)
def apply(value: Int): JNumber = JNumber(value.toInt.toString)
def apply(value: Integer): JNumber = JNumber(value.toString)
def apply(value: Long): JNumber = JNumber(value.toString)
View BoolOp.hs
{-# LANGUAGE DeriveFunctor #-}
{-# LANGUAGE DeriveFoldable #-}
{-# LANGUAGE DeriveTraversable #-}
-- |
module Flare.AST.BoolOp where
import Control.Monad
import Control.Monad.Trans
import Data.List (intersperse)
View Board.hs.diff
diff --git a/src/Scrabble/Board/Board.hs b/src/Scrabble/Board/Board.hs
index 7741e22..a847ed1 100644
--- a/src/Scrabble/Board/Board.hs
+++ b/src/Scrabble/Board/Board.hs
@@ -25,30 +25,31 @@ module Scrabble.Board.Board
import Data.Aeson (ToJSON, FromJSON, toJSON, parseJSON, withArray)
import Data.Array (Array, listArray)
-import qualified Data.Array as A
+import Data.Bifunctor (second)
View boston-haskell-calendar.txt
April Talk 1: Austin Seipp
April Talk 2: ? (maybe lightning talks, or book someone else)
May Talk 1: Fere (François-René ÐVB Rideau)
May Talk 2: ? (maybe lightning talks, or book someone else)
June Talk 1: Maybe Nathan Howell (but possibly some other month, Ed needs to follow up)
June Talk 2 ?
Later:
View ip1.hs
{-# LANGUAGE GADTs, ConstraintKinds, Rank2Types, ImplicitParams #-}
data Rec fields where
Rec :: fields => Rec fields
infixr 1 ?
(?) :: Rec fields -> (fields => r) -> r
Rec ? e = e
record :: Rec (?a :: Int, ?b :: String)
View gist:ed7443d6d1f339e61e95
*ghci> g
Game {, [Josh rack: HXDOTQI score: 0id: 0] :| [[Nick rack: KGAITTE score: 0id: 1]], ______________________________________________
|3W| | |2L| | | |3W| | | |2L| | |3W|
| |2W| | | |3L| | | |3L| | | |2W| |
| | |2W| | | |2L| |2L| | | |2W| | |
|2L| | |2W| | | |2L| | | |2W| | |2L|
| | | | |2W| | | | | |2W| | | | |
| |3L| | | |3L| | | |3L| | | |3L| |
| | |2L| | | |2L| |2L| | | |2L| | |
|3W| | |2L| | | | *| | | |2L| | |3W|
View scrabble.ghci
$ stack ghci
*ghci> import Data.Aeson
*ghci> let g = unsafeNewGame [human "josh"]
*ghci> let g = unsafeNewGame [human "josh", human "nick"]
*ghci> g
Game {, [[josh rack: DOERUTO score: 0id: 0],[nick rack: ELIALIH score: 0id: 1]], ______________________________________________
|3W| | |2L| | | |3W| | | |2L| | |3W|
| |2W| | | |3L| | | |3L| | | |2W| |
| | |2W| | | |2L| |2L| | | |2W| | |
|2L| | |2W| | | |2L| | | |2W| | |2L|
View Mappy.scala
import scala.language.higherKinds
import scalaz.{Applicative, Traverse}
import scalaz.\/
import scalaz.std.list._
import scalaz.std.option._
import scalaz.syntax.either._
import scalaz.syntax.traverse._
object Mappy {
View HowDoICallEval.scala
//libraryDependencies += "org.scalaz" %% "scalaz-core" % "7.2.0"
import scala.language.higherKinds
import scalaz.{MonadState, MonadListen, MonadReader, MonadError, \/}
import scalaz.std.list._
// All I want to do in this code is invoke the eval function. That's it.
// This code compiles, so it's close, just needs the finishing touch.
object HowDoICallEval {