Skip to Content.
Sympa Menu

sm-discuss - Re: [SM-Discuss] multiple depends in one line

sm-discuss AT lists.ibiblio.org

Subject: Public SourceMage Discussion List

List archive

Chronological Thread  
  • From: seth AT swoolley.homeip.net
  • To: Juuso Alasuutari <iuso AT sourcemage.org>
  • Cc: sm-discuss AT lists.ibiblio.org
  • Subject: Re: [SM-Discuss] multiple depends in one line
  • Date: Fri, 18 Aug 2006 09:54:17 -0700

On Fri, Aug 18, 2006 at 10:42:59AM +0300, Juuso Alasuutari wrote:
> On Friday 18 August 2006 10:30, seth AT swoolley.homeip.net wrote:
> > What kind of behavior do you want, that a single prompt supports both, or
> > two separate ones?
> >
> > Is it single-pole double-throw or double-pole double-throw?
>
> This figure of speech I'm afraid I don't understand. What I'd like to see
> is
> the possibility to optionally depend on several spells with a single
> prompt,
> but I take it you already know this much. I'm probably missing the point of
> your question, could you please clarify?

I was just asking if it should prompt twice or once. SPDT/DPDT is an
electronics term for different behaviors a double-throwing switch can
have: (my best 3d representation:)

DPDT SPDT
+ +
/ /|
---o o--- ---o |o---
|
+ or +
/ /
---o o--- ---o o---

do the / switches operate together or independently? if independently
it is called "double pole" the user can throw the switches regardless of
the state of the other. If not independently, it is called "single
pole", the user has one master switch which controls both switches.

Of course, I'm not talking about the three or more case. You're talking
about single-pole-multi-throw as what you want.

>
> > As with any misfeature, it's good to make sure it's really operating
> > desirably.
> >
> > Personally, I see little reason to support this feature.
>
> I do see use for it (as do apparently some others who've replied to this
> thread). One example is what I mentioned in an earlier posting. Basically
> every spell that now has the clumsy 'config_query VAR; if [[ $VAR == y ]];
> then depends x; depends, y; depends z; fi' procedure would benefit.
>
> My knowledge about Sorcery's internals is vague and I might be
> over-simplifying, but I'm guessing that this accidental feature wouldn't
> require too much work to become actually usable.

As I replied in the other thread, a wrapper function would be the best
style. sorcery is the kernel -- the kernel should be abstract,
functional, and small enough to audit.




Archive powered by MHonArc 2.6.24.

Top of Page