@effect/io
Advanced tools
Comparing version 0.0.3 to 0.0.4
@@ -324,20 +324,6 @@ "use strict"; | ||
exports.stripSomeDefects = stripSomeDefects; | ||
const as = error => { | ||
return self => { | ||
if (self._tag === "Fail") { | ||
return fail(error); | ||
} | ||
return self; | ||
}; | ||
}; | ||
const as = error => self => map(() => error)(self); | ||
/** @internal */ | ||
exports.as = as; | ||
const map = f => { | ||
return self => { | ||
if (self._tag === "Fail") { | ||
return fail(f(self.error)); | ||
} | ||
return self; | ||
}; | ||
}; | ||
const map = f => self => flatMap(e => fail(f(e)))(self); | ||
// ----------------------------------------------------------------------------- | ||
@@ -348,10 +334,3 @@ // Sequencing | ||
exports.map = map; | ||
const flatMap = f => { | ||
return self => { | ||
if (self._tag === "Fail") { | ||
return f(self.error); | ||
} | ||
return self; | ||
}; | ||
}; | ||
const flatMap = f => self => match(empty, error => f(error), defect => die(defect), fiberId => interrupt(fiberId), (cause, annotation) => annotated(cause, annotation), (left, right) => sequential(left, right), (left, right) => parallel(left, right))(self); | ||
/** @internal */ | ||
@@ -358,0 +337,0 @@ exports.flatMap = flatMap; |
{ | ||
"name": "@effect/io", | ||
"version": "0.0.3", | ||
"version": "0.0.4", | ||
"license": "MIT", | ||
@@ -5,0 +5,0 @@ "repository": { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
3960381
65899