summaryrefslogtreecommitdiff
path: root/doc/todo/type_level_port_conflict_detection.mdwn
diff options
context:
space:
mode:
authorJoey Hess2016-04-27 16:09:18 -0400
committerJoey Hess2016-04-27 16:09:18 -0400
commit6e09ae96c03ebc589ae9bb647e30de19fbe2f2e7 (patch)
treeebbd3059dade4848e1b45f85f3d905790733e3d6 /doc/todo/type_level_port_conflict_detection.mdwn
parent33da29496e1253550cac03675ce5435cda04ae8a (diff)
layout
Diffstat (limited to 'doc/todo/type_level_port_conflict_detection.mdwn')
-rw-r--r--doc/todo/type_level_port_conflict_detection.mdwn46
1 files changed, 23 insertions, 23 deletions
diff --git a/doc/todo/type_level_port_conflict_detection.mdwn b/doc/todo/type_level_port_conflict_detection.mdwn
index 8aa8d026..09d22a02 100644
--- a/doc/todo/type_level_port_conflict_detection.mdwn
+++ b/doc/todo/type_level_port_conflict_detection.mdwn
@@ -64,26 +64,26 @@ but it is not yet integrated into the Property types. --[[Joey]]
> > construct port singletons.)
> >
> > --[[Joey]]
-
-> > > A further problem with this is that it's not clear from the
-> > > `virtualHost` type signature that it needs to have a port applied to
-> > > it to get a usable property. So in a way, by adding this advanced
-> > > type safety, we've lost the most fundamental type safety of all:
-> > > Functions must have the right parameters applied!
-> > >
-> > > Well then, let's require a parameter.
-> > >
-> > > virtualHost :: Domain -> WebRoot -> Resource port -> RevertableProperty DebianLike DebianLike
-> > >
-> > > Make `Resource` only able to be constructed by `using`,
-> > > so the user must say:
-> > >
-> > > & virtualHost "example.com" "/var/www" `using` (port :: UsingPort 80)
-> > >
-> > > So the type of `using` would be something like:
-> > >
-> > > using :: (Resource r -> Property proptype) -> r -> Property (r + proptype)
-> > >
-> > > (Complicated some as it needs to also support RevertableProperty.)
-> > >
-> > > --[[Joey]]
+> >
+> > A further problem with this is that it's not clear from the
+> > `virtualHost` type signature that it needs to have a port applied to
+> > it to get a usable property. So in a way, by adding this advanced
+> > type safety, we've lost the most fundamental type safety of all:
+> > Functions must have the right parameters applied!
+> >
+> > Well then, let's require a parameter.
+> >
+> > virtualHost :: Domain -> WebRoot -> Resource port -> RevertableProperty DebianLike DebianLike
+> >
+> > Make `Resource` only able to be constructed by `using`,
+> > so the user must say:
+> >
+> > & virtualHost "example.com" "/var/www" `using` (port :: UsingPort 80)
+> >
+> > So the type of `using` would be something like:
+> >
+> > using :: (Resource r -> Property proptype) -> r -> Property (r + proptype)
+> >
+> > (Complicated some as it needs to also support RevertableProperty.)
+> >
+> > --[[Joey]]