other-languages

here be heresies and things we have to use for work
borkdude 2017-12-01T11:42:57.000196Z

What did Rich Hickey mean with “types are parochial”? What does parochial mean in that context? I’m not a native speaker, but even looking it up in a dictionary doesn’t fully explain it to me.

borkdude 2017-12-01T11:45:54.000220Z

What I think he means: types force you to choose a name for a combination of attributes and attributes from different types don’t merge

borkdude 2017-12-01T11:46:01.000279Z

so the type “governs” the set of attributes?

borkdude 2017-12-01T14:10:41.000126Z

Pragmatic “app” monad in Haskell :thinking_face:

newtype AppM a = AppM (LoggingT (ReaderT Context (ExceptT AppError IO)) a)
    deriving ( Functor, Applicative, Monad, MonadIO
             , MonadError AppError, MonadReader Context, MonadLogger)
https://savanni.luminescent-dreams.com/page/haskell-app-monad

2017-12-01T15:52:55.000346Z

@borkdude that's my interpretation as well.

2017-12-01T15:53:45.000298Z

or as Brandon put it recently: https://twitter.com/BrandonBloom/status/935570873699909633

borkdude 2017-12-01T15:55:21.000028Z

I read the tweet also recently, but didn’t fully grok it

borkdude 2017-12-01T15:56:55.000283Z

but I recognize the feeling of “this would never be a problem in Clojure” when working with typed languages 😉

seancorfield 2017-12-01T18:19:11.000021Z

@borkdude Not sure if it helps but Rich means "parochial" in terms of "narrow scope or outlook" and I took it to mean that types are usually very focused and restrictive, so code is less reusable across domains -- compared to dynamically typed code that can operate on many different concrete types.

seancorfield 2017-12-01T18:21:01.000310Z

Specifically, when you define a class type to represent a data structure, you end up with a set of operations on that class type -- that cannot be used on similar data structures that have a different type. Whereas we have operations on "collections" and "sequences" because we use data instead of specific types of data.

seancorfield 2017-12-01T18:21:41.000556Z

I'd never thought of types that way until I heard Rich say it -- it was sort of a light bulb moment for me (which his talks often are).