Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!dali.cs.montana.edu!uakari.primate.wisc.edu!zaphod.mps.ohio-state.edu!usc!elroy.jpl.nasa.gov!turnkey!ladcgw.ladc.bull.com!melb.bull.oz.au!sjg From: sjg@melb.bull.oz.au (Simon J. Gerraty) Newsgroups: comp.mail.sendmail Subject: LHS map lookup. Missing feature in IDA sendmail? Message-ID: <1991Jun3.090222.13897@melb.bull.oz.au> Date: 3 Jun 91 09:02:22 GMT Sender: news@melb.bull.oz.au (USENET News Account) Organization: Bull HN Information Systems Australia. Lines: 34 Nntp-Posting-Host: sun0 In the process of building/testing sendmail-5.65+IDA, I seem to have come accross a need for a new feature. The $(x key $@ arg $: default $) feature is _just_ what I have always wanted on the RHS of a re-write rule. However I am used to having Sun's $%x and $!x features for checking a key in a map in the LHS of the rules. Ie. I want to be able to have a rule match iff a key is present in a map, or iff a key is NOT present in a map. Then I'd like to be able to make use of the lookup feature. This seems such a fundamental requirement - that obviously I'm not thinking right. Could some one please: 1/ mail me an example of how the current IDA features can be used to replace something like: R$*<@$%Y>$* $#ether $@$2 $:$1<@$2>$3 user@etherhost 2/ let me know whether someone else has already done this. 3/ set me straight :-) Its been a busy few weeks, so please flame > /dev/null if I'm obviously not thinking properly :-) Thanks! -- Simon J. Gerraty (work) (home) #include /* imagine something *very* witty here */