Comments (3)
Option's MonadError only works with Unit
error types, as we saw early on that it cannot be implemented by a lossy constructors that'd throw that String
or any other error type away. It won't pass the MonadError tests.
from arrow-core.
Thanks for answering that quick.
When you mean
as we saw early on that it cannot be implemented by a lossy constructors
where that has been describe?
Also I am sorry as new to arrow I am not understanding the
Option's MonadError only works with Unit error types
Could you please provide an example based on the code I put above for being clearer.
Thanks in advance
from arrow-core.
Could you please provide an example based on the code I put above for being clearer.
This is what Option would work with:
private val objectGateway: objectGateway = object : ObjectGateway {
override fun <F> getObject1(number: String, ME: MonadError<F, Unit>): Kind<F, String> {
return ME.just("NUMBER")
}
override fun <F> getObject2(number: String, anotherNumber: String, ME: MonadError<F, Unit>): Kind<F, Int> {
return ME.raiseError(Unit)
}
}
Option
has a MonadError<ForOption, Unit>
, meaning that you can only build None
with Unit
. You cannot build None
with an associated String
or DummyException
.
where that has been describe?
In the arrow-contributors channel, early on meaning around 2017 :D
from arrow-core.
Related Issues (20)
- BUILD: error when integrating 'Deprecate @higherkind & @extension for TupleN (#292)' with the rest of Arrow libraries
- BUILD: error when integrating 'Deprecate extension methods for NonEmptyList (#304)' with the rest of Arrow libraries
- BUILD: error when merging 'Deprecate extensions methods for Set and SetK (#299)' on master branch
- DOC: error when integrating 'Fix incorrect package new instances (#306)' with the rest of Arrow libraries
- BUILD: error when integrating 'CU-cew8k0 Remove Deprecated `Id<A>` data type. (#291)' with the rest of Arrow libraries
- BUILD: error when merging 'CU-cn28ya Deprecate @higherkind & @extension for Ior (#317)' on master branch
- BUILD: error when integrating 'Deprecates Kind and its associated type class types. (#281)' with the rest of Arrow libraries
- BUILD: error when integrating 'Deprecates Kind and its associated type class types. (#281)' with the rest of Arrow libraries
- BUILD: error when integrating 'Deprecate Show (#321)' with the rest of Arrow libraries
- BUILD: error when merging 'Deprecate Eq (#322)' on master branch HOT 1
- BUILD: error when integrating 'CU-cn24b4 Remove extension and higherkind annotations for Const (#315)' with the rest of Arrow libraries
- BUILD: error when integrating 'CU-cn24b4 Remove extension and higherkind annotations for Const (#315)' with the rest of Arrow libraries
- BUILD: error when integrating 'Fix typo in deprecation messages (#335)' with the rest of Arrow libraries
- BUILD: error when merging 'Unify syntax for extracting inner values (#338)' on master branch
- BUILD: error when integrating 'Deprecate Hash (#337)' with the rest of Arrow libraries
- DOC: error when merging 'Make memoization compatible with MPP (#331)' on master branch HOT 1
- BUILD: error when merging 'Make memoization compatible with MPP (#331)' on master branch HOT 2
- BUILD: error when merging 'Make memoization compatible with MPP (#331)' on master branch
- BUILD: error when merging 'Make memoization compatible with MPP (#331)' on master branch HOT 2
- BUILD: error when integrating 'Publication: disable checksums for maven-metadata.xml (#354)' with the rest of Arrow libraries HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from arrow-core.