it should be very easy and obvious

3 views
Skip to first unread message

Raoul Duke

unread,
Nov 17, 2021, 6:48:29 PM11/17/21
to pi...@googlegroups.com
how to pass ceil vs. floor unapplied functions to another function that wants to optionally use that operation if given. 

Raoul Duke

unread,
Nov 17, 2021, 7:11:57 PM11/17/21
to pi...@googlegroups.com
or to apply ceil etc. to a struct's relevant fields in some super concise ergonomic fun way. 

Mike Austin

unread,
Nov 17, 2021, 8:34:29 PM11/17/21
to PiLuD
floor and ceil have the same type signature, don't they? Are you talking C/Obj-C?

Raoul Duke

unread,
Nov 17, 2021, 9:21:49 PM11/17/21
to pi...@googlegroups.com
in a super statically typed language do they easily correctly automagically support all numeric types? :) swift ux. 

--
You received this message because you are subscribed to the Google Groups "PiLuD" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pilud+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pilud/f4d8228b-36a5-4f55-83b4-b29a98e8a714n%40googlegroups.com.

Mike Austin

unread,
Nov 18, 2021, 11:30:36 AM11/18/21
to PiLuD
Oh, I thought you were comparing just ceil to floor. Yes, the different signature with float, double, etc. are not compatible without generics.

Raoul Duke

unread,
Nov 18, 2021, 11:33:00 AM11/18/21
to pi...@googlegroups.com
and then swift makes it a nightmare to get to work because of how all
the protocol stuff works, and has cryptic error messages because of
other syntax "flexibility" that gets in the way so the error messages
end up being - as i like to describe swift - akin to a zen master
pointing a finger at the fart.
Reply all
Reply to author
Forward
0 new messages